From f8bb4d86fbfc4fa3f65b4df99f8458ea87623429 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joan=20S=C3=A1nchez?= Date: Mon, 7 Sep 2020 08:15:43 +0200 Subject: [PATCH] State fix & supplier search fix --- modules/entry/front/basic-data/index.html | 0 modules/entry/front/basic-data/index.js | 10 ++++++++++ modules/entry/front/create/index.html | 2 +- modules/entry/front/routes.json | 9 +++++++++ 4 files changed, 20 insertions(+), 1 deletion(-) create mode 100644 modules/entry/front/basic-data/index.html create mode 100644 modules/entry/front/basic-data/index.js diff --git a/modules/entry/front/basic-data/index.html b/modules/entry/front/basic-data/index.html new file mode 100644 index 000000000..e69de29bb diff --git a/modules/entry/front/basic-data/index.js b/modules/entry/front/basic-data/index.js new file mode 100644 index 000000000..141a365fa --- /dev/null +++ b/modules/entry/front/basic-data/index.js @@ -0,0 +1,10 @@ +import ngModule from '../module'; +import Section from 'salix/components/section'; + +ngModule.vnComponent('vnEntryBasicData', { + template: require('./index.html'), + controller: Section, + bindings: { + entry: '<' + } +}); diff --git a/modules/entry/front/create/index.html b/modules/entry/front/create/index.html index 77fd92d55..7b5dfc928 100644 --- a/modules/entry/front/create/index.html +++ b/modules/entry/front/create/index.html @@ -17,7 +17,7 @@ ng-model="$ctrl.entry.supplierFk" url="Suppliers" show-field="nickname" - search-function="{or: [{id: $search}, {name: {like: '%'+ $search +'%'}}]}" + search-function="{or: [{id: $search}, {nickname: {like: '%'+ $search +'%'}}]}" value-field="id" order="nickname" label="Supplier" diff --git a/modules/entry/front/routes.json b/modules/entry/front/routes.json index 09a29db76..a430a95fa 100644 --- a/modules/entry/front/routes.json +++ b/modules/entry/front/routes.json @@ -10,6 +10,7 @@ {"state": "entry.latestBuys", "icon": "icon-latestBuys"} ], "card": [ + {"state": "entry.card.basicData", "icon": "settings"}, {"state": "entry.card.buy", "icon": "icon-lines"}, {"state": "entry.card.log", "icon": "history"} ] @@ -52,6 +53,14 @@ "params": { "entry": "$ctrl.entry" } + }, { + "url": "/basic-data", + "state": "entry.card.basicData", + "component": "vn-entry-basic-data", + "description": "Basic data", + "params": { + "entry": "$ctrl.entry" + } }, { "url" : "/log", "state": "entry.card.log",