salix/modules/order/front/index/index.js

37 lines
1018 B
JavaScript
Raw Normal View History

2018-07-18 12:38:43 +00:00
import ngModule from '../module';
2020-03-17 14:18:02 +00:00
import Section from 'salix/components/section';
2018-07-18 12:38:43 +00:00
2020-03-17 14:18:02 +00:00
export default class Controller extends Section {
showClientDescriptor(event, clientFk) {
this.$.clientDescriptor.clientFk = clientFk;
this.$.clientDescriptor.parent = event.target;
this.$.clientDescriptor.show();
2018-09-06 10:47:25 +00:00
event.preventDefault();
event.stopImmediatePropagation();
}
showWorkerDescriptor(event, workerFk) {
event.preventDefault();
event.stopImmediatePropagation();
this.selectedWorker = workerFk;
this.$.workerDescriptor.parent = event.target;
this.$.workerDescriptor.show();
}
2018-09-06 10:47:25 +00:00
onDescriptorLoad() {
this.$.popover.relocate();
2018-09-06 10:47:25 +00:00
}
preview(event, order) {
event.preventDefault();
event.stopImmediatePropagation();
this.selectedOrder = order;
this.$.summary.show();
2018-07-18 12:38:43 +00:00
}
}
ngModule.component('vnOrderIndex', {
template: require('./index.html'),
controller: Controller
});