From 1607a340d223aded470b7b9ebe3e45df9a28ec8b Mon Sep 17 00:00:00 2001 From: Bernat Date: Thu, 11 Oct 2018 10:56:28 +0200 Subject: [PATCH 1/2] new model defaulter --- services/client/common/models/defaulter.json | 32 ++++++++++++++++++++ services/client/server/model-config.json | 3 ++ 2 files changed, 35 insertions(+) create mode 100644 services/client/common/models/defaulter.json diff --git a/services/client/common/models/defaulter.json b/services/client/common/models/defaulter.json new file mode 100644 index 000000000..d6d510df7 --- /dev/null +++ b/services/client/common/models/defaulter.json @@ -0,0 +1,32 @@ +{ + "name": "Defaulter", + "description": "defaulters client", + "base": "VnModel", + "options": { + "mysql": { + "table": "defaulter", + "database": "vn" + } + }, + "properties": { + "created": { + "type": "Date" + }, + "amount": { + "type": "Number" + }, + "defaulterSinced": { + "type": "Number" + }, + "hasChanged": { + "type": "Number" + } + }, + "relations": { + "client": { + "type": "belongsTo", + "model": "Client", + "foreignKey": "clientFk" + } + } +} \ No newline at end of file diff --git a/services/client/server/model-config.json b/services/client/server/model-config.json index a61abc531..1c8d68889 100644 --- a/services/client/server/model-config.json +++ b/services/client/server/model-config.json @@ -52,5 +52,8 @@ }, "TpvResponse": { "dataSource": "hedera" + }, + "Defaulter": { + "dataSource": "vn" } } From f80c9134e190937430e24d744684d27cc02eac7f Mon Sep 17 00:00:00 2001 From: Bernat Date: Thu, 11 Oct 2018 11:01:58 +0200 Subject: [PATCH 2/2] update acl --- services/db/install/changes/1.2-CHECK/06.ACL.sql | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/services/db/install/changes/1.2-CHECK/06.ACL.sql b/services/db/install/changes/1.2-CHECK/06.ACL.sql index e33b1683a..ffb794099 100644 --- a/services/db/install/changes/1.2-CHECK/06.ACL.sql +++ b/services/db/install/changes/1.2-CHECK/06.ACL.sql @@ -7,8 +7,8 @@ VALUES (108, 'ItemPlacement', '*', 'WRITE', 'ALLOW', 'ROLE', 'marketingBoss'), (109, 'UserConfig', '*', '*', 'ALLOW', 'ROLE', 'employee'), (110, 'Bank', '*', 'READ', 'ALLOW', 'ROLE', 'employee'), -(111, 'ClientLog', '*', 'READ', 'ALLOW', 'ROLE', 'employee'); - +(111, 'ClientLog', '*', 'READ', 'ALLOW', 'ROLE', 'employee'), +(112, 'Defaulter', '*', 'READ', 'ALLOW', 'ROLE', 'employee'); UPDATE salix.ACL SET model='ItemTag', property='*', accessType='WRITE', permission='ALLOW', principalType='ROLE', principalId='marketingBoss' WHERE id=52; \ No newline at end of file