cat-qw-lib 0.47.7 → 0.47.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/fesm2022/cat-qw-lib.mjs
CHANGED
|
@@ -4220,20 +4220,21 @@ class WidgetItemComponent {
|
|
|
4220
4220
|
this.widgetStore.setOnViewPropertyDetails({ propertyId: null, isDailogShow: false });
|
|
4221
4221
|
}
|
|
4222
4222
|
handleWidgetItemClick(widgetItem) {
|
|
4223
|
-
|
|
4223
|
+
const updatedItem = { ...widgetItem };
|
|
4224
|
+
switch (updatedItem.route) {
|
|
4224
4225
|
case SHARED.DIRECT_DEBIT:
|
|
4225
4226
|
const directDebit = this.widget.dataItems.filter((val) => val.key === SHARED.DIRECT_DEBITID);
|
|
4226
|
-
|
|
4227
|
+
updatedItem.value = directDebit[0].value;
|
|
4227
4228
|
break;
|
|
4228
4229
|
case SHARED.SOLICITOR:
|
|
4229
4230
|
const solicitor = this.widget.dataItems.filter((val) => val.key === SHARED.SOLICITORID);
|
|
4230
|
-
|
|
4231
|
+
updatedItem.value = solicitor[0].value;
|
|
4231
4232
|
break;
|
|
4232
4233
|
case SHARED.PRODUCT:
|
|
4233
4234
|
const product = this.widget.dataItems.filter((val) => val.key === SHARED.PRODUCT_ID);
|
|
4234
|
-
|
|
4235
|
+
updatedItem.value = product[0].value;
|
|
4235
4236
|
}
|
|
4236
|
-
this.widgetStore.setOnWidgetItemClick(
|
|
4237
|
+
this.widgetStore.setOnWidgetItemClick(updatedItem);
|
|
4237
4238
|
}
|
|
4238
4239
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.4", ngImport: i0, type: WidgetItemComponent, deps: [{ token: StyleBuilderService }, { token: WidgetStore }], target: i0.ɵɵFactoryTarget.Component });
|
|
4239
4240
|
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.0.4", type: WidgetItemComponent, isStandalone: false, selector: "lib-widget-item", inputs: { widgetItem: "widgetItem", widget: "widget", application: "application" }, ngImport: i0, template: "<div class=\"widget-container\">\r\n <div class=\"flex justify-content-between\"\r\n [ngClass]=\"!(widgetItem.key === 'Address' && widget.predefinedName === 'PropertyWidget') ? 'align-items-center' : ''\">\r\n <p class=\"mb-0 text-color-secondary mr-3 key-field-wrapper w-50\">{{ widgetItem?.key }}</p>\r\n\r\n <div class=\"mb-0 text-color font-semibold text-value-wrapper w-50 flex align-items-center justify-content-end\">\r\n <i *ngIf=\"widgetItem?.style?.includes('color: red;')\" class=\"pi pi-exclamation-triangle text-red-500 mr-1\"\r\n style=\"font-size: 1.3rem\"></i>\r\n <p *ngIf=\"!(widgetItem.key === 'Address' && widget.predefinedName === 'PropertyWidget')\" class=\"key-field-wrapper\"\r\n [ngStyle]=\"getStyle(widgetItem?.style)\">\r\n <ng-container *ngIf=\"widgetItem?.isLink; else plainText\">\r\n <a class=\"cursor-pointer\" (click)=\"handleWidgetItemClick(widgetItem)\">\r\n {{ (widgetItem.value && widgetItem.value !== 'null') ? widgetItem.value : '' }}\r\n </a>\r\n </ng-container>\r\n <ng-template #plainText>\r\n <a class=\"cursor-pointer\" (click)=\"handleWidgetItemClick(widgetItem)\"> {{ (widgetItem?.value && widgetItem?.value !== 'null') ? widgetItem?.value : '' }} </a>\r\n </ng-template>\r\n </p>\r\n <i *ngIf=\"widgetItem.key === 'Address' && widget.predefinedName === 'PropertyWidget'\"\r\n class=\"pi pi-map-marker map-icon map-icon-wrapper\"></i>\r\n </div>\r\n </div>\r\n\r\n\r\n <div *ngIf=\"widgetItem.key === 'Address' && widget.predefinedName === 'PropertyWidget'\"\r\n class=\"address-title-wrapper cursor-pointer\" [ngStyle]=\"getStyle(widgetItem?.style)\" (click)=\"onHandleSidebar(widget.recordId)\">\r\n {{ widgetItem?.value }}\r\n </div>\r\n</div>", styles: [".text-value-wrapper{-webkit-line-clamp:1;-webkit-box-orient:vertical;overflow:hidden;text-overflow:ellipsis;white-space:normal;max-width:100%}.key-field-wrapper{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.w-50{width:50%!important}.map-icon-wrapper{font-size:16px;padding:13px;border-radius:30px;border:1px solid rgba(76,98,146,.1);background:#4c62920a}.address-title-wrapper{width:80%;word-break:break-word;margin-top:-12px}\n"], dependencies: [{ kind: "directive", type: i1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }] });
|