|
|
|
|
@ -2,6 +2,8 @@
|
|
|
|
|
{
|
|
|
|
|
$scope.globals = globals;
|
|
|
|
|
|
|
|
|
|
//$scope.isNewRecord = false;
|
|
|
|
|
|
|
|
|
|
$scope.descricao = null;
|
|
|
|
|
|
|
|
|
|
$scope.calculatedAge = 0;
|
|
|
|
|
@ -88,7 +90,14 @@
|
|
|
|
|
$scope.editing.ficha.data_conclusao = null;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$scope.storeFichasClinicas.upsert($scope.selected, $scope.editing, function(response, selected, editing, isNewRecord){
|
|
|
|
|
//var isNewRecord = $scope.editing.ficha.id == null;
|
|
|
|
|
|
|
|
|
|
$scope.storeFichasClinicas.upsert($scope.selected, $scope.editing, function(response, selected, editing){
|
|
|
|
|
|
|
|
|
|
//if(isNewRecord && response.success)
|
|
|
|
|
//{
|
|
|
|
|
// $scope.isNewRecord = true;
|
|
|
|
|
//}
|
|
|
|
|
|
|
|
|
|
if(response.success && complete)
|
|
|
|
|
{
|
|
|
|
|
@ -189,6 +198,7 @@
|
|
|
|
|
|
|
|
|
|
$scope.$parent.loadModule({Controller: 'Search'}, function(className, scope, isNewModule){
|
|
|
|
|
|
|
|
|
|
angular.element(scope.comboTrabalhadores.domEl).triggerHandler('change');
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
@ -196,6 +206,7 @@
|
|
|
|
|
label: 'Gravar',
|
|
|
|
|
className: 'btn-success',
|
|
|
|
|
callback: function() {
|
|
|
|
|
|
|
|
|
|
$scope.save(false);
|
|
|
|
|
|
|
|
|
|
globals.plugins.hideSideMenu();
|
|
|
|
|
|