1 namespace app.services {
4 private $uibModal: ng.ui.bootstrap.IModalService;
5 private modalOption: ng.ui.bootstrap.IModalSettings;
6 public static $inject = ['$uibModal'];
9 constructor($uibModal: ng.ui.bootstrap.IModalService) {
11 constructor($uibModal: ng.ui.bootstrap.IModalService) {
12 >>>>>>> 6b2b2b88511733893d2c6e7848c389abfcd53ba6
13 this.$uibModal = $uibModal;
22 public open(modalName: string): ng.ui.bootstrap.IModalServiceInstance {
23 //public open(modalName: string): string {
24 if(modalName === 'SelectCommand') {
25 //this.modalOption.controller = 'SelectCommandController';
26 this.modalOption.templateUrl = 'templates/select-command.html';
27 this.modalOption.size = 'lg';
29 return this.$uibModal.open(this.modalOption);
34 public selectCommand(): ng.ui.bootstrap.IModalServiceInstance {
35 this.modalOption.templateUrl = 'templates/select-command.html';
36 this.modalOption.controller = 'selectCommandController';
37 this.modalOption.controllerAs = 'c';
38 this.modalOption.size = 'lg';
39 return this.$uibModal.open(this.modalOption);
42 public preview(): ng.ui.bootstrap.IModalServiceInstance {
43 this.modalOption.templateUrl = 'templates/preview.html';
44 this.modalOption.controller = 'previewController';
45 this.modalOption.controllerAs = 'c';
46 this.modalOption.size = 'lg';
47 return this.$uibModal.open(this.modalOption);
51 public upload(): ng.ui.bootstrap.IModalServiceInstance {
52 this.modalOption.templateUrl = 'templates/upload.html';
53 this.modalOption.controller = 'uploadController';
54 this.modalOption.controllerAs ='c';
55 this.modalOption.size = 'lg';
56 return this.$uibModal.open(this.modalOption);
60 >>>>>>> 6b2b2b88511733893d2c6e7848c389abfcd53ba6