diff --git a/modules/client/back/model-config.json b/modules/client/back/model-config.json
index 3956f0c97..4feb3b168 100644
--- a/modules/client/back/model-config.json
+++ b/modules/client/back/model-config.json
@@ -86,9 +86,6 @@
"ClientSample": {
"dataSource": "vn"
},
- "Parking": {
- "dataSource": "vn"
- },
"Sms": {
"dataSource": "vn"
},
@@ -101,9 +98,6 @@
"SageTransactionType": {
"dataSource": "vn"
},
- "Shelving": {
- "dataSource": "vn"
- },
"TpvError": {
"dataSource": "vn"
},
diff --git a/modules/client/back/models/parking.json b/modules/client/back/models/parking.json
deleted file mode 100644
index 7efcf72d3..000000000
--- a/modules/client/back/models/parking.json
+++ /dev/null
@@ -1,33 +0,0 @@
-{
- "name": "Parking",
- "base": "VnModel",
- "options": {
- "mysql": {
- "table": "parking"
- }
- },
- "properties": {
- "id": {
- "type": "number",
- "id": true,
- "description": "Identifier"
- },
- "column": {
- "type": "string",
- "required": true
- },
- "row": {
- "type": "string",
- "required": true
- },
- "sectorFk": {
- "type": "number"
- },
- "code": {
- "type": "string"
- },
- "pickingOrder": {
- "type": "number"
- }
- }
-}
diff --git a/modules/client/back/models/shelving.json b/modules/client/back/models/shelving.json
deleted file mode 100644
index 8e1ae3779..000000000
--- a/modules/client/back/models/shelving.json
+++ /dev/null
@@ -1,45 +0,0 @@
-{
- "name": "Shelving",
- "base": "VnModel",
- "options": {
- "mysql": {
- "table": "shelving"
- }
- },
- "properties": {
- "code": {
- "type": "string",
- "id": true,
- "description": "Identifier"
- },
- "parkingFk": {
- "type": "number",
- "required": true
- },
- "isPrinted": {
- "type": "boolean",
- "required": true
- },
- "priority": {
- "type": "number"
- },
- "userFk": {
- "type": "number"
- },
- "isRecyclable": {
- "type": "boolean"
- }
- },
- "relations": {
- "parking": {
- "type": "belongsTo",
- "model": "Parking",
- "foreignKey": "parkingFk"
- },
- "worker": {
- "type": "belongsTo",
- "model": "Worker",
- "foreignKey": "userFk"
- }
- }
-}
diff --git a/modules/client/front/index.js b/modules/client/front/index.js
index a5e4324ca..ea732beea 100644
--- a/modules/client/front/index.js
+++ b/modules/client/front/index.js
@@ -47,4 +47,3 @@ import './consumption-search-panel';
import './defaulter';
import './notification';
import './unpaid';
-import './shelving';
diff --git a/modules/client/front/routes.json b/modules/client/front/routes.json
index e55b45f3b..82052c95b 100644
--- a/modules/client/front/routes.json
+++ b/modules/client/front/routes.json
@@ -8,8 +8,7 @@
"main": [
{"state": "client.index", "icon": "person"},
{"state": "client.notification", "icon": "campaign"},
- {"state": "client.defaulter", "icon": "icon-defaulter"},
- {"state": "client.shelving", "icon": "contact_support"}
+ {"state": "client.defaulter", "icon": "icon-defaulter"}
],
"card": [
{"state": "client.card.basicData", "icon": "settings"},
@@ -37,10 +36,7 @@
{"state": "client.card.unpaid", "icon": "icon-defaulter"}
]
}
- ],
- "shelving": [
- {"state": "client.shelving.card.basicData", "icon": "settings"}
- ]
+ ]
},
"keybindings": [
{"key": "c", "state": "client.index"}
@@ -385,43 +381,6 @@
"component": "vn-client-unpaid",
"acl": ["administrative"],
"description": "Unpaid"
- },
- {
- "url": "/shelving?q",
- "state": "client.shelving",
- "component": "vn-shelving",
- "description": "Shelvings"
- },
- {
- "url": "/create",
- "state": "client.shelving.create",
- "component": "vn-shelving-create",
- "description": "New shelving"
- },
- {
- "url": "/:id",
- "state": "client.shelving.card",
- "component": "vn-shelving-card",
- "abstract": true,
- "description": "Detail"
- },
- {
- "url": "/summary",
- "state": "client.shelving.card.summary",
- "component": "vn-shelving-summary",
- "description": "Summary",
- "params": {
- "shelving": "$ctrl.shelving"
- }
- },
- {
- "url": "/basic-data",
- "state": "client.shelving.card.basicData",
- "component": "vn-shelving-basic-data",
- "description": "Basic data",
- "params": {
- "shelving": "$ctrl.shelving"
- }
}
]
}
diff --git a/modules/client/front/shelving/basic-data/index.html b/modules/client/front/shelving/basic-data/index.html
deleted file mode 100644
index 20cf34d7c..000000000
--- a/modules/client/front/shelving/basic-data/index.html
+++ /dev/null
@@ -1,55 +0,0 @@
-
-
-
\ No newline at end of file
diff --git a/modules/client/front/shelving/basic-data/index.js b/modules/client/front/shelving/basic-data/index.js
deleted file mode 100644
index b39707dd1..000000000
--- a/modules/client/front/shelving/basic-data/index.js
+++ /dev/null
@@ -1,12 +0,0 @@
-import ngModule from '../../module';
-import Section from 'salix/components/section';
-
-export default class Controller extends Section {}
-
-ngModule.component('vnShelvingBasicData', {
- template: require('./index.html'),
- controller: Controller,
- bindings: {
- shelving: '<'
- }
-});
diff --git a/modules/client/front/shelving/card/index.html b/modules/client/front/shelving/card/index.html
deleted file mode 100644
index 788a1ef00..000000000
--- a/modules/client/front/shelving/card/index.html
+++ /dev/null
@@ -1,5 +0,0 @@
-
-
-
-
-
diff --git a/modules/client/front/shelving/card/index.js b/modules/client/front/shelving/card/index.js
deleted file mode 100644
index 82d3c6d87..000000000
--- a/modules/client/front/shelving/card/index.js
+++ /dev/null
@@ -1,20 +0,0 @@
-import ngModule from '../../module';
-import ModuleCard from 'salix/components/module-card';
-
-class Controller extends ModuleCard {
- reload() {
- const filter = {
- include: [
- {relation: 'worker'},
- {relation: 'parking'}
- ]
- };
- this.$http.get(`Shelvings/${this.$params.id}`, {filter})
- .then(res => this.shelving = res.data);
- }
-}
-
-ngModule.vnComponent('vnShelvingCard', {
- template: require('./index.html'),
- controller: Controller
-});
diff --git a/modules/client/front/shelving/card/index.spec.js b/modules/client/front/shelving/card/index.spec.js
deleted file mode 100644
index f39840e5f..000000000
--- a/modules/client/front/shelving/card/index.spec.js
+++ /dev/null
@@ -1,25 +0,0 @@
-import './index';
-
-describe('component vnRoleCard', () => {
- let controller;
- let $httpBackend;
-
- beforeEach(ngModule('account'));
-
- beforeEach(inject(($componentController, _$httpBackend_) => {
- $httpBackend = _$httpBackend_;
- controller = $componentController('vnRoleCard', {$element: null});
- }));
-
- describe('reload()', () => {
- it('should reload the controller data', () => {
- controller.$params.id = 1;
-
- $httpBackend.expectGET('Roles/1').respond('foo');
- controller.reload();
- $httpBackend.flush();
-
- expect(controller.role).toBe('foo');
- });
- });
-});
diff --git a/modules/client/front/shelving/create/index.html b/modules/client/front/shelving/create/index.html
deleted file mode 100644
index 1f8d09224..000000000
--- a/modules/client/front/shelving/create/index.html
+++ /dev/null
@@ -1,38 +0,0 @@
-
-
-
diff --git a/modules/client/front/shelving/create/index.js b/modules/client/front/shelving/create/index.js
deleted file mode 100644
index 336859b08..000000000
--- a/modules/client/front/shelving/create/index.js
+++ /dev/null
@@ -1,15 +0,0 @@
-import ngModule from '../../module';
-import Section from 'salix/components/section';
-
-export default class Controller extends Section {
- onSubmit() {
- return this.$.watcher.submit().then(res =>
- this.$state.go('client.shelving.card.basicData', {id: res.data.id})
- );
- }
-}
-
-ngModule.component('vnShelvingCreate', {
- template: require('./index.html'),
- controller: Controller
-});
diff --git a/modules/client/front/shelving/descriptor/index.html b/modules/client/front/shelving/descriptor/index.html
deleted file mode 100644
index 05654e313..000000000
--- a/modules/client/front/shelving/descriptor/index.html
+++ /dev/null
@@ -1,42 +0,0 @@
-
-
-
- Delete
-
-
-
-
-
-
-
-
-
-
- {{::$ctrl.shelving.worker.firstName}}
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/modules/client/front/shelving/descriptor/index.js b/modules/client/front/shelving/descriptor/index.js
deleted file mode 100644
index 8bf2b3395..000000000
--- a/modules/client/front/shelving/descriptor/index.js
+++ /dev/null
@@ -1,26 +0,0 @@
-import ngModule from '../../module';
-import Descriptor from 'salix/components/descriptor';
-
-class Controller extends Descriptor {
- get shelving() {
- return this.entity;
- }
-
- set shelving(value) {
- this.entity = value;
- }
-
- onDelete() {
- return this.$http.delete(`Shelvings/${this.shelving.code}`)
- .then(() => this.$state.go('client.shelving'))
- .then(() => this.vnApp.showSuccess(this.$t('Shelving removed')));
- }
-}
-
-ngModule.component('vnShelvingDescriptor', {
- template: require('./index.html'),
- controller: Controller,
- bindings: {
- shelving: '<'
- }
-});
diff --git a/modules/client/front/shelving/descriptor/index.spec.js b/modules/client/front/shelving/descriptor/index.spec.js
deleted file mode 100644
index e2761c639..000000000
--- a/modules/client/front/shelving/descriptor/index.spec.js
+++ /dev/null
@@ -1,29 +0,0 @@
-import './index';
-
-describe('component vnRoleDescriptor', () => {
- let controller;
- let $httpBackend;
-
- let role = {id: 1, name: 'foo'};
-
- beforeEach(ngModule('account'));
-
- beforeEach(inject(($componentController, _$httpBackend_) => {
- $httpBackend = _$httpBackend_;
- controller = $componentController('vnRoleDescriptor', {$element: null}, {role});
- }));
-
- describe('onDelete()', () => {
- it('should delete entity and go to index', () => {
- controller.$state.go = jest.fn();
- jest.spyOn(controller.vnApp, 'showSuccess');
-
- $httpBackend.expectDELETE('Roles/1').respond();
- controller.onDelete();
- $httpBackend.flush();
-
- expect(controller.$state.go).toHaveBeenCalledWith('account.role');
- expect(controller.vnApp.showSuccess).toHaveBeenCalled();
- });
- });
-});
diff --git a/modules/client/front/shelving/descriptor/locale/es.yml b/modules/client/front/shelving/descriptor/locale/es.yml
deleted file mode 100644
index 1ca512e4f..000000000
--- a/modules/client/front/shelving/descriptor/locale/es.yml
+++ /dev/null
@@ -1,2 +0,0 @@
-Role will be removed: El rol va a ser eliminado
-Role removed: Rol eliminado
\ No newline at end of file
diff --git a/modules/client/front/shelving/index.js b/modules/client/front/shelving/index.js
deleted file mode 100644
index c8282e196..000000000
--- a/modules/client/front/shelving/index.js
+++ /dev/null
@@ -1,8 +0,0 @@
-import './main';
-import './index/';
-import './summary';
-import './card';
-import './descriptor';
-import './search-panel';
-import './create';
-import './basic-data';
diff --git a/modules/client/front/shelving/index/index.html b/modules/client/front/shelving/index/index.html
deleted file mode 100644
index b69961796..000000000
--- a/modules/client/front/shelving/index/index.html
+++ /dev/null
@@ -1,43 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/modules/client/front/shelving/index/index.js b/modules/client/front/shelving/index/index.js
deleted file mode 100644
index da2a15efd..000000000
--- a/modules/client/front/shelving/index/index.js
+++ /dev/null
@@ -1,14 +0,0 @@
-import ngModule from '../../module';
-import Section from 'salix/components/section';
-
-export default class Controller extends Section {
- preview(shelving) {
- this.selectedShelving = shelving;
- this.$.summary.show();
- }
-}
-
-ngModule.component('vnShelvingIndex', {
- template: require('./index.html'),
- controller: Controller
-});
diff --git a/modules/client/front/shelving/index/locale/es.yml b/modules/client/front/shelving/index/locale/es.yml
deleted file mode 100644
index 70932e983..000000000
--- a/modules/client/front/shelving/index/locale/es.yml
+++ /dev/null
@@ -1,2 +0,0 @@
-New role: Nuevo rol
-View role: Ver rol
\ No newline at end of file
diff --git a/modules/client/front/shelving/locale/es.yml b/modules/client/front/shelving/locale/es.yml
deleted file mode 100644
index 159fc7f16..000000000
--- a/modules/client/front/shelving/locale/es.yml
+++ /dev/null
@@ -1 +0,0 @@
-Subroles: Subroles
diff --git a/modules/client/front/shelving/main/index.html b/modules/client/front/shelving/main/index.html
deleted file mode 100644
index 324cc57cb..000000000
--- a/modules/client/front/shelving/main/index.html
+++ /dev/null
@@ -1,18 +0,0 @@
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/modules/client/front/shelving/main/index.js b/modules/client/front/shelving/main/index.js
deleted file mode 100644
index 580be0996..000000000
--- a/modules/client/front/shelving/main/index.js
+++ /dev/null
@@ -1,29 +0,0 @@
-import ngModule from '../../module';
-import ModuleMain from 'salix/components/module-main';
-
-export default class Shelving extends ModuleMain {
- constructor($element, $) {
- super($element, $);
- this.filter = {
- include: [
- {relation: 'parking'}
- ],
- };
- }
-
- exprBuilder(param, value) {
- switch (param) {
- case 'search':
- return {code: {like: `%${value}%`}};
- case 'parkingFk':
- case 'userFk':
- case 'isRecyclable':
- return {[param]: value};
- }
- }
-}
-
-ngModule.vnComponent('vnShelving', {
- controller: Shelving,
- template: require('./index.html')
-});
diff --git a/modules/client/front/shelving/search-panel/index.html b/modules/client/front/shelving/search-panel/index.html
deleted file mode 100644
index b7ca068a5..000000000
--- a/modules/client/front/shelving/search-panel/index.html
+++ /dev/null
@@ -1,43 +0,0 @@
-
-
-
\ No newline at end of file
diff --git a/modules/client/front/shelving/search-panel/index.js b/modules/client/front/shelving/search-panel/index.js
deleted file mode 100644
index 4f9c3b599..000000000
--- a/modules/client/front/shelving/search-panel/index.js
+++ /dev/null
@@ -1,7 +0,0 @@
-import ngModule from '../../module';
-import SearchPanel from 'core/components/searchbar/search-panel';
-
-ngModule.component('vnShelvingSearchPanel', {
- template: require('./index.html'),
- controller: SearchPanel
-});
diff --git a/modules/client/front/shelving/summary/index.html b/modules/client/front/shelving/summary/index.html
deleted file mode 100644
index 7d38c644c..000000000
--- a/modules/client/front/shelving/summary/index.html
+++ /dev/null
@@ -1,38 +0,0 @@
-
-
- {{summary.code}}
-
-
-
- Basic data
-
-
-
-
-
-
-
-
- {{::summary.worker.firstName}}
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/modules/client/front/shelving/summary/index.js b/modules/client/front/shelving/summary/index.js
deleted file mode 100644
index eba827956..000000000
--- a/modules/client/front/shelving/summary/index.js
+++ /dev/null
@@ -1,32 +0,0 @@
-import ngModule from '../../module';
-import Component from 'core/lib/component';
-
-class Controller extends Component {
- set shelving(value) {
- console.log(value);
- this._shelving = value;
- this.$.summary = null;
- if (!value) return;
-
- const filter = {
- include: [
- {relation: 'worker'},
- {relation: 'parking'}
- ]
- };
- this.$http.get(`Shelvings/${value.code}`, {filter})
- .then(res => this.$.summary = res.data);
- }
-
- get shelving() {
- return this._shelving;
- }
-}
-
-ngModule.component('vnShelvingSummary', {
- template: require('./index.html'),
- controller: Controller,
- bindings: {
- shelving: '<'
- }
-});