From eab5af19b5b70ae48ae4f9b73c25b2f3277334d6 Mon Sep 17 00:00:00 2001 From: jgallego Date: Wed, 18 Jan 2017 12:02:02 +0100 Subject: [PATCH] webAcces guarda --- @salix/crud/src/client/web-access/index.html | 8 ++++---- @salix/crud/src/client/web-access/index.js | 2 +- db.json | 9 +++++---- 3 files changed, 10 insertions(+), 9 deletions(-) diff --git a/@salix/crud/src/client/web-access/index.html b/@salix/crud/src/client/web-access/index.html index ea06062cc..355e33246 100644 --- a/@salix/crud/src/client/web-access/index.html +++ b/@salix/crud/src/client/web-access/index.html @@ -2,13 +2,13 @@ Web access - - + + - - + + diff --git a/@salix/crud/src/client/web-access/index.js b/@salix/crud/src/client/web-access/index.js index de7d2216e..938fdb1da 100644 --- a/@salix/crud/src/client/web-access/index.js +++ b/@salix/crud/src/client/web-access/index.js @@ -15,7 +15,7 @@ export const COMPONENT = { this.submit = function() { if (!equalsObject(this.account, this.accountOld)) { this.client.modify = "WebAccess"; - $http.put(`/client/api/Accounts/${this.account.id}`, this.account).then( + $http.put('/client/api/Accounts', this.account).then( json => { this.account = json.data; self.copyAccount(); diff --git a/db.json b/db.json index 598279613..36dd6cd63 100644 --- a/db.json +++ b/db.json @@ -9,7 +9,7 @@ "Country": 3, "Province": 3, "Agency": 4, - "Account": 15, + "Account": 19, "ClientObservation": 1265 }, "models": { @@ -53,9 +53,10 @@ "3": "{\"name\":\"DHL\",\"id\":3}" }, "Account": { - "1": "{\"id\":1,\"password\":\"12\"}", - "12": "{\"id\":12,\"name\":\"prueba12\",\"active\":true,\"user\":\"juanete\"}", - "13": "{\"id\":13,\"name\":\"manu\",\"active\":false,\"user\":\"joselito\"}" + "1": "{\"id\":1,\"password\":\"joselito\",\"name\":\"asdf\"}", + "12": "{\"id\":12,\"name\":\"\",\"active\":true}", + "14": "{\"id\":14,\"name\":\"us14\",\"active\":false}", + "15": "{\"id\":15,\"name\":\"asdf\"}" }, "ClientObservation": { "1258": "{\"text\":\"Nota de prueba 1\",\"creationDate\":\"2017-01-17T15:24:23.320Z\",\"client\":12,\"salesPerson\":\"user\",\"id\":1258}",