Al crear no se comprueba la introducción de los datos
This commit is contained in:
parent
915bb464cb
commit
b68760d0ae
|
@ -18,4 +18,3 @@
|
||||||
</vn-vertical>
|
</vn-vertical>
|
||||||
</vn-card>
|
</vn-card>
|
||||||
</form>
|
</form>
|
||||||
<vn-confirm-client client="create.model" client-old="create.model" state="create.state"></vn-confirm-client>
|
|
||||||
|
|
|
@ -7,11 +7,12 @@ export const COMPONENT = {
|
||||||
controllerAs: "create",
|
controllerAs: "create",
|
||||||
controller: function($http, $state) {
|
controller: function($http, $state) {
|
||||||
this.submit = function() {
|
this.submit = function() {
|
||||||
|
this.model.active = true;
|
||||||
$http.post('/client/api/Clients', this.model).then(
|
$http.post('/client/api/Clients', this.model).then(
|
||||||
json => $state.go('clientCard.basicData', {id: json.data.id})
|
json => $state.go('clientCard.basicData', {id: json.data.id})
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
COMPONENT.controller.$inject = ["$http", "$state"];
|
COMPONENT.controller.$inject = ['$http', '$state'];
|
||||||
module.component(NAME, COMPONENT);
|
module.component(NAME, COMPONENT);
|
||||||
|
|
Loading…
Reference in New Issue