@colijnit/sharedcomponents 260.1.3 → 260.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/{103.16299d7a4742c74e622f.js → 729.7933323f8da0a530fd0f.js} +1 -1
- package/bundles/colijnit-sharedcomponents.umd.js +57 -11
- package/bundles/colijnit-sharedcomponents.umd.js.map +1 -1
- package/colijnit-sharedcomponents.metadata.json +1 -1
- package/esm2015/lib/components/task-creator/task-creator.component.js +108 -74
- package/esm2015/lib/components/task-creator/task-creator.module.js +2 -2
- package/fesm2015/colijnit-sharedcomponents.js +107 -73
- package/fesm2015/colijnit-sharedcomponents.js.map +1 -1
- package/index.html +2 -2
- package/lib/components/task-creator/task-creator.component.d.ts +11 -0
- package/{main.0fede440659af08dfbbf.js → main.05f04e77b1b4468bd751.js} +1 -1
- package/package.json +2 -2
- package/runtime.dfb2da895094a2c6c0f4.js +1 -0
- package/styles.3f618234e2ebfcaf5caa.css +1 -0
- package/runtime.275b78aac2b14b7fa6ad.js +0 -1
- package/styles.e8050dd6bc2e98376c40.css +0 -1
|
@@ -16436,12 +16436,12 @@
|
|
|
16436
16436
|
this._formMasterService = _formMasterService;
|
|
16437
16437
|
this.icons = exports["ɵcd"];
|
|
16438
16438
|
this.table = tableName_enum.TableName.Transactions;
|
|
16439
|
+
this.allowEmailing = true;
|
|
16439
16440
|
this.activityCreated = new i0.EventEmitter();
|
|
16440
|
-
this.optionCollection = [
|
|
16441
|
-
|
|
16442
|
-
|
|
16443
|
-
|
|
16444
|
-
];
|
|
16441
|
+
this.optionCollection = [];
|
|
16442
|
+
this.remarkListItem = { icon: this.iconService.getIcon(this.icons.CommentRegular), label: this.dictionaryService.get('REMARK', true) };
|
|
16443
|
+
this.workListItem = { icon: this.iconService.getIcon(this.icons.PersonDiggingRegular), label: this.dictionaryService.get('WORK', true) };
|
|
16444
|
+
this.taskListItem = { icon: this.iconService.getIcon(this.icons.ListUlRegular), label: this.dictionaryService.get('TASK', true) };
|
|
16445
16445
|
this.showFilesDialog = false;
|
|
16446
16446
|
this.documents = [];
|
|
16447
16447
|
this.oldDocuments = [];
|
|
@@ -16454,7 +16454,34 @@
|
|
|
16454
16454
|
this.workDescription = "";
|
|
16455
16455
|
this.taskName = "";
|
|
16456
16456
|
this.taskDescription = "";
|
|
16457
|
+
this._allowRemarkCreation = true;
|
|
16458
|
+
this._allowWorkCreation = true;
|
|
16459
|
+
this._allowTaskCreation = true;
|
|
16457
16460
|
}
|
|
16461
|
+
Object.defineProperty(TaskCreatorComponent.prototype, "allowRemarkCreation", {
|
|
16462
|
+
set: function (allow) {
|
|
16463
|
+
this._allowRemarkCreation = allow;
|
|
16464
|
+
this.setupOptionCollection();
|
|
16465
|
+
},
|
|
16466
|
+
enumerable: false,
|
|
16467
|
+
configurable: true
|
|
16468
|
+
});
|
|
16469
|
+
Object.defineProperty(TaskCreatorComponent.prototype, "allowWorkCreation", {
|
|
16470
|
+
set: function (allow) {
|
|
16471
|
+
this._allowWorkCreation = allow;
|
|
16472
|
+
this.setupOptionCollection();
|
|
16473
|
+
},
|
|
16474
|
+
enumerable: false,
|
|
16475
|
+
configurable: true
|
|
16476
|
+
});
|
|
16477
|
+
Object.defineProperty(TaskCreatorComponent.prototype, "allowTaskCreation", {
|
|
16478
|
+
set: function (allow) {
|
|
16479
|
+
this._allowTaskCreation = allow;
|
|
16480
|
+
this.setupOptionCollection();
|
|
16481
|
+
},
|
|
16482
|
+
enumerable: false,
|
|
16483
|
+
configurable: true
|
|
16484
|
+
});
|
|
16458
16485
|
TaskCreatorComponent.prototype.showClass = function () {
|
|
16459
16486
|
return true;
|
|
16460
16487
|
};
|
|
@@ -16464,7 +16491,7 @@
|
|
|
16464
16491
|
return __generator(this, function (_b) {
|
|
16465
16492
|
switch (_b.label) {
|
|
16466
16493
|
case 0:
|
|
16467
|
-
this.
|
|
16494
|
+
this.setupOptionCollection();
|
|
16468
16495
|
_a = this;
|
|
16469
16496
|
return [4 /*yield*/, this.sharedService.getEmailSenderByWorkflowCategoryAndKey('SERVICE_ORDER', this.remarkAndWorkKey)];
|
|
16470
16497
|
case 1:
|
|
@@ -16474,6 +16501,21 @@
|
|
|
16474
16501
|
});
|
|
16475
16502
|
});
|
|
16476
16503
|
};
|
|
16504
|
+
TaskCreatorComponent.prototype.setupOptionCollection = function () {
|
|
16505
|
+
this.optionCollection = [];
|
|
16506
|
+
if (this._allowRemarkCreation) {
|
|
16507
|
+
this.optionCollection.push(this.remarkListItem);
|
|
16508
|
+
}
|
|
16509
|
+
if (this._allowWorkCreation) {
|
|
16510
|
+
this.optionCollection.push(this.workListItem);
|
|
16511
|
+
}
|
|
16512
|
+
if (this._allowTaskCreation) {
|
|
16513
|
+
this.optionCollection.push(this.taskListItem);
|
|
16514
|
+
}
|
|
16515
|
+
if (this.optionCollection.length > 0) {
|
|
16516
|
+
this.chosenActivityType = this.optionCollection[0];
|
|
16517
|
+
}
|
|
16518
|
+
};
|
|
16477
16519
|
TaskCreatorComponent.prototype.itemSelected = function (item) {
|
|
16478
16520
|
this.chosenActivityType = item;
|
|
16479
16521
|
};
|
|
@@ -16666,10 +16708,10 @@
|
|
|
16666
16708
|
});
|
|
16667
16709
|
};
|
|
16668
16710
|
TaskCreatorComponent.prototype.findReportType = function () {
|
|
16669
|
-
if (this.chosenActivityType === this.
|
|
16711
|
+
if (this.chosenActivityType === this.remarkListItem) {
|
|
16670
16712
|
return reportType_enum.ReportType.RemarkMessage;
|
|
16671
16713
|
}
|
|
16672
|
-
else if (this.chosenActivityType === this.
|
|
16714
|
+
else if (this.chosenActivityType === this.workListItem) {
|
|
16673
16715
|
return reportType_enum.ReportType.WorkMessage;
|
|
16674
16716
|
}
|
|
16675
16717
|
else {
|
|
@@ -16703,13 +16745,13 @@
|
|
|
16703
16745
|
history.emailAddresses = this._createEmailAddressString(this.emailAddresses);
|
|
16704
16746
|
history.emailDateTime = new Date();
|
|
16705
16747
|
history.message = 'Email Content created via Report';
|
|
16706
|
-
if (!(this.chosenActivityType === this.
|
|
16748
|
+
if (!(this.chosenActivityType === this.remarkListItem)) return [3 /*break*/, 3];
|
|
16707
16749
|
return [4 /*yield*/, this.sharedService.insertEmailHistoryForRemark(history)];
|
|
16708
16750
|
case 2:
|
|
16709
16751
|
_a.sent();
|
|
16710
16752
|
return [3 /*break*/, 7];
|
|
16711
16753
|
case 3:
|
|
16712
|
-
if (!(this.chosenActivityType === this.
|
|
16754
|
+
if (!(this.chosenActivityType === this.workListItem)) return [3 /*break*/, 5];
|
|
16713
16755
|
return [4 /*yield*/, this.sharedService.insertEmailHistoryForWork(history)];
|
|
16714
16756
|
case 4:
|
|
16715
16757
|
_a.sent();
|
|
@@ -16774,7 +16816,7 @@
|
|
|
16774
16816
|
TaskCreatorComponent.decorators = [
|
|
16775
16817
|
{ type: i0.Component, args: [{
|
|
16776
16818
|
selector: "co-task-creator",
|
|
16777
|
-
template: "\n <div class=\"task-creator-wrapper\">\n <div class=\"top-rows\">\n <co-email-selector [(emailAddresses)]=\"emailAddresses\" [(bccEmailAddresses)]=\"bccEmailAddresses\"\n [key]=\"remarkAndWorkKey\" [workflowCategoryType]=\"workflowCategoryType\"></co-email-selector>\n <co-form #createForm class=\"creator-remarks input-fields\">\n <co-list-of-icons [collection]=\"optionCollection\" (itemSelected)=\"itemSelected($event)\"></co-list-of-icons>\n <co-input-textarea *ngIf=\"chosenActivityType ===
|
|
16819
|
+
template: "\n <div class=\"task-creator-wrapper\">\n <div class=\"top-rows\">\n <co-email-selector [(emailAddresses)]=\"emailAddresses\" [(bccEmailAddresses)]=\"bccEmailAddresses\" *ngIf=\"allowEmailing\"\n [key]=\"remarkAndWorkKey\" [workflowCategoryType]=\"workflowCategoryType\"></co-email-selector>\n <co-form #createForm class=\"creator-remarks input-fields\">\n <co-list-of-icons [collection]=\"optionCollection\" (itemSelected)=\"itemSelected($event)\"></co-list-of-icons>\n <co-input-textarea *ngIf=\"chosenActivityType === remarkListItem\"\n [required]=\"chosenActivityType === remarkListItem\"\n [placeholder]=\"'REMARK' | sharedLocalize\" [(model)]=\"remarkText\"\n class=\"large-remark\"></co-input-textarea>\n <co-input-textarea *ngIf=\"chosenActivityType === workListItem\"\n [required]=\"chosenActivityType === workListItem\"\n [placeholder]=\"'DESCRIPTION' | sharedLocalize\" [(model)]=\"workDescription\"\n class=\"large-remark\"></co-input-textarea>\n <div class=\"task-input-fields\" *ngIf=\"chosenActivityType === taskListItem\">\n <co-input-text [(model)]=\"taskName\" [placeholder]=\"'NAME' | sharedLocalize\"\n [required]=\"chosenActivityType === taskListItem\"></co-input-text>\n <co-input-textarea [(model)]=\"taskDescription\" [placeholder]=\"'DESCRIPTION' | sharedLocalize\"\n class=\"large-remark\"\n [required]=\"chosenActivityType === taskListItem\"></co-input-textarea>\n </div>\n </co-form>\n </div>\n <div class=\"extras-buttons\">\n <co-button [iconData]=\"iconService.getIcon(icons.PaperclipRegular)\" (click)=\"openAttachmentDialog()\"\n [label]=\"documents.length === 0 ? '' : documents.length.toString()\"></co-button>\n <co-button *ngIf=\"chosenActivityType === remarkListItem\"\n [iconData]=\"iconService.getIcon(icons.PaperPlaneTopSolid)\"\n (click)=\"createRemarkClicked()\"></co-button>\n <co-button *ngIf=\"chosenActivityType === workListItem\"\n [iconData]=\"iconService.getIcon(icons.PaperPlaneTopSolid)\"\n (click)=\"createWorkClicked()\"></co-button>\n <co-button *ngIf=\"chosenActivityType === taskListItem\"\n [iconData]=\"iconService.getIcon(icons.PaperPlaneTopSolid)\"\n (click)=\"createTaskClicked()\"></co-button>\n </div>\n </div>\n <co-dialog *ngIf=\"showFilesDialog\" (closeClick)=\"attachmentDialogCancelled()\"\n [headerTemplate]=\"attachmentHeaderTemplate\"\n [footerTemplate]=\"attachmentFooterTemplate\">\n\n <ng-template #attachmentHeaderTemplate>\n <div class=\"co-dialog-wrapper-popup-title\">\n <co-icon [iconData]=\"iconService.getIcon(icons.PaperclipRegular)\"></co-icon>\n <div class=\"co-dialog-header-title\" [textContent]=\"'ATTACHMENTS' | sharedLocalize\"></div>\n </div>\n </ng-template>\n <co-files-upload (documentsAdded)=\"addedDocument($event)\" (documentDeleted)=\"deletedDocument\"\n [documents]=\"documents\" [useWithoutSettingProps]=\"true\"></co-files-upload>\n </co-dialog>\n\n\n <ng-template #attachmentFooterTemplate>\n <div class=\"co-dialog-footer-button-wrapper\">\n <co-button class=\"save-button\"\n [iconData]=\"iconService.getIcon(icons.CheckDuotone)\"\n (click)=\"attachmentDialogClosed()\"></co-button>\n <co-button class=\"close-button\"\n [iconData]=\"iconService.getIcon(icons.CrossSkinny)\"\n (click)=\"attachmentDialogCancelled()\"></co-button>\n </div>\n </ng-template>\n ",
|
|
16778
16820
|
providers: [
|
|
16779
16821
|
corecomponents_v12.FormMasterService,
|
|
16780
16822
|
{
|
|
@@ -16799,6 +16841,10 @@
|
|
|
16799
16841
|
remarkAndWorkKey: [{ type: i0.Input }],
|
|
16800
16842
|
taskKey: [{ type: i0.Input }],
|
|
16801
16843
|
workflowCategoryType: [{ type: i0.Input }],
|
|
16844
|
+
allowRemarkCreation: [{ type: i0.Input }],
|
|
16845
|
+
allowWorkCreation: [{ type: i0.Input }],
|
|
16846
|
+
allowTaskCreation: [{ type: i0.Input }],
|
|
16847
|
+
allowEmailing: [{ type: i0.Input }],
|
|
16802
16848
|
activityCreated: [{ type: i0.Output }],
|
|
16803
16849
|
showClass: [{ type: i0.HostBinding, args: ["class.co-task-creator",] }],
|
|
16804
16850
|
hidden: [{ type: i0.HostBinding, args: ['class.co-shared-hidden',] }]
|