diff --git a/modules/ticket/front/index/index.html b/modules/ticket/front/index/index.html
index 8bff26233..249baf815 100644
--- a/modules/ticket/front/index/index.html
+++ b/modules/ticket/front/index/index.html
@@ -55,13 +55,13 @@
diff --git a/modules/ticket/front/index/index.js b/modules/ticket/front/index/index.js
index f9c14600d..9176f1490 100644
--- a/modules/ticket/front/index/index.js
+++ b/modules/ticket/front/index/index.js
@@ -2,8 +2,9 @@ import ngModule from '../module';
import './style.scss';
export default class Controller {
- constructor($scope, $state, $stateParams) {
+ constructor($scope, $state, $stateParams, $translate) {
this.$ = $scope;
+ this.$translate = $translate;
this.$stateParams = $stateParams;
this.$state = $state;
this.selectedTicket = null;
@@ -41,9 +42,9 @@ export default class Controller {
}
goToLines(event, ticketFk) {
- event.preventDefault();
- event.stopImmediatePropagation();
- this.$state.go('ticket.card.sale', {id: ticketFk});
+ this.preventDefault(event);
+ let url = this.$state.href('ticket.card.sale', {id: ticketFk}, {absolute: true});
+ window.open(url, '_blank');
}
goToTurns() {
@@ -85,30 +86,32 @@ export default class Controller {
}
showClientDescriptor(event, clientFk) {
- event.preventDefault();
- event.stopImmediatePropagation();
+ this.preventDefault(event);
this.$.clientDescriptor.clientFk = clientFk;
this.$.clientDescriptor.parent = event.target;
this.$.clientDescriptor.show();
}
showWorkerDescriptor(event, userId) {
- event.preventDefault();
- event.stopImmediatePropagation();
+ this.preventDefault(event);
this.selectedWorker = userId;
this.$.workerDescriptor.parent = event.target;
this.$.workerDescriptor.show();
}
preview(event, ticket) {
- event.preventDefault();
- event.stopImmediatePropagation();
+ this.preventDefault(event);
this.selectedTicket = ticket;
this.$.summary.show();
}
+
+ preventDefault(event) {
+ event.preventDefault();
+ event.stopImmediatePropagation();
+ }
}
-Controller.$inject = ['$scope', '$state', '$stateParams'];
+Controller.$inject = ['$scope', '$state', '$stateParams', '$translate'];
ngModule.component('vnTicketIndex', {
template: require('./index.html'),
diff --git a/modules/ticket/front/index/locale/es.yml b/modules/ticket/front/index/locale/es.yml
index bb8624797..293ef9fdc 100644
--- a/modules/ticket/front/index/locale/es.yml
+++ b/modules/ticket/front/index/locale/es.yml
@@ -1,2 +1,3 @@
Turns: Turnos
-Go to lines: Ir a lineas
\ No newline at end of file
+Go to lines: Ir a lineas
+Not available: No disponible
\ No newline at end of file