This is an automated email from the git hooks/post-receive script. New commit to branch develop in repository pollen. See http://git.chorem.org/pollen.git commit 036512a2c647c1d7695b1edcc8fa16cca4cf2a39 Author: Adrien Garandel <a.garandel@dralagen.fr> Date: Fri Aug 8 16:55:31 2014 +0200 stop event for popup editChoice, edit transition popup --- pollen-ui-angular/src/main/webapp/js/controllers/pollCtrl.js | 6 +++++- pollen-ui-angular/src/main/webapp/less/style.less | 6 ++++++ pollen-ui-angular/src/main/webapp/less/variables.less | 3 ++- pollen-ui-angular/src/main/webapp/partials/inline-poll.html | 10 +++++----- 4 files changed, 18 insertions(+), 7 deletions(-) diff --git a/pollen-ui-angular/src/main/webapp/js/controllers/pollCtrl.js b/pollen-ui-angular/src/main/webapp/js/controllers/pollCtrl.js index 125cdb7..bc82cc7 100644 --- a/pollen-ui-angular/src/main/webapp/js/controllers/pollCtrl.js +++ b/pollen-ui-angular/src/main/webapp/js/controllers/pollCtrl.js @@ -432,8 +432,12 @@ angular.module('pollControllers', ['ngRoute', 'pollenServices', 'pascalprecht.tr popupChoice(choice, 'Ajout d\'un Choix'); } - $scope.editChoice = function (choice) { + $scope.editChoice = function (choice, e) { popupChoice(choice, 'Edition du Choix'); + if (e) { + e.stopPropagation(); + e.preventDefault(); + } } diff --git a/pollen-ui-angular/src/main/webapp/less/style.less b/pollen-ui-angular/src/main/webapp/less/style.less index 713be4c..59e1e95 100644 --- a/pollen-ui-angular/src/main/webapp/less/style.less +++ b/pollen-ui-angular/src/main/webapp/less/style.less @@ -609,3 +609,9 @@ footer { } } } + +.modal { + &.fade .modal-dialog { + .translate(0, 0); + } +} \ No newline at end of file diff --git a/pollen-ui-angular/src/main/webapp/less/variables.less b/pollen-ui-angular/src/main/webapp/less/variables.less index c823952..2ff3a53 100644 --- a/pollen-ui-angular/src/main/webapp/less/variables.less +++ b/pollen-ui-angular/src/main/webapp/less/variables.less @@ -20,6 +20,7 @@ */ @import "../lib/bootstrap/less/variables.less"; +@import "../lib/bootstrap/less/mixins.less"; @time-transition : 0.8s; @short-time-transition : 0.2s; @@ -112,4 +113,4 @@ } } -} \ No newline at end of file +} diff --git a/pollen-ui-angular/src/main/webapp/partials/inline-poll.html b/pollen-ui-angular/src/main/webapp/partials/inline-poll.html index 4ecd5fa..1da8c67 100644 --- a/pollen-ui-angular/src/main/webapp/partials/inline-poll.html +++ b/pollen-ui-angular/src/main/webapp/partials/inline-poll.html @@ -30,28 +30,28 @@ <div ng-hide="showEdit && ((data.poll.addChoiceAllowed && (choice.permission || !choice.id)) || globalVariables.editMode)" class="fixe-input" title="{{choice.description}}"> {{ choice.choiceValue || ('poll.edit' | translate) }} <info-error error="choice.restError.choiceValue[0]" data="choice.choiceValue"></info-error> - <input type="button" class="btn btn-default" ng-if="(data.poll.choiceAddAllowed && (choice.permission || !choice.id)) || globalVariables.editMode" ng-show="showEditHover" ng-click="editChoice(choice)" value="..."/></div> + <input type="button" class="btn btn-default" ng-if="(data.poll.choiceAddAllowed && (choice.permission || !choice.id)) || globalVariables.editMode" ng-show="showEditHover" ng-click="editChoice(choice, $event);" value="..."/></div> <div ng-show="showEdit && ((data.poll.addChoiceAllowed && (choice.permission || !choice.id)) || globalVariables.editMode)"> <input type="text" class="form-control" ng-model="choice.choiceValue" focus-me="showEdit" ng-exit="showEdit = false;" auto-save="saveChoice(choice)" required/> - <input type="button" class="btn btn-default" data-toggle="modal" data-target="#popupAddChoice" ng-click="editChoice(choice)" value="..."/> + <input type="button" class="btn btn-default" data-toggle="modal" data-target="#popupAddChoice" ng-click="editChoice(choice, $event);" value="..."/> </div> </div> <div ng-if="choice.choiceType == 'DATE'" edit-me="showEdit" > <div ng-hide="showEdit && (data.poll.addChoiceAllowed && (choice.permission || !choice.id) || globalVariables.editMode)" class="fixe-input" title="{{choice.description}}"> {{ (choice.choiceValue | date:globalVariables.dateTimeFormat) || ('poll.edit' | translate) }} <info-error error="choice.restError.choiceValue[0]" data="choice.choiceValue"></info-error> - <input type="button" class="btn btn-default" ng-if="(data.poll.choiceAddAllowed && (choice.permission || !choice.id)) || globalVariables.editMode" ng-show="showEditHover" ng-click="editChoice(choice)" value="..."/> + <input type="button" class="btn btn-default" ng-if="(data.poll.choiceAddAllowed && (choice.permission || !choice.id)) || globalVariables.editMode" ng-show="showEditHover" ng-click="editChoice(choice, $event);" value="..."/> </div> <div ng-show="showEdit && (data.poll.choiceAddAllowed && (choice.permission || !choice.id) || globalVariables.editMode)" > <datetimepicker ng-model="choice.choiceValue" focus="showEdit" ng-exit="showEdit = false" ng-save="saveChoice(choice)"></datetimepicker> - <input type="button" class="btn btn-default" data-toggle="modal" data-target="#popupAddChoice" ng-click="editChoice(choice)" value="..."/> + <input type="button" class="btn btn-default" data-toggle="modal" data-target="#popupAddChoice" ng-click="editChoice(choice, $event);" value="..."/> </div> </div> <div ng-if="choice.choiceType == 'RESOURCE'"> <div class="fixe-input" title="{{choice.description}}"> {{choice.choiceValue.meta.name}} <info-error error="choice.restError.choiceValue[0]" data="choice.choiceValue"></info-error> - <input type="button" class="btn btn-default" ng-if="data.poll.choiceAddAllowed && (choice.permission || !choice.id) || globalVariables.editMode" ng-show="showEditHover" ng-click="editChoice(choice)" value="..."/> + <input type="button" class="btn btn-default" ng-if="data.poll.choiceAddAllowed && (choice.permission || !choice.id) || globalVariables.editMode" ng-show="showEditHover" ng-click="editChoice(choice, $event);" value="..."/> <br/> <print-resource image="choice.choiceValue.id" name="choice.choiceValue.meta.name"></print-resource> -- To stop receiving notification emails like this one, please contact chorem.org SCM administrator <admin+scm@chorem.org>.