@unifylib/ui-lib 1.0.76 → 1.0.77

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.
@@ -3878,7 +3878,8 @@ class AuditLogComponent {
3878
3878
  this.auditLogEntries = [];
3879
3879
  this.fields = [];
3880
3880
  this.showHiddenFields = [];
3881
- this.itemId = 0;
3881
+ /** Resolved entity id for audit filter (numeric or string). */
3882
+ this.auditRecordId = null;
3882
3883
  this.currentDirection = 'ltr';
3883
3884
  }
3884
3885
  ngOnInit() {
@@ -3888,25 +3889,43 @@ class AuditLogComponent {
3888
3889
  });
3889
3890
  this.loadItem();
3890
3891
  }
3892
+ resolveStateRecord() {
3893
+ const s = history.state;
3894
+ if (!s) {
3895
+ return null;
3896
+ }
3897
+ const candidate = s['raw'] ??
3898
+ s['entityData'] ??
3899
+ s['userData'] ??
3900
+ s['entity'] ??
3901
+ s['data'];
3902
+ return candidate ?? null;
3903
+ }
3891
3904
  loadItem() {
3892
- const state = history.state.raw;
3893
- if (state && state.id) {
3894
- this.itemId = state.id;
3905
+ const state = this.resolveStateRecord();
3906
+ const id = state?.['id'];
3907
+ if (id !== undefined && id !== null && id !== '') {
3908
+ const num = Number(id);
3909
+ this.auditRecordId = !Number.isNaN(num) && num > 0 ? num : String(id);
3895
3910
  }
3896
- const filterRequest = new FilterRequest();
3897
- if (this.itemId > 0) {
3898
- filterRequest.filters = [];
3899
- filterRequest.sortDirection = "DESC";
3900
- filterRequest.pageSize = 1000;
3901
- filterRequest.filters.push(new Filter({
3902
- key: 0,
3903
- fieldType: 'Long',
3904
- fieldName: 'id',
3905
- valueObject: this.itemId,
3906
- filterType: 'FILED_FILTER',
3907
- operator: 'EQUALS'
3908
- }));
3911
+ else {
3912
+ this.auditRecordId = null;
3913
+ }
3914
+ if (this.auditRecordId === null) {
3915
+ return;
3909
3916
  }
3917
+ const filterRequest = new FilterRequest();
3918
+ filterRequest.filters = [];
3919
+ filterRequest.sortDirection = "DESC";
3920
+ filterRequest.pageSize = 1000;
3921
+ filterRequest.filters.push(new Filter({
3922
+ key: 0,
3923
+ fieldType: 'Long',
3924
+ fieldName: 'id',
3925
+ valueObject: this.auditRecordId,
3926
+ filterType: 'FILED_FILTER',
3927
+ operator: 'EQUALS'
3928
+ }));
3910
3929
  this.backendService.getItemAuditLog(filterRequest, this.pageInfo.apiUri).subscribe({
3911
3930
  next: (resp) => {
3912
3931
  if (resp?.body?.length > 0) {
@@ -3918,7 +3937,7 @@ class AuditLogComponent {
3918
3937
  });
3919
3938
  }
3920
3939
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: AuditLogComponent, deps: [{ token: i1.MatDialog }, { token: i3$3.ActivatedRoute }, { token: i3$1.Directionality }, { token: 'securityManager' }, { token: BackendService }], target: i0.ɵɵFactoryTarget.Component }); }
3921
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: AuditLogComponent, isStandalone: true, selector: "app-audit-log", inputs: { pageInfo: "pageInfo", statusName: "statusName", module: "module", identifier: "identifier", fields: "fields", showHiddenFields: "showHiddenFields" }, providers: [DatePipe], ngImport: i0, template: "<div *ngIf=\"itemId > 0 && this.auditLogEntries.length > 0\">\r\n\r\n<mat-expansion-panel class=\"location-card\"\r\n #panel=\"matExpansionPanel\"\r\n [expanded]=\"true\"\r\n [hideToggle]=\"true\"\r\n (opened)=\" panel.open() \"\r\n (closed)=\" panel.open()\">\r\n <mat-expansion-panel-header class=\"card-header\" >\r\n <mat-panel-title>\r\n <div class=\"title-container\">\r\n <h3 class=\"card-title\">\r\n {{ 'audit-log.title' | translate }}\r\n </h3>\r\n </div>\r\n </mat-panel-title>\r\n\r\n </mat-expansion-panel-header>\r\n <div class=\"panel-body\">\r\n <hr class=\"divider\"/>\r\n <div class=\"timeline-container\">\r\n <div *ngFor=\"let auditLog of auditLogEntries; let i = index\" class=\"timeline-item\">\r\n <div class=\"timeline-marker\">\r\n <div class=\"timeline-circle\"></div>\r\n <div *ngIf=\"i !== auditLogEntries.length - 1\" class=\"timeline-line\"></div>\r\n </div>\r\n\r\n <div class=\"timeline-content\">\r\n <div class=\"log-main-text\">\r\n <span class=\"actor-name\">{{ auditLog.createdByDisplayName || auditLog.createdBy || ('system' | translate) }}</span>\r\n <span class=\"action-text\">\r\n {{\r\n 'audit-log.action_' +\r\n auditLog?.action +\r\n '_' +\r\n module\r\n | translate\r\n }}\r\n</span>\r\n <div *ngIf=\"statusName && auditLog.action === 'EDIT'\" style=\"display: inline\">\r\n <span class=\"action-text\"> to </span>\r\n <button [ngClass]=\"auditLog.subject[statusName]\" class=\"stateType\" mat-button>\r\n {{ pageInfo.labelsSection + '.' + auditLog.subject[statusName] | translate }}\r\n </button>\r\n\r\n </div>\r\n </div>\r\n <div class=\"log-timestamp\">\r\n {{ auditLog.createdOn | date: 'dd MMM, yyyy HH:mm a' }}\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n\r\n </div>\r\n</mat-expansion-panel>\r\n\r\n</div>\r\n", styles: [".audit-log-header{font-family:sans-serif;color:#333;margin-bottom:8px;padding-left:10px}.timeline-container{padding:20px;background-color:#fff}.timeline-item{display:flex;margin-bottom:15px;position:relative}.timeline-marker{display:flex;flex-direction:column;align-items:center;margin-right:20px;width:20px;justify-content:center}.timeline-marker .timeline-line{width:1px;background-color:#d1d1d1;flex-grow:1;position:absolute;top:0;height:calc(100% + 80px)}.timeline-circle{width:14px;height:14px;border-radius:50%;border:2px solid #345a7d;background:#fff;z-index:2}.timeline-content{flex-grow:1;background:#fff;border:1px solid #f0f0f0;border-radius:8px;padding:15px 20px;box-shadow:0 2px 4px #0000000d;cursor:pointer;transition:background .2s}.log-main-text{font-size:14px;margin-bottom:4px;color:#333}.log-main-text .actor-name,.log-main-text .target-name{font-weight:800;color:#002c44}.log-timestamp{font-size:12px;color:#888}.location-card{border:1px solid #dcdcdc;border-radius:8px;background:#fff;margin:18px auto;overflow:hidden}.location-card .mat-expansion-panel-header{padding:0 15px}.location-card .mat-expansion-panel-header ::ng-deep .mat-content{margin:0!important}.location-card .panel-body{padding:20px 15px;padding-top:0!important}.location-card .panel-body ::ng-deep app-base-form-canvas .main-form-canvas{margin-top:20px!important}.location-card .panel-description{justify-content:end!important;margin:0!important}.location-card .card-header{display:flex;justify-content:space-between;align-items:center;padding:10px 16px!important}.location-card .card-header .title-container{display:flex;flex-direction:column;gap:8px;align-items:flex-start;justify-content:center}.location-card .card-header .card-title{margin:0;font-size:24px;font-weight:700;line-height:1.2;color:#000;width:fit-content;white-space:nowrap}.location-card .card-header .card-subtitle{margin:0;font-family:lusail-light,sans-serif;font-weight:300;font-size:16px;line-height:1.2;color:#888;width:fit-content}.location-card .card-header .btn-edit{width:120px;min-height:32px!important;border-radius:9999px!important;font-size:16px!important}.location-card .card-header .expand-icon{color:#339dff;font-size:16px}.location-card .divider{border:none;border-top:2px solid var(--primary-color-3nd);margin-bottom:20px;margin-top:0}.flex-auto{flex:1 1 auto;display:flex;flex-direction:column}.row{display:flex;flex-direction:row;width:100%}.gap-20{gap:20px}.buttons-wrapper{display:flex;text-align-last:end;margin:0!important;gap:16px;justify-content:flex-end}.buttons-wrapper .action{min-height:44px!important;min-width:135px!important;width:auto!important}.button-text span{font-size:18px}.button-text mat-icon{font-size:18px!important}.btn-none-background-primary{margin:0!important}@media (max-width: 768px){.desktop-buttons{display:none!important}.desktop-buttons.show-on-mobile{display:flex!important}.mobile-buttons{display:flex;gap:12px;align-items:center;justify-content:flex-end}.btn-download-mobile{width:45px!important;height:44px!important;min-width:45px!important;padding:0!important;border-radius:8px!important;background:#0d4261!important;display:flex;align-items:center;justify-content:center}.btn-download-mobile mat-icon{color:#fff!important;font-size:24px!important;width:24px!important;height:28px!important;margin:0!important}.btn-download-mobile .mdc-button__label{padding:0!important}.btn-menu-mobile{width:44px!important;height:44px!important;min-width:44px!important;padding:0!important;border-radius:8px!important;border:1px solid #3e627b!important;background:#fff!important;display:flex;align-items:center;justify-content:center}.btn-menu-mobile mat-icon{color:#0d4261!important;font-size:24px!important;width:25px!important;height:24px!important;margin:0!important;rotate:90deg}.btn-menu-mobile .mdc-button__label{padding:0!important}}@media (min-width: 769px){.mobile-buttons{display:none!important}}@media (max-width: 600px){::ng-deep .main-form-canvas{display:block!important}}\n"], dependencies: [{ kind: "directive", type: NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i6$1.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i2.TranslatePipe, name: "translate" }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "pipe", type: DatePipe, name: "date" }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: MatExpansionPanelTitle, selector: "mat-panel-title" }, { kind: "component", type: MatExpansionPanel, selector: "mat-expansion-panel", inputs: ["hideToggle", "togglePosition"], outputs: ["afterExpand", "afterCollapse"], exportAs: ["matExpansionPanel"] }, { kind: "component", type: MatExpansionPanelHeader, selector: "mat-expansion-panel-header", inputs: ["expandedHeight", "collapsedHeight", "tabIndex"] }] }); }
3940
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: AuditLogComponent, isStandalone: true, selector: "app-audit-log", inputs: { pageInfo: "pageInfo", statusName: "statusName", module: "module", identifier: "identifier", fields: "fields", showHiddenFields: "showHiddenFields" }, providers: [DatePipe], ngImport: i0, template: "<div *ngIf=\"auditRecordId !== null && this.auditLogEntries.length > 0\">\n\n<mat-expansion-panel class=\"location-card\"\n #panel=\"matExpansionPanel\"\n [expanded]=\"true\"\n [hideToggle]=\"true\"\n (opened)=\" panel.open() \"\n (closed)=\" panel.open()\">\n <mat-expansion-panel-header class=\"card-header\" >\n <mat-panel-title>\n <div class=\"title-container\">\n <h3 class=\"card-title\">\n {{ 'audit-log.title' | translate }}\n </h3>\n </div>\n </mat-panel-title>\n\n </mat-expansion-panel-header>\n <div class=\"panel-body\">\n <hr class=\"divider\"/>\n <div class=\"timeline-container\">\n <div *ngFor=\"let auditLog of auditLogEntries; let i = index\" class=\"timeline-item\">\n <div class=\"timeline-marker\">\n <div class=\"timeline-circle\"></div>\n <div *ngIf=\"i !== auditLogEntries.length - 1\" class=\"timeline-line\"></div>\n </div>\n\n <div class=\"timeline-content\">\n <div class=\"log-main-text\">\n <span class=\"action-text\">{{ 'audit-log.user' | translate }}</span>\n <span class=\"actor-name\">{{ auditLog.createdByDisplayName || auditLog.createdBy || ('system' | translate) }}</span>\n <span class=\"action-text\">{{ 'audit-log.at' | translate }}</span>\n <span class=\"log-timestamp-inline\">{{ auditLog.createdOn | date: 'dd MMM, yyyy HH:mm a' }}</span>\n <span class=\"action-text action-highlight\">{{\n 'audit-log.action_' +\n auditLog?.action +\n '_' +\n module\n | translate\n }}</span>\n <ng-container *ngIf=\"statusName && auditLog.action === 'EDIT'\">\n <span class=\"action-text\">{{ 'audit-log.to' | translate }}</span>\n <button [ngClass]=\"auditLog.subject[statusName]\" class=\"stateType\" mat-button>\n {{ pageInfo.labelsSection + '.' + auditLog.subject[statusName] | translate }}\n </button>\n </ng-container>\n </div>\n </div>\n </div>\n </div>\n\n\n </div>\n</mat-expansion-panel>\n\n</div>\n", styles: [".audit-log-header{font-family:sans-serif;color:#333;margin-bottom:8px;padding-left:10px}.timeline-container{padding:20px;background-color:#fff}.timeline-item{display:flex;margin-bottom:15px;position:relative}.timeline-marker{display:flex;flex-direction:column;align-items:center;margin-right:20px;width:20px;justify-content:center}.timeline-marker .timeline-line{width:1px;background-color:#d1d1d1;flex-grow:1;position:absolute;top:0;height:calc(100% + 80px)}.timeline-circle{width:14px;height:14px;border-radius:50%;border:2px solid #345a7d;background:#fff;z-index:2}.timeline-content{flex-grow:1;background:#fff;border:1px solid #f0f0f0;border-radius:8px;padding:15px 20px;box-shadow:0 2px 4px #0000000d;cursor:pointer;transition:background .2s}.log-main-text{font-size:14px;margin-bottom:0;color:#333;display:flex;flex-wrap:wrap;align-items:baseline;gap:.35em}.log-main-text .actor-name,.log-main-text .target-name{font-weight:800;color:#002c44}.log-main-text .action-text{color:#333}.log-main-text .action-highlight{font-weight:600;color:#002c44}.log-timestamp{font-size:12px;color:#888}.log-timestamp-inline{display:inline;font-size:14px;color:#555;font-weight:500}.location-card{border:1px solid #dcdcdc;border-radius:8px;background:#fff;margin:18px auto;overflow:hidden}.location-card .mat-expansion-panel-header{padding:0 15px}.location-card .mat-expansion-panel-header ::ng-deep .mat-content{margin:0!important}.location-card .panel-body{padding:20px 15px;padding-top:0!important}.location-card .panel-body ::ng-deep app-base-form-canvas .main-form-canvas{margin-top:20px!important}.location-card .panel-description{justify-content:end!important;margin:0!important}.location-card .card-header{display:flex;justify-content:space-between;align-items:center;padding:10px 16px!important}.location-card .card-header .title-container{display:flex;flex-direction:column;gap:8px;align-items:flex-start;justify-content:center}.location-card .card-header .card-title{margin:0;font-size:24px;font-weight:700;line-height:1.2;color:#000;width:fit-content;white-space:nowrap}.location-card .card-header .card-subtitle{margin:0;font-family:lusail-light,sans-serif;font-weight:300;font-size:16px;line-height:1.2;color:#888;width:fit-content}.location-card .card-header .btn-edit{width:120px;min-height:32px!important;border-radius:9999px!important;font-size:16px!important}.location-card .card-header .expand-icon{color:#339dff;font-size:16px}.location-card .divider{border:none;border-top:2px solid var(--primary-color-3nd);margin-bottom:20px;margin-top:0}.flex-auto{flex:1 1 auto;display:flex;flex-direction:column}.row{display:flex;flex-direction:row;width:100%}.gap-20{gap:20px}.buttons-wrapper{display:flex;text-align-last:end;margin:0!important;gap:16px;justify-content:flex-end}.buttons-wrapper .action{min-height:44px!important;min-width:135px!important;width:auto!important}.button-text span{font-size:18px}.button-text mat-icon{font-size:18px!important}.btn-none-background-primary{margin:0!important}@media (max-width: 768px){.desktop-buttons{display:none!important}.desktop-buttons.show-on-mobile{display:flex!important}.mobile-buttons{display:flex;gap:12px;align-items:center;justify-content:flex-end}.btn-download-mobile{width:45px!important;height:44px!important;min-width:45px!important;padding:0!important;border-radius:8px!important;background:#0d4261!important;display:flex;align-items:center;justify-content:center}.btn-download-mobile mat-icon{color:#fff!important;font-size:24px!important;width:24px!important;height:28px!important;margin:0!important}.btn-download-mobile .mdc-button__label{padding:0!important}.btn-menu-mobile{width:44px!important;height:44px!important;min-width:44px!important;padding:0!important;border-radius:8px!important;border:1px solid #3e627b!important;background:#fff!important;display:flex;align-items:center;justify-content:center}.btn-menu-mobile mat-icon{color:#0d4261!important;font-size:24px!important;width:25px!important;height:24px!important;margin:0!important;rotate:90deg}.btn-menu-mobile .mdc-button__label{padding:0!important}}@media (min-width: 769px){.mobile-buttons{display:none!important}}@media (max-width: 600px){::ng-deep .main-form-canvas{display:block!important}}\n"], dependencies: [{ kind: "directive", type: NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i6$1.MatButton, selector: " button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button] ", exportAs: ["matButton"] }, { kind: "ngmodule", type: TranslateModule }, { kind: "pipe", type: i2.TranslatePipe, name: "translate" }, { kind: "directive", type: NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "pipe", type: DatePipe, name: "date" }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: MatExpansionPanelTitle, selector: "mat-panel-title" }, { kind: "component", type: MatExpansionPanel, selector: "mat-expansion-panel", inputs: ["hideToggle", "togglePosition"], outputs: ["afterExpand", "afterCollapse"], exportAs: ["matExpansionPanel"] }, { kind: "component", type: MatExpansionPanelHeader, selector: "mat-expansion-panel-header", inputs: ["expandedHeight", "collapsedHeight", "tabIndex"] }] }); }
3922
3941
  }
3923
3942
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: AuditLogComponent, decorators: [{
3924
3943
  type: Component,
@@ -3933,7 +3952,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImpo
3933
3952
  MatExpansionPanelTitle,
3934
3953
  MatExpansionPanel,
3935
3954
  MatExpansionPanelHeader
3936
- ], providers: [DatePipe], template: "<div *ngIf=\"itemId > 0 && this.auditLogEntries.length > 0\">\r\n\r\n<mat-expansion-panel class=\"location-card\"\r\n #panel=\"matExpansionPanel\"\r\n [expanded]=\"true\"\r\n [hideToggle]=\"true\"\r\n (opened)=\" panel.open() \"\r\n (closed)=\" panel.open()\">\r\n <mat-expansion-panel-header class=\"card-header\" >\r\n <mat-panel-title>\r\n <div class=\"title-container\">\r\n <h3 class=\"card-title\">\r\n {{ 'audit-log.title' | translate }}\r\n </h3>\r\n </div>\r\n </mat-panel-title>\r\n\r\n </mat-expansion-panel-header>\r\n <div class=\"panel-body\">\r\n <hr class=\"divider\"/>\r\n <div class=\"timeline-container\">\r\n <div *ngFor=\"let auditLog of auditLogEntries; let i = index\" class=\"timeline-item\">\r\n <div class=\"timeline-marker\">\r\n <div class=\"timeline-circle\"></div>\r\n <div *ngIf=\"i !== auditLogEntries.length - 1\" class=\"timeline-line\"></div>\r\n </div>\r\n\r\n <div class=\"timeline-content\">\r\n <div class=\"log-main-text\">\r\n <span class=\"actor-name\">{{ auditLog.createdByDisplayName || auditLog.createdBy || ('system' | translate) }}</span>\r\n <span class=\"action-text\">\r\n {{\r\n 'audit-log.action_' +\r\n auditLog?.action +\r\n '_' +\r\n module\r\n | translate\r\n }}\r\n</span>\r\n <div *ngIf=\"statusName && auditLog.action === 'EDIT'\" style=\"display: inline\">\r\n <span class=\"action-text\"> to </span>\r\n <button [ngClass]=\"auditLog.subject[statusName]\" class=\"stateType\" mat-button>\r\n {{ pageInfo.labelsSection + '.' + auditLog.subject[statusName] | translate }}\r\n </button>\r\n\r\n </div>\r\n </div>\r\n <div class=\"log-timestamp\">\r\n {{ auditLog.createdOn | date: 'dd MMM, yyyy HH:mm a' }}\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n\r\n\r\n </div>\r\n</mat-expansion-panel>\r\n\r\n</div>\r\n", styles: [".audit-log-header{font-family:sans-serif;color:#333;margin-bottom:8px;padding-left:10px}.timeline-container{padding:20px;background-color:#fff}.timeline-item{display:flex;margin-bottom:15px;position:relative}.timeline-marker{display:flex;flex-direction:column;align-items:center;margin-right:20px;width:20px;justify-content:center}.timeline-marker .timeline-line{width:1px;background-color:#d1d1d1;flex-grow:1;position:absolute;top:0;height:calc(100% + 80px)}.timeline-circle{width:14px;height:14px;border-radius:50%;border:2px solid #345a7d;background:#fff;z-index:2}.timeline-content{flex-grow:1;background:#fff;border:1px solid #f0f0f0;border-radius:8px;padding:15px 20px;box-shadow:0 2px 4px #0000000d;cursor:pointer;transition:background .2s}.log-main-text{font-size:14px;margin-bottom:4px;color:#333}.log-main-text .actor-name,.log-main-text .target-name{font-weight:800;color:#002c44}.log-timestamp{font-size:12px;color:#888}.location-card{border:1px solid #dcdcdc;border-radius:8px;background:#fff;margin:18px auto;overflow:hidden}.location-card .mat-expansion-panel-header{padding:0 15px}.location-card .mat-expansion-panel-header ::ng-deep .mat-content{margin:0!important}.location-card .panel-body{padding:20px 15px;padding-top:0!important}.location-card .panel-body ::ng-deep app-base-form-canvas .main-form-canvas{margin-top:20px!important}.location-card .panel-description{justify-content:end!important;margin:0!important}.location-card .card-header{display:flex;justify-content:space-between;align-items:center;padding:10px 16px!important}.location-card .card-header .title-container{display:flex;flex-direction:column;gap:8px;align-items:flex-start;justify-content:center}.location-card .card-header .card-title{margin:0;font-size:24px;font-weight:700;line-height:1.2;color:#000;width:fit-content;white-space:nowrap}.location-card .card-header .card-subtitle{margin:0;font-family:lusail-light,sans-serif;font-weight:300;font-size:16px;line-height:1.2;color:#888;width:fit-content}.location-card .card-header .btn-edit{width:120px;min-height:32px!important;border-radius:9999px!important;font-size:16px!important}.location-card .card-header .expand-icon{color:#339dff;font-size:16px}.location-card .divider{border:none;border-top:2px solid var(--primary-color-3nd);margin-bottom:20px;margin-top:0}.flex-auto{flex:1 1 auto;display:flex;flex-direction:column}.row{display:flex;flex-direction:row;width:100%}.gap-20{gap:20px}.buttons-wrapper{display:flex;text-align-last:end;margin:0!important;gap:16px;justify-content:flex-end}.buttons-wrapper .action{min-height:44px!important;min-width:135px!important;width:auto!important}.button-text span{font-size:18px}.button-text mat-icon{font-size:18px!important}.btn-none-background-primary{margin:0!important}@media (max-width: 768px){.desktop-buttons{display:none!important}.desktop-buttons.show-on-mobile{display:flex!important}.mobile-buttons{display:flex;gap:12px;align-items:center;justify-content:flex-end}.btn-download-mobile{width:45px!important;height:44px!important;min-width:45px!important;padding:0!important;border-radius:8px!important;background:#0d4261!important;display:flex;align-items:center;justify-content:center}.btn-download-mobile mat-icon{color:#fff!important;font-size:24px!important;width:24px!important;height:28px!important;margin:0!important}.btn-download-mobile .mdc-button__label{padding:0!important}.btn-menu-mobile{width:44px!important;height:44px!important;min-width:44px!important;padding:0!important;border-radius:8px!important;border:1px solid #3e627b!important;background:#fff!important;display:flex;align-items:center;justify-content:center}.btn-menu-mobile mat-icon{color:#0d4261!important;font-size:24px!important;width:25px!important;height:24px!important;margin:0!important;rotate:90deg}.btn-menu-mobile .mdc-button__label{padding:0!important}}@media (min-width: 769px){.mobile-buttons{display:none!important}}@media (max-width: 600px){::ng-deep .main-form-canvas{display:block!important}}\n"] }]
3955
+ ], providers: [DatePipe], template: "<div *ngIf=\"auditRecordId !== null && this.auditLogEntries.length > 0\">\n\n<mat-expansion-panel class=\"location-card\"\n #panel=\"matExpansionPanel\"\n [expanded]=\"true\"\n [hideToggle]=\"true\"\n (opened)=\" panel.open() \"\n (closed)=\" panel.open()\">\n <mat-expansion-panel-header class=\"card-header\" >\n <mat-panel-title>\n <div class=\"title-container\">\n <h3 class=\"card-title\">\n {{ 'audit-log.title' | translate }}\n </h3>\n </div>\n </mat-panel-title>\n\n </mat-expansion-panel-header>\n <div class=\"panel-body\">\n <hr class=\"divider\"/>\n <div class=\"timeline-container\">\n <div *ngFor=\"let auditLog of auditLogEntries; let i = index\" class=\"timeline-item\">\n <div class=\"timeline-marker\">\n <div class=\"timeline-circle\"></div>\n <div *ngIf=\"i !== auditLogEntries.length - 1\" class=\"timeline-line\"></div>\n </div>\n\n <div class=\"timeline-content\">\n <div class=\"log-main-text\">\n <span class=\"action-text\">{{ 'audit-log.user' | translate }}</span>\n <span class=\"actor-name\">{{ auditLog.createdByDisplayName || auditLog.createdBy || ('system' | translate) }}</span>\n <span class=\"action-text\">{{ 'audit-log.at' | translate }}</span>\n <span class=\"log-timestamp-inline\">{{ auditLog.createdOn | date: 'dd MMM, yyyy HH:mm a' }}</span>\n <span class=\"action-text action-highlight\">{{\n 'audit-log.action_' +\n auditLog?.action +\n '_' +\n module\n | translate\n }}</span>\n <ng-container *ngIf=\"statusName && auditLog.action === 'EDIT'\">\n <span class=\"action-text\">{{ 'audit-log.to' | translate }}</span>\n <button [ngClass]=\"auditLog.subject[statusName]\" class=\"stateType\" mat-button>\n {{ pageInfo.labelsSection + '.' + auditLog.subject[statusName] | translate }}\n </button>\n </ng-container>\n </div>\n </div>\n </div>\n </div>\n\n\n </div>\n</mat-expansion-panel>\n\n</div>\n", styles: [".audit-log-header{font-family:sans-serif;color:#333;margin-bottom:8px;padding-left:10px}.timeline-container{padding:20px;background-color:#fff}.timeline-item{display:flex;margin-bottom:15px;position:relative}.timeline-marker{display:flex;flex-direction:column;align-items:center;margin-right:20px;width:20px;justify-content:center}.timeline-marker .timeline-line{width:1px;background-color:#d1d1d1;flex-grow:1;position:absolute;top:0;height:calc(100% + 80px)}.timeline-circle{width:14px;height:14px;border-radius:50%;border:2px solid #345a7d;background:#fff;z-index:2}.timeline-content{flex-grow:1;background:#fff;border:1px solid #f0f0f0;border-radius:8px;padding:15px 20px;box-shadow:0 2px 4px #0000000d;cursor:pointer;transition:background .2s}.log-main-text{font-size:14px;margin-bottom:0;color:#333;display:flex;flex-wrap:wrap;align-items:baseline;gap:.35em}.log-main-text .actor-name,.log-main-text .target-name{font-weight:800;color:#002c44}.log-main-text .action-text{color:#333}.log-main-text .action-highlight{font-weight:600;color:#002c44}.log-timestamp{font-size:12px;color:#888}.log-timestamp-inline{display:inline;font-size:14px;color:#555;font-weight:500}.location-card{border:1px solid #dcdcdc;border-radius:8px;background:#fff;margin:18px auto;overflow:hidden}.location-card .mat-expansion-panel-header{padding:0 15px}.location-card .mat-expansion-panel-header ::ng-deep .mat-content{margin:0!important}.location-card .panel-body{padding:20px 15px;padding-top:0!important}.location-card .panel-body ::ng-deep app-base-form-canvas .main-form-canvas{margin-top:20px!important}.location-card .panel-description{justify-content:end!important;margin:0!important}.location-card .card-header{display:flex;justify-content:space-between;align-items:center;padding:10px 16px!important}.location-card .card-header .title-container{display:flex;flex-direction:column;gap:8px;align-items:flex-start;justify-content:center}.location-card .card-header .card-title{margin:0;font-size:24px;font-weight:700;line-height:1.2;color:#000;width:fit-content;white-space:nowrap}.location-card .card-header .card-subtitle{margin:0;font-family:lusail-light,sans-serif;font-weight:300;font-size:16px;line-height:1.2;color:#888;width:fit-content}.location-card .card-header .btn-edit{width:120px;min-height:32px!important;border-radius:9999px!important;font-size:16px!important}.location-card .card-header .expand-icon{color:#339dff;font-size:16px}.location-card .divider{border:none;border-top:2px solid var(--primary-color-3nd);margin-bottom:20px;margin-top:0}.flex-auto{flex:1 1 auto;display:flex;flex-direction:column}.row{display:flex;flex-direction:row;width:100%}.gap-20{gap:20px}.buttons-wrapper{display:flex;text-align-last:end;margin:0!important;gap:16px;justify-content:flex-end}.buttons-wrapper .action{min-height:44px!important;min-width:135px!important;width:auto!important}.button-text span{font-size:18px}.button-text mat-icon{font-size:18px!important}.btn-none-background-primary{margin:0!important}@media (max-width: 768px){.desktop-buttons{display:none!important}.desktop-buttons.show-on-mobile{display:flex!important}.mobile-buttons{display:flex;gap:12px;align-items:center;justify-content:flex-end}.btn-download-mobile{width:45px!important;height:44px!important;min-width:45px!important;padding:0!important;border-radius:8px!important;background:#0d4261!important;display:flex;align-items:center;justify-content:center}.btn-download-mobile mat-icon{color:#fff!important;font-size:24px!important;width:24px!important;height:28px!important;margin:0!important}.btn-download-mobile .mdc-button__label{padding:0!important}.btn-menu-mobile{width:44px!important;height:44px!important;min-width:44px!important;padding:0!important;border-radius:8px!important;border:1px solid #3e627b!important;background:#fff!important;display:flex;align-items:center;justify-content:center}.btn-menu-mobile mat-icon{color:#0d4261!important;font-size:24px!important;width:25px!important;height:24px!important;margin:0!important;rotate:90deg}.btn-menu-mobile .mdc-button__label{padding:0!important}}@media (min-width: 769px){.mobile-buttons{display:none!important}}@media (max-width: 600px){::ng-deep .main-form-canvas{display:block!important}}\n"] }]
3937
3956
  }], ctorParameters: () => [{ type: i1.MatDialog }, { type: i3$3.ActivatedRoute }, { type: i3$1.Directionality }, { type: undefined, decorators: [{
3938
3957
  type: Inject,
3939
3958
  args: ['securityManager']