fixes #183: clear new ticket fields

This commit is contained in:
Davide Alberani 2017-05-07 14:58:18 +02:00
parent d244694dc9
commit 405c92903c

View file

@ -634,6 +634,7 @@ eventManControllers.controller('EventTicketsCtrl', ['$scope', '$state', 'Event',
};
$scope.submitForm = function(dataModelSubmitted) {
$scope.ticket = {_id: $scope.ticket._id};
angular.forEach(dataModelSubmitted, function(value, key) {
key = $scope.formFieldsMap[key] || key;
$scope.ticket[key] = value;