Merge pull request #2699 from normanjaeckel/TrivialChange

Fixed trivial change (disable versioning) checkboxes.
This commit is contained in:
Emanuel Schütze 2016-11-30 21:39:50 +01:00 committed by GitHub
commit 5ab8b3172b
2 changed files with 4 additions and 8 deletions

View File

@ -78,10 +78,6 @@ angular.module('OpenSlidesApp.motions.motionservices', ['OpenSlidesApp.motions',
motion = _motion;
obj.lineBrokenText = motion.getTextWithLineBreaks($scope.version);
obj.originalHtml = obj.lineBrokenText;
if (motion.state.versioning && Config.get('motions_allow_disable_versioning').value) {
obj.trivialChange = true;
}
};

View File

@ -1433,6 +1433,7 @@ angular.module('OpenSlidesApp.motions.site', [
// set initial values for form model by create deep copy of motion object
// so list/detail view is not updated while editing
$scope.model = angular.copy(motion);
$scope.model.disable_versioning = false;
$scope.model.more = false;
// get all form fields
@ -1455,10 +1456,9 @@ angular.module('OpenSlidesApp.motions.site', [
// get reason of latest version
$scope.formFields[i].defaultValue = motion.getReason(-1);
}
if ($scope.formFields[i].key == "disable_versioning" &&
Config.get('motions_allow_disable_versioning')) {
// check current state if versioning is active
if (motion.state.versioning) {
if ($scope.formFields[i].key == "disable_versioning") {
if (Config.get('motions_allow_disable_versioning').value && motion.state.versioning) {
// check current state if versioning is active
$scope.formFields[i].hide = false;
}
}