diff --git a/client/production/src/index/index.html b/client/production/src/index/index.html
index bc4488aa9..63e899206 100644
--- a/client/production/src/index/index.html
+++ b/client/production/src/index/index.html
@@ -31,7 +31,7 @@
-
+
diff --git a/client/production/src/locale/es.json b/client/production/src/locale/es.json
index 0cf5acba5..59571cb2c 100644
--- a/client/production/src/locale/es.json
+++ b/client/production/src/locale/es.json
@@ -22,5 +22,9 @@
"Province" : "Provincia",
"Filter" : "Filtrar",
"Cancel" : "Cancelar",
+ "Worker" : "Trabajador",
+ "Town" : "PoblaciĆ³n",
+ "Client ID" : "ID Cliente",
+
"Ticket with incidence" : "Ticket con incidencia"
}
\ No newline at end of file
diff --git a/client/production/src/production-actions/production-actions.html b/client/production/src/production-actions/production-actions.html
index 4786d9136..db9daf932 100644
--- a/client/production/src/production-actions/production-actions.html
+++ b/client/production/src/production-actions/production-actions.html
@@ -1,7 +1,7 @@
-
+
@@ -10,6 +10,6 @@
-
+
\ No newline at end of file
diff --git a/client/production/src/production-actions/production-actions.js b/client/production/src/production-actions/production-actions.js
index 0e5482f30..fee7b687b 100644
--- a/client/production/src/production-actions/production-actions.js
+++ b/client/production/src/production-actions/production-actions.js
@@ -35,45 +35,35 @@ export default class ProductionActions {
return this._actionWorker;
}
- _changeState(ids, sateteId, stateName, index) {
- this.$http.put(`/production/api/TicketStates/${sateteId}/changeState`, {tickets: ids}).then(
+ _changeState(ids, sateteId) {
+ this.$http.put(`/production/api/TicketStates/${sateteId}/changeState`, {tickets: ids})
+ .then(
() => {
- index.forEach(
- i => {
- this.tickets[i].state = stateName;
- this.tickets[i].stateFk = sateteId;
- }
- );
+ this.parent.searchTickets();
}
);
}
_sendMessage(tickets) {
- this.$http.post(`/production/api/FakeProductions/messageSend`, {tickets: tickets}).then(
- () => {
- this.vnApp.showMessage(this.$translate.instant('Success: message send!'));
- }
- );
+ this.$http.post(`/production/api/FakeProductions/messageSend`, {tickets: tickets})
+ .then(
+ () => {
+ this.vnApp.showMessage(this.$translate.instant('Success: message send!'));
+ }
+ );
}
_changeTime(ids, time, index) {
- this.$http.put(`/production/api/Tickets/${time}/changeTime`, {tickets: ids}).then(
+ this.$http.put(`/production/api/Tickets/${time}/changeTime`, {tickets: ids})
+ .then(
() => {
- index.forEach(
- i => {
- this.tickets[i].hour = time;
- }
- );
+ this.parent.searchTickets();
}
);
}
_changeWorker(ids, workerFk, index) {
- this.$http.put(`/production/api/Tickets/${workerFk}/changeWorker`, {tickets: ids}).then(
+ this.$http.put(`/production/api/Tickets/${workerFk}/changeWorker`, {tickets: ids})
+ .then(
() => {
- index.forEach(
- i => {
- this.tickets[i].workerFk = this.actionWorker.id;
- this.tickets[i].worker = this.actionWorker.name;
- }
- );
+ this.parent.searchTickets();
}
);
}
@@ -82,7 +72,7 @@ export default class ProductionActions {
let ids = [];
let index = [];
let tickets = [];
- this.tickets.forEach(
+ this.parent.tickets.forEach(
(val, i) => {
if (val.checked) {
ids.push(val.ticketFk);
@@ -94,13 +84,13 @@ export default class ProductionActions {
if (tickets.length) {
switch (actionName) {
case 'changeState' :
- this._changeState(ids, this.actionState.id, this.actionState.name, index);
+ this._changeState(ids, this.actionState.id);
break;
case 'addComment':
this._sendMessage(tickets);
break;
case 'markPrinted':
- this._changeState(ids, 4, 'Impreso', index);
+ this._changeState(ids, 4);
break;
case 'changeTime':
this._changeTime(ids, this.actionHours.name, index);
@@ -121,10 +111,8 @@ ProductionActions.$inject = ['$http', '$translate', 'vnApp'];
ngModule.component('vnProductionActions', {
template: require('./production-actions.html'),
- bindings: {
- tickets: '<',
- states: '<',
- hourItems: '<'
- },
- controller: ProductionActions
+ controller: ProductionActions,
+ require: {
+ parent: '^^vnProductionIndex'
+ }
});
diff --git a/client/production/src/production-table/production-table.html b/client/production/src/production-table/production-table.html
index 42a9e45ac..e87410722 100644
--- a/client/production/src/production-table/production-table.html
+++ b/client/production/src/production-table/production-table.html
@@ -8,6 +8,7 @@
+
@@ -16,7 +17,7 @@
-
+
@@ -27,8 +28,9 @@
{{::ticket.agency}}
{{::ticket.routeFk}}
{{::ticket.salesPerson | ucwords}}
- {{ticket.hour}}
- {{ticket.state}}
+ {{::ticket.worker | ucwords}}
+ {{::ticket.hour}}
+ {{::ticket.state}}
{{::ticket.lines}}
{{::ticket.m3}}
{{::ticket.boxes}}
@@ -44,10 +46,15 @@
:
{{$ctrl.footer.total}}
-
+
+
+
+
+
+
{{$ctrl.footer.lines}}
{{$ctrl.footer.meters}}
-
+
diff --git a/services/nginx/static/templates/tooltip.locator.tpl.html b/services/nginx/static/templates/tooltip.locator.tpl.html
index 214d3342b..be0877ab8 100644
--- a/services/nginx/static/templates/tooltip.locator.tpl.html
+++ b/services/nginx/static/templates/tooltip.locator.tpl.html
@@ -1,9 +1,9 @@
{{::ticket.city | ucwords}}