From aceecd9c7a5396592a70bf4436bd21b0ff13186a Mon Sep 17 00:00:00 2001 From: Carlos Jimenez Ruiz Date: Fri, 8 Mar 2019 09:41:53 +0100 Subject: [PATCH] Tarea #1197 worker.centralita --- modules/worker/front/card/index.js | 4 +++- modules/worker/front/index.js | 1 + modules/worker/front/locale/es.yml | 3 ++- modules/worker/front/pbx/index.html | 28 ++++++++++++++++++++++++++++ modules/worker/front/pbx/index.js | 8 ++++++++ modules/worker/front/routes.json | 12 +++++++++++- 6 files changed, 53 insertions(+), 3 deletions(-) create mode 100644 modules/worker/front/pbx/index.html create mode 100644 modules/worker/front/pbx/index.js diff --git a/modules/worker/front/card/index.js b/modules/worker/front/card/index.js index 9b4f6f93f..fe8a57fb9 100644 --- a/modules/worker/front/card/index.js +++ b/modules/worker/front/card/index.js @@ -22,7 +22,9 @@ class Controller { }, { relation: 'sip', - scope: {fields: ['extension']} + scope: { + fields: ['extension', 'secret'] + } }, { relation: 'department', scope: { diff --git a/modules/worker/front/index.js b/modules/worker/front/index.js index 79f374f30..e9aa1424c 100644 --- a/modules/worker/front/index.js +++ b/modules/worker/front/index.js @@ -7,3 +7,4 @@ import './descriptor'; import './descriptor-popover'; import './search-panel'; import './basic-data'; +import './pbx'; diff --git a/modules/worker/front/locale/es.yml b/modules/worker/front/locale/es.yml index 7caf36e0b..674d13ea0 100644 --- a/modules/worker/front/locale/es.yml +++ b/modules/worker/front/locale/es.yml @@ -7,4 +7,5 @@ Department: Departamento User id: Id de usuario Role: Rol Extension: Extensión -Go to client: Ir al cliente \ No newline at end of file +Go to client: Ir al cliente +Private Branch Exchange: Centralita \ No newline at end of file diff --git a/modules/worker/front/pbx/index.html b/modules/worker/front/pbx/index.html new file mode 100644 index 000000000..ed29e4450 --- /dev/null +++ b/modules/worker/front/pbx/index.html @@ -0,0 +1,28 @@ + + + +
+ + + + + + + + + + + + + +
diff --git a/modules/worker/front/pbx/index.js b/modules/worker/front/pbx/index.js new file mode 100644 index 000000000..70dcc9aef --- /dev/null +++ b/modules/worker/front/pbx/index.js @@ -0,0 +1,8 @@ +import ngModule from '../module'; + +ngModule.component('vnWorkerPbx', { + template: require('./index.html'), + bindings: { + worker: '<' + } +}); diff --git a/modules/worker/front/routes.json b/modules/worker/front/routes.json index cb2823484..7ef1237e0 100644 --- a/modules/worker/front/routes.json +++ b/modules/worker/front/routes.json @@ -4,7 +4,8 @@ "icon" : "icon-worker", "validations" : true, "menu": [ - {"state": "worker.card.basicData", "icon": "settings"} + {"state": "worker.card.basicData", "icon": "settings"}, + {"state": "worker.card.pbx", "icon": ""} ], "routes": [ { @@ -41,6 +42,15 @@ "worker": "$ctrl.worker" }, "acl": ["developer"] + }, { + "url": "/pbx", + "state": "worker.card.pbx", + "component": "vn-worker-pbx", + "description": "Private Branch Exchange", + "params": { + "worker": "$ctrl.worker" + }, + "acl": ["hr"] } ] } \ No newline at end of file