nuxeo-development-framework 4.1.0 → 4.1.1

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.
@@ -2441,7 +2441,7 @@
2441
2441
  return NdfNuxeoDialog;
2442
2442
  }(BaseComponent));
2443
2443
  NdfNuxeoDialog.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: NdfNuxeoDialog, deps: [{ token: i0__namespace.Injector }], target: i0__namespace.ɵɵFactoryTarget.Component });
2444
- NdfNuxeoDialog.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: NdfNuxeoDialog, selector: "ndf-nuxeo-dialog", inputs: { dialogTitle: "dialogTitle", subTitle: "subTitle", loaderMode: "loaderMode" }, queries: [{ propertyName: "contentTemplate", first: true, predicate: ["contentTemplate"], descendants: true }, { propertyName: "actionsTemplate", first: true, predicate: ["actionsTemplate"], descendants: true }], viewQueries: [{ propertyName: "dialogBody", first: true, predicate: ["dialogBody"], descendants: true }], usesInheritance: true, ngImport: i0__namespace, template: "<div SetDirRtl class=\"ndf-dialog-wrapper flex flex-col\">\r\n\t<div\r\n\t\tclass=\"dialog-header flex h-20 p-6 justify-between items-center w-full bg-vapor text-blue-munsell text-xl not-italic font-bold leading-7\"\r\n\t>\r\n\t\t<div class=\"flex flex-col\">\r\n\t\t\t<span>{{ data?.dialogConfig?.title || dialogTitle }}</span>\r\n\t\t\t<span class=\"text-base font-normal\"\r\n\t\t\t\t>{{ data?.dialogConfig?.subTitle || subTitle }}</span\r\n\t\t\t>\r\n\t\t</div>\r\n\t\t<button\r\n\t\t\tclass=\"flex items-center justify-center rounded-full bg-anti-flash-white w-10 h-10\"\r\n\t\t\t(click)=\"executeAction()\"\r\n\t\t\tmatTooltip=\"{{'BUTTONS.CLOSE' | translate}}\"\r\n\t\t>\r\n\t\t\t<mat-icon class=\"icon-size-3.5\" [svgIcon]=\"'icons:cancel-icon'\">\r\n\t\t\t</mat-icon>\r\n\t\t</button>\r\n\t</div>\r\n\t<div\r\n\t\t#dialogBody\r\n\t\tclass=\"dialog-body flex flex-col gap-y-4 p-6 overflow-y-auto relative z-99\"\r\n\t\t[ngClass]=\"{'overflow-hidden': loading}\"\r\n\t>\r\n\t\t<ng-container\r\n\t\t\t*ngTemplateOutlet=\"data?.dialogConfig?.contentTemplate || contentTemplate\"\r\n\t\t></ng-container>\r\n\t\t<ng-container *ngIf=\"loading\">\r\n\t\t\t<div\r\n\t\t\t\tclass=\"overlay flex w-full h-full items-center justify-center absolute left-0 bottom-0 right-0 bg-gray-300 opacity-40 z-999\"\r\n\t\t\t\t[ngStyle]=\"{'top': dialogBodyTopOffset + 'px'}\"\r\n\t\t\t></div>\r\n\t\t\t<div\r\n\t\t\t\tclass=\"overlay flex w-full h-full items-center justify-center absolute left-0 bottom-0 right-0 z-9999\"\r\n\t\t\t\t*ngIf=\"loaderMode === 'spinner'\"\r\n\t\t\t\t[ngStyle]=\"{'top': dialogBodyTopOffset + 'px'}\"\r\n\t\t\t>\r\n\t\t\t\t<mat-spinner\r\n\t\t\t\t\t[value]=\"90\"\r\n\t\t\t\t\t[strokeWidth]=\"4\"\r\n\t\t\t\t\toverlay=\"true\"\r\n\t\t\t\t\t[diameter]=\"40\"\r\n\t\t\t\t\tcolor=\"primary\"\r\n\t\t\t\t>\r\n\t\t\t\t</mat-spinner>\r\n\t\t\t</div>\r\n\t\t\t<div\r\n\t\t\t\tclass=\"block w-full h-px absolute inset-0 z-9999\"\r\n\t\t\t\t*ngIf=\"loaderMode === 'progressBar'\"\r\n\t\t\t>\r\n\t\t\t\t<mat-progress-bar mode=\"indeterminate\"></mat-progress-bar>\r\n\t\t\t</div>\r\n\t\t</ng-container>\r\n\t</div>\r\n\t<div class=\"flex w-full justify-end p-6 pt-0 gap-x-4\">\r\n\t\t<button class=\"cancelation-button\" (click)=\"executeAction()\">\r\n\t\t\t{{\"BUTTONS.CANCEL\" | translate}}\r\n\t\t</button>\r\n\t\t<ng-container\r\n\t\t\t*ngTemplateOutlet=\"(data?.dialogConfig?.actionsTemplate || actionsTemplate); context: { dialog: this }\"\r\n\t\t></ng-container>\r\n\t</div>\r\n</div>\r\n", styles: ["::ng-deep .ndf-dialog .mat-dialog-container{overflow:hidden!important;border-radius:8px!important}.ndf-dialog-wrapper .dialog-body{height:auto;max-height:calc(100vh - 208px)}\n"], components: [{ type: i2__namespace$1.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }], directives: [{ type: SetDirRtlDirective, selector: "[SetDirRtl]" }, { type: i2__namespace$2.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltipPosition", "matTooltipDisabled", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { type: i4__namespace$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i4__namespace$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i4__namespace$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4__namespace$1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }], pipes: { "translate": i1__namespace.TranslatePipe } });
2444
+ NdfNuxeoDialog.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: NdfNuxeoDialog, selector: "ndf-nuxeo-dialog", inputs: { dialogTitle: "dialogTitle", subTitle: "subTitle", loaderMode: "loaderMode" }, queries: [{ propertyName: "contentTemplate", first: true, predicate: ["contentTemplate"], descendants: true }, { propertyName: "actionsTemplate", first: true, predicate: ["actionsTemplate"], descendants: true }], viewQueries: [{ propertyName: "dialogBody", first: true, predicate: ["dialogBody"], descendants: true }], usesInheritance: true, ngImport: i0__namespace, template: "<div SetDirRtl class=\"ndf-dialog-wrapper flex flex-col h-full\">\r\n\t<div\r\n\t\tclass=\"dialog-header flex h-20 p-6 justify-between items-center w-full bg-vapor text-blue-munsell text-xl not-italic font-bold leading-7\"\r\n\t>\r\n\t\t<div class=\"flex flex-col\">\r\n\t\t\t<span>{{ data?.dialogConfig?.title || dialogTitle }}</span>\r\n\t\t\t<span class=\"text-base font-normal\"\r\n\t\t\t\t>{{ data?.dialogConfig?.subTitle || subTitle }}</span\r\n\t\t\t>\r\n\t\t</div>\r\n\t\t<button\r\n\t\t\tclass=\"flex items-center justify-center rounded-full bg-anti-flash-white w-10 h-10\"\r\n\t\t\t(click)=\"executeAction()\"\r\n\t\t\tmatTooltip=\"{{'BUTTONS.CLOSE' | translate}}\"\r\n\t\t>\r\n\t\t\t<mat-icon class=\"icon-size-3.5\" [svgIcon]=\"'icons:cancel-icon'\">\r\n\t\t\t</mat-icon>\r\n\t\t</button>\r\n\t</div>\r\n\t<div\r\n\t\t#dialogBody\r\n\t\tclass=\"dialog-body flex flex-col gap-y-4 p-6 overflow-y-auto relative z-99\"\r\n\t\t[ngClass]=\"{'overflow-hidden': loading}\"\r\n\t>\r\n\t\t<ng-container\r\n\t\t\t*ngTemplateOutlet=\"data?.dialogConfig?.contentTemplate || contentTemplate\"\r\n\t\t></ng-container>\r\n\t\t<ng-container *ngIf=\"loading\">\r\n\t\t\t<div\r\n\t\t\t\tclass=\"overlay flex w-full h-full items-center justify-center absolute left-0 bottom-0 right-0 bg-gray-300 opacity-40 z-999\"\r\n\t\t\t\t[ngStyle]=\"{'top': dialogBodyTopOffset + 'px'}\"\r\n\t\t\t></div>\r\n\t\t\t<div\r\n\t\t\t\tclass=\"overlay flex w-full h-full items-center justify-center absolute left-0 bottom-0 right-0 z-9999\"\r\n\t\t\t\t*ngIf=\"loaderMode === 'spinner'\"\r\n\t\t\t\t[ngStyle]=\"{'top': dialogBodyTopOffset + 'px'}\"\r\n\t\t\t>\r\n\t\t\t\t<mat-spinner\r\n\t\t\t\t\t[value]=\"90\"\r\n\t\t\t\t\t[strokeWidth]=\"4\"\r\n\t\t\t\t\toverlay=\"true\"\r\n\t\t\t\t\t[diameter]=\"40\"\r\n\t\t\t\t\tcolor=\"primary\"\r\n\t\t\t\t>\r\n\t\t\t\t</mat-spinner>\r\n\t\t\t</div>\r\n\t\t\t<div\r\n\t\t\t\tclass=\"block w-full h-px absolute inset-0 z-9999\"\r\n\t\t\t\t*ngIf=\"loaderMode === 'progressBar'\"\r\n\t\t\t>\r\n\t\t\t\t<mat-progress-bar mode=\"indeterminate\"></mat-progress-bar>\r\n\t\t\t</div>\r\n\t\t</ng-container>\r\n\t</div>\r\n\t<div class=\"flex w-full justify-end p-6 pt-0 gap-x-4\">\r\n\t\t<button class=\"cancelation-button\" (click)=\"executeAction()\">\r\n\t\t\t{{\"BUTTONS.CANCEL\" | translate}}\r\n\t\t</button>\r\n\t\t<ng-container\r\n\t\t\t*ngTemplateOutlet=\"(data?.dialogConfig?.actionsTemplate || actionsTemplate); context: { dialog: this }\"\r\n\t\t></ng-container>\r\n\t</div>\r\n</div>\r\n", styles: ["::ng-deep .ndf-dialog .mat-dialog-container{overflow:hidden!important;border-radius:8px!important}.ndf-dialog-wrapper .dialog-body{height:100%;max-height:calc(100vh - 208px)}:host{height:100%;display:block}\n"], components: [{ type: i2__namespace$1.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }], directives: [{ type: SetDirRtlDirective, selector: "[SetDirRtl]" }, { type: i2__namespace$2.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltipPosition", "matTooltipDisabled", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { type: i4__namespace$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i4__namespace$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i4__namespace$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4__namespace$1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }], pipes: { "translate": i1__namespace.TranslatePipe } });
2445
2445
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: NdfNuxeoDialog, decorators: [{
2446
2446
  type: i0.Component,
2447
2447
  args: [{
@@ -6665,7 +6665,7 @@
6665
6665
  return CorrespondenceRelationListComponent;
6666
6666
  }());
6667
6667
  CorrespondenceRelationListComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CorrespondenceRelationListComponent, deps: [{ token: CorrespondenceRelationService }, { token: i1__namespace$3.MatDialog }, { token: ViewerFilesService }, { token: DocumentsService }, { token: AdapterService }], target: i0__namespace.ɵɵFactoryTarget.Component });
6668
- CorrespondenceRelationListComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: CorrespondenceRelationListComponent, selector: "cts-correspondence-relation-list", inputs: { correspondence_id: "correspondence_id", reload: "reload" }, ngImport: i0__namespace, template: "<div class=\"relations-list\" *ngIf=\"relateddoc.length > 0\">\r\n <ng-container>\r\n <div *ngFor=\"let group of relateddoc; first as isFirst\">\r\n <mat-accordion class=\"example-headers-align\" multi>\r\n <mat-expansion-panel [expanded]=\"isFirst\">\r\n <mat-expansion-panel-header>\r\n <mat-panel-title>\r\n {{ group[0] }}\r\n </mat-panel-title>\r\n </mat-expansion-panel-header>\r\n <ng-template matExpansionPanelContent>\r\n <mat-list>\r\n <div class=\"mat-list-items\" *ngFor=\"let item of group[1]\">\r\n <cts-item-list\r\n [item]=\"item\"\r\n [title]=\"item.title\"\r\n [iconname]=\"'link'\"\r\n [actions]=\"menu_actions\"\r\n (actionclicked)=\"handleMenuItemClicked($event)\"\r\n (itemClicked)=\"showCorrespondenceInViewer(item)\"\r\n [moreclasses]=\"'link-relation'\"\r\n ></cts-item-list>\r\n </div>\r\n </mat-list>\r\n </ng-template>\r\n </mat-expansion-panel>\r\n </mat-accordion>\r\n </div>\r\n </ng-container>\r\n</div>\r\n<div class=\"nocontent\" *ngIf=\"relateddoc.length === 0\">\r\n <p>{{ \"correspondence-relation.nocontent\" | translate }}</p>\r\n</div>\r\n", styles: [".relations-list{border:1px solid #eee}.relations-list .mat-expansion-panel{box-shadow:none!important}.relations-list .mat-expansion-panel-header{border-bottom:1px solid #d9dce2;background-color:#f5f6f8;height:50px!important}.relations-list .mat-expansion-panel-header:hover{background-color:#f5f6f8!important}.relations-list .mat-expansion-panel-header:focus{background-color:#f5f6f8!important}.relations-list .mat-expansion-panel-header-title{font-weight:500}.relations-list .mat-accordion .mat-expansion-panel{border-radius:0!important}.relations-list .mat-expansion-panel-body{padding:0!important}.nocontent{color:gray;padding:10px;font-size:14px;border:1px solid #d9dce2}.nocontent p{margin:0;text-align:center}\n"], components: [{ type: i6__namespace$3.MatExpansionPanel, selector: "mat-expansion-panel", inputs: ["disabled", "expanded", "hideToggle", "togglePosition"], outputs: ["opened", "closed", "expandedChange", "afterExpand", "afterCollapse"], exportAs: ["matExpansionPanel"] }, { type: i6__namespace$3.MatExpansionPanelHeader, selector: "mat-expansion-panel-header", inputs: ["expandedHeight", "collapsedHeight"] }, { type: i2__namespace$4.MatList, selector: "mat-list, mat-action-list", inputs: ["disableRipple", "disabled"], exportAs: ["matList"] }, { type: ItemListComponent, selector: "cts-item-list", inputs: ["item", "iconname", "title", "actions", "isselected", "moreclasses"], outputs: ["itemClicked", "actionclicked"] }], directives: [{ type: i4__namespace$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4__namespace$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i6__namespace$3.MatAccordion, selector: "mat-accordion", inputs: ["multi", "displayMode", "togglePosition", "hideToggle"], exportAs: ["matAccordion"] }, { type: i6__namespace$3.MatExpansionPanelTitle, selector: "mat-panel-title" }, { type: i6__namespace$3.MatExpansionPanelContent, selector: "ng-template[matExpansionPanelContent]" }], pipes: { "translate": i1__namespace.TranslatePipe }, encapsulation: i0__namespace.ViewEncapsulation.None });
6668
+ CorrespondenceRelationListComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: CorrespondenceRelationListComponent, selector: "cts-correspondence-relation-list", inputs: { correspondence_id: "correspondence_id", reload: "reload" }, ngImport: i0__namespace, template: "<div class=\"relations-list\" *ngIf=\"relateddoc.length > 0\">\r\n <ng-container>\r\n <div *ngFor=\"let group of relateddoc; first as isFirst\">\r\n <mat-accordion class=\"example-headers-align\" multi>\r\n <mat-expansion-panel [expanded]=\"isFirst\">\r\n <mat-expansion-panel-header>\r\n <mat-panel-title>\r\n {{('vocabulary.VOC_CorrespondenceRelationsNames.' + group[0]) | translate }}\r\n </mat-panel-title>\r\n </mat-expansion-panel-header>\r\n <ng-template matExpansionPanelContent>\r\n <mat-list>\r\n <div class=\"mat-list-items\" *ngFor=\"let item of group[1]\">\r\n <cts-item-list\r\n [item]=\"item\"\r\n [title]=\"item.title\"\r\n [iconname]=\"'link'\"\r\n [actions]=\"menu_actions\"\r\n (actionclicked)=\"handleMenuItemClicked($event)\"\r\n (itemClicked)=\"showCorrespondenceInViewer(item)\"\r\n [moreclasses]=\"'link-relation'\"\r\n ></cts-item-list>\r\n </div>\r\n </mat-list>\r\n </ng-template>\r\n </mat-expansion-panel>\r\n </mat-accordion>\r\n </div>\r\n </ng-container>\r\n</div>\r\n<div class=\"nocontent\" *ngIf=\"relateddoc.length === 0\">\r\n <p>{{ \"correspondence-relation.nocontent\" | translate }}</p>\r\n</div>\r\n", styles: [".relations-list{border:1px solid #eee}.relations-list .mat-expansion-panel{box-shadow:none!important}.relations-list .mat-expansion-panel-header{border-bottom:1px solid #d9dce2;background-color:#f5f6f8;height:50px!important}.relations-list .mat-expansion-panel-header:hover{background-color:#f5f6f8!important}.relations-list .mat-expansion-panel-header:focus{background-color:#f5f6f8!important}.relations-list .mat-expansion-panel-header-title{font-weight:500}.relations-list .mat-accordion .mat-expansion-panel{border-radius:0!important}.relations-list .mat-expansion-panel-body{padding:0!important}.nocontent{color:gray;padding:10px;font-size:14px;border:1px solid #d9dce2}.nocontent p{margin:0;text-align:center}\n"], components: [{ type: i6__namespace$3.MatExpansionPanel, selector: "mat-expansion-panel", inputs: ["disabled", "expanded", "hideToggle", "togglePosition"], outputs: ["opened", "closed", "expandedChange", "afterExpand", "afterCollapse"], exportAs: ["matExpansionPanel"] }, { type: i6__namespace$3.MatExpansionPanelHeader, selector: "mat-expansion-panel-header", inputs: ["expandedHeight", "collapsedHeight"] }, { type: i2__namespace$4.MatList, selector: "mat-list, mat-action-list", inputs: ["disableRipple", "disabled"], exportAs: ["matList"] }, { type: ItemListComponent, selector: "cts-item-list", inputs: ["item", "iconname", "title", "actions", "isselected", "moreclasses"], outputs: ["itemClicked", "actionclicked"] }], directives: [{ type: i4__namespace$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4__namespace$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i6__namespace$3.MatAccordion, selector: "mat-accordion", inputs: ["multi", "displayMode", "togglePosition", "hideToggle"], exportAs: ["matAccordion"] }, { type: i6__namespace$3.MatExpansionPanelTitle, selector: "mat-panel-title" }, { type: i6__namespace$3.MatExpansionPanelContent, selector: "ng-template[matExpansionPanelContent]" }], pipes: { "translate": i1__namespace.TranslatePipe }, encapsulation: i0__namespace.ViewEncapsulation.None });
6669
6669
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CorrespondenceRelationListComponent, decorators: [{
6670
6670
  type: i0.Component,
6671
6671
  args: [{
@@ -22340,62 +22340,171 @@
22340
22340
  args: ['fileInput']
22341
22341
  }] } });
22342
22342
 
22343
- var CreateModalComponent = /** @class */ (function () {
22344
- function CreateModalComponent(data, dialogRef, uploadMangmentService, dialogMangmentService, fileMangerService, tosterService, formBuilder, adapeter, fileManagerService, appConfService, dateHelperService, translationService, userService, nuxeoService, environment, dynamicFormService) {
22345
- var _this = this;
22346
- this.data = data;
22347
- this.dialogRef = dialogRef;
22348
- this.uploadMangmentService = uploadMangmentService;
22349
- this.dialogMangmentService = dialogMangmentService;
22350
- this.fileMangerService = fileMangerService;
22351
- this.tosterService = tosterService;
22352
- this.formBuilder = formBuilder;
22353
- this.adapeter = adapeter;
22354
- this.fileManagerService = fileManagerService;
22355
- this.appConfService = appConfService;
22356
- this.dateHelperService = dateHelperService;
22357
- this.translationService = translationService;
22358
- this.userService = userService;
22359
- this.nuxeoService = nuxeoService;
22360
- this.environment = environment;
22361
- this.dynamicFormService = dynamicFormService;
22362
- this.addingProperties = false;
22363
- this.payloadList = [];
22364
- this.createWhenFinishMode = false;
22365
- this.showRenderer = false; // used to force renderer to feel changes in forms and value when changing files
22343
+ var CreateModalComponent = /** @class */ (function (_super) {
22344
+ __extends(CreateModalComponent, _super);
22345
+ function CreateModalComponent(data, uploadMangmentService, dialogMangmentService, fileMangerService, tosterService, formBuilder, adapeter, fileManagerService, appConfService, dateHelperService, userService, environment, injector, dynamicFormService) {
22346
+ var _this = _super.call(this, injector) || this;
22347
+ _this.data = data;
22348
+ _this.uploadMangmentService = uploadMangmentService;
22349
+ _this.dialogMangmentService = dialogMangmentService;
22350
+ _this.fileMangerService = fileMangerService;
22351
+ _this.tosterService = tosterService;
22352
+ _this.formBuilder = formBuilder;
22353
+ _this.adapeter = adapeter;
22354
+ _this.fileManagerService = fileManagerService;
22355
+ _this.appConfService = appConfService;
22356
+ _this.dateHelperService = dateHelperService;
22357
+ _this.userService = userService;
22358
+ _this.environment = environment;
22359
+ _this.dynamicFormService = dynamicFormService;
22360
+ _this.addingProperties = false;
22361
+ _this.payloadList = [];
22362
+ _this.createWhenFinishMode = false;
22363
+ _this.showRenderer = false; // used to force renderer to feel changes in forms and value when changing files
22366
22364
  // uploadFinishSubscription: Subscription;
22367
- this.usingExtraFields = false; // flage to switch between static form types
22368
- this.isArabic = false;
22369
- this.showStaticForm = false;
22370
- this.disableCreateWhenFinishBtn = true;
22371
- this.creating = false;
22372
- this.displayNoteMessage = true;
22373
- this.myEnvironment = this.environment;
22374
- this.createWhenFinishMode = false;
22375
- this.addingProperties = this.uploadMangmentService.addingPropertiesMode;
22376
- this.fileType = this.dialogMangmentService.fileType; // object that was constructed inside subtypes service
22377
- this.source = this.dialogMangmentService.addingFrom;
22378
- this.fileManagerService.getFileSchemas(this.fileType.type).subscribe(function (schemas) {
22365
+ _this.usingExtraFields = false; // flage to switch between static form types
22366
+ _this.showStaticForm = false;
22367
+ _this.disableCreateWhenFinishBtn = true;
22368
+ _this.creating = false;
22369
+ _this.displayNoteMessage = true;
22370
+ _this.createWhenFinish = function () {
22371
+ _this.createWhenFinishMode = true;
22372
+ return _this.minimizDialog();
22373
+ };
22374
+ _this.startAddingProperties = function () {
22375
+ //if starting from filemnager then i have fixed file type for all attachmetn and single dynaimc form type
22376
+ if (_this.source === 'fileManger') {
22377
+ // this.dynamicFormService.getDynamicForm(this.fileType).subscribe(res => {
22378
+ _this.uploadMangmentService.uploadedFilesStatus.uploadedFiles.forEach(function (file) {
22379
+ file['fileType'] = _this.source === 'fileManger' ? _this.fileType : {};
22380
+ file['dynamicForm'] = _this.dialogMangmentService.storedDynamicForm;
22381
+ file['dynamicData'] = {};
22382
+ file['staticFormValid'] = _this.usingExtraFields ? false : true;
22383
+ file['staticData'] = _this.setStaticData(file.title ? file.title : file.name);
22384
+ file['generalValidationValid'] = true;
22385
+ });
22386
+ _this.uploadMangmentService.uploadedFilesStatus.allfiles.forEach(function (file) {
22387
+ file['fileType'] = _this.source === 'fileManger' ? _this.fileType : {};
22388
+ file['dynamicForm'] = _this.dialogMangmentService.storedDynamicForm;
22389
+ file['dynamicData'] = {};
22390
+ file['staticFormValid'] = _this.usingExtraFields ? false : true;
22391
+ file['staticData'] = _this.setStaticData(file.title ? file.title : file.name);
22392
+ file['generalValidationValid'] = true;
22393
+ });
22394
+ }
22395
+ _this.addingProperties = true;
22396
+ _this.uploadMangmentService.addingPropertiesMode = true;
22397
+ };
22398
+ _this.createDocument = function () {
22399
+ var _a, _b;
22400
+ _this.creating = true;
22401
+ _this.uploadMangmentService.failedFiles = [];
22402
+ _this.uploadMangmentService.GeneralFormValidation = _this.checkValidation();
22403
+ if (_this.uploadMangmentService.GeneralFormValidation) {
22404
+ var apiCalls_1 = [];
22405
+ if (((_a = _this.data) === null || _a === void 0 ? void 0 : _a.path.includes('/default-domain/workspaces/DMSWorkspaces')) ||
22406
+ ((_b = _this.data) === null || _b === void 0 ? void 0 : _b.path.includes('/default-domain/UserWorkspaces/'))) {
22407
+ _this.constructPayLoadToWorkSpace(_this.uploadMangmentService.uploadedFilesStatus.uploadedFiles);
22408
+ _this.payloadList.forEach(function (payload) {
22409
+ apiCalls_1.push(_this.fileMangerService.createFile(payload, _this.fileManagerService.selectedFolderId, 'DMS.CreateDocumentFromBlob'));
22410
+ });
22411
+ }
22412
+ else {
22413
+ _this.constructPayLoad(_this.uploadMangmentService.uploadedFilesStatus.uploadedFiles);
22414
+ _this.payloadList.forEach(function (payload) {
22415
+ apiCalls_1.push(_this.fileMangerService.createFile(payload, _this.fileManagerService.selectedFolderId));
22416
+ });
22417
+ }
22418
+ return rxjs.forkJoin(apiCalls_1).pipe(operators.tap(function (response) {
22419
+ _this.creating = false;
22420
+ response.forEach(function (singleRes) {
22421
+ if (singleRes['status'] && singleRes['status'] === 'failed') {
22422
+ _this.uploadMangmentService.failedFiles.push(singleRes['originFile']);
22423
+ }
22424
+ });
22425
+ if (_this.uploadMangmentService.failedFiles.length > 0) {
22426
+ _this.tosterService.show('error', 'TOASTER.ERROR', 'TOASTER.UPLOAD_ERROR');
22427
+ _this.uploadMangmentService.uploadedFilesStatus.uploadedFiles = [];
22428
+ _this.selectedFile = null;
22429
+ _this.uploadMangmentService.uploadedFilesStatus.allfiles = __spreadArray([], __read(_this.uploadMangmentService.failedFiles));
22430
+ }
22431
+ else {
22432
+ _this.fileMangerService.onRefreshingFileManger.next();
22433
+ _this.tosterService.show('success', 'TOASTER.SUCCESS', 'TOASTER.FILE_CREATED_SUCCE');
22434
+ _super.prototype.close.call(_this, false);
22435
+ _this.uploadMangmentService.resetStatus();
22436
+ }
22437
+ }, function (error) {
22438
+ _this.creating = false;
22439
+ }));
22440
+ }
22441
+ else {
22442
+ _this.creating = false;
22443
+ return rxjs.of(null);
22444
+ }
22445
+ };
22446
+ _this.tryAgainCreateDocument = function () {
22447
+ _this.uploadMangmentService.uploadFilesMangment(_this.uploadMangmentService.failedFiles);
22448
+ return rxjs.of(null);
22449
+ };
22450
+ _this.minimizDialog = function () {
22451
+ _super.prototype.close.call(_this, true);
22452
+ return rxjs.of(null);
22453
+ };
22454
+ _this.ApplyChangesToAll = function () {
22455
+ _this.uploadMangmentService.uploadedFilesStatus.uploadedFiles.forEach(function (file) {
22456
+ var title = file['staticData']
22457
+ ? file['staticData']['title']
22458
+ : file.name;
22459
+ file['fileType'] = _this.selectedFile.fileType;
22460
+ file['dynamicForm'] = _this.selectedFile.dynamicForm;
22461
+ file['dynamicData'] = _this.selectedFile.dynamicData;
22462
+ file['staticFormValid'] = _this.selectedFile.staticFormValid;
22463
+ file['staticData'] = Object.assign({}, _this.fileForm.value);
22464
+ file['staticData']['title'] = title;
22465
+ });
22466
+ _this.uploadMangmentService.uploadedFilesStatus.allfiles.forEach(function (file) {
22467
+ var title = file['staticData'] ? file['staticData']['title'] : file.name;
22468
+ file['fileType'] = _this.selectedFile.fileType;
22469
+ file['dynamicForm'] = _this.selectedFile.dynamicForm;
22470
+ file['dynamicData'] = _this.selectedFile.dynamicData;
22471
+ file['staticFormValid'] = _this.selectedFile.staticFormValid;
22472
+ file['staticData'] = Object.assign({}, _this.fileForm.value);
22473
+ file['staticData']['title'] = title;
22474
+ });
22475
+ return rxjs.of(null);
22476
+ };
22477
+ _this.myEnvironment = _this.environment;
22478
+ _this.createWhenFinishMode = false;
22479
+ _this.addingProperties = _this.uploadMangmentService.addingPropertiesMode;
22480
+ _this.fileType = _this.dialogMangmentService.fileType; // object that was constructed inside subtypes service
22481
+ _this.source = _this.dialogMangmentService.addingFrom;
22482
+ _this.fileManagerService
22483
+ .getFileSchemas(_this.fileType.type)
22484
+ .subscribe(function (schemas) {
22379
22485
  schemas.map(function (item) {
22380
- if (item.name === "generaldocument") {
22486
+ if (item.name === 'generaldocument') {
22381
22487
  _this.usingExtraFields = true;
22382
22488
  }
22383
22489
  });
22384
22490
  _this.initiatfileForm();
22385
22491
  _this.uploadMangmentService.gettingPropFromModal({
22386
- 'fileType': _this.source === 'fileManger' ? _this.fileType : {},
22387
- 'dynamicForm': _this.dialogMangmentService.storedDynamicForm,
22388
- 'dynamicData': {},
22389
- 'staticFormValid': _this.usingExtraFields ? false : true,
22390
- 'generalValidationValid': true,
22391
- 'usingExtraFields': _this.usingExtraFields,
22392
- 'path': _this.data.path
22492
+ fileType: _this.source === 'fileManger' ? _this.fileType : {},
22493
+ dynamicForm: _this.dialogMangmentService.storedDynamicForm,
22494
+ dynamicData: {},
22495
+ staticFormValid: _this.usingExtraFields ? false : true,
22496
+ generalValidationValid: true,
22497
+ usingExtraFields: _this.usingExtraFields,
22498
+ path: _this.data.path
22393
22499
  });
22394
22500
  });
22501
+ return _this;
22395
22502
  }
22396
22503
  CreateModalComponent.prototype.KeyUpEvent = function (event) {
22397
- if (this.addingProperties && this.uploadMangmentService.failedFiles.length === 0) {
22398
- if (this.uploadMangmentService.uploadedFilesStatus.uploadInProgress && !this.disableCreateWhenFinishBtn) {
22504
+ if (this.addingProperties &&
22505
+ this.uploadMangmentService.failedFiles.length === 0) {
22506
+ if (this.uploadMangmentService.uploadedFilesStatus.uploadInProgress &&
22507
+ !this.disableCreateWhenFinishBtn) {
22399
22508
  this.createWhenFinish();
22400
22509
  }
22401
22510
  else {
@@ -22405,17 +22514,16 @@
22405
22514
  };
22406
22515
  CreateModalComponent.prototype.ngOnInit = function () {
22407
22516
  var _this = this;
22408
- this.langSubscription = this.translationService.isArabic.subscribe(function (res) {
22409
- _this.isArabic = res;
22410
- });
22411
22517
  if (this.uploadMangmentService.uploadFinishSubscription) {
22412
22518
  this.uploadMangmentService.uploadFinishSubscription.unsubscribe();
22413
22519
  }
22414
- this.uploadMangmentService.uploadFinishSubscription = this.uploadMangmentService.onUploadFinish.subscribe(function (res) {
22415
- if (_this.createWhenFinishMode || _this.uploadMangmentService.failedFiles.length > 0) {
22416
- _this.createDocument();
22417
- }
22418
- });
22520
+ this.uploadMangmentService.uploadFinishSubscription =
22521
+ this.uploadMangmentService.onUploadFinish.subscribe(function (res) {
22522
+ if (_this.createWhenFinishMode ||
22523
+ _this.uploadMangmentService.failedFiles.length > 0) {
22524
+ _this.createDocument();
22525
+ }
22526
+ });
22419
22527
  };
22420
22528
  CreateModalComponent.prototype.initiatfileForm = function () {
22421
22529
  if (this.usingExtraFields) {
@@ -22441,44 +22549,16 @@
22441
22549
  description: ['']
22442
22550
  });
22443
22551
  }
22444
- this.staticFormFields = this.appConfService.myConfiguration.staticFormFields;
22445
- };
22446
- CreateModalComponent.prototype.createWhenFinish = function () {
22447
- this.createWhenFinishMode = true;
22448
- this.minimizDialog();
22552
+ this.staticFormFields =
22553
+ this.appConfService.myConfiguration.staticFormFields;
22449
22554
  };
22450
- CreateModalComponent.prototype.closeDialog = function () {
22555
+ CreateModalComponent.prototype.close = function () {
22451
22556
  this.uploadMangmentService.GeneralFormValidation = true;
22452
22557
  this.fileFormSubscription ? this.fileFormSubscription.unsubscribe() : '';
22453
22558
  this.addingProperties = false;
22454
22559
  this.uploadMangmentService.resetStatus();
22455
- this.dialogRef.close(false);
22456
- };
22457
- CreateModalComponent.prototype.startAddingProperties = function () {
22458
- var _this = this;
22459
- //if starting from filemnager then i have fixed file type for all attachmetn and single dynaimc form type
22460
- if (this.source === 'fileManger') {
22461
- // this.dynamicFormService.getDynamicForm(this.fileType).subscribe(res => {
22462
- this.uploadMangmentService.uploadedFilesStatus.uploadedFiles.map(function (file) {
22463
- file['fileType'] = _this.source === 'fileManger' ? _this.fileType : {};
22464
- file['dynamicForm'] = _this.dialogMangmentService.storedDynamicForm;
22465
- file['dynamicData'] = {};
22466
- file['staticFormValid'] = _this.usingExtraFields ? false : true;
22467
- file['staticData'] = _this.setStaticData(file.title ? file.title : file.name);
22468
- file['generalValidationValid'] = true;
22469
- });
22470
- this.uploadMangmentService.uploadedFilesStatus.allfiles.map(function (file) {
22471
- file['fileType'] = _this.source === 'fileManger' ? _this.fileType : {};
22472
- file['dynamicForm'] = _this.dialogMangmentService.storedDynamicForm;
22473
- file['dynamicData'] = {};
22474
- file['staticFormValid'] = _this.usingExtraFields ? false : true;
22475
- file['staticData'] = _this.setStaticData(file.title ? file.title : file.name);
22476
- file['generalValidationValid'] = true;
22477
- });
22478
- // })
22479
- }
22480
- this.addingProperties = true;
22481
- this.uploadMangmentService.addingPropertiesMode = true;
22560
+ _super.prototype.close.call(this);
22561
+ return rxjs.of(null);
22482
22562
  };
22483
22563
  CreateModalComponent.prototype.setStaticData = function (title) {
22484
22564
  if (this.usingExtraFields) {
@@ -22505,73 +22585,19 @@
22505
22585
  };
22506
22586
  }
22507
22587
  };
22508
- CreateModalComponent.prototype.createDocument = function () {
22509
- var _this = this;
22510
- var _a, _b;
22511
- this.creating = true;
22512
- this.uploadMangmentService.failedFiles = [];
22513
- this.uploadMangmentService.GeneralFormValidation = this.checkValidation();
22514
- if (this.uploadMangmentService.GeneralFormValidation) {
22515
- var apiCalls_1 = [];
22516
- if (((_a = this.data) === null || _a === void 0 ? void 0 : _a.path.includes('/default-domain/workspaces/DMSWorkspaces')) || ((_b = this.data) === null || _b === void 0 ? void 0 : _b.path.includes('/default-domain/UserWorkspaces/'))) {
22517
- this.constructPayLoadToWorkSpace(this.uploadMangmentService.uploadedFilesStatus.uploadedFiles);
22518
- this.payloadList.map(function (payload) {
22519
- apiCalls_1.push(_this.fileMangerService.createFile(payload, _this.fileManagerService.selectedFolderId, 'DMS.CreateDocumentFromBlob'));
22520
- });
22521
- }
22522
- else {
22523
- this.constructPayLoad(this.uploadMangmentService.uploadedFilesStatus.uploadedFiles);
22524
- this.payloadList.map(function (payload) {
22525
- apiCalls_1.push(_this.fileMangerService.createFile(payload, _this.fileManagerService.selectedFolderId));
22526
- });
22527
- }
22528
- rxjs.forkJoin(apiCalls_1).subscribe(function (response) {
22529
- //console.log(res);
22530
- _this.creating = false;
22531
- response.map(function (singleRes) {
22532
- if (singleRes['status'] && singleRes['status'] === 'failed') {
22533
- _this.uploadMangmentService.failedFiles.push(singleRes['originFile']);
22534
- }
22535
- });
22536
- if (_this.uploadMangmentService.failedFiles.length > 0) {
22537
- _this.tosterService.show('error', 'TOASTER.ERROR', 'TOASTER.UPLOAD_ERROR');
22538
- _this.uploadMangmentService.uploadedFilesStatus.uploadedFiles = [];
22539
- _this.selectedFile = null;
22540
- _this.uploadMangmentService.uploadedFilesStatus.allfiles = __spreadArray([], __read(_this.uploadMangmentService.failedFiles));
22541
- }
22542
- else {
22543
- _this.fileMangerService.onRefreshingFileManger.next();
22544
- _this.tosterService.show('success', 'TOASTER.SUCCESS', "TOASTER.FILE_CREATED_SUCCE");
22545
- _this.dialogRef.close(false);
22546
- _this.uploadMangmentService.resetStatus();
22547
- }
22548
- }, function (error) {
22549
- _this.creating = false;
22550
- // console.log(error);
22551
- // this.tosterService.show('error' , 'TOASTER.ERROR' , 'TOASTER.UPLOAD_ERROR');
22552
- // this.closeDialog();
22553
- });
22554
- }
22555
- else {
22556
- this.creating = false;
22557
- }
22558
- };
22559
22588
  CreateModalComponent.prototype.constructPayLoadToWorkSpace = function (files) {
22560
22589
  var _this = this;
22561
22590
  this.payloadList = [];
22562
22591
  files.map(function (file) {
22563
22592
  var param = {
22564
- "fileindex": 0,
22565
- "fileName": file.staticData.title,
22566
- "batchid": file.batch.blob['upload-batch'],
22567
- "description": _this.fileForm.controls.description.value
22593
+ fileindex: 0,
22594
+ fileName: file.staticData.title,
22595
+ batchid: file.batch.blob['upload-batch'],
22596
+ description: _this.fileForm.controls.description.value
22568
22597
  };
22569
22598
  _this.payloadList.push({ params: param, originFile: file });
22570
22599
  });
22571
22600
  };
22572
- CreateModalComponent.prototype.tryAgainCreateDocument = function () {
22573
- this.uploadMangmentService.uploadFilesMangment(this.uploadMangmentService.failedFiles);
22574
- };
22575
22601
  CreateModalComponent.prototype.constructPayLoad = function (files) {
22576
22602
  var _this = this;
22577
22603
  this.payloadList = [];
@@ -22579,18 +22605,18 @@
22579
22605
  var props = _this.dynamicFormService.constructDynamicFormPayload(file.dynamicData.data ? file.dynamicData.data : {}, file.dynamicForm);
22580
22606
  var staticFormData = _this.mappingStaticData(file.staticData);
22581
22607
  var param = {
22582
- "document": {
22583
- "type": file.fileType.type,
22584
- "name": file.staticData.title,
22585
- "properties": Object.assign(Object.assign(Object.assign({}, props), staticFormData), { "file:content": {
22586
- "upload-batch": file.batch.blob['upload-batch'],
22587
- "upload-fileId": file.batch.blob['upload-fileId'],
22588
- "mime-type": file.type
22608
+ document: {
22609
+ type: file.fileType.type,
22610
+ name: file.staticData.title,
22611
+ properties: Object.assign(Object.assign(Object.assign({}, props), staticFormData), { 'file:content': {
22612
+ 'upload-batch': file.batch.blob['upload-batch'],
22613
+ 'upload-fileId': file.batch.blob['upload-fileId'],
22614
+ 'mime-type': file.type
22589
22615
  } })
22590
22616
  }
22591
22617
  };
22592
22618
  if (file.fileType.documentCode) {
22593
- param["documentTypeCode"] = file.fileType.documentCode;
22619
+ param['documentTypeCode'] = file.fileType.documentCode;
22594
22620
  }
22595
22621
  _this.payloadList.push({ params: param, originFile: file });
22596
22622
  });
@@ -22599,13 +22625,14 @@
22599
22625
  if (data.gdocumentDate && data.gdocumentDate !== null) {
22600
22626
  moment__namespace.locale('en');
22601
22627
  data['hdocumentDate'] = this.dateHelperService.gregorianToHijri(data.gdocumentDate, 'iYYYY-iMM-iDD');
22602
- data.gdocumentDate = (moment__namespace(data.gdocumentDate).format("YYYY-MM-DDT00:00:00.000") + "Z");
22628
+ data.gdocumentDate =
22629
+ moment__namespace(data.gdocumentDate).format('YYYY-MM-DDT00:00:00.000') + 'Z';
22603
22630
  }
22604
22631
  return this.adapeter.adaptOut(data, this.staticFormFields);
22605
22632
  };
22606
22633
  CreateModalComponent.prototype.selectFile = function (file) {
22607
22634
  var _this = this;
22608
- console.log("file in select", file);
22635
+ console.log('file in select', file);
22609
22636
  this.showStaticForm = false;
22610
22637
  this.agencyNameFilter = undefined;
22611
22638
  this.countryNameFilter = undefined;
@@ -22617,8 +22644,13 @@
22617
22644
  this.showRenderer = false;
22618
22645
  // check if file has properties of adding properties or not then add it to him
22619
22646
  if (!file.hasOwnProperty('fileType')) {
22620
- this.dynamicFormService.getDynamicForm(this.fileType.documentCode ? this.fileType.documentCode : this.fileType.type).subscribe(function (res) {
22621
- file['fileType'] = _this.source === 'fileManger' ? _this.fileType : {};
22647
+ this.dynamicFormService
22648
+ .getDynamicForm(this.fileType.documentCode
22649
+ ? this.fileType.documentCode
22650
+ : this.fileType.type)
22651
+ .subscribe(function (res) {
22652
+ file['fileType'] =
22653
+ _this.source === 'fileManger' ? _this.fileType : {};
22622
22654
  file['dynamicForm'] = res;
22623
22655
  file['dynamicData'] = {};
22624
22656
  file['staticFormValid'] = _this.usingExtraFields ? false : true;
@@ -22630,7 +22662,8 @@
22630
22662
  }
22631
22663
  _this.fileForm.patchValue(_this.selectedFile['staticData']);
22632
22664
  _this.temporaryDyanmicData = {};
22633
- _this.temporaryDyanmicData = _this.selectedFile.dynamicData.data ? Object.assign({}, _this.selectedFile.dynamicData.data) : {};
22665
+ _this.temporaryDyanmicData = _this.selectedFile.dynamicData.data
22666
+ ? Object.assign({}, _this.selectedFile.dynamicData.data) : {};
22634
22667
  setTimeout(function () {
22635
22668
  _this.showRenderer = true;
22636
22669
  _this.showStaticForm = true;
@@ -22638,12 +22671,19 @@
22638
22671
  //console.log(file);
22639
22672
  if (!_this.fileFormSubscription) {
22640
22673
  setTimeout(function () {
22641
- _this.fileFormSubscription = _this.fileForm.valueChanges.subscribe(function (res) {
22642
- _this.selectedFile.staticFormValid = _this.fileForm ? _this.fileForm.valid : false;
22643
- _this.selectedFile.staticData = _this.fileForm ? _this.fileForm.value : {};
22644
- });
22674
+ _this.fileFormSubscription =
22675
+ _this.fileForm.valueChanges.subscribe(function (res) {
22676
+ _this.selectedFile.staticFormValid = _this.fileForm
22677
+ ? _this.fileForm.valid
22678
+ : false;
22679
+ _this.selectedFile.staticData = _this.fileForm
22680
+ ? _this.fileForm.value
22681
+ : {};
22682
+ });
22645
22683
  if (_this.fileForm.get('agencyCategoryCode')) {
22646
- _this.agencyCategCodeSubscription = _this.fileForm.get('agencyCategoryCode').valueChanges.subscribe(function (res) {
22684
+ _this.agencyCategCodeSubscription = _this.fileForm
22685
+ .get('agencyCategoryCode')
22686
+ .valueChanges.subscribe(function (res) {
22647
22687
  _this.fileForm.get('agencyName').setValue(null);
22648
22688
  _this.agencyNameFilter = {
22649
22689
  category: res
@@ -22651,7 +22691,9 @@
22651
22691
  });
22652
22692
  }
22653
22693
  if (_this.fileForm.get('countryCategoryCode')) {
22654
- _this.countryCategCodeSubscription = _this.fileForm.get('countryCategoryCode').valueChanges.subscribe(function (res) {
22694
+ _this.countryCategCodeSubscription = _this.fileForm
22695
+ .get('countryCategoryCode')
22696
+ .valueChanges.subscribe(function (res) {
22655
22697
  _this.fileForm.get('countryName').setValue(null);
22656
22698
  _this.countryNameFilter = {
22657
22699
  category: res
@@ -22679,7 +22721,9 @@
22679
22721
  };
22680
22722
  }
22681
22723
  this.temporaryDyanmicData = {};
22682
- this.temporaryDyanmicData = this.selectedFile.dynamicData.data ? this.selectedFile.dynamicData.data : {};
22724
+ this.temporaryDyanmicData = this.selectedFile.dynamicData.data
22725
+ ? this.selectedFile.dynamicData.data
22726
+ : {};
22683
22727
  setTimeout(function () {
22684
22728
  _this.showRenderer = true;
22685
22729
  _this.showStaticForm = true;
@@ -22687,11 +22731,17 @@
22687
22731
  if (!this.fileFormSubscription) {
22688
22732
  setTimeout(function () {
22689
22733
  _this.fileFormSubscription = _this.fileForm.valueChanges.subscribe(function (res) {
22690
- _this.selectedFile.staticFormValid = _this.fileForm ? _this.fileForm.valid : false;
22691
- _this.selectedFile.staticData = _this.fileForm ? _this.fileForm.value : {};
22734
+ _this.selectedFile.staticFormValid = _this.fileForm
22735
+ ? _this.fileForm.valid
22736
+ : false;
22737
+ _this.selectedFile.staticData = _this.fileForm
22738
+ ? _this.fileForm.value
22739
+ : {};
22692
22740
  });
22693
22741
  if (_this.fileForm.get('agencyCategoryCode')) {
22694
- _this.agencyCategCodeSubscription = _this.fileForm.get('agencyCategoryCode').valueChanges.subscribe(function (res) {
22742
+ _this.agencyCategCodeSubscription = _this.fileForm
22743
+ .get('agencyCategoryCode')
22744
+ .valueChanges.subscribe(function (res) {
22695
22745
  _this.fileForm.get('agencyName').setValue(null);
22696
22746
  _this.agencyNameFilter = {
22697
22747
  category: res
@@ -22699,7 +22749,9 @@
22699
22749
  });
22700
22750
  }
22701
22751
  if (_this.fileForm.get('countryCategoryCode')) {
22702
- _this.countryCategCodeSubscription = _this.fileForm.get('countryCategoryCode').valueChanges.subscribe(function (res) {
22752
+ _this.countryCategCodeSubscription = _this.fileForm
22753
+ .get('countryCategoryCode')
22754
+ .valueChanges.subscribe(function (res) {
22703
22755
  _this.fileForm.get('countryName').setValue(null);
22704
22756
  _this.countryNameFilter = {
22705
22757
  category: res
@@ -22721,9 +22773,6 @@
22721
22773
  this.selectedFile.dynamicData = Object.assign({}, dynamicData);
22722
22774
  }
22723
22775
  };
22724
- CreateModalComponent.prototype.minimizDialog = function () {
22725
- this.dialogRef.close(true);
22726
- };
22727
22776
  CreateModalComponent.prototype.removeItem = function (item, listofFiles) {
22728
22777
  var removeIndex = listofFiles.findIndex(function (file) { return file.name === item.name; });
22729
22778
  listofFiles.splice(removeIndex, 1);
@@ -22737,33 +22786,14 @@
22737
22786
  // this.selectedFile = null;
22738
22787
  }
22739
22788
  };
22740
- CreateModalComponent.prototype.ApplyChangesToAll = function () {
22741
- var _this = this;
22742
- this.uploadMangmentService.uploadedFilesStatus.uploadedFiles.map(function (file) {
22743
- var title = file['staticData'] ? file['staticData']['title'] : file.name;
22744
- file['fileType'] = _this.selectedFile.fileType;
22745
- file['dynamicForm'] = _this.selectedFile.dynamicForm;
22746
- file['dynamicData'] = _this.selectedFile.dynamicData;
22747
- file['staticFormValid'] = _this.selectedFile.staticFormValid;
22748
- file['staticData'] = Object.assign({}, _this.fileForm.value);
22749
- file['staticData']['title'] = title;
22750
- });
22751
- this.uploadMangmentService.uploadedFilesStatus.allfiles.map(function (file) {
22752
- var title = file['staticData'] ? file['staticData']['title'] : file.name;
22753
- file['fileType'] = _this.selectedFile.fileType;
22754
- file['dynamicForm'] = _this.selectedFile.dynamicForm;
22755
- file['dynamicData'] = _this.selectedFile.dynamicData;
22756
- file['staticFormValid'] = _this.selectedFile.staticFormValid;
22757
- file['staticData'] = Object.assign({}, _this.fileForm.value);
22758
- file['staticData']['title'] = title;
22759
- });
22760
- };
22761
22789
  CreateModalComponent.prototype.checkValidation = function () {
22762
22790
  var validation = true;
22763
- this.uploadMangmentService.uploadedFilesStatus.uploadedFiles.map(function (file) {
22791
+ this.uploadMangmentService.uploadedFilesStatus.uploadedFiles.forEach(function (file) {
22764
22792
  var _a, _b;
22765
- console.log("file", file);
22766
- if (!file.hasOwnProperty('fileType') || file['staticFormValid'] === false || ((_b = (_a = file.dynamicData) === null || _a === void 0 ? void 0 : _a.originalEvent) === null || _b === void 0 ? void 0 : _b.isValid) === false) {
22793
+ console.log('file', file);
22794
+ if (!file.hasOwnProperty('fileType') ||
22795
+ file['staticFormValid'] === false ||
22796
+ ((_b = (_a = file.dynamicData) === null || _a === void 0 ? void 0 : _a.originalEvent) === null || _b === void 0 ? void 0 : _b.isValid) === false) {
22767
22797
  file['generalValidationValid'] = false;
22768
22798
  validation = false;
22769
22799
  }
@@ -22773,7 +22803,8 @@
22773
22803
  });
22774
22804
  this.uploadMangmentService.uploadedFilesStatus.allfiles.map(function (file) {
22775
22805
  var _a, _b;
22776
- if (file['staticFormValid'] === false || ((_b = (_a = file.dynamicData) === null || _a === void 0 ? void 0 : _a.originalEvent) === null || _b === void 0 ? void 0 : _b.isValid) === false) {
22806
+ if (file['staticFormValid'] === false ||
22807
+ ((_b = (_a = file.dynamicData) === null || _a === void 0 ? void 0 : _a.originalEvent) === null || _b === void 0 ? void 0 : _b.isValid) === false) {
22777
22808
  file['generalValidationValid'] = false;
22778
22809
  validation = false;
22779
22810
  }
@@ -22785,14 +22816,17 @@
22785
22816
  };
22786
22817
  CreateModalComponent.prototype.ngOnDestroy = function () {
22787
22818
  this.fileFormSubscription ? this.fileFormSubscription.unsubscribe() : '';
22788
- this.langSubscription ? this.langSubscription.unsubscribe() : '';
22789
- this.countryCategCodeSubscription ? this.countryCategCodeSubscription.unsubscribe() : '';
22790
- this.agencyCategCodeSubscription ? this.agencyCategCodeSubscription.unsubscribe() : '';
22819
+ this.countryCategCodeSubscription
22820
+ ? this.countryCategCodeSubscription.unsubscribe()
22821
+ : '';
22822
+ this.agencyCategCodeSubscription
22823
+ ? this.agencyCategCodeSubscription.unsubscribe()
22824
+ : '';
22791
22825
  };
22792
22826
  return CreateModalComponent;
22793
- }());
22794
- CreateModalComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CreateModalComponent, deps: [{ token: i1$4.MAT_DIALOG_DATA }, { token: i1__namespace$3.MatDialogRef }, { token: UploadManagmentService }, { token: DialogMangmentService }, { token: FileManagerService }, { token: CustomToastrService }, { token: i6__namespace.FormBuilder }, { token: AdapterService }, { token: FileManagerService }, { token: AppConfigService }, { token: DateHelperService }, { token: TranslationService }, { token: UserService }, { token: NuxeoService }, { token: 'environment' }, { token: DynamicFormService }], target: i0__namespace.ɵɵFactoryTarget.Component });
22795
- CreateModalComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: CreateModalComponent, selector: "app-create-modal", host: { listeners: { "document:keyup.enter": "KeyUpEvent($event)" } }, ngImport: i0__namespace, template: "<div class=\"relative w-full h-full\">\r\n <div class=\"iner-wrapper\" [ngClass]=\"{ 'd-flex': addingProperties }\">\r\n <div *ngIf=\"addingProperties\" class=\"properties-section p-3 overflow-x-hidden overflow-y-auto\">\r\n <div class=\"\" *ngIf=\"selectedFile && source === 'fileManger' && showStaticForm\">\r\n <div class=\"mb-5\">\r\n <div class=\"label-style\">\r\n {{ \"CREATE.FILE_TYPE\" | translate }}\r\n </div>\r\n <div class=\"text-base text-gray-900\">{{ isArabic ? fileType.arabicText : fileType.englishText }}\r\n </div>\r\n </div>\r\n <div class=\"file-fields mt-3\" SetRtl>\r\n <form [formGroup]=\"fileForm\">\r\n <!-- -----------------old static form ---------------------- -->\r\n <div>\r\n <div class=\"single-field mb-3\">\r\n <div class=\"label-style\">\r\n {{ \"CREATE.TITLE\" | translate\r\n }}<span class=\"text-red-500\">*</span>\r\n </div>\r\n <input class=\"\r\n field-style\r\n \" formControlName=\"title\" placeholder=\" {{ 'CREATE.TITLE' | translate}}\" />\r\n </div>\r\n <div class=\"single-field mb-3\">\r\n <div class=\"label-style\">\r\n {{ \"CREATE.DESCRIPTION\" | translate }}\r\n </div>\r\n <input class=\"field-style\" formControlName=\"description\"\r\n placeholder=\" {{ 'CREATE.DESCRIPTION' | translate}}\" />\r\n </div>\r\n </div>\r\n <!-- ---------------------------------- -->\r\n\r\n <!------------------ new statis form ---------------------------->\r\n <div *ngIf=\"usingExtraFields\">\r\n <app-dynamic-fields-renderer [form]=\"fileForm\" [agencyNameFilter]=\"agencyNameFilter\"\r\n [countryNameFilter]=\"countryNameFilter\"></app-dynamic-fields-renderer>\r\n </div>\r\n </form>\r\n\r\n <div class=\"dynamic-part\" *ngIf=\"showRenderer\">\r\n <app-dynamic-form [form]=\"selectedFile.dynamicForm\" [data]=\"temporaryDyanmicData\"\r\n (change)=\"ondynamicFormChange($event)\"></app-dynamic-form>\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"\r\n w-full\r\n h-full\r\n p-3\r\n flex\r\n justify-center\r\n items-center\r\n text-lg text-gray-900\"\r\n *ngIf=\"!selectedFile\">\r\n {{ \"CREATE.SELECT_TOSTART_ADDING\" | translate }}\r\n </div>\r\n \r\n </div>\r\n <div class=\"attachment-tab-body overflow-hidden\" [ngClass]=\"{ 'attachment-iner-small-body': addingProperties }\">\r\n <app-attachments [multiple]=\"true\" (onSelectingItem)=\"selectFile($event)\"></app-attachments>\r\n </div>\r\n </div>\r\n <div class=\"w-full text-red-500 text-base text-start px-3\" *ngIf=\"!uploadMangmentService.GeneralFormValidation\">\r\n\r\n {{ \"CREATE.FILL_REQUIRED_FIELD\" | translate }}\r\n </div>\r\n <div class=\"actions-iner-wrapper w-full flex justify-between items-center absolute bottom-0\">\r\n <div class=\"flex\">\r\n <button *ngIf=\"\r\n (uploadMangmentService.uploadedFilesStatus\r\n .uploadInProgress ||\r\n uploadMangmentService.uploadedFilesStatus.uploadedFiles\r\n .length > 0) &&\r\n !addingProperties\r\n \" (click)=\"startAddingProperties()\" class=\"submission-button\">\r\n {{ \"BUTTONS.ADD_PROPERTIES\" | translate }}\r\n </button>\r\n <button *ngIf=\"\r\n addingProperties &&\r\n uploadMangmentService.uploadedFilesStatus.uploadedFiles\r\n .length +\r\n uploadMangmentService.uploadedFilesStatus.allfiles\r\n .length >\r\n 1\r\n \" (click)=\"ApplyChangesToAll()\" [disabled]=\"!selectedFile || !selectedFile.staticFormValid\" [ngClass]=\"{\r\n 'opacity-30 cursor-not-allowed':\r\n !selectedFile || !selectedFile.staticFormValid,\r\n 'cursor-pointer hover:text-white hover:bg-gray-900': !(\r\n !selectedFile || !selectedFile.staticFormValid\r\n )\r\n }\" class=\"submission-button mx-2\">\r\n {{ \"BUTTONS.APPLY_TO_ALL\" | translate }}\r\n </button>\r\n\r\n <ng-container *ngIf=\"\r\n addingProperties &&\r\n !uploadMangmentService.uploadedFilesStatus.uploadInProgress &&\r\n uploadMangmentService.failedFiles.length === 0\r\n \">\r\n <button (click)=\"createDocument()\" class=\"submission-button relative\" [disabled]=\"creating\">\r\n <span *ngIf=\"!creating; else loader\">{{ \"BUTTONS.CREATE\" | translate }}</span>\r\n </button>\r\n <ng-template #loader>\r\n <mat-spinner [value]=\"90\" [strokeWidth]=\"3\" overlay=\"true\" [diameter]=\"25\" color=\"warn\">\r\n </mat-spinner>\r\n </ng-template>\r\n </ng-container>\r\n\r\n <button *ngIf=\"\r\n addingProperties &&\r\n !uploadMangmentService.uploadedFilesStatus.uploadInProgress &&\r\n uploadMangmentService.failedFiles.length > 0\r\n \" (click)=\"tryAgainCreateDocument()\" class=\"submission-button\">\r\n {{ \"BUTTONS.TRY_AGAIN\" | translate }}\r\n </button>\r\n\r\n <button [disabled]=\"!fileForm?.valid || disableCreateWhenFinishBtn\" *ngIf=\"\r\n addingProperties &&\r\n uploadMangmentService.uploadedFilesStatus.uploadInProgress\r\n \" (click)=\"createWhenFinish()\" class=\"submission-button w-44\">\r\n {{ \"BUTTONS.CREATE_WHEN_FINSH\" | translate }}\r\n </button>\r\n </div>\r\n <div class=\"flex\">\r\n <button class=\"cancelation-button mx-2\" (click)=\"minimizDialog()\" *ngIf=\"\r\n uploadMangmentService.uploadedFilesStatus\r\n .uploadInProgress ||\r\n uploadMangmentService.uploadedFilesStatus\r\n .numberOfUploadedFiles !== 0 ||\r\n addingProperties\r\n \">\r\n {{ \"BUTTONS.MINIMIZED\" | translate }}\r\n </button>\r\n <button class=\"cancelation-button\" (click)=\"closeDialog()\">\r\n {{ \"BUTTONS.CANCEL\" | translate }}\r\n </button>\r\n </div>\r\n </div>\r\n</div>", styles: [".dynamic-part{margin-left:-15px;margin-right:-15px}.iner-wrapper{height:calc(100% - 70px)}.iner-wrapper .properties-section{width:calc(100% - 270px);height:calc(100% - 15px)}.iner-wrapper .attachment-tab-body{height:calc(100% - -20px);overflow-y:auto;overflow-x:hidden}.iner-wrapper .attachment-iner-small-body{width:350px}.rtl .actions-iner-wrapper{direction:ltr}.actions-iner-wrapper{direction:rtl}\n"], components: [{ type: DynamicFieldsRendererComponent, selector: "app-dynamic-fields-renderer", inputs: ["form", "agencyNameFilter", "countryNameFilter", "mode", "fields"] }, { type: DynamicFormComponent, selector: "app-dynamic-form", inputs: ["form", "data", "readOnly"], outputs: ["change"] }, { type: AttachmentsComponent, selector: "app-attachments", inputs: ["allowedTypes", "params", "path", "maxSize", "docParams", "multiple", "createDocument", "allowedMaxNumberOfFiles", "source"], outputs: ["uploadSuccess", "uploadError", "onSelectingItem", "itemRemoved"] }, { type: i8__namespace.MatSpinner, selector: "mat-spinner", inputs: ["color"] }], directives: [{ type: i4__namespace$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i4__namespace$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: SetRtlDirective, selector: "[SetRtl]" }, { type: i6__namespace.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i6__namespace.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i6__namespace.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i6__namespace.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i6__namespace.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i6__namespace.FormControlName, selector: "[formControlName]", inputs: ["disabled", "formControlName", "ngModel"], outputs: ["ngModelChange"] }], pipes: { "translate": i1__namespace.TranslatePipe } });
22827
+ }(BaseDialogComponent));
22828
+ CreateModalComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CreateModalComponent, deps: [{ token: i1$4.MAT_DIALOG_DATA }, { token: UploadManagmentService }, { token: DialogMangmentService }, { token: FileManagerService }, { token: CustomToastrService }, { token: i6__namespace.FormBuilder }, { token: AdapterService }, { token: FileManagerService }, { token: AppConfigService }, { token: DateHelperService }, { token: UserService }, { token: 'environment' }, { token: i0__namespace.Injector }, { token: DynamicFormService }], target: i0__namespace.ɵɵFactoryTarget.Component });
22829
+ CreateModalComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: CreateModalComponent, selector: "app-create-modal", host: { listeners: { "document:keyup.enter": "KeyUpEvent($event)" } }, usesInheritance: true, ngImport: i0__namespace, template: "<ndf-nuxeo-dialog dialogTitle=\"{{ 'CREATE.createFile' | translate }}\">\r\n\t<ng-template #contentTemplate>\r\n\t\t<div class=\"relative w-full h-full\">\r\n\t\t\t<div class=\"iner-wrapper\" [ngClass]=\"{ 'd-flex': addingProperties }\">\r\n\t\t\t\t<div\r\n\t\t\t\t\t*ngIf=\"addingProperties\"\r\n\t\t\t\t\tclass=\"properties-section p-3 overflow-x-hidden overflow-y-auto\"\r\n\t\t\t\t>\r\n\t\t\t\t\t<div\r\n\t\t\t\t\t\tclass=\"\"\r\n\t\t\t\t\t\t*ngIf=\"selectedFile && source === 'fileManger' && showStaticForm\"\r\n\t\t\t\t\t>\r\n\t\t\t\t\t\t<div class=\"mb-5\">\r\n\t\t\t\t\t\t\t<div class=\"label-style\">\r\n\t\t\t\t\t\t\t\t{{ 'CREATE.FILE_TYPE' | translate }}\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t<div class=\"text-base text-gray-900\">\r\n\t\t\t\t\t\t\t\t{{ isArabic ? fileType.arabicText : fileType.englishText }}\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t<div class=\"file-fields mt-3\" SetRtl>\r\n\t\t\t\t\t\t\t<form [formGroup]=\"fileForm\">\r\n\t\t\t\t\t\t\t\t<!-- -----------------old static form ---------------------- -->\r\n\t\t\t\t\t\t\t\t<div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"single-field mb-3\">\r\n\t\t\t\t\t\t\t\t\t\t<div class=\"label-style\">\r\n\t\t\t\t\t\t\t\t\t\t\t{{ 'CREATE.TITLE' | translate\r\n\t\t\t\t\t\t\t\t\t\t\t}}<span class=\"text-red-500\">*</span>\r\n\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t<input\r\n\t\t\t\t\t\t\t\t\t\t\tclass=\"field-style\"\r\n\t\t\t\t\t\t\t\t\t\t\tformControlName=\"title\"\r\n\t\t\t\t\t\t\t\t\t\t\tplaceholder=\" {{ 'CREATE.TITLE' | translate }}\"\r\n\t\t\t\t\t\t\t\t\t\t/>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t<div class=\"single-field mb-3\">\r\n\t\t\t\t\t\t\t\t\t\t<div class=\"label-style\">\r\n\t\t\t\t\t\t\t\t\t\t\t{{ 'CREATE.DESCRIPTION' | translate }}\r\n\t\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t\t\t<input\r\n\t\t\t\t\t\t\t\t\t\t\tclass=\"field-style\"\r\n\t\t\t\t\t\t\t\t\t\t\tformControlName=\"description\"\r\n\t\t\t\t\t\t\t\t\t\t\tplaceholder=\" {{ 'CREATE.DESCRIPTION' | translate }}\"\r\n\t\t\t\t\t\t\t\t\t\t/>\r\n\t\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t\t<!-- ---------------------------------- -->\r\n\r\n\t\t\t\t\t\t\t\t<!------------------ new statis form ---------------------------->\r\n\t\t\t\t\t\t\t\t<div *ngIf=\"usingExtraFields\">\r\n\t\t\t\t\t\t\t\t\t<app-dynamic-fields-renderer\r\n\t\t\t\t\t\t\t\t\t\t[form]=\"fileForm\"\r\n\t\t\t\t\t\t\t\t\t\t[agencyNameFilter]=\"agencyNameFilter\"\r\n\t\t\t\t\t\t\t\t\t\t[countryNameFilter]=\"countryNameFilter\"\r\n\t\t\t\t\t\t\t\t\t></app-dynamic-fields-renderer>\r\n\t\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t\t</form>\r\n\r\n\t\t\t\t\t\t\t<div class=\"dynamic-part\" *ngIf=\"showRenderer\">\r\n\t\t\t\t\t\t\t\t<app-dynamic-form\r\n\t\t\t\t\t\t\t\t\t[form]=\"selectedFile.dynamicForm\"\r\n\t\t\t\t\t\t\t\t\t[data]=\"temporaryDyanmicData\"\r\n\t\t\t\t\t\t\t\t\t(change)=\"ondynamicFormChange($event)\"\r\n\t\t\t\t\t\t\t\t></app-dynamic-form>\r\n\t\t\t\t\t\t\t</div>\r\n\t\t\t\t\t\t</div>\r\n\t\t\t\t\t</div>\r\n\t\t\t\t\t<div\r\n\t\t\t\t\t\tclass=\"w-full h-full p-3 flex justify-center items-center text-lg text-gray-900\"\r\n\t\t\t\t\t\t*ngIf=\"!selectedFile\"\r\n\t\t\t\t\t>\r\n\t\t\t\t\t\t{{ 'CREATE.SELECT_TOSTART_ADDING' | translate }}\r\n\t\t\t\t\t</div>\r\n\t\t\t\t</div>\r\n\t\t\t\t<div\r\n\t\t\t\t\tclass=\"attachment-tab-body overflow-hidden\"\r\n\t\t\t\t\t[ngClass]=\"{ 'attachment-iner-small-body': addingProperties }\"\r\n\t\t\t\t>\r\n\t\t\t\t\t<app-attachments\r\n\t\t\t\t\t\t[multiple]=\"true\"\r\n\t\t\t\t\t\t(onSelectingItem)=\"selectFile($event)\"\r\n\t\t\t\t\t></app-attachments>\r\n\t\t\t\t</div>\r\n\t\t\t</div>\r\n\t\t\t<div\r\n\t\t\t\tclass=\"w-full text-red-500 text-base text-start px-3\"\r\n\t\t\t\t*ngIf=\"!uploadMangmentService.GeneralFormValidation\"\r\n\t\t\t>\r\n\t\t\t\t{{ 'CREATE.FILL_REQUIRED_FIELD' | translate }}\r\n\t\t\t</div>\r\n\t\t</div>\r\n\t</ng-template>\r\n\r\n\t<ng-template #actionsTemplate let-dialog=\"dialog\">\r\n\t\t<!-- WAS_IN_FLEX_DIV -->\r\n\t\t<button\r\n\t\t\t*ngIf=\"\r\n\t\t\t\t(uploadMangmentService.uploadedFilesStatus.uploadInProgress ||\r\n\t\t\t\t\tuploadMangmentService.uploadedFilesStatus.uploadedFiles.length > 0) &&\r\n\t\t\t\t!addingProperties\r\n\t\t\t\"\r\n\t\t\t(click)=\"dialog.executeAction(startAddingProperties)\"\r\n\t\t\tclass=\"submission-button\"\r\n\t\t>\r\n\t\t\t{{ 'BUTTONS.ADD_PROPERTIES' | translate }}\r\n\t\t</button>\r\n\t\t<button\r\n\t\t\t*ngIf=\"\r\n\t\t\t\taddingProperties &&\r\n\t\t\t\tuploadMangmentService.uploadedFilesStatus.uploadedFiles.length +\r\n\t\t\t\t\tuploadMangmentService.uploadedFilesStatus.allfiles.length >\r\n\t\t\t\t\t1\r\n\t\t\t\"\r\n\t\t\t(click)=\"dialog.executeAction(ApplyChangesToAll)\"\r\n\t\t\t[disabled]=\"!selectedFile || !selectedFile.staticFormValid\"\r\n\t\t\t[ngClass]=\"{\r\n\t\t\t\t'opacity-30 cursor-not-allowed':\r\n\t\t\t\t\t!selectedFile || !selectedFile.staticFormValid,\r\n\t\t\t\t'cursor-pointer hover:text-white hover:bg-gray-900': !(\r\n\t\t\t\t\t!selectedFile || !selectedFile.staticFormValid\r\n\t\t\t\t)\r\n\t\t\t}\"\r\n\t\t\tclass=\"submission-button mx-2\"\r\n\t\t>\r\n\t\t\t{{ 'BUTTONS.APPLY_TO_ALL' | translate }}\r\n\t\t</button>\r\n\t\t<!-- WAS_IN_FLEX_DIV -->\r\n\r\n\t\t<ng-container\r\n\t\t\t*ngIf=\"\r\n\t\t\t\taddingProperties &&\r\n\t\t\t\t!uploadMangmentService.uploadedFilesStatus.uploadInProgress &&\r\n\t\t\t\tuploadMangmentService.failedFiles.length === 0\r\n\t\t\t\"\r\n\t\t>\r\n\t\t\t<button\r\n\t\t\t\t(click)=\"dialog.executeAction(createDocument)\"\r\n\t\t\t\tclass=\"submission-button relative\"\r\n\t\t\t\t[disabled]=\"creating\"\r\n\t\t\t>\r\n\t\t\t\t<span *ngIf=\"!creating; else loader\">{{\r\n\t\t\t\t\t'BUTTONS.CREATE' | translate\r\n\t\t\t\t}}</span>\r\n\t\t\t</button>\r\n\t\t\t<ng-template #loader>\r\n\t\t\t\t<mat-spinner\r\n\t\t\t\t\t[value]=\"90\"\r\n\t\t\t\t\t[strokeWidth]=\"3\"\r\n\t\t\t\t\toverlay=\"true\"\r\n\t\t\t\t\t[diameter]=\"25\"\r\n\t\t\t\t\tcolor=\"warn\"\r\n\t\t\t\t>\r\n\t\t\t\t</mat-spinner>\r\n\t\t\t</ng-template>\r\n\t\t</ng-container>\r\n\r\n\t\t<button\r\n\t\t\t*ngIf=\"\r\n\t\t\t\taddingProperties &&\r\n\t\t\t\t!uploadMangmentService.uploadedFilesStatus.uploadInProgress &&\r\n\t\t\t\tuploadMangmentService.failedFiles.length > 0\r\n\t\t\t\"\r\n\t\t\t(click)=\"dialog.executeAction(tryAgainCreateDocument)\"\r\n\t\t\tclass=\"submission-button\"\r\n\t\t>\r\n\t\t\t{{ 'BUTTONS.TRY_AGAIN' | translate }}\r\n\t\t</button>\r\n\r\n\t\t<button\r\n\t\t\t[disabled]=\"!fileForm?.valid || disableCreateWhenFinishBtn\"\r\n\t\t\t*ngIf=\"\r\n\t\t\t\taddingProperties &&\r\n\t\t\t\tuploadMangmentService.uploadedFilesStatus.uploadInProgress\r\n\t\t\t\"\r\n\t\t\t(click)=\"dialog.executeAction(createWhenFinish)\"\r\n\t\t\tclass=\"submission-button w-44\"\r\n\t\t>\r\n\t\t\t{{ 'BUTTONS.CREATE_WHEN_FINSH' | translate }}\r\n\t\t</button>\r\n\r\n\t\t<!-- WAS_IN_FLEX_DIV -->\r\n\t\t<button\r\n\t\t\tclass=\"cancelation-button mx-2\"\r\n\t\t\t(click)=\"dialog.executeAction(minimizDialog)\"\r\n\t\t\t*ngIf=\"\r\n\t\t\t\tuploadMangmentService.uploadedFilesStatus.uploadInProgress ||\r\n\t\t\t\tuploadMangmentService.uploadedFilesStatus.numberOfUploadedFiles !== 0 ||\r\n\t\t\t\taddingProperties\r\n\t\t\t\"\r\n\t\t>\r\n\t\t\t{{ 'BUTTONS.MINIMIZED' | translate }}\r\n\t\t</button>\r\n\t\t<!-- <button class=\"cancelation-button\" (click)=\" dialog.executeAction(closeDialog)\">\r\n{{ 'BUTTONS.CANCEL' | translate }}\r\n</button> -->\r\n\t</ng-template>\r\n</ndf-nuxeo-dialog>\r\n", styles: [".dynamic-part{margin-left:-15px;margin-right:-15px}.iner-wrapper{height:calc(100% - 70px)}.iner-wrapper .properties-section{width:calc(100% - 270px);height:calc(100% - 15px)}.iner-wrapper .attachment-tab-body{height:calc(100% - -20px);overflow-y:auto;overflow-x:hidden}.iner-wrapper .attachment-iner-small-body{width:350px}.rtl .actions-iner-wrapper{direction:ltr}.actions-iner-wrapper{direction:rtl}:host{height:100%;display:block}\n"], components: [{ type: NdfNuxeoDialog, selector: "ndf-nuxeo-dialog", inputs: ["dialogTitle", "subTitle", "loaderMode"] }, { type: DynamicFieldsRendererComponent, selector: "app-dynamic-fields-renderer", inputs: ["form", "agencyNameFilter", "countryNameFilter", "mode", "fields"] }, { type: DynamicFormComponent, selector: "app-dynamic-form", inputs: ["form", "data", "readOnly"], outputs: ["change"] }, { type: AttachmentsComponent, selector: "app-attachments", inputs: ["allowedTypes", "params", "path", "maxSize", "docParams", "multiple", "createDocument", "allowedMaxNumberOfFiles", "source"], outputs: ["uploadSuccess", "uploadError", "onSelectingItem", "itemRemoved"] }, { type: i8__namespace.MatSpinner, selector: "mat-spinner", inputs: ["color"] }], directives: [{ type: i4__namespace$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i4__namespace$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: SetRtlDirective, selector: "[SetRtl]" }, { type: i6__namespace.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i6__namespace.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i6__namespace.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i6__namespace.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i6__namespace.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i6__namespace.FormControlName, selector: "[formControlName]", inputs: ["disabled", "formControlName", "ngModel"], outputs: ["ngModelChange"] }], pipes: { "translate": i1__namespace.TranslatePipe } });
22796
22830
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CreateModalComponent, decorators: [{
22797
22831
  type: i0.Component,
22798
22832
  args: [{
@@ -22804,10 +22838,10 @@
22804
22838
  return [{ type: undefined, decorators: [{
22805
22839
  type: i0.Inject,
22806
22840
  args: [i1$4.MAT_DIALOG_DATA]
22807
- }] }, { type: i1__namespace$3.MatDialogRef }, { type: UploadManagmentService }, { type: DialogMangmentService }, { type: FileManagerService }, { type: CustomToastrService }, { type: i6__namespace.FormBuilder }, { type: AdapterService }, { type: FileManagerService }, { type: AppConfigService }, { type: DateHelperService }, { type: TranslationService }, { type: UserService }, { type: NuxeoService }, { type: undefined, decorators: [{
22841
+ }] }, { type: UploadManagmentService }, { type: DialogMangmentService }, { type: FileManagerService }, { type: CustomToastrService }, { type: i6__namespace.FormBuilder }, { type: AdapterService }, { type: FileManagerService }, { type: AppConfigService }, { type: DateHelperService }, { type: UserService }, { type: undefined, decorators: [{
22808
22842
  type: i0.Inject,
22809
22843
  args: ['environment']
22810
- }] }, { type: DynamicFormService }];
22844
+ }] }, { type: i0__namespace.Injector }, { type: DynamicFormService }];
22811
22845
  }, propDecorators: { KeyUpEvent: [{
22812
22846
  type: i0.HostListener,
22813
22847
  args: ['document:keyup.enter', ['$event']]
@@ -28504,7 +28538,8 @@
28504
28538
  i6.FormsModule,
28505
28539
  DisplaySuitableIconModule,
28506
28540
  i4$3.MatProgressBarModule,
28507
- i7$1.MatCheckboxModule], exports: [SidepanelComponent,
28541
+ i7$1.MatCheckboxModule,
28542
+ NuxeoDialogModule], exports: [SidepanelComponent,
28508
28543
  CopyComponent,
28509
28544
  DeleteComponent,
28510
28545
  MoveComponent,
@@ -28574,7 +28609,8 @@
28574
28609
  i6.FormsModule,
28575
28610
  DisplaySuitableIconModule,
28576
28611
  i4$3.MatProgressBarModule,
28577
- i7$1.MatCheckboxModule
28612
+ i7$1.MatCheckboxModule,
28613
+ NuxeoDialogModule
28578
28614
  ], i3$3.DxPopupModule,
28579
28615
  i3$3.DxScrollViewModule,
28580
28616
  i4$4.DxiToolbarItemModule,
@@ -28605,7 +28641,7 @@
28605
28641
  TemplateModalComponent,
28606
28642
  UpdateModalComponent,
28607
28643
  ClipboardComponent,
28608
- FileGridInfiniteScrollDirective,
28644
+ FileGridInfiniteScrollDirective
28609
28645
  ],
28610
28646
  imports: [
28611
28647
  i4.CommonModule,
@@ -28650,7 +28686,8 @@
28650
28686
  i6.FormsModule,
28651
28687
  DisplaySuitableIconModule,
28652
28688
  i4$3.MatProgressBarModule,
28653
- i7$1.MatCheckboxModule
28689
+ i7$1.MatCheckboxModule,
28690
+ NuxeoDialogModule
28654
28691
  ],
28655
28692
  exports: [
28656
28693
  SidepanelComponent,
@@ -28679,7 +28716,7 @@
28679
28716
  i3$3.DxFormModule,
28680
28717
  i3$3.DxTreeViewModule,
28681
28718
  ClipboardComponent,
28682
- FileGridInfiniteScrollDirective,
28719
+ FileGridInfiniteScrollDirective
28683
28720
  ]
28684
28721
  }]
28685
28722
  }] });