@posiwise/admin-module 0.0.118 → 0.0.120
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/esm2022/lib/components/incidents/add-edit-incident/add-edit-incident.component.mjs +3 -3
- package/esm2022/lib/components/incidents/incidents-list/incidents-list.component.mjs +3 -3
- package/esm2022/lib/components/login-notifications/login-notification-details/login-notification-details.component.mjs +3 -3
- package/esm2022/lib/components/newsletters/newsletter-details/newsletter-details.component.mjs +6 -5
- package/esm2022/lib/components/subscriptions/subscription-agents-list/subscription-agents-list.component.mjs +3 -3
- package/esm2022/lib/components/tracking/ahoy-events/ahoy-events.component.mjs +31 -15
- package/esm2022/lib/components/tracking/ahoy-messages/ahoy-messages.component.mjs +28 -13
- package/esm2022/lib/components/tracking/ahoy-visits/ahoy-visits.component.mjs +33 -19
- package/esm2022/lib/components/tracking/events/events.component.mjs +33 -19
- package/esm2022/lib/components/tracking/versions/versions.component.mjs +33 -19
- package/fesm2022/posiwise-admin-module.mjs +159 -90
- package/fesm2022/posiwise-admin-module.mjs.map +1 -1
- package/package.json +1 -1
|
@@ -2272,7 +2272,7 @@ class LoginNotificationDetailsComponent extends AppBaseComponent {
|
|
|
2272
2272
|
});
|
|
2273
2273
|
}
|
|
2274
2274
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: LoginNotificationDetailsComponent, deps: [{ token: i0.Injector }, { token: i1.AdminService }, { token: i1$1.ProductService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
2275
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: LoginNotificationDetailsComponent, selector: "pw-login-notification-details", usesInheritance: true, ngImport: i0, template: "<div class=\"container-fluid pw-tab overflow-hidden\">\n <div class=\"dashboard\">\n <div class=\"dashboard-body\">\n <div class=\"me-auto col-xs-6 mt-4\">\n <a href=\"javascript:void(0)\"\n [routerLink]=\"[routers.loginNotifications]\"\n class=\"previous\">\n <i class=\"fa fa-arrow-alt-circle-left\" aria-hidden=\"true\"></i>\n </a>\n <h3 class=\"m-subheader__title m-subheader__title--separator\">\n <span>{{ id ? 'Edit' : 'Add New' }}: Login Notification</span>\n </h3>\n </div>\n <div class=\"w-100 text-center mt-3\"\n *ngIf=\"isLoading\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div class=\"p-2 mt-3\">\n <form [formGroup]=\"form\"\n *ngIf=\"!isLoading\"\n (ngSubmit)=\"onSave()\">\n <div class=\"row\">\n <div class=\"col-12 col-sm-4 col-md-3\"\n *ngIf=\"loginNotificationTypes$ | async as types\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.NotificationType' | transloco\"\n [label]=\"'Admin.LoginNotification.NotificationType' | transloco\"\n name=\"notification_type\"\n [errorMsg]=\"\n 'Admin.LoginNotification.Validation.NotificationType'\n | transloco\n \">\n\n <select id=\"type\"\n class=\"form-select mt-2 no-radius\"\n [ngClass]=\"{\n 'is-invalid': submitted && f['notification_type'].errors\n }\"\n formControlName=\"notification_type\">\n <option value=\"\">Select Type</option>\n <option *ngFor=\"let item of types['available_types']\"\n [value]=\"item\">\n {{ item }}\n </option>\n </select>\n </pw-input-container>\n </div>\n <!-- Feature keys -->\n <div class=\"mb-3 col-12 col-sm-4 col-md-3\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.Features' | transloco\"\n [label]=\"'Admin.LoginNotification.Features' | transloco\"\n name=\"feature_keys\"\n [errorMsg]=\"\n 'Admin.LoginNotification.Validation.Features' | transloco\n \">\n <p-multiSelect [options]=\"featureKeys\"\n placeholder=\"Select feature keys\"\n [showHeader]=\"true\"\n [showToggleAll]=\"true\"\n formControlName=\"feature_keys\"\n appendTo=\"body\"></p-multiSelect>\n </pw-input-container>\n </div>\n <!-- visible_from -->\n <div class=\"col-12 col-sm-4 col-md-3\">\n <div class=\"mb-3\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.VisibleFrom' | transloco\"\n [label]=\"'Admin.LoginNotification.VisibleFrom' | transloco\"\n name=\"visible_from\"\n [errorMsg]=\"\n 'Admin.LoginNotification.Validation.VisibleFrom' | transloco\n \">\n <div>\n <p-calendar formControlName=\"visible_from\"\n [showIcon]=\"true\"\n [showTime]=\"true\"\n dateFormat=\"dd-M-yy\"\n [placeholder]=\"'Visible Date'\"\n [ngClass]=\"{\n 'is-invalid': submitted && f['visible_from'].errors\n }\">\n </p-calendar>\n </div>\n </pw-input-container>\n </div>\n </div>\n <!-- visible_until -->\n <div class=\"col-12 col-sm-4 col-md-3\">\n <div class=\"mb-3\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.VisibleUntil' | transloco\"\n [label]=\"'Admin.LoginNotification.VisibleUntil' | transloco\"\n name=\"visible_until\"\n [errorMsg]=\"\n 'Admin.LoginNotification.Validation.VisibleUntil'\n | transloco\n \">\n <div>\n <p-calendar formControlName=\"visible_until\"\n [showIcon]=\"true\"\n [showTime]=\"true\"\n dateFormat=\"dd-M-y\"\n [placeholder]=\"'Visible Until Date'\"\n [ngClass]=\"{\n 'is-invalid': submitted && f['visible_until'].errors\n }\">\n </p-calendar>\n </div>\n </pw-input-container>\n </div>\n </div>\n <!-- body -->\n <div class=\"col-12 col-sm-12\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.Body' | transloco\"\n [label]=\"'Admin.LoginNotification.Body' | transloco\"\n name=\"body\"\n [errorMsg]=\"'Admin.LoginNotification.Validation.Body' | transloco\">\n <textarea rows=\"3\"\n type=\"text\"\n class=\"form-control\"\n formControlName=\"body\"\n [ngClass]=\"{ 'is-invalid': submitted && f['body'].errors }\"></textarea>\n </pw-input-container>\n </div>\n </div>\n <div class=\"col-12 text-end mt-3\">\n <button type=\"button\"\n class=\"btn btn-outline-default me-2\"\n (click)=\"back()\">\n {{ 'Button.Cancel' | transloco }}\n </button>\n <button type=\"submit\"\n [buttonBusy]=\"buttonBusy\"\n class=\"btn btn-primary\">\n {{ 'Button.Submit' | transloco }}\n </button>\n </div>\n </form>\n </div>\n </div>\n </div>\n</div>\n", dependencies: [{ kind: "component", type: i6.MultiSelect, selector: "p-multiSelect", inputs: ["id", "ariaLabel", "style", "styleClass", "panelStyle", "panelStyleClass", "inputId", "disabled", "readonly", "group", "filter", "filterPlaceHolder", "filterLocale", "overlayVisible", "tabindex", "variant", "appendTo", "dataKey", "name", "ariaLabelledBy", "displaySelectedLabel", "maxSelectedLabels", "selectionLimit", "selectedItemsLabel", "showToggleAll", "emptyFilterMessage", "emptyMessage", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "showHeader", "filterBy", "scrollHeight", "lazy", "virtualScroll", "loading", "virtualScrollItemSize", "loadingIcon", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "display", "autocomplete", "showClear", "autofocus", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "defaultLabel", "placeholder", "options", "filterValue", "itemSize", "selectAll", "focusOnHover", "filterFields", "selectOnFocus", "autoOptionFocus"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onClear", "onPanelShow", "onPanelHide", "onLazyLoad", "onRemove", "onSelectAllChange"] }, { kind: "component", type: i7$2.Calendar, selector: "p-calendar", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepYearPicker", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.ProgressSpinner, selector: "p-progressSpinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "component", type: i9.InputContainerComponent, selector: "pw-input-container", inputs: ["name", "label", "labelClass", "tooltipPosition", "required", "errorMsg", "isReadOnly", "showTooltip", "tooltipText", "showTriangle", "afterLabel", "showAfterLabel", "showTriangleText"] }, { kind: "directive", type: i10.ButtonBusyDirective, selector: "[buttonBusy]", inputs: ["buttonBusy", "busyText"] }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i3.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "pipe", type: i2.AsyncPipe, name: "async" }, { kind: "pipe", type: i12.TranslocoPipe, name: "transloco" }] }); }
|
|
2275
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: LoginNotificationDetailsComponent, selector: "pw-login-notification-details", usesInheritance: true, ngImport: i0, template: "<div class=\"container-fluid pw-tab overflow-hidden\">\n <div class=\"dashboard\">\n <div class=\"dashboard-body\">\n <div class=\"me-auto col-xs-6 mt-4\">\n <a href=\"javascript:void(0)\"\n [routerLink]=\"[routers.loginNotifications]\"\n class=\"previous\">\n <i class=\"fa fa-arrow-alt-circle-left\" aria-hidden=\"true\"></i>\n </a>\n <h3 class=\"m-subheader__title m-subheader__title--separator\">\n <span>{{ id ? 'Edit' : 'Add New' }}: Login Notification</span>\n </h3>\n </div>\n <div class=\"w-100 text-center mt-3\"\n *ngIf=\"isLoading\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div class=\"p-2 mt-3\">\n <form [formGroup]=\"form\"\n *ngIf=\"!isLoading\"\n (ngSubmit)=\"onSave()\">\n <div class=\"row\">\n <div class=\"col-12 col-sm-4 col-md-3\"\n *ngIf=\"loginNotificationTypes$ | async as types\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.NotificationType' | transloco\"\n [label]=\"'Admin.LoginNotification.NotificationType' | transloco\"\n name=\"notification_type\"\n [errorMsg]=\"\n 'Admin.LoginNotification.Validation.NotificationType'\n | transloco\n \">\n\n <select id=\"type\"\n class=\"form-select mt-2 no-radius\"\n [ngClass]=\"{\n 'is-invalid': submitted && f['notification_type'].errors\n }\"\n formControlName=\"notification_type\">\n <option value=\"\">Select Type</option>\n <option *ngFor=\"let item of types['available_types']\"\n [value]=\"item\">\n {{ item }}\n </option>\n </select>\n </pw-input-container>\n </div>\n <!-- Feature keys -->\n <div class=\"mb-3 col-12 col-sm-4 col-md-3\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.Features' | transloco\"\n [label]=\"'Admin.LoginNotification.Features' | transloco\"\n name=\"feature_keys\"\n [errorMsg]=\"\n 'Admin.LoginNotification.Validation.Features' | transloco\n \">\n <p-multiSelect [options]=\"featureKeys\"\n placeholder=\"Select feature keys\"\n [showHeader]=\"true\"\n [showToggleAll]=\"true\"\n formControlName=\"feature_keys\"\n appendTo=\"body\"></p-multiSelect>\n </pw-input-container>\n </div>\n <!-- visible_from -->\n <div class=\"col-12 col-sm-4 col-md-3\">\n <div class=\"mb-3\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.VisibleFrom' | transloco\"\n [label]=\"'Admin.LoginNotification.VisibleFrom' | transloco\"\n name=\"visible_from\"\n [errorMsg]=\"\n 'Admin.LoginNotification.Validation.VisibleFrom' | transloco\n \">\n <div>\n <p-calendar formControlName=\"visible_from\"\n [showIcon]=\"true\"\n [showTime]=\"true\"\n dateFormat=\"dd-M-yy\"\n [placeholder]=\"'Visible Date'\"\n [ngClass]=\"{\n 'is-invalid': submitted && f['visible_from'].errors\n }\">\n </p-calendar>\n </div>\n </pw-input-container>\n </div>\n </div>\n <!-- visible_until -->\n <div class=\"col-12 col-sm-4 col-md-3\">\n <div class=\"mb-3\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.VisibleUntil' | transloco\"\n [label]=\"'Admin.LoginNotification.VisibleUntil' | transloco\"\n name=\"visible_until\"\n [errorMsg]=\"\n 'Admin.LoginNotification.Validation.VisibleUntil'\n | transloco\n \">\n <div>\n <p-calendar formControlName=\"visible_until\"\n [showIcon]=\"true\"\n [showTime]=\"true\"\n dateFormat=\"dd-M-yy\"\n [placeholder]=\"'Visible Until Date'\"\n [ngClass]=\"{\n 'is-invalid': submitted && f['visible_until'].errors\n }\">\n </p-calendar>\n </div>\n </pw-input-container>\n </div>\n </div>\n <!-- body -->\n <div class=\"col-12 col-sm-12\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.Body' | transloco\"\n [label]=\"'Admin.LoginNotification.Body' | transloco\"\n name=\"body\"\n [errorMsg]=\"'Admin.LoginNotification.Validation.Body' | transloco\">\n <textarea rows=\"3\"\n type=\"text\"\n class=\"form-control\"\n formControlName=\"body\"\n [ngClass]=\"{ 'is-invalid': submitted && f['body'].errors }\"></textarea>\n </pw-input-container>\n </div>\n </div>\n <div class=\"col-12 text-end mt-3\">\n <button type=\"button\"\n class=\"btn btn-outline-default me-2\"\n (click)=\"back()\">\n {{ 'Button.Cancel' | transloco }}\n </button>\n <button type=\"submit\"\n [buttonBusy]=\"buttonBusy\"\n class=\"btn btn-primary\">\n {{ 'Button.Submit' | transloco }}\n </button>\n </div>\n </form>\n </div>\n </div>\n </div>\n</div>\n", dependencies: [{ kind: "component", type: i6.MultiSelect, selector: "p-multiSelect", inputs: ["id", "ariaLabel", "style", "styleClass", "panelStyle", "panelStyleClass", "inputId", "disabled", "readonly", "group", "filter", "filterPlaceHolder", "filterLocale", "overlayVisible", "tabindex", "variant", "appendTo", "dataKey", "name", "ariaLabelledBy", "displaySelectedLabel", "maxSelectedLabels", "selectionLimit", "selectedItemsLabel", "showToggleAll", "emptyFilterMessage", "emptyMessage", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "showHeader", "filterBy", "scrollHeight", "lazy", "virtualScroll", "loading", "virtualScrollItemSize", "loadingIcon", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "display", "autocomplete", "showClear", "autofocus", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "defaultLabel", "placeholder", "options", "filterValue", "itemSize", "selectAll", "focusOnHover", "filterFields", "selectOnFocus", "autoOptionFocus"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onClear", "onPanelShow", "onPanelHide", "onLazyLoad", "onRemove", "onSelectAllChange"] }, { kind: "component", type: i7$2.Calendar, selector: "p-calendar", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepYearPicker", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.ProgressSpinner, selector: "p-progressSpinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "component", type: i9.InputContainerComponent, selector: "pw-input-container", inputs: ["name", "label", "labelClass", "tooltipPosition", "required", "errorMsg", "isReadOnly", "showTooltip", "tooltipText", "showTriangle", "afterLabel", "showAfterLabel", "showTriangleText"] }, { kind: "directive", type: i10.ButtonBusyDirective, selector: "[buttonBusy]", inputs: ["buttonBusy", "busyText"] }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i3.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "pipe", type: i2.AsyncPipe, name: "async" }, { kind: "pipe", type: i12.TranslocoPipe, name: "transloco" }] }); }
|
|
2276
2276
|
}
|
|
2277
2277
|
__decorate([
|
|
2278
2278
|
ValidateForm('form'),
|
|
@@ -2282,7 +2282,7 @@ __decorate([
|
|
|
2282
2282
|
], LoginNotificationDetailsComponent.prototype, "onSave", null);
|
|
2283
2283
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: LoginNotificationDetailsComponent, decorators: [{
|
|
2284
2284
|
type: Component,
|
|
2285
|
-
args: [{ selector: 'pw-login-notification-details', template: "<div class=\"container-fluid pw-tab overflow-hidden\">\n <div class=\"dashboard\">\n <div class=\"dashboard-body\">\n <div class=\"me-auto col-xs-6 mt-4\">\n <a href=\"javascript:void(0)\"\n [routerLink]=\"[routers.loginNotifications]\"\n class=\"previous\">\n <i class=\"fa fa-arrow-alt-circle-left\" aria-hidden=\"true\"></i>\n </a>\n <h3 class=\"m-subheader__title m-subheader__title--separator\">\n <span>{{ id ? 'Edit' : 'Add New' }}: Login Notification</span>\n </h3>\n </div>\n <div class=\"w-100 text-center mt-3\"\n *ngIf=\"isLoading\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div class=\"p-2 mt-3\">\n <form [formGroup]=\"form\"\n *ngIf=\"!isLoading\"\n (ngSubmit)=\"onSave()\">\n <div class=\"row\">\n <div class=\"col-12 col-sm-4 col-md-3\"\n *ngIf=\"loginNotificationTypes$ | async as types\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.NotificationType' | transloco\"\n [label]=\"'Admin.LoginNotification.NotificationType' | transloco\"\n name=\"notification_type\"\n [errorMsg]=\"\n 'Admin.LoginNotification.Validation.NotificationType'\n | transloco\n \">\n\n <select id=\"type\"\n class=\"form-select mt-2 no-radius\"\n [ngClass]=\"{\n 'is-invalid': submitted && f['notification_type'].errors\n }\"\n formControlName=\"notification_type\">\n <option value=\"\">Select Type</option>\n <option *ngFor=\"let item of types['available_types']\"\n [value]=\"item\">\n {{ item }}\n </option>\n </select>\n </pw-input-container>\n </div>\n <!-- Feature keys -->\n <div class=\"mb-3 col-12 col-sm-4 col-md-3\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.Features' | transloco\"\n [label]=\"'Admin.LoginNotification.Features' | transloco\"\n name=\"feature_keys\"\n [errorMsg]=\"\n 'Admin.LoginNotification.Validation.Features' | transloco\n \">\n <p-multiSelect [options]=\"featureKeys\"\n placeholder=\"Select feature keys\"\n [showHeader]=\"true\"\n [showToggleAll]=\"true\"\n formControlName=\"feature_keys\"\n appendTo=\"body\"></p-multiSelect>\n </pw-input-container>\n </div>\n <!-- visible_from -->\n <div class=\"col-12 col-sm-4 col-md-3\">\n <div class=\"mb-3\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.VisibleFrom' | transloco\"\n [label]=\"'Admin.LoginNotification.VisibleFrom' | transloco\"\n name=\"visible_from\"\n [errorMsg]=\"\n 'Admin.LoginNotification.Validation.VisibleFrom' | transloco\n \">\n <div>\n <p-calendar formControlName=\"visible_from\"\n [showIcon]=\"true\"\n [showTime]=\"true\"\n dateFormat=\"dd-M-yy\"\n [placeholder]=\"'Visible Date'\"\n [ngClass]=\"{\n 'is-invalid': submitted && f['visible_from'].errors\n }\">\n </p-calendar>\n </div>\n </pw-input-container>\n </div>\n </div>\n <!-- visible_until -->\n <div class=\"col-12 col-sm-4 col-md-3\">\n <div class=\"mb-3\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.VisibleUntil' | transloco\"\n [label]=\"'Admin.LoginNotification.VisibleUntil' | transloco\"\n name=\"visible_until\"\n [errorMsg]=\"\n 'Admin.LoginNotification.Validation.VisibleUntil'\n | transloco\n \">\n <div>\n <p-calendar formControlName=\"visible_until\"\n [showIcon]=\"true\"\n [showTime]=\"true\"\n dateFormat=\"dd-M-
|
|
2285
|
+
args: [{ selector: 'pw-login-notification-details', template: "<div class=\"container-fluid pw-tab overflow-hidden\">\n <div class=\"dashboard\">\n <div class=\"dashboard-body\">\n <div class=\"me-auto col-xs-6 mt-4\">\n <a href=\"javascript:void(0)\"\n [routerLink]=\"[routers.loginNotifications]\"\n class=\"previous\">\n <i class=\"fa fa-arrow-alt-circle-left\" aria-hidden=\"true\"></i>\n </a>\n <h3 class=\"m-subheader__title m-subheader__title--separator\">\n <span>{{ id ? 'Edit' : 'Add New' }}: Login Notification</span>\n </h3>\n </div>\n <div class=\"w-100 text-center mt-3\"\n *ngIf=\"isLoading\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div class=\"p-2 mt-3\">\n <form [formGroup]=\"form\"\n *ngIf=\"!isLoading\"\n (ngSubmit)=\"onSave()\">\n <div class=\"row\">\n <div class=\"col-12 col-sm-4 col-md-3\"\n *ngIf=\"loginNotificationTypes$ | async as types\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.NotificationType' | transloco\"\n [label]=\"'Admin.LoginNotification.NotificationType' | transloco\"\n name=\"notification_type\"\n [errorMsg]=\"\n 'Admin.LoginNotification.Validation.NotificationType'\n | transloco\n \">\n\n <select id=\"type\"\n class=\"form-select mt-2 no-radius\"\n [ngClass]=\"{\n 'is-invalid': submitted && f['notification_type'].errors\n }\"\n formControlName=\"notification_type\">\n <option value=\"\">Select Type</option>\n <option *ngFor=\"let item of types['available_types']\"\n [value]=\"item\">\n {{ item }}\n </option>\n </select>\n </pw-input-container>\n </div>\n <!-- Feature keys -->\n <div class=\"mb-3 col-12 col-sm-4 col-md-3\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.Features' | transloco\"\n [label]=\"'Admin.LoginNotification.Features' | transloco\"\n name=\"feature_keys\"\n [errorMsg]=\"\n 'Admin.LoginNotification.Validation.Features' | transloco\n \">\n <p-multiSelect [options]=\"featureKeys\"\n placeholder=\"Select feature keys\"\n [showHeader]=\"true\"\n [showToggleAll]=\"true\"\n formControlName=\"feature_keys\"\n appendTo=\"body\"></p-multiSelect>\n </pw-input-container>\n </div>\n <!-- visible_from -->\n <div class=\"col-12 col-sm-4 col-md-3\">\n <div class=\"mb-3\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.VisibleFrom' | transloco\"\n [label]=\"'Admin.LoginNotification.VisibleFrom' | transloco\"\n name=\"visible_from\"\n [errorMsg]=\"\n 'Admin.LoginNotification.Validation.VisibleFrom' | transloco\n \">\n <div>\n <p-calendar formControlName=\"visible_from\"\n [showIcon]=\"true\"\n [showTime]=\"true\"\n dateFormat=\"dd-M-yy\"\n [placeholder]=\"'Visible Date'\"\n [ngClass]=\"{\n 'is-invalid': submitted && f['visible_from'].errors\n }\">\n </p-calendar>\n </div>\n </pw-input-container>\n </div>\n </div>\n <!-- visible_until -->\n <div class=\"col-12 col-sm-4 col-md-3\">\n <div class=\"mb-3\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.VisibleUntil' | transloco\"\n [label]=\"'Admin.LoginNotification.VisibleUntil' | transloco\"\n name=\"visible_until\"\n [errorMsg]=\"\n 'Admin.LoginNotification.Validation.VisibleUntil'\n | transloco\n \">\n <div>\n <p-calendar formControlName=\"visible_until\"\n [showIcon]=\"true\"\n [showTime]=\"true\"\n dateFormat=\"dd-M-yy\"\n [placeholder]=\"'Visible Until Date'\"\n [ngClass]=\"{\n 'is-invalid': submitted && f['visible_until'].errors\n }\">\n </p-calendar>\n </div>\n </pw-input-container>\n </div>\n </div>\n <!-- body -->\n <div class=\"col-12 col-sm-12\">\n <pw-input-container [showTooltip]=\"true\"\n [tooltipText]=\"'Admin.LoginNotification.Tooltip.Body' | transloco\"\n [label]=\"'Admin.LoginNotification.Body' | transloco\"\n name=\"body\"\n [errorMsg]=\"'Admin.LoginNotification.Validation.Body' | transloco\">\n <textarea rows=\"3\"\n type=\"text\"\n class=\"form-control\"\n formControlName=\"body\"\n [ngClass]=\"{ 'is-invalid': submitted && f['body'].errors }\"></textarea>\n </pw-input-container>\n </div>\n </div>\n <div class=\"col-12 text-end mt-3\">\n <button type=\"button\"\n class=\"btn btn-outline-default me-2\"\n (click)=\"back()\">\n {{ 'Button.Cancel' | transloco }}\n </button>\n <button type=\"submit\"\n [buttonBusy]=\"buttonBusy\"\n class=\"btn btn-primary\">\n {{ 'Button.Submit' | transloco }}\n </button>\n </div>\n </form>\n </div>\n </div>\n </div>\n</div>\n" }]
|
|
2286
2286
|
}], ctorParameters: () => [{ type: i0.Injector }, { type: i1.AdminService }, { type: i1$1.ProductService }], propDecorators: { onSave: [] } });
|
|
2287
2287
|
|
|
2288
2288
|
class LoginNotificationTabsComponent {
|
|
@@ -2436,7 +2436,7 @@ class NewsletterDetailsComponent extends AppBaseComponent {
|
|
|
2436
2436
|
super.ngOnDestroy();
|
|
2437
2437
|
}
|
|
2438
2438
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: NewsletterDetailsComponent, deps: [{ token: i1.AdminService }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
2439
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: NewsletterDetailsComponent, selector: "pw-newsletter-details", usesInheritance: true, ngImport: i0, template: "<div class=\"container-fluid pw-tab overflow-hidden\">\n <div class=\"dashboard\">\n <div class=\"dashboard-body\">\n <div class=\"me-auto col-xs-6 mt-4\">\n <a href=\"javascript:void(0)\"
|
|
2439
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: NewsletterDetailsComponent, selector: "pw-newsletter-details", usesInheritance: true, ngImport: i0, template: "<div class=\"container-fluid pw-tab overflow-hidden\">\n <div class=\"dashboard\">\n <div class=\"dashboard-body\">\n <div class=\"me-auto col-xs-6 mt-4\">\n <a href=\"javascript:void(0)\" [routerLink]=\"[routers.newsletter]\" class=\"previous\">\n <i class=\"fa fa-arrow-alt-circle-left\" aria-hidden=\"true\"></i>\n </a>\n <h3 class=\"m-subheader__title m-subheader__title--separator\">\n <span>Newsletter: {{ isLoading ? '' : (data?.name ? data.name : 'Add New') }}</span>\n </h3>\n </div>\n\n <div class=\"w-100 text-center mt-3\" *ngIf=\"isLoading\">\n <p-progressSpinner strokeWidth=\"2\"></p-progressSpinner>\n </div>\n\n <div class=\"p-2 mt-3\" *ngIf=\"!isLoading\">\n <form [formGroup]=\"form\" (ngSubmit)=\"onSave()\">\n <div class=\"row\">\n <!-- Name Field -->\n <div class=\"col-12 col-md-8\">\n <pw-input-container [showTooltip]=\"true\" [tooltipText]=\"'Admin.Newsletter.Tooltip.Name' | transloco\"\n [label]=\"'Label.Name' | transloco\" class=\"mb-3\" name=\"name\" [errorMsg]=\"'Admin.Newsletter.Validation.Name' | transloco\">\n <input type=\"text\" class=\"form-control\" formControlName=\"name\" [ngClass]=\"{ 'is-invalid': submitted && f['name'].errors }\" />\n </pw-input-container>\n </div>\n\n <!-- Code Field -->\n <div class=\"col-12 col-md-4\">\n <pw-input-container [showTooltip]=\"true\" [tooltipText]=\"'Admin.Newsletter.Tooltip.Code' | transloco\"\n [label]=\"'Label.Code' | transloco\" class=\"mb-3\" name=\"code\" [errorMsg]=\"'Admin.Newsletter.Validation.Code' | transloco\">\n <input type=\"text\" class=\"form-control\" formControlName=\"code\" [ngClass]=\"{ 'is-invalid': submitted && f['code'].errors }\" />\n </pw-input-container>\n </div>\n\n <!-- IsActive Toggle -->\n <div class=\"col-6 col-md-2\">\n <pw-input-container [showTooltip]=\"true\" [tooltipText]=\"'Admin.Newsletter.Tooltip.IsActive' | transloco\"\n [label]=\"'Label.IsActive' | transloco\" class=\"mb-3\" name=\"active\">\n <ui-switch class=\"d-block\" formControlName=\"active\" name=\"active\" [ngClass]=\"{ 'is-invalid': submitted && f['active'].errors }\"></ui-switch>\n </pw-input-container>\n </div>\n\n <!-- CanUnsubscribe Toggle -->\n <div class=\"col-6 col-md-2\">\n <pw-input-container [showTooltip]=\"true\" [tooltipText]=\"'Admin.Newsletter.Tooltip.CanUnsubscribe' | transloco\"\n [label]=\"'Label.CanUnsubscribe' | transloco\" class=\"mb-3\" name=\"visible\">\n <ui-switch class=\"d-block\" formControlName=\"visible\" name=\"visible\" [ngClass]=\"{ 'is-invalid': submitted && f['visible'].errors }\"></ui-switch>\n </pw-input-container>\n </div>\n\n <!-- Form Actions -->\n <div class=\"col-12 text-end mt-3\">\n <button type=\"button\" class=\"btn btn-outline-default me-2\" (click)=\"back()\">{{ 'Button.Cancel' | transloco }}</button>\n <button type=\"submit\" [buttonBusy]=\"buttonBusy\" class=\"btn btn-primary\" *rbacAllow=\"'Pages.Admin.Newsletter.Edit'\">{{ 'Button.Submit' | transloco }}</button>\n </div>\n </div>\n </form>\n </div>\n </div>\n </div>\n</div>\n", dependencies: [{ kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "component", type: i4$1.UiSwitchComponent, selector: "ui-switch", inputs: ["size", "color", "switchOffColor", "switchColor", "defaultBgColor", "defaultBoColor", "checkedLabel", "uncheckedLabel", "checkedTextColor", "uncheckedTextColor", "beforeChange", "ariaLabel", "checked", "disabled", "reverse", "loading"], outputs: ["change", "changeEvent", "valueChange"] }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.ProgressSpinner, selector: "p-progressSpinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "component", type: i9.InputContainerComponent, selector: "pw-input-container", inputs: ["name", "label", "labelClass", "tooltipPosition", "required", "errorMsg", "isReadOnly", "showTooltip", "tooltipText", "showTriangle", "afterLabel", "showAfterLabel", "showTriangleText"] }, { kind: "directive", type: i10.ButtonBusyDirective, selector: "[buttonBusy]", inputs: ["buttonBusy", "busyText"] }, { kind: "directive", type: i10.RbacAllowDirective, selector: "[rbacAllow]", inputs: ["rbacAllow"] }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i3.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "pipe", type: i12.TranslocoPipe, name: "transloco" }] }); }
|
|
2440
2440
|
}
|
|
2441
2441
|
__decorate([
|
|
2442
2442
|
ValidateForm('form'),
|
|
@@ -2446,7 +2446,7 @@ __decorate([
|
|
|
2446
2446
|
], NewsletterDetailsComponent.prototype, "onSave", null);
|
|
2447
2447
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: NewsletterDetailsComponent, decorators: [{
|
|
2448
2448
|
type: Component,
|
|
2449
|
-
args: [{ selector: 'pw-newsletter-details', template: "<div class=\"container-fluid pw-tab overflow-hidden\">\n <div class=\"dashboard\">\n <div class=\"dashboard-body\">\n <div class=\"me-auto col-xs-6 mt-4\">\n <a href=\"javascript:void(0)\"
|
|
2449
|
+
args: [{ selector: 'pw-newsletter-details', template: "<div class=\"container-fluid pw-tab overflow-hidden\">\n <div class=\"dashboard\">\n <div class=\"dashboard-body\">\n <div class=\"me-auto col-xs-6 mt-4\">\n <a href=\"javascript:void(0)\" [routerLink]=\"[routers.newsletter]\" class=\"previous\">\n <i class=\"fa fa-arrow-alt-circle-left\" aria-hidden=\"true\"></i>\n </a>\n <h3 class=\"m-subheader__title m-subheader__title--separator\">\n <span>Newsletter: {{ isLoading ? '' : (data?.name ? data.name : 'Add New') }}</span>\n </h3>\n </div>\n\n <div class=\"w-100 text-center mt-3\" *ngIf=\"isLoading\">\n <p-progressSpinner strokeWidth=\"2\"></p-progressSpinner>\n </div>\n\n <div class=\"p-2 mt-3\" *ngIf=\"!isLoading\">\n <form [formGroup]=\"form\" (ngSubmit)=\"onSave()\">\n <div class=\"row\">\n <!-- Name Field -->\n <div class=\"col-12 col-md-8\">\n <pw-input-container [showTooltip]=\"true\" [tooltipText]=\"'Admin.Newsletter.Tooltip.Name' | transloco\"\n [label]=\"'Label.Name' | transloco\" class=\"mb-3\" name=\"name\" [errorMsg]=\"'Admin.Newsletter.Validation.Name' | transloco\">\n <input type=\"text\" class=\"form-control\" formControlName=\"name\" [ngClass]=\"{ 'is-invalid': submitted && f['name'].errors }\" />\n </pw-input-container>\n </div>\n\n <!-- Code Field -->\n <div class=\"col-12 col-md-4\">\n <pw-input-container [showTooltip]=\"true\" [tooltipText]=\"'Admin.Newsletter.Tooltip.Code' | transloco\"\n [label]=\"'Label.Code' | transloco\" class=\"mb-3\" name=\"code\" [errorMsg]=\"'Admin.Newsletter.Validation.Code' | transloco\">\n <input type=\"text\" class=\"form-control\" formControlName=\"code\" [ngClass]=\"{ 'is-invalid': submitted && f['code'].errors }\" />\n </pw-input-container>\n </div>\n\n <!-- IsActive Toggle -->\n <div class=\"col-6 col-md-2\">\n <pw-input-container [showTooltip]=\"true\" [tooltipText]=\"'Admin.Newsletter.Tooltip.IsActive' | transloco\"\n [label]=\"'Label.IsActive' | transloco\" class=\"mb-3\" name=\"active\">\n <ui-switch class=\"d-block\" formControlName=\"active\" name=\"active\" [ngClass]=\"{ 'is-invalid': submitted && f['active'].errors }\"></ui-switch>\n </pw-input-container>\n </div>\n\n <!-- CanUnsubscribe Toggle -->\n <div class=\"col-6 col-md-2\">\n <pw-input-container [showTooltip]=\"true\" [tooltipText]=\"'Admin.Newsletter.Tooltip.CanUnsubscribe' | transloco\"\n [label]=\"'Label.CanUnsubscribe' | transloco\" class=\"mb-3\" name=\"visible\">\n <ui-switch class=\"d-block\" formControlName=\"visible\" name=\"visible\" [ngClass]=\"{ 'is-invalid': submitted && f['visible'].errors }\"></ui-switch>\n </pw-input-container>\n </div>\n\n <!-- Form Actions -->\n <div class=\"col-12 text-end mt-3\">\n <button type=\"button\" class=\"btn btn-outline-default me-2\" (click)=\"back()\">{{ 'Button.Cancel' | transloco }}</button>\n <button type=\"submit\" [buttonBusy]=\"buttonBusy\" class=\"btn btn-primary\" *rbacAllow=\"'Pages.Admin.Newsletter.Edit'\">{{ 'Button.Submit' | transloco }}</button>\n </div>\n </div>\n </form>\n </div>\n </div>\n </div>\n</div>\n" }]
|
|
2450
2450
|
}], ctorParameters: () => [{ type: i1.AdminService }, { type: i0.Injector }], propDecorators: { onSave: [] } });
|
|
2451
2451
|
|
|
2452
2452
|
class NewsletterItemDetailsComponent extends AppBaseComponent {
|
|
@@ -4295,11 +4295,11 @@ class SubscriptionAgentsListComponent extends AppBaseComponent {
|
|
|
4295
4295
|
});
|
|
4296
4296
|
}
|
|
4297
4297
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: SubscriptionAgentsListComponent, deps: [{ token: i1.AdminService }, { token: i11.NgbDateParserFormatter }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
4298
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: SubscriptionAgentsListComponent, selector: "pw-subscription-agents-list", usesInheritance: true, ngImport: i0, template: "<ng-container *ngIf=\"!newEmbass\">\n <div class=\"w-100 text-center mt-3\">\n <div class=\"d-flex align-items-center\">\n <div class=\"ms-auto col-xs-12\">\n <a class=\"btn btn-sm btn-outline-primary float-end\"\n (click)=\"newEmbass = true\"\n id=\"btn-create\">\n <i class=\"fa fa-plus-circle me-2\" aria-hidden=\"true\"></i>Add Ambassadors\n </a>\n </div>\n </div>\n <ng-template [ngIf]=\"!isLoaded\">\n <p-progressSpinner> </p-progressSpinner>\n </ng-template>\n </div>\n <div class=\"primeng-datatable-container table-responsive mt-0\"\n [class.hideTable]=\"totalUnfilteredCount === 0\">\n <p-table #dt\n [value]=\"allAgents\"\n [paginator]=\"totalRecords !== 0\"\n [rows]=\"PAGE_SIZE\"\n [lazy]=\"true\"\n [totalRecords]=\"totalRecords\"\n [loading]=\"loading\"\n [filterDelay]=\"1000\"\n [customSort]=\"true\">\n <ng-template pTemplate=\"caption\">\n <div class=\"text-end\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Ambassadors...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90\" />\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\">{{ 'Admin.Subscriptions.AgentName' | transloco }}</th>\n <th scope=\"true\">{{ 'Label.Email' | transloco }}</th>\n <th scope=\"true\">{{ 'Admin.Subscriptions.Percentage' | transloco }}</th>\n <th scope=\"true\">{{ 'Admin.Subscriptions.EndDate' | transloco }}</th>\n <th scope=\"true\">{{ 'Label.Actions' | transloco }}</th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-agent>\n <tr>\n <td data-head=\"Agent Name\">\n {{ agent.user.first_name !== null ? agent.user.first_name : 'N/A' }}\n </td>\n <td data-head=\"Email\">\n {{ agent.user.email !== null ? agent.user.email : 'N/A' }}\n </td>\n <td data-head=\"Percentage\">{{ agent.percentage }}</td>\n <td data-head=\"End Date\">{{ agent.end_date | dateFormat }}</td>\n <td data-head=\"Action\">\n <ul class=\"list-unstyled list-inline\">\n <li ngbTooltip=\"Edit\"\n class=\"me-2 me-sm-3\"\n [routerLink]=\"[\n '/admin/subscription/',\n agent.subscription_id,\n 'agent_details',\n agent.user_id\n ]\">\n <i class=\"fa fa-edit edit-icon\" aria-hidden=\"true\"></i>\n </li>\n <li ngbTooltip=\"Delete\"\n class=\"me-2 me-sm-3\"\n (click)=\"onDelete(agent?.user_id)\">\n <i class=\"fa fa-trash delete-icon\" aria-hidden=\"true\"></i>\n </li>\n </ul>\n </td>\n </tr>\n </ng-template>\n </p-table>\n <span class=\"total-records-count\" *ngIf=\"totalRecords !== 0\">{{ 'Label.Total' | transloco }}: {{ totalRecords }}</span>\n </div>\n <div *ngIf=\"totalRecords === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Subscriptions.NoAmbassadorsMessage' | transloco\">\n </pw-no-data>\n </div>\n</ng-container>\n<ng-container *ngIf=\"newEmbass\">\n <form [formGroup]=\"formEmbassador\"\n id=\"mainFrom\"\n (ngSubmit)=\"onAddEmbassador()\">\n <div class=\"row mb-2\">\n <div class=\"col-10 col-md-6 offset-md-3\">\n <div class=\"ui-fluid skills-modal\">\n <p-autoComplete [suggestions]=\"filteredUsers\"\n formControlName=\"email\"\n dataKey=\"id\"\n field=\"displayName\"\n (completeMethod)=\"search($event)\"\n styleClass=\"w-100\"\n [dropdown]=\"true\"\n placeholder=\"Search ambassador\"\n [multiple]=\"true\">\n </p-autoComplete>\n </div>\n\n <div class=\"row mt-3\">\n <div class=\"col\">\n <input type=\"number\"\n formControlName=\"percentage\"\n class=\"form-control\"\n placeholder=\"Enter percentage\" />\n </div>\n <div class=\"col\">\n <div class=\"input-group\">\n <input class=\"form-control\"\n placeholder=\"dd-mm-yyyy\"\n formControlName=\"endDate\"\n ngbDatepicker\n #d=\"ngbDatepicker\"\n [minDate]=\"{ day: 1, month: 1, year: 1950 }\"\n [maxDate]=\"{ day: 31, month: 12, year: 2050 }\" />\n <div class=\"input-group-append\">\n <button class=\"btn btn-primary\"\n (click)=\"d.toggle()\"\n type=\"button\">\n <i class=\"fa fa-calendar\" aria-hidden=\"true\"></i>\n </button>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"text-center mt-2\">\n <button type=\"button\"\n (click)=\"newEmbass = false\"\n class=\"btn btn-sm btn-outline-default me-2\">\n {{ 'Button.Cancel' | transloco }}\n </button>\n <button type=\"submit\"\n [buttonBusy]=\"submitted\"\n class=\"btn btn-sm btn-primary me-2\">Add Ambassador</button>\n </div>\n </form>\n</ng-container>\n", styles: ["#mainFrom{padding-bottom:144px}\n"], dependencies: [{ kind: "component", type: i2$1.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorStyleClass", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "groupRowsByOrder", "responsiveLayout", "breakpoint", "paginatorLocale", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll", "virtualRowHeight"], outputs: ["contextMenuSelectionChange", "selectAllChange", "selectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: i3$1.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "component", type: i4$3.AutoComplete, selector: "p-autoComplete", inputs: ["minLength", "delay", "style", "panelStyle", "styleClass", "panelStyleClass", "inputStyle", "inputId", "inputStyleClass", "placeholder", "readonly", "disabled", "scrollHeight", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "maxlength", "name", "required", "size", "appendTo", "autoHighlight", "forceSelection", "type", "autoZIndex", "baseZIndex", "ariaLabel", "dropdownAriaLabel", "ariaLabelledBy", "dropdownIcon", "unique", "group", "completeOnFocus", "showClear", "field", "dropdown", "showEmptyMessage", "dropdownMode", "multiple", "tabindex", "dataKey", "emptyMessage", "showTransitionOptions", "hideTransitionOptions", "autofocus", "autocomplete", "optionGroupChildren", "optionGroupLabel", "overlayOptions", "suggestions", "itemSize", "optionLabel", "optionValue", "id", "searchMessage", "emptySelectionMessage", "selectionMessage", "autoOptionFocus", "selectOnFocus", "searchLocale", "optionDisabled", "focusOnHover", "variant"], outputs: ["completeMethod", "onSelect", "onUnselect", "onFocus", "onBlur", "onDropdownClick", "onClear", "onKeyUp", "onShow", "onHide", "onLazyLoad"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["variant"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.ProgressSpinner, selector: "p-progressSpinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "component", type: i9.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "directive", type: i10.ButtonBusyDirective, selector: "[buttonBusy]", inputs: ["buttonBusy", "busyText"] }, { kind: "directive", type: i11.NgbInputDatepicker, selector: "input[ngbDatepicker]", inputs: ["autoClose", "contentTemplate", "datepickerClass", "dayTemplate", "dayTemplateData", "displayMonths", "firstDayOfWeek", "footerTemplate", "markDisabled", "minDate", "maxDate", "navigation", "outsideDays", "placement", "popperOptions", "restoreFocus", "showWeekNumbers", "startDate", "container", "positionTarget", "weekdays", "disabled"], outputs: ["dateSelect", "navigate", "closed"], exportAs: ["ngbDatepicker"] }, { kind: "directive", type: i11.NgbTooltip, selector: "[ngbTooltip]", inputs: ["animation", "autoClose", "placement", "popperOptions", "triggers", "positionTarget", "container", "disableTooltip", "tooltipClass", "tooltipContext", "openDelay", "closeDelay", "ngbTooltip"], outputs: ["shown", "hidden"], exportAs: ["ngbTooltip"] }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i3.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "pipe", type: i12.TranslocoPipe, name: "transloco" }, { kind: "pipe", type: i13.DateFormatPipe, name: "dateFormat" }] }); }
|
|
4298
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: SubscriptionAgentsListComponent, selector: "pw-subscription-agents-list", usesInheritance: true, ngImport: i0, template: "<ng-container *ngIf=\"!newEmbass\">\n <div class=\"w-100 text-center mt-3\">\n <div class=\"d-flex align-items-center\">\n <div class=\"ms-auto col-xs-12\">\n <a class=\"btn btn-sm btn-outline-primary float-end\"\n (click)=\"newEmbass = true\"\n id=\"btn-create\">\n <i class=\"fa fa-plus-circle me-2\" aria-hidden=\"true\"></i>Add Ambassadors\n </a>\n </div>\n </div>\n <ng-template [ngIf]=\"!isLoaded\">\n <p-progressSpinner> </p-progressSpinner>\n </ng-template>\n </div>\n <div class=\"primeng-datatable-container table-responsive mt-0\"\n [class.hideTable]=\"totalUnfilteredCount === 0\">\n <p-table #dt\n [value]=\"allAgents\"\n [paginator]=\"totalRecords !== 0\"\n [rows]=\"PAGE_SIZE\"\n [lazy]=\"true\"\n [totalRecords]=\"totalRecords\"\n [loading]=\"loading\"\n [filterDelay]=\"1000\"\n [customSort]=\"true\">\n <ng-template pTemplate=\"caption\">\n <div class=\"text-end\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Ambassadors...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90\" />\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\">{{ 'Admin.Subscriptions.AgentName' | transloco }}</th>\n <th scope=\"true\">{{ 'Label.Email' | transloco }}</th>\n <th scope=\"true\">{{ 'Admin.Subscriptions.Percentage' | transloco }}</th>\n <th scope=\"true\">{{ 'Admin.Subscriptions.EndDate' | transloco }}</th>\n <th scope=\"true\">{{ 'Label.Actions' | transloco }}</th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-agent>\n <tr>\n <td data-head=\"Agent Name\">\n {{ agent.user.first_name !== null ? agent.user.first_name : 'N/A' }}\n </td>\n <td data-head=\"Email\">\n {{ agent.user.email !== null ? agent.user.email : 'N/A' }}\n </td>\n <td data-head=\"Percentage\">{{ agent.percentage }}</td>\n <td data-head=\"End Date\">{{ agent.end_date | dateFormat }}</td>\n <td data-head=\"Action\">\n <ul class=\"list-unstyled list-inline\">\n <li ngbTooltip=\"Edit\"\n class=\"me-2 me-sm-3\"\n [routerLink]=\"[\n '/admin/subscription/',\n agent.subscription_id,\n 'agent_details',\n agent.user_id\n ]\">\n <i class=\"fa fa-edit edit-icon\" aria-hidden=\"true\"></i>\n </li>\n <li ngbTooltip=\"Delete\"\n class=\"me-2 me-sm-3\"\n (click)=\"onDelete(agent?.user_id)\">\n <i class=\"fa fa-trash delete-icon\" aria-hidden=\"true\"></i>\n </li>\n </ul>\n </td>\n </tr>\n </ng-template>\n </p-table>\n <span class=\"total-records-count\" *ngIf=\"totalRecords !== 0\">{{ 'Label.Total' | transloco }}: {{ totalRecords }}</span>\n </div>\n <div *ngIf=\"totalRecords === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Subscriptions.NoAmbassadorsMessage' | transloco\">\n </pw-no-data>\n </div>\n</ng-container>\n<ng-container *ngIf=\"newEmbass\">\n <form [formGroup]=\"formEmbassador\"\n id=\"mainFrom\"\n (ngSubmit)=\"onAddEmbassador()\">\n <div class=\"row mb-2\">\n <div class=\"col-10 col-md-6 offset-md-3\">\n <div class=\"ui-fluid skills-modal\">\n <p-autoComplete [suggestions]=\"filteredUsers\"\n formControlName=\"email\"\n dataKey=\"id\"\n field=\"displayName\"\n (completeMethod)=\"search($event)\"\n styleClass=\"w-100\"\n [dropdown]=\"true\"\n placeholder=\"Search ambassador\"\n [multiple]=\"true\">\n </p-autoComplete>\n </div>\n\n <div class=\"row mt-3\">\n <div class=\"col\">\n <input type=\"number\"\n formControlName=\"percentage\"\n class=\"form-control\"\n placeholder=\"Enter percentage\" />\n </div>\n <div class=\"col\">\n <div class=\"input-group\">\n <input class=\"form-control\"\n placeholder=\"dd-mmm-yyyy\"\n formControlName=\"endDate\"\n ngbDatepicker\n #d=\"ngbDatepicker\"\n [minDate]=\"{ day: 1, month: 1, year: 1950 }\"\n [maxDate]=\"{ day: 31, month: 12, year: 2050 }\" />\n <div class=\"input-group-append\">\n <button class=\"btn btn-primary\"\n (click)=\"d.toggle()\"\n type=\"button\">\n <i class=\"fa fa-calendar\" aria-hidden=\"true\"></i>\n </button>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"text-center mt-2\">\n <button type=\"button\"\n (click)=\"newEmbass = false\"\n class=\"btn btn-sm btn-outline-default me-2\">\n {{ 'Button.Cancel' | transloco }}\n </button>\n <button type=\"submit\"\n [buttonBusy]=\"submitted\"\n class=\"btn btn-sm btn-primary me-2\">Add Ambassador</button>\n </div>\n </form>\n</ng-container>\n", styles: ["#mainFrom{padding-bottom:144px}\n"], dependencies: [{ kind: "component", type: i2$1.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorStyleClass", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "groupRowsByOrder", "responsiveLayout", "breakpoint", "paginatorLocale", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll", "virtualRowHeight"], outputs: ["contextMenuSelectionChange", "selectAllChange", "selectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: i3$1.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "component", type: i4$3.AutoComplete, selector: "p-autoComplete", inputs: ["minLength", "delay", "style", "panelStyle", "styleClass", "panelStyleClass", "inputStyle", "inputId", "inputStyleClass", "placeholder", "readonly", "disabled", "scrollHeight", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "maxlength", "name", "required", "size", "appendTo", "autoHighlight", "forceSelection", "type", "autoZIndex", "baseZIndex", "ariaLabel", "dropdownAriaLabel", "ariaLabelledBy", "dropdownIcon", "unique", "group", "completeOnFocus", "showClear", "field", "dropdown", "showEmptyMessage", "dropdownMode", "multiple", "tabindex", "dataKey", "emptyMessage", "showTransitionOptions", "hideTransitionOptions", "autofocus", "autocomplete", "optionGroupChildren", "optionGroupLabel", "overlayOptions", "suggestions", "itemSize", "optionLabel", "optionValue", "id", "searchMessage", "emptySelectionMessage", "selectionMessage", "autoOptionFocus", "selectOnFocus", "searchLocale", "optionDisabled", "focusOnHover", "variant"], outputs: ["completeMethod", "onSelect", "onUnselect", "onFocus", "onBlur", "onDropdownClick", "onClear", "onKeyUp", "onShow", "onHide", "onLazyLoad"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["variant"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NumberValueAccessor, selector: "input[type=number][formControlName],input[type=number][formControl],input[type=number][ngModel]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.ProgressSpinner, selector: "p-progressSpinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "component", type: i9.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "directive", type: i10.ButtonBusyDirective, selector: "[buttonBusy]", inputs: ["buttonBusy", "busyText"] }, { kind: "directive", type: i11.NgbInputDatepicker, selector: "input[ngbDatepicker]", inputs: ["autoClose", "contentTemplate", "datepickerClass", "dayTemplate", "dayTemplateData", "displayMonths", "firstDayOfWeek", "footerTemplate", "markDisabled", "minDate", "maxDate", "navigation", "outsideDays", "placement", "popperOptions", "restoreFocus", "showWeekNumbers", "startDate", "container", "positionTarget", "weekdays", "disabled"], outputs: ["dateSelect", "navigate", "closed"], exportAs: ["ngbDatepicker"] }, { kind: "directive", type: i11.NgbTooltip, selector: "[ngbTooltip]", inputs: ["animation", "autoClose", "placement", "popperOptions", "triggers", "positionTarget", "container", "disableTooltip", "tooltipClass", "tooltipContext", "openDelay", "closeDelay", "ngbTooltip"], outputs: ["shown", "hidden"], exportAs: ["ngbTooltip"] }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i3.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "pipe", type: i12.TranslocoPipe, name: "transloco" }, { kind: "pipe", type: i13.DateFormatPipe, name: "dateFormat" }] }); }
|
|
4299
4299
|
}
|
|
4300
4300
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: SubscriptionAgentsListComponent, decorators: [{
|
|
4301
4301
|
type: Component,
|
|
4302
|
-
args: [{ selector: 'pw-subscription-agents-list', template: "<ng-container *ngIf=\"!newEmbass\">\n <div class=\"w-100 text-center mt-3\">\n <div class=\"d-flex align-items-center\">\n <div class=\"ms-auto col-xs-12\">\n <a class=\"btn btn-sm btn-outline-primary float-end\"\n (click)=\"newEmbass = true\"\n id=\"btn-create\">\n <i class=\"fa fa-plus-circle me-2\" aria-hidden=\"true\"></i>Add Ambassadors\n </a>\n </div>\n </div>\n <ng-template [ngIf]=\"!isLoaded\">\n <p-progressSpinner> </p-progressSpinner>\n </ng-template>\n </div>\n <div class=\"primeng-datatable-container table-responsive mt-0\"\n [class.hideTable]=\"totalUnfilteredCount === 0\">\n <p-table #dt\n [value]=\"allAgents\"\n [paginator]=\"totalRecords !== 0\"\n [rows]=\"PAGE_SIZE\"\n [lazy]=\"true\"\n [totalRecords]=\"totalRecords\"\n [loading]=\"loading\"\n [filterDelay]=\"1000\"\n [customSort]=\"true\">\n <ng-template pTemplate=\"caption\">\n <div class=\"text-end\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Ambassadors...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90\" />\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\">{{ 'Admin.Subscriptions.AgentName' | transloco }}</th>\n <th scope=\"true\">{{ 'Label.Email' | transloco }}</th>\n <th scope=\"true\">{{ 'Admin.Subscriptions.Percentage' | transloco }}</th>\n <th scope=\"true\">{{ 'Admin.Subscriptions.EndDate' | transloco }}</th>\n <th scope=\"true\">{{ 'Label.Actions' | transloco }}</th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-agent>\n <tr>\n <td data-head=\"Agent Name\">\n {{ agent.user.first_name !== null ? agent.user.first_name : 'N/A' }}\n </td>\n <td data-head=\"Email\">\n {{ agent.user.email !== null ? agent.user.email : 'N/A' }}\n </td>\n <td data-head=\"Percentage\">{{ agent.percentage }}</td>\n <td data-head=\"End Date\">{{ agent.end_date | dateFormat }}</td>\n <td data-head=\"Action\">\n <ul class=\"list-unstyled list-inline\">\n <li ngbTooltip=\"Edit\"\n class=\"me-2 me-sm-3\"\n [routerLink]=\"[\n '/admin/subscription/',\n agent.subscription_id,\n 'agent_details',\n agent.user_id\n ]\">\n <i class=\"fa fa-edit edit-icon\" aria-hidden=\"true\"></i>\n </li>\n <li ngbTooltip=\"Delete\"\n class=\"me-2 me-sm-3\"\n (click)=\"onDelete(agent?.user_id)\">\n <i class=\"fa fa-trash delete-icon\" aria-hidden=\"true\"></i>\n </li>\n </ul>\n </td>\n </tr>\n </ng-template>\n </p-table>\n <span class=\"total-records-count\" *ngIf=\"totalRecords !== 0\">{{ 'Label.Total' | transloco }}: {{ totalRecords }}</span>\n </div>\n <div *ngIf=\"totalRecords === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Subscriptions.NoAmbassadorsMessage' | transloco\">\n </pw-no-data>\n </div>\n</ng-container>\n<ng-container *ngIf=\"newEmbass\">\n <form [formGroup]=\"formEmbassador\"\n id=\"mainFrom\"\n (ngSubmit)=\"onAddEmbassador()\">\n <div class=\"row mb-2\">\n <div class=\"col-10 col-md-6 offset-md-3\">\n <div class=\"ui-fluid skills-modal\">\n <p-autoComplete [suggestions]=\"filteredUsers\"\n formControlName=\"email\"\n dataKey=\"id\"\n field=\"displayName\"\n (completeMethod)=\"search($event)\"\n styleClass=\"w-100\"\n [dropdown]=\"true\"\n placeholder=\"Search ambassador\"\n [multiple]=\"true\">\n </p-autoComplete>\n </div>\n\n <div class=\"row mt-3\">\n <div class=\"col\">\n <input type=\"number\"\n formControlName=\"percentage\"\n class=\"form-control\"\n placeholder=\"Enter percentage\" />\n </div>\n <div class=\"col\">\n <div class=\"input-group\">\n <input class=\"form-control\"\n placeholder=\"dd-
|
|
4302
|
+
args: [{ selector: 'pw-subscription-agents-list', template: "<ng-container *ngIf=\"!newEmbass\">\n <div class=\"w-100 text-center mt-3\">\n <div class=\"d-flex align-items-center\">\n <div class=\"ms-auto col-xs-12\">\n <a class=\"btn btn-sm btn-outline-primary float-end\"\n (click)=\"newEmbass = true\"\n id=\"btn-create\">\n <i class=\"fa fa-plus-circle me-2\" aria-hidden=\"true\"></i>Add Ambassadors\n </a>\n </div>\n </div>\n <ng-template [ngIf]=\"!isLoaded\">\n <p-progressSpinner> </p-progressSpinner>\n </ng-template>\n </div>\n <div class=\"primeng-datatable-container table-responsive mt-0\"\n [class.hideTable]=\"totalUnfilteredCount === 0\">\n <p-table #dt\n [value]=\"allAgents\"\n [paginator]=\"totalRecords !== 0\"\n [rows]=\"PAGE_SIZE\"\n [lazy]=\"true\"\n [totalRecords]=\"totalRecords\"\n [loading]=\"loading\"\n [filterDelay]=\"1000\"\n [customSort]=\"true\">\n <ng-template pTemplate=\"caption\">\n <div class=\"text-end\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Ambassadors...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90\" />\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\">{{ 'Admin.Subscriptions.AgentName' | transloco }}</th>\n <th scope=\"true\">{{ 'Label.Email' | transloco }}</th>\n <th scope=\"true\">{{ 'Admin.Subscriptions.Percentage' | transloco }}</th>\n <th scope=\"true\">{{ 'Admin.Subscriptions.EndDate' | transloco }}</th>\n <th scope=\"true\">{{ 'Label.Actions' | transloco }}</th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-agent>\n <tr>\n <td data-head=\"Agent Name\">\n {{ agent.user.first_name !== null ? agent.user.first_name : 'N/A' }}\n </td>\n <td data-head=\"Email\">\n {{ agent.user.email !== null ? agent.user.email : 'N/A' }}\n </td>\n <td data-head=\"Percentage\">{{ agent.percentage }}</td>\n <td data-head=\"End Date\">{{ agent.end_date | dateFormat }}</td>\n <td data-head=\"Action\">\n <ul class=\"list-unstyled list-inline\">\n <li ngbTooltip=\"Edit\"\n class=\"me-2 me-sm-3\"\n [routerLink]=\"[\n '/admin/subscription/',\n agent.subscription_id,\n 'agent_details',\n agent.user_id\n ]\">\n <i class=\"fa fa-edit edit-icon\" aria-hidden=\"true\"></i>\n </li>\n <li ngbTooltip=\"Delete\"\n class=\"me-2 me-sm-3\"\n (click)=\"onDelete(agent?.user_id)\">\n <i class=\"fa fa-trash delete-icon\" aria-hidden=\"true\"></i>\n </li>\n </ul>\n </td>\n </tr>\n </ng-template>\n </p-table>\n <span class=\"total-records-count\" *ngIf=\"totalRecords !== 0\">{{ 'Label.Total' | transloco }}: {{ totalRecords }}</span>\n </div>\n <div *ngIf=\"totalRecords === 0 && isLoaded\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Subscriptions.NoAmbassadorsMessage' | transloco\">\n </pw-no-data>\n </div>\n</ng-container>\n<ng-container *ngIf=\"newEmbass\">\n <form [formGroup]=\"formEmbassador\"\n id=\"mainFrom\"\n (ngSubmit)=\"onAddEmbassador()\">\n <div class=\"row mb-2\">\n <div class=\"col-10 col-md-6 offset-md-3\">\n <div class=\"ui-fluid skills-modal\">\n <p-autoComplete [suggestions]=\"filteredUsers\"\n formControlName=\"email\"\n dataKey=\"id\"\n field=\"displayName\"\n (completeMethod)=\"search($event)\"\n styleClass=\"w-100\"\n [dropdown]=\"true\"\n placeholder=\"Search ambassador\"\n [multiple]=\"true\">\n </p-autoComplete>\n </div>\n\n <div class=\"row mt-3\">\n <div class=\"col\">\n <input type=\"number\"\n formControlName=\"percentage\"\n class=\"form-control\"\n placeholder=\"Enter percentage\" />\n </div>\n <div class=\"col\">\n <div class=\"input-group\">\n <input class=\"form-control\"\n placeholder=\"dd-mmm-yyyy\"\n formControlName=\"endDate\"\n ngbDatepicker\n #d=\"ngbDatepicker\"\n [minDate]=\"{ day: 1, month: 1, year: 1950 }\"\n [maxDate]=\"{ day: 31, month: 12, year: 2050 }\" />\n <div class=\"input-group-append\">\n <button class=\"btn btn-primary\"\n (click)=\"d.toggle()\"\n type=\"button\">\n <i class=\"fa fa-calendar\" aria-hidden=\"true\"></i>\n </button>\n </div>\n </div>\n </div>\n </div>\n </div>\n </div>\n <div class=\"text-center mt-2\">\n <button type=\"button\"\n (click)=\"newEmbass = false\"\n class=\"btn btn-sm btn-outline-default me-2\">\n {{ 'Button.Cancel' | transloco }}\n </button>\n <button type=\"submit\"\n [buttonBusy]=\"submitted\"\n class=\"btn btn-sm btn-primary me-2\">Add Ambassador</button>\n </div>\n </form>\n</ng-container>\n", styles: ["#mainFrom{padding-bottom:144px}\n"] }]
|
|
4303
4303
|
}], ctorParameters: () => [{ type: i1.AdminService }, { type: i11.NgbDateParserFormatter }, { type: i0.Injector }] });
|
|
4304
4304
|
|
|
4305
4305
|
class SubscriptionDetailsComponent extends AppBaseComponent {
|
|
@@ -5639,7 +5639,8 @@ class AhoyEventsComponent extends AppBaseComponent {
|
|
|
5639
5639
|
this.stopLoading = true;
|
|
5640
5640
|
}
|
|
5641
5641
|
else {
|
|
5642
|
-
|
|
5642
|
+
const validResults = result.filter(user => user.value && user.label);
|
|
5643
|
+
this.searchOptions = [...this.searchOptions, ...validResults];
|
|
5643
5644
|
this.userPage++;
|
|
5644
5645
|
}
|
|
5645
5646
|
});
|
|
@@ -5650,14 +5651,18 @@ class AhoyEventsComponent extends AppBaseComponent {
|
|
|
5650
5651
|
if (!service) {
|
|
5651
5652
|
service = this.microServices.find(x => x.value === this.appConfig.links?.main_api);
|
|
5652
5653
|
}
|
|
5653
|
-
const obj = {
|
|
5654
|
-
|
|
5655
|
-
|
|
5656
|
-
|
|
5657
|
-
|
|
5658
|
-
|
|
5659
|
-
|
|
5660
|
-
|
|
5654
|
+
const obj = {
|
|
5655
|
+
...paging,
|
|
5656
|
+
...(this.startDate && this.endDate
|
|
5657
|
+
? {
|
|
5658
|
+
start_at: new Date(this.startDate).toISOString(),
|
|
5659
|
+
end_at: new Date(this.endDate).toISOString()
|
|
5660
|
+
}
|
|
5661
|
+
: {}),
|
|
5662
|
+
search: this.searchText || '',
|
|
5663
|
+
user_ids: this.selectedOption.length ? this.selectedOption.toString() : undefined // Only include if there are selected options
|
|
5664
|
+
};
|
|
5665
|
+
Object.keys(obj).forEach(key => obj[key] === undefined && delete obj[key]);
|
|
5661
5666
|
this.ahoyService
|
|
5662
5667
|
.getAhoyEvents(obj, service, paging)
|
|
5663
5668
|
.subscribe((response) => {
|
|
@@ -5698,15 +5703,25 @@ class AhoyEventsComponent extends AppBaseComponent {
|
|
|
5698
5703
|
handleFilter($event) {
|
|
5699
5704
|
this.userSearchText = $event.filter;
|
|
5700
5705
|
this.stopLoading = false;
|
|
5701
|
-
this.userPage =
|
|
5706
|
+
this.userPage = 1; // Reset to first page for new search
|
|
5702
5707
|
this.adminDataService
|
|
5703
5708
|
.getUsers({
|
|
5704
|
-
page: this.
|
|
5709
|
+
page: this.userPage,
|
|
5705
5710
|
page_size: PAGE_SIZE,
|
|
5706
5711
|
search: this.userSearchText
|
|
5707
5712
|
}, this.subscriptionId)
|
|
5708
5713
|
.then(result => {
|
|
5709
|
-
|
|
5714
|
+
const newUsers = result.filter(user => user.value &&
|
|
5715
|
+
user.label &&
|
|
5716
|
+
!this.selectedOption.some(selected => selected.value === user.value));
|
|
5717
|
+
newUsers.forEach(user => {
|
|
5718
|
+
const index = this.searchOptions.findIndex(existing => existing.value === user.value);
|
|
5719
|
+
if (index !== -1) {
|
|
5720
|
+
console.log('Removing user');
|
|
5721
|
+
this.searchOptions.splice(index, 1); // Remove the user from searchOptions
|
|
5722
|
+
}
|
|
5723
|
+
});
|
|
5724
|
+
this.searchOptions = [...this.searchOptions, ...newUsers];
|
|
5710
5725
|
});
|
|
5711
5726
|
}
|
|
5712
5727
|
ngOnDestroy() {
|
|
@@ -5718,11 +5733,11 @@ class AhoyEventsComponent extends AppBaseComponent {
|
|
|
5718
5733
|
}
|
|
5719
5734
|
}
|
|
5720
5735
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: AhoyEventsComponent, deps: [{ token: i0.Injector }, { token: i1$1.AhoyService }, { token: i11.NgbModal }, { token: i0.ChangeDetectorRef }, { token: i1.AdminDataService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
5721
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: AhoyEventsComponent, selector: "pw-ahoy-events", viewQueries: [{ propertyName: "multiSelector", first: true, predicate: ["multiSelector"], descendants: true }], usesInheritance: true, ngImport: i0, template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0 float-start\">Ahoy Events</h2>\n </div>\n</div>\n<div class=\"w-100 text-center mt-3\"\n *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n</div>\n<div class=\"primeng-datatable-container mt-0\" [class.hideTable]=\"data.unfiltered_count === 0\">\n <div class=\"user-management-table table-responsive\">\n <p-table #dt\n [value]=\"data.events\"\n [paginator]=\"data.object_count !== 0\"\n [lazy]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [totalRecords]=\"data.object_count\"\n [loading]=\"loading\"\n [sortField]=\"defaultSortField\"\n [sortOrder]=\"defaultSortOrder\"\n [filterDelay]=\"1000\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template pTemplate=\"caption\">\n <div class=\"row\">\n <div *rbacAllow=\"'SuperAdmin'\"\n class=\"col-sm-2 mb-2 mb-md-0\">\n <select (change)=\"onServiceChange($event.target.value)\"\n class=\"form-control form-select\">\n <option *ngFor=\"let item of microServices\"\n [value]=\"item.name\">\n {{ item.name }}\n </option>\n </select>\n </div>\n <div class=\"col-sm-2\">\n <p-multiSelect #multiSelector [options]=\"searchOptions\"\n (onChange)=\"onSearchOptionChange($event)\"\n placeholder=\"Filter by users\"\n [(ngModel)]=\"filterSource\"\n [showToggleAll]=\"true\"\n [showHeader]=\"true\"\n appendTo=\"body\"\n [lazy]=\"true\"\n (scroll)=\"onScroll($event)\"\n (onPanelShow)=\"onPanelShow()\"\n [loading]=\"userLoading\"\n (onFilter)=\"handleFilter($event)\"\n >\n </p-multiSelect>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [showTime]=\"true\"\n [appendTo]=\"'body'\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'Start Date'\"\n [(ngModel)]=\"startDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [appendTo]=\"'body'\"\n [showTime]=\"true\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'End Date'\"\n [(ngModel)]=\"endDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col d-flex align-items-center\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Events...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90 form-control bg-white\" />\n </div>\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\"\n pSortableColumn=\"name\">\n {{ 'Label.Name' | transloco }}\n <p-sortIcon field=\"name\"></p-sortIcon>\n </th>\n <th scope=\"true\">\n {{ 'Admin.Tracking.Properties' | transloco }}\n </th>\n <th scope=\"true\"\n pSortableColumn=\"time\">\n {{ 'Admin.Tracking.Time' | transloco }}\n <p-sortIcon field=\"time\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"user_id\">\n {{ 'Admin.Tracking.User' | transloco }}\n <p-sortIcon field=\"user_id\"></p-sortIcon>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-event>\n <tr [class.d-none]=\"loading\">\n <td data-head=\"Name\">{{ event.name }}</td>\n <td data-head=\"Properties\">\n <span *ngIf=\"(event?.properties | json) !== '{}'\" class=\"badge bg-info cursor-pointer\"\n (click)=\"revealProp(objModal,event?.properties)\">Reveal properties</span></td>\n <td data-head=\"Time\">{{ event.time }}</td>\n <td data-head=\"User\">\n <span *ngIf=\"event?.user_id\">\n <span *ngIf=\"event?.user\"><a [routerLink]=\"['/members', event?.user?.slug]\">{{ event?.user?.first_name }} {{ event?.user?.last_name }}</a></span>\n <span *ngIf=\"!event?.user\">{{ event?.user_id }}</span>\n </span>\n </td>\n </tr>\n </ng-template>\n </p-table>\n <div *ngIf=\" data.object_count === 0 && data.unfiltered_count !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\" [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n <span *ngIf=\"data.object_count !== 0\" class=\"total-records-count\">{{ 'Label.Total' | transloco }}: {{ data.object_count }}</span>\n </div>\n</div>\n<div *ngIf=\"!loading && data.unfiltered_count === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Ahoy.NoEventsDataMessage' | transloco\"> </pw-no-data>\n</div>\n<!-- Object Modal -->\n<ng-template #objModal\n let-modal>\n <div class=\"modal-header\">\n <h4 class=\"modal-title\">{{ 'Admin.Tracking.Properties' | transloco }}</h4>\n <button type=\"button\"\n class=\"btn-close float-end\"\n aria-label=\"Close\"\n (click)=\"modal.dismiss()\">\n\n </button>\n </div>\n <div class=\"modal-body\">\n <div *ngIf=\"activeObject\">\n <ngx-json-viewer [json]=\"activeObject\"\n [expanded]=\"false\"></ngx-json-viewer>\n </div>\n </div>\n</ng-template>\n", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}@media (min-width: 767px){.table-responsive td,.table-responsive th{font-size:11px!important}}\n"], dependencies: [{ kind: "component", type: i2$1.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorStyleClass", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "groupRowsByOrder", "responsiveLayout", "breakpoint", "paginatorLocale", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll", "virtualRowHeight"], outputs: ["contextMenuSelectionChange", "selectAllChange", "selectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: i3$1.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "directive", type: i2$1.SortableColumn, selector: "[pSortableColumn]", inputs: ["pSortableColumn", "pSortableColumnDisabled"] }, { kind: "component", type: i2$1.SortIcon, selector: "p-sortIcon", inputs: ["field"] }, { kind: "component", type: i6.MultiSelect, selector: "p-multiSelect", inputs: ["id", "ariaLabel", "style", "styleClass", "panelStyle", "panelStyleClass", "inputId", "disabled", "readonly", "group", "filter", "filterPlaceHolder", "filterLocale", "overlayVisible", "tabindex", "variant", "appendTo", "dataKey", "name", "ariaLabelledBy", "displaySelectedLabel", "maxSelectedLabels", "selectionLimit", "selectedItemsLabel", "showToggleAll", "emptyFilterMessage", "emptyMessage", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "showHeader", "filterBy", "scrollHeight", "lazy", "virtualScroll", "loading", "virtualScrollItemSize", "loadingIcon", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "display", "autocomplete", "showClear", "autofocus", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "defaultLabel", "placeholder", "options", "filterValue", "itemSize", "selectAll", "focusOnHover", "filterFields", "selectOnFocus", "autoOptionFocus"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onClear", "onPanelShow", "onPanelHide", "onLazyLoad", "onRemove", "onSelectAllChange"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["variant"] }, { kind: "component", type: i8$1.NgxJsonViewerComponent, selector: "ngx-json-viewer", inputs: ["json", "expanded", "depth", "_currentDepth"] }, { kind: "component", type: i7$2.Calendar, selector: "p-calendar", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepYearPicker", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.ProgressSpinner, selector: "p-progressSpinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "component", type: i9.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "directive", type: i10.RbacAllowDirective, selector: "[rbacAllow]", inputs: ["rbacAllow"] }, { kind: "pipe", type: i2.JsonPipe, name: "json" }, { kind: "pipe", type: i12.TranslocoPipe, name: "transloco" }] }); }
|
|
5736
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: AhoyEventsComponent, selector: "pw-ahoy-events", viewQueries: [{ propertyName: "multiSelector", first: true, predicate: ["multiSelector"], descendants: true }], usesInheritance: true, ngImport: i0, template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0 float-start\">Ahoy Events</h2>\n </div>\n</div>\n<div class=\"w-100 text-center mt-3\"\n *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n</div>\n<div class=\"primeng-datatable-container mt-0\" [class.hideTable]=\"data.unfiltered_count === 0\">\n <div class=\"user-management-table table-responsive\">\n <p-table #dt\n [value]=\"data.events\"\n [paginator]=\"data.object_count !== 0\"\n [lazy]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [totalRecords]=\"data.object_count\"\n [loading]=\"loading\"\n [sortField]=\"defaultSortField\"\n [sortOrder]=\"defaultSortOrder\"\n [filterDelay]=\"1000\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template pTemplate=\"caption\">\n <div class=\"row\">\n <div *rbacAllow=\"'SuperAdmin'\"\n class=\"col-sm-2 mb-2 mb-md-0\">\n <select (change)=\"onServiceChange($event.target.value)\"\n class=\"form-control form-select\">\n <option *ngFor=\"let item of microServices\"\n [value]=\"item.name\">\n {{ item.name }}\n </option>\n </select>\n </div>\n <div class=\"col-sm-2\">\n <p-multiSelect #multiSelector [options]=\"searchOptions\"\n (onChange)=\"onSearchOptionChange($event)\"\n placeholder=\"Filter by users\"\n [(ngModel)]=\"filterSource\"\n [showToggleAll]=\"true\"\n [showHeader]=\"true\"\n appendTo=\"body\"\n [lazy]=\"true\"\n (scroll)=\"onScroll($event)\"\n (onPanelShow)=\"onPanelShow()\"\n [loading]=\"userLoading\"\n (onFilter)=\"handleFilter($event)\"\n >\n </p-multiSelect>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [showTime]=\"true\"\n [appendTo]=\"'body'\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'Start Date'\"\n [(ngModel)]=\"startDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [appendTo]=\"'body'\"\n [showTime]=\"true\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'End Date'\"\n [(ngModel)]=\"endDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col d-flex align-items-center\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Events...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90 form-control bg-white\" />\n </div>\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\"\n pSortableColumn=\"name\">\n {{ 'Label.Name' | transloco }}\n <p-sortIcon field=\"name\"></p-sortIcon>\n </th>\n <th scope=\"true\">\n {{ 'Admin.Tracking.Properties' | transloco }}\n </th>\n <th scope=\"true\"\n pSortableColumn=\"time\">\n {{ 'Admin.Tracking.Time' | transloco }}\n <p-sortIcon field=\"time\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"user_id\">\n {{ 'Admin.Tracking.User' | transloco }}\n <p-sortIcon field=\"user_id\"></p-sortIcon>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-event>\n <tr [class.d-none]=\"loading\">\n <td data-head=\"Name\">{{ event.name }}</td>\n <td data-head=\"Properties\">\n <span *ngIf=\"(event?.properties | json) !== '{}'\" class=\"badge bg-info cursor-pointer\"\n (click)=\"revealProp(objModal,event?.properties)\">Reveal properties</span></td>\n <td data-head=\"Time\">{{ event.time | dateFormat: 'datetime'}}</td>\n <td data-head=\"User\">\n <span *ngIf=\"event?.user_id\">\n <span *ngIf=\"event?.user\"><a [routerLink]=\"['/members', event?.user?.slug]\">{{ event?.user?.first_name }} {{ event?.user?.last_name }}</a></span>\n <span *ngIf=\"!event?.user\">{{ event?.user_id }}</span>\n </span>\n </td>\n </tr>\n </ng-template>\n </p-table>\n <div *ngIf=\" data.object_count === 0 && data.unfiltered_count !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\" [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n <span *ngIf=\"data.object_count !== 0\" class=\"total-records-count\">{{ 'Label.Total' | transloco }}: {{ data.object_count }}</span>\n </div>\n</div>\n<div *ngIf=\"!loading && data.unfiltered_count === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Ahoy.NoEventsDataMessage' | transloco\"> </pw-no-data>\n</div>\n<!-- Object Modal -->\n<ng-template #objModal\n let-modal>\n <div class=\"modal-header\">\n <h4 class=\"modal-title\">{{ 'Admin.Tracking.Properties' | transloco }}</h4>\n <button type=\"button\"\n class=\"btn-close float-end\"\n aria-label=\"Close\"\n (click)=\"modal.dismiss()\">\n\n </button>\n </div>\n <div class=\"modal-body\">\n <div *ngIf=\"activeObject\">\n <ngx-json-viewer [json]=\"activeObject\"\n [expanded]=\"false\"></ngx-json-viewer>\n </div>\n </div>\n</ng-template>\n", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}@media (min-width: 767px){.table-responsive td,.table-responsive th{font-size:11px!important}}\n"], dependencies: [{ kind: "component", type: i2$1.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorStyleClass", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "groupRowsByOrder", "responsiveLayout", "breakpoint", "paginatorLocale", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll", "virtualRowHeight"], outputs: ["contextMenuSelectionChange", "selectAllChange", "selectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: i3$1.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "directive", type: i2$1.SortableColumn, selector: "[pSortableColumn]", inputs: ["pSortableColumn", "pSortableColumnDisabled"] }, { kind: "component", type: i2$1.SortIcon, selector: "p-sortIcon", inputs: ["field"] }, { kind: "component", type: i6.MultiSelect, selector: "p-multiSelect", inputs: ["id", "ariaLabel", "style", "styleClass", "panelStyle", "panelStyleClass", "inputId", "disabled", "readonly", "group", "filter", "filterPlaceHolder", "filterLocale", "overlayVisible", "tabindex", "variant", "appendTo", "dataKey", "name", "ariaLabelledBy", "displaySelectedLabel", "maxSelectedLabels", "selectionLimit", "selectedItemsLabel", "showToggleAll", "emptyFilterMessage", "emptyMessage", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "showHeader", "filterBy", "scrollHeight", "lazy", "virtualScroll", "loading", "virtualScrollItemSize", "loadingIcon", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "display", "autocomplete", "showClear", "autofocus", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "defaultLabel", "placeholder", "options", "filterValue", "itemSize", "selectAll", "focusOnHover", "filterFields", "selectOnFocus", "autoOptionFocus"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onClear", "onPanelShow", "onPanelHide", "onLazyLoad", "onRemove", "onSelectAllChange"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["variant"] }, { kind: "component", type: i8$1.NgxJsonViewerComponent, selector: "ngx-json-viewer", inputs: ["json", "expanded", "depth", "_currentDepth"] }, { kind: "component", type: i7$2.Calendar, selector: "p-calendar", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepYearPicker", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.ProgressSpinner, selector: "p-progressSpinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "component", type: i9.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "directive", type: i10.RbacAllowDirective, selector: "[rbacAllow]", inputs: ["rbacAllow"] }, { kind: "pipe", type: i2.JsonPipe, name: "json" }, { kind: "pipe", type: i12.TranslocoPipe, name: "transloco" }, { kind: "pipe", type: i13.DateFormatPipe, name: "dateFormat" }] }); }
|
|
5722
5737
|
}
|
|
5723
5738
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: AhoyEventsComponent, decorators: [{
|
|
5724
5739
|
type: Component,
|
|
5725
|
-
args: [{ selector: 'pw-ahoy-events', template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0 float-start\">Ahoy Events</h2>\n </div>\n</div>\n<div class=\"w-100 text-center mt-3\"\n *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n</div>\n<div class=\"primeng-datatable-container mt-0\" [class.hideTable]=\"data.unfiltered_count === 0\">\n <div class=\"user-management-table table-responsive\">\n <p-table #dt\n [value]=\"data.events\"\n [paginator]=\"data.object_count !== 0\"\n [lazy]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [totalRecords]=\"data.object_count\"\n [loading]=\"loading\"\n [sortField]=\"defaultSortField\"\n [sortOrder]=\"defaultSortOrder\"\n [filterDelay]=\"1000\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template pTemplate=\"caption\">\n <div class=\"row\">\n <div *rbacAllow=\"'SuperAdmin'\"\n class=\"col-sm-2 mb-2 mb-md-0\">\n <select (change)=\"onServiceChange($event.target.value)\"\n class=\"form-control form-select\">\n <option *ngFor=\"let item of microServices\"\n [value]=\"item.name\">\n {{ item.name }}\n </option>\n </select>\n </div>\n <div class=\"col-sm-2\">\n <p-multiSelect #multiSelector [options]=\"searchOptions\"\n (onChange)=\"onSearchOptionChange($event)\"\n placeholder=\"Filter by users\"\n [(ngModel)]=\"filterSource\"\n [showToggleAll]=\"true\"\n [showHeader]=\"true\"\n appendTo=\"body\"\n [lazy]=\"true\"\n (scroll)=\"onScroll($event)\"\n (onPanelShow)=\"onPanelShow()\"\n [loading]=\"userLoading\"\n (onFilter)=\"handleFilter($event)\"\n >\n </p-multiSelect>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [showTime]=\"true\"\n [appendTo]=\"'body'\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'Start Date'\"\n [(ngModel)]=\"startDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [appendTo]=\"'body'\"\n [showTime]=\"true\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'End Date'\"\n [(ngModel)]=\"endDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col d-flex align-items-center\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Events...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90 form-control bg-white\" />\n </div>\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\"\n pSortableColumn=\"name\">\n {{ 'Label.Name' | transloco }}\n <p-sortIcon field=\"name\"></p-sortIcon>\n </th>\n <th scope=\"true\">\n {{ 'Admin.Tracking.Properties' | transloco }}\n </th>\n <th scope=\"true\"\n pSortableColumn=\"time\">\n {{ 'Admin.Tracking.Time' | transloco }}\n <p-sortIcon field=\"time\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"user_id\">\n {{ 'Admin.Tracking.User' | transloco }}\n <p-sortIcon field=\"user_id\"></p-sortIcon>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-event>\n <tr [class.d-none]=\"loading\">\n <td data-head=\"Name\">{{ event.name }}</td>\n <td data-head=\"Properties\">\n <span *ngIf=\"(event?.properties | json) !== '{}'\" class=\"badge bg-info cursor-pointer\"\n (click)=\"revealProp(objModal,event?.properties)\">Reveal properties</span></td>\n <td data-head=\"Time\">{{ event.time }}</td>\n <td data-head=\"User\">\n <span *ngIf=\"event?.user_id\">\n <span *ngIf=\"event?.user\"><a [routerLink]=\"['/members', event?.user?.slug]\">{{ event?.user?.first_name }} {{ event?.user?.last_name }}</a></span>\n <span *ngIf=\"!event?.user\">{{ event?.user_id }}</span>\n </span>\n </td>\n </tr>\n </ng-template>\n </p-table>\n <div *ngIf=\" data.object_count === 0 && data.unfiltered_count !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\" [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n <span *ngIf=\"data.object_count !== 0\" class=\"total-records-count\">{{ 'Label.Total' | transloco }}: {{ data.object_count }}</span>\n </div>\n</div>\n<div *ngIf=\"!loading && data.unfiltered_count === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Ahoy.NoEventsDataMessage' | transloco\"> </pw-no-data>\n</div>\n<!-- Object Modal -->\n<ng-template #objModal\n let-modal>\n <div class=\"modal-header\">\n <h4 class=\"modal-title\">{{ 'Admin.Tracking.Properties' | transloco }}</h4>\n <button type=\"button\"\n class=\"btn-close float-end\"\n aria-label=\"Close\"\n (click)=\"modal.dismiss()\">\n\n </button>\n </div>\n <div class=\"modal-body\">\n <div *ngIf=\"activeObject\">\n <ngx-json-viewer [json]=\"activeObject\"\n [expanded]=\"false\"></ngx-json-viewer>\n </div>\n </div>\n</ng-template>\n", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}@media (min-width: 767px){.table-responsive td,.table-responsive th{font-size:11px!important}}\n"] }]
|
|
5740
|
+
args: [{ selector: 'pw-ahoy-events', template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0 float-start\">Ahoy Events</h2>\n </div>\n</div>\n<div class=\"w-100 text-center mt-3\"\n *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n</div>\n<div class=\"primeng-datatable-container mt-0\" [class.hideTable]=\"data.unfiltered_count === 0\">\n <div class=\"user-management-table table-responsive\">\n <p-table #dt\n [value]=\"data.events\"\n [paginator]=\"data.object_count !== 0\"\n [lazy]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [totalRecords]=\"data.object_count\"\n [loading]=\"loading\"\n [sortField]=\"defaultSortField\"\n [sortOrder]=\"defaultSortOrder\"\n [filterDelay]=\"1000\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template pTemplate=\"caption\">\n <div class=\"row\">\n <div *rbacAllow=\"'SuperAdmin'\"\n class=\"col-sm-2 mb-2 mb-md-0\">\n <select (change)=\"onServiceChange($event.target.value)\"\n class=\"form-control form-select\">\n <option *ngFor=\"let item of microServices\"\n [value]=\"item.name\">\n {{ item.name }}\n </option>\n </select>\n </div>\n <div class=\"col-sm-2\">\n <p-multiSelect #multiSelector [options]=\"searchOptions\"\n (onChange)=\"onSearchOptionChange($event)\"\n placeholder=\"Filter by users\"\n [(ngModel)]=\"filterSource\"\n [showToggleAll]=\"true\"\n [showHeader]=\"true\"\n appendTo=\"body\"\n [lazy]=\"true\"\n (scroll)=\"onScroll($event)\"\n (onPanelShow)=\"onPanelShow()\"\n [loading]=\"userLoading\"\n (onFilter)=\"handleFilter($event)\"\n >\n </p-multiSelect>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [showTime]=\"true\"\n [appendTo]=\"'body'\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'Start Date'\"\n [(ngModel)]=\"startDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [appendTo]=\"'body'\"\n [showTime]=\"true\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'End Date'\"\n [(ngModel)]=\"endDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col d-flex align-items-center\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Events...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90 form-control bg-white\" />\n </div>\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\"\n pSortableColumn=\"name\">\n {{ 'Label.Name' | transloco }}\n <p-sortIcon field=\"name\"></p-sortIcon>\n </th>\n <th scope=\"true\">\n {{ 'Admin.Tracking.Properties' | transloco }}\n </th>\n <th scope=\"true\"\n pSortableColumn=\"time\">\n {{ 'Admin.Tracking.Time' | transloco }}\n <p-sortIcon field=\"time\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"user_id\">\n {{ 'Admin.Tracking.User' | transloco }}\n <p-sortIcon field=\"user_id\"></p-sortIcon>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-event>\n <tr [class.d-none]=\"loading\">\n <td data-head=\"Name\">{{ event.name }}</td>\n <td data-head=\"Properties\">\n <span *ngIf=\"(event?.properties | json) !== '{}'\" class=\"badge bg-info cursor-pointer\"\n (click)=\"revealProp(objModal,event?.properties)\">Reveal properties</span></td>\n <td data-head=\"Time\">{{ event.time | dateFormat: 'datetime'}}</td>\n <td data-head=\"User\">\n <span *ngIf=\"event?.user_id\">\n <span *ngIf=\"event?.user\"><a [routerLink]=\"['/members', event?.user?.slug]\">{{ event?.user?.first_name }} {{ event?.user?.last_name }}</a></span>\n <span *ngIf=\"!event?.user\">{{ event?.user_id }}</span>\n </span>\n </td>\n </tr>\n </ng-template>\n </p-table>\n <div *ngIf=\" data.object_count === 0 && data.unfiltered_count !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\" [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n <span *ngIf=\"data.object_count !== 0\" class=\"total-records-count\">{{ 'Label.Total' | transloco }}: {{ data.object_count }}</span>\n </div>\n</div>\n<div *ngIf=\"!loading && data.unfiltered_count === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Ahoy.NoEventsDataMessage' | transloco\"> </pw-no-data>\n</div>\n<!-- Object Modal -->\n<ng-template #objModal\n let-modal>\n <div class=\"modal-header\">\n <h4 class=\"modal-title\">{{ 'Admin.Tracking.Properties' | transloco }}</h4>\n <button type=\"button\"\n class=\"btn-close float-end\"\n aria-label=\"Close\"\n (click)=\"modal.dismiss()\">\n\n </button>\n </div>\n <div class=\"modal-body\">\n <div *ngIf=\"activeObject\">\n <ngx-json-viewer [json]=\"activeObject\"\n [expanded]=\"false\"></ngx-json-viewer>\n </div>\n </div>\n</ng-template>\n", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}@media (min-width: 767px){.table-responsive td,.table-responsive th{font-size:11px!important}}\n"] }]
|
|
5726
5741
|
}], ctorParameters: () => [{ type: i0.Injector }, { type: i1$1.AhoyService }, { type: i11.NgbModal }, { type: i0.ChangeDetectorRef }, { type: i1.AdminDataService }], propDecorators: { multiSelector: [{
|
|
5727
5742
|
type: ViewChild,
|
|
5728
5743
|
args: ['multiSelector']
|
|
@@ -5777,14 +5792,18 @@ class AhoyMessagesComponent extends AppBaseComponent {
|
|
|
5777
5792
|
if (!service) {
|
|
5778
5793
|
service = this.microServices.find(x => x.value === this.appConfig.links?.main_api);
|
|
5779
5794
|
}
|
|
5780
|
-
const obj = {
|
|
5781
|
-
|
|
5782
|
-
|
|
5783
|
-
|
|
5784
|
-
|
|
5785
|
-
|
|
5786
|
-
|
|
5787
|
-
|
|
5795
|
+
const obj = {
|
|
5796
|
+
...paging,
|
|
5797
|
+
...(this.startDate && this.endDate
|
|
5798
|
+
? {
|
|
5799
|
+
start_at: new Date(this.startDate).toISOString(),
|
|
5800
|
+
end_at: new Date(this.endDate).toISOString()
|
|
5801
|
+
}
|
|
5802
|
+
: {}),
|
|
5803
|
+
search: this.searchText || '',
|
|
5804
|
+
user_ids: this.selectedOption.length ? this.selectedOption.toString() : undefined // Only include if there are selected options
|
|
5805
|
+
};
|
|
5806
|
+
Object.keys(obj).forEach(key => obj[key] === undefined && delete obj[key]);
|
|
5788
5807
|
this.ahoyService
|
|
5789
5808
|
.getAhoyMessages(obj, service, paging)
|
|
5790
5809
|
.subscribe((response) => {
|
|
@@ -5843,7 +5862,8 @@ class AhoyMessagesComponent extends AppBaseComponent {
|
|
|
5843
5862
|
this.stopLoading = true;
|
|
5844
5863
|
}
|
|
5845
5864
|
else {
|
|
5846
|
-
|
|
5865
|
+
const validResults = result.filter(user => user.value && user.label);
|
|
5866
|
+
this.searchOptions = [...this.searchOptions, ...validResults];
|
|
5847
5867
|
this.userPage++;
|
|
5848
5868
|
}
|
|
5849
5869
|
});
|
|
@@ -5866,15 +5886,25 @@ class AhoyMessagesComponent extends AppBaseComponent {
|
|
|
5866
5886
|
handleFilter($event) {
|
|
5867
5887
|
this.userSearchText = $event.filter;
|
|
5868
5888
|
this.stopLoading = false;
|
|
5869
|
-
this.userPage =
|
|
5889
|
+
this.userPage = 1;
|
|
5870
5890
|
this.adminDataService
|
|
5871
5891
|
.getUsers({
|
|
5872
|
-
page: this.
|
|
5892
|
+
page: this.userPage,
|
|
5873
5893
|
page_size: PAGE_SIZE,
|
|
5874
5894
|
search: this.userSearchText
|
|
5875
5895
|
}, this.subscriptionId)
|
|
5876
5896
|
.then(result => {
|
|
5877
|
-
|
|
5897
|
+
const newUsers = result.filter(user => user.value &&
|
|
5898
|
+
user.label &&
|
|
5899
|
+
!this.selectedOption.some(selected => selected.value === user.value));
|
|
5900
|
+
newUsers.forEach(user => {
|
|
5901
|
+
const index = this.searchOptions.findIndex(existing => existing.value === user.value);
|
|
5902
|
+
if (index !== -1) {
|
|
5903
|
+
console.log('Removing user');
|
|
5904
|
+
this.searchOptions.splice(index, 1);
|
|
5905
|
+
}
|
|
5906
|
+
});
|
|
5907
|
+
this.searchOptions = [...this.searchOptions, ...newUsers];
|
|
5878
5908
|
});
|
|
5879
5909
|
}
|
|
5880
5910
|
ngOnDestroy() {
|
|
@@ -5975,25 +6005,28 @@ class AhoyVisitsComponent extends AppBaseComponent {
|
|
|
5975
6005
|
this.stopLoading = true;
|
|
5976
6006
|
}
|
|
5977
6007
|
else {
|
|
5978
|
-
|
|
6008
|
+
const validResults = result.filter(user => user.value && user.label);
|
|
6009
|
+
this.searchOptions = [...this.searchOptions, ...validResults];
|
|
5979
6010
|
this.userPage++;
|
|
5980
6011
|
}
|
|
5981
6012
|
});
|
|
5982
6013
|
}
|
|
5983
6014
|
getAhoyVisits(paging) {
|
|
5984
6015
|
this.isLoaded = false;
|
|
5985
|
-
|
|
5986
|
-
|
|
5987
|
-
|
|
5988
|
-
|
|
5989
|
-
|
|
5990
|
-
|
|
5991
|
-
|
|
5992
|
-
|
|
5993
|
-
|
|
5994
|
-
|
|
5995
|
-
|
|
5996
|
-
|
|
6016
|
+
const service = this.microServices.find(x => x.name === this.selectedMicroService) ||
|
|
6017
|
+
this.microServices.find(x => x.value === this.appConfig.links?.main_api);
|
|
6018
|
+
const obj = {
|
|
6019
|
+
...paging,
|
|
6020
|
+
...(this.startDate && this.endDate
|
|
6021
|
+
? {
|
|
6022
|
+
start_at: new Date(this.startDate).toISOString(),
|
|
6023
|
+
end_at: new Date(this.endDate).toISOString()
|
|
6024
|
+
}
|
|
6025
|
+
: {}),
|
|
6026
|
+
search: this.searchText || '',
|
|
6027
|
+
user_ids: this.selectedOption.length ? this.selectedOption.toString() : undefined // Only include if there are selected options
|
|
6028
|
+
};
|
|
6029
|
+
Object.keys(obj).forEach(key => obj[key] === undefined && delete obj[key]);
|
|
5997
6030
|
this.ahoyService
|
|
5998
6031
|
.getAhoyVisits(obj, service, paging)
|
|
5999
6032
|
.subscribe((response) => {
|
|
@@ -6027,15 +6060,25 @@ class AhoyVisitsComponent extends AppBaseComponent {
|
|
|
6027
6060
|
handleFilter($event) {
|
|
6028
6061
|
this.userSearchText = $event.filter;
|
|
6029
6062
|
this.stopLoading = false;
|
|
6030
|
-
this.userPage =
|
|
6063
|
+
this.userPage = 1;
|
|
6031
6064
|
this.adminDataService
|
|
6032
6065
|
.getUsers({
|
|
6033
|
-
page: this.
|
|
6066
|
+
page: this.userPage,
|
|
6034
6067
|
page_size: PAGE_SIZE,
|
|
6035
6068
|
search: this.userSearchText
|
|
6036
6069
|
}, this.subscriptionId)
|
|
6037
6070
|
.then(result => {
|
|
6038
|
-
|
|
6071
|
+
const newUsers = result.filter(user => user.value &&
|
|
6072
|
+
user.label &&
|
|
6073
|
+
!this.selectedOption.some(selected => selected.value === user.value));
|
|
6074
|
+
newUsers.forEach(user => {
|
|
6075
|
+
const index = this.searchOptions.findIndex(existing => existing.value === user.value);
|
|
6076
|
+
if (index !== -1) {
|
|
6077
|
+
console.log('Removing user');
|
|
6078
|
+
this.searchOptions.splice(index, 1);
|
|
6079
|
+
}
|
|
6080
|
+
});
|
|
6081
|
+
this.searchOptions = [...this.searchOptions, ...newUsers];
|
|
6039
6082
|
});
|
|
6040
6083
|
}
|
|
6041
6084
|
ngOnDestroy() {
|
|
@@ -6046,11 +6089,11 @@ class AhoyVisitsComponent extends AppBaseComponent {
|
|
|
6046
6089
|
}
|
|
6047
6090
|
}
|
|
6048
6091
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: AhoyVisitsComponent, deps: [{ token: i0.Injector }, { token: i1$1.AhoyService }, { token: i0.ChangeDetectorRef }, { token: i1.AdminDataService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
6049
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: AhoyVisitsComponent, selector: "pw-ahoy-visits", usesInheritance: true, ngImport: i0, template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0 float-start\">Ahoy Visits</h2>\n </div>\n</div>\n<div class=\"w-100 text-center mt-3\"\n *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n</div>\n<div class=\"primeng-datatable-container mt-0\" [class.hideTable]=\"data.unfiltered_count === 0\">\n <div class=\"user-management-table table-responsive\">\n <p-table #dt\n [value]=\"data.visits\"\n [paginator]=\"data.object_count !== 0\"\n [lazy]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [totalRecords]=\"data.object_count\"\n [loading]=\"loading\"\n [sortField]=\"'started_at'\"\n [sortOrder]=\"-1\"\n [filterDelay]=\"1000\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template pTemplate=\"caption\">\n <div class=\"row\">\n <div *rbacAllow=\"'SuperAdmin'\"\n class=\"col-sm-2 mb-2 mb-md-0\">\n <select (change)=\"onServiceChange($event.target.value)\"\n class=\"form-control form-select\">\n <option *ngFor=\"let item of microServices\"\n [value]=\"item.name\">\n {{ item.name }}\n </option>\n </select>\n </div>\n <div class=\"col-sm-2\">\n <p-multiSelect #multiSelector [options]=\"searchOptions\"\n (onChange)=\"onSearchOptionChange($event)\"\n placeholder=\"Filter by users\"\n [(ngModel)]=\"filterSource\"\n [showToggleAll]=\"true\"\n [showHeader]=\"true\"\n appendTo=\"body\"\n [lazy]=\"true\"\n (scroll)=\"onScroll($event)\"\n (onPanelShow)=\"onPanelShow()\"\n [loading]=\"userLoading\"\n (onFilter)=\"handleFilter($event)\"\n >\n </p-multiSelect>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [showTime]=\"true\"\n [appendTo]=\"'body'\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'Start Date'\"\n [(ngModel)]=\"startDate\"\n [showIcon]=\"true\"\n dateFormat=\"yy-M-dd\"\n >\n </p-calendar>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [appendTo]=\"'body'\"\n [showTime]=\"true\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'End Date'\"\n [(ngModel)]=\"endDate\"\n [showIcon]=\"true\"\n dateFormat=\"yy-M-dd\">\n </p-calendar>\n </div>\n <div class=\"col d-flex align-items-center\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Visits...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90 form-control bg-white\" />\n </div>\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\"\n pSortableColumn=\"browser\">\n {{ 'Admin.Tracking.Browser' | transloco }}\n <p-sortIcon field=\"browser\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"device_type\">\n {{ 'Admin.Tracking.DeviceType' | transloco }}\n <p-sortIcon field=\"device_type\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"ip\">\n {{ 'Admin.Tracking.Ip' | transloco }}\n <p-sortIcon field=\"ip\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"os\">\n {{ 'Admin.Tracking.Os' | transloco }}\n <p-sortIcon field=\"os\"></p-sortIcon>\n </th>\n <th scope=\"true\">\n {{ 'Admin.Tracking.User' | transloco }}\n </th>\n <th scope=\"true\"\n pSortableColumn=\"started_at\">\n {{ 'Admin.Tracking.StartedAt' | transloco }}\n <p-sortIcon field=\"started_at\"></p-sortIcon>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-visits>\n <tr [class.d-none]=\"loading\">\n <td data-head=\"Browser\">{{ visits.browser }}</td>\n <td data-head=\"Device Type\">{{ visits.device_type }}</td>\n <td data-head=\"IP\">{{ visits.ip }}</td>\n <td data-head=\"OS\">{{ visits.os }}</td>\n <td data-head=\"User\">\n <span *ngIf=\"visits?.user_id\">\n <span *ngIf=\"visits?.user\"><a [routerLink]=\"['/members', visits?.user?.slug]\">{{ visits?.user?.first_name }} {{ visits?.user?.last_name }}</a></span>\n <span *ngIf=\"!visits?.user\">{{ visits?.user_id }}</span>\n </span>\n </td>\n <td data-head=\"Started At\">{{ visits.started_at }}</td>\n </tr>\n </ng-template>\n </p-table>\n <div *ngIf=\" data.object_count === 0 && data.unfiltered_count !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\" [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n <span *ngIf=\"data.object_count !== 0\" class=\"total-records-count\">{{ 'Label.Total' | transloco }}: {{ data.object_count }}</span>\n </div>\n</div>\n<div *ngIf=\"!loading && data.unfiltered_count === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Ahoy.NoVistitsDataMessage' | transloco\"> </pw-no-data>\n</div>\n", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}.table-responsive td,.table-responsive th{font-size:11px!important}\n"], dependencies: [{ kind: "component", type: i2$1.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorStyleClass", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "groupRowsByOrder", "responsiveLayout", "breakpoint", "paginatorLocale", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll", "virtualRowHeight"], outputs: ["contextMenuSelectionChange", "selectAllChange", "selectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: i3$1.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "directive", type: i2$1.SortableColumn, selector: "[pSortableColumn]", inputs: ["pSortableColumn", "pSortableColumnDisabled"] }, { kind: "component", type: i2$1.SortIcon, selector: "p-sortIcon", inputs: ["field"] }, { kind: "component", type: i6.MultiSelect, selector: "p-multiSelect", inputs: ["id", "ariaLabel", "style", "styleClass", "panelStyle", "panelStyleClass", "inputId", "disabled", "readonly", "group", "filter", "filterPlaceHolder", "filterLocale", "overlayVisible", "tabindex", "variant", "appendTo", "dataKey", "name", "ariaLabelledBy", "displaySelectedLabel", "maxSelectedLabels", "selectionLimit", "selectedItemsLabel", "showToggleAll", "emptyFilterMessage", "emptyMessage", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "showHeader", "filterBy", "scrollHeight", "lazy", "virtualScroll", "loading", "virtualScrollItemSize", "loadingIcon", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "display", "autocomplete", "showClear", "autofocus", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "defaultLabel", "placeholder", "options", "filterValue", "itemSize", "selectAll", "focusOnHover", "filterFields", "selectOnFocus", "autoOptionFocus"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onClear", "onPanelShow", "onPanelHide", "onLazyLoad", "onRemove", "onSelectAllChange"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["variant"] }, { kind: "component", type: i7$2.Calendar, selector: "p-calendar", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepYearPicker", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.ProgressSpinner, selector: "p-progressSpinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "component", type: i9.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "directive", type: i10.RbacAllowDirective, selector: "[rbacAllow]", inputs: ["rbacAllow"] }, { kind: "pipe", type: i12.TranslocoPipe, name: "transloco" }] }); }
|
|
6092
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: AhoyVisitsComponent, selector: "pw-ahoy-visits", usesInheritance: true, ngImport: i0, template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0 float-start\">Ahoy Visits</h2>\n </div>\n</div>\n<div class=\"w-100 text-center mt-3\"\n *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n</div>\n<div class=\"primeng-datatable-container mt-0\" [class.hideTable]=\"data.unfiltered_count === 0\">\n <div class=\"user-management-table table-responsive\">\n <p-table #dt\n [value]=\"data.visits\"\n [paginator]=\"data.object_count !== 0\"\n [lazy]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [totalRecords]=\"data.object_count\"\n [loading]=\"loading\"\n [sortField]=\"'started_at'\"\n [sortOrder]=\"-1\"\n [filterDelay]=\"1000\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template pTemplate=\"caption\">\n <div class=\"row\">\n <div *rbacAllow=\"'SuperAdmin'\"\n class=\"col-sm-2 mb-2 mb-md-0\">\n <select (change)=\"onServiceChange($event.target.value)\"\n class=\"form-control form-select\">\n <option *ngFor=\"let item of microServices\"\n [value]=\"item.name\">\n {{ item.name }}\n </option>\n </select>\n </div>\n <div class=\"col-sm-2\">\n <p-multiSelect #multiSelector [options]=\"searchOptions\"\n (onChange)=\"onSearchOptionChange($event)\"\n placeholder=\"Filter by users\"\n [(ngModel)]=\"filterSource\"\n [showToggleAll]=\"true\"\n [showHeader]=\"true\"\n appendTo=\"body\"\n [lazy]=\"true\"\n (scroll)=\"onScroll($event)\"\n (onPanelShow)=\"onPanelShow()\"\n [loading]=\"userLoading\"\n (onFilter)=\"handleFilter($event)\"\n >\n </p-multiSelect>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [showTime]=\"true\"\n [appendTo]=\"'body'\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'Start Date'\"\n [(ngModel)]=\"startDate\"\n [showIcon]=\"true\"\n dateFormat=\"yy-M-dd\"\n >\n </p-calendar>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [appendTo]=\"'body'\"\n [showTime]=\"true\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'End Date'\"\n [(ngModel)]=\"endDate\"\n [showIcon]=\"true\"\n dateFormat=\"yy-M-dd\">\n </p-calendar>\n </div>\n <div class=\"col d-flex align-items-center\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Visits...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90 form-control bg-white\" />\n </div>\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\"\n pSortableColumn=\"browser\">\n {{ 'Admin.Tracking.Browser' | transloco }}\n <p-sortIcon field=\"browser\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"device_type\">\n {{ 'Admin.Tracking.DeviceType' | transloco }}\n <p-sortIcon field=\"device_type\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"ip\">\n {{ 'Admin.Tracking.Ip' | transloco }}\n <p-sortIcon field=\"ip\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"os\">\n {{ 'Admin.Tracking.Os' | transloco }}\n <p-sortIcon field=\"os\"></p-sortIcon>\n </th>\n <th scope=\"true\">\n {{ 'Admin.Tracking.User' | transloco }}\n </th>\n <th scope=\"true\"\n pSortableColumn=\"started_at\">\n {{ 'Admin.Tracking.StartedAt' | transloco }}\n <p-sortIcon field=\"started_at\"></p-sortIcon>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-visits>\n <tr [class.d-none]=\"loading\">\n <td data-head=\"Browser\">{{ visits.browser }}</td>\n <td data-head=\"Device Type\">{{ visits.device_type }}</td>\n <td data-head=\"IP\">{{ visits.ip }}</td>\n <td data-head=\"OS\">{{ visits.os }}</td>\n <td data-head=\"User\">\n <span *ngIf=\"visits?.user_id\">\n <span *ngIf=\"visits?.user\"><a [routerLink]=\"['/members', visits?.user?.slug]\">{{ visits?.user?.first_name }} {{ visits?.user?.last_name }}</a></span>\n <span *ngIf=\"!visits?.user\">{{ visits?.user_id }}</span>\n </span>\n </td>\n <td data-head=\"Started At\">{{ visits.started_at | dateFormat : 'datetime' }}</td>\n </tr>\n </ng-template>\n </p-table>\n <div *ngIf=\" data.object_count === 0 && data.unfiltered_count !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\" [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n <span *ngIf=\"data.object_count !== 0\" class=\"total-records-count\">{{ 'Label.Total' | transloco }}: {{ data.object_count }}</span>\n </div>\n</div>\n<div *ngIf=\"!loading && data.unfiltered_count === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Ahoy.NoVistitsDataMessage' | transloco\"> </pw-no-data>\n</div>\n", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}.table-responsive td,.table-responsive th{font-size:11px!important}\n"], dependencies: [{ kind: "component", type: i2$1.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorStyleClass", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "groupRowsByOrder", "responsiveLayout", "breakpoint", "paginatorLocale", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll", "virtualRowHeight"], outputs: ["contextMenuSelectionChange", "selectAllChange", "selectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: i3$1.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "directive", type: i2$1.SortableColumn, selector: "[pSortableColumn]", inputs: ["pSortableColumn", "pSortableColumnDisabled"] }, { kind: "component", type: i2$1.SortIcon, selector: "p-sortIcon", inputs: ["field"] }, { kind: "component", type: i6.MultiSelect, selector: "p-multiSelect", inputs: ["id", "ariaLabel", "style", "styleClass", "panelStyle", "panelStyleClass", "inputId", "disabled", "readonly", "group", "filter", "filterPlaceHolder", "filterLocale", "overlayVisible", "tabindex", "variant", "appendTo", "dataKey", "name", "ariaLabelledBy", "displaySelectedLabel", "maxSelectedLabels", "selectionLimit", "selectedItemsLabel", "showToggleAll", "emptyFilterMessage", "emptyMessage", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "showHeader", "filterBy", "scrollHeight", "lazy", "virtualScroll", "loading", "virtualScrollItemSize", "loadingIcon", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "display", "autocomplete", "showClear", "autofocus", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "defaultLabel", "placeholder", "options", "filterValue", "itemSize", "selectAll", "focusOnHover", "filterFields", "selectOnFocus", "autoOptionFocus"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onClear", "onPanelShow", "onPanelHide", "onLazyLoad", "onRemove", "onSelectAllChange"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["variant"] }, { kind: "component", type: i7$2.Calendar, selector: "p-calendar", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepYearPicker", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.ProgressSpinner, selector: "p-progressSpinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "component", type: i9.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "directive", type: i10.RbacAllowDirective, selector: "[rbacAllow]", inputs: ["rbacAllow"] }, { kind: "pipe", type: i12.TranslocoPipe, name: "transloco" }, { kind: "pipe", type: i13.DateFormatPipe, name: "dateFormat" }] }); }
|
|
6050
6093
|
}
|
|
6051
6094
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: AhoyVisitsComponent, decorators: [{
|
|
6052
6095
|
type: Component,
|
|
6053
|
-
args: [{ selector: 'pw-ahoy-visits', template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0 float-start\">Ahoy Visits</h2>\n </div>\n</div>\n<div class=\"w-100 text-center mt-3\"\n *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n</div>\n<div class=\"primeng-datatable-container mt-0\" [class.hideTable]=\"data.unfiltered_count === 0\">\n <div class=\"user-management-table table-responsive\">\n <p-table #dt\n [value]=\"data.visits\"\n [paginator]=\"data.object_count !== 0\"\n [lazy]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [totalRecords]=\"data.object_count\"\n [loading]=\"loading\"\n [sortField]=\"'started_at'\"\n [sortOrder]=\"-1\"\n [filterDelay]=\"1000\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template pTemplate=\"caption\">\n <div class=\"row\">\n <div *rbacAllow=\"'SuperAdmin'\"\n class=\"col-sm-2 mb-2 mb-md-0\">\n <select (change)=\"onServiceChange($event.target.value)\"\n class=\"form-control form-select\">\n <option *ngFor=\"let item of microServices\"\n [value]=\"item.name\">\n {{ item.name }}\n </option>\n </select>\n </div>\n <div class=\"col-sm-2\">\n <p-multiSelect #multiSelector [options]=\"searchOptions\"\n (onChange)=\"onSearchOptionChange($event)\"\n placeholder=\"Filter by users\"\n [(ngModel)]=\"filterSource\"\n [showToggleAll]=\"true\"\n [showHeader]=\"true\"\n appendTo=\"body\"\n [lazy]=\"true\"\n (scroll)=\"onScroll($event)\"\n (onPanelShow)=\"onPanelShow()\"\n [loading]=\"userLoading\"\n (onFilter)=\"handleFilter($event)\"\n >\n </p-multiSelect>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [showTime]=\"true\"\n [appendTo]=\"'body'\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'Start Date'\"\n [(ngModel)]=\"startDate\"\n [showIcon]=\"true\"\n dateFormat=\"yy-M-dd\"\n >\n </p-calendar>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [appendTo]=\"'body'\"\n [showTime]=\"true\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'End Date'\"\n [(ngModel)]=\"endDate\"\n [showIcon]=\"true\"\n dateFormat=\"yy-M-dd\">\n </p-calendar>\n </div>\n <div class=\"col d-flex align-items-center\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Visits...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90 form-control bg-white\" />\n </div>\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\"\n pSortableColumn=\"browser\">\n {{ 'Admin.Tracking.Browser' | transloco }}\n <p-sortIcon field=\"browser\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"device_type\">\n {{ 'Admin.Tracking.DeviceType' | transloco }}\n <p-sortIcon field=\"device_type\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"ip\">\n {{ 'Admin.Tracking.Ip' | transloco }}\n <p-sortIcon field=\"ip\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"os\">\n {{ 'Admin.Tracking.Os' | transloco }}\n <p-sortIcon field=\"os\"></p-sortIcon>\n </th>\n <th scope=\"true\">\n {{ 'Admin.Tracking.User' | transloco }}\n </th>\n <th scope=\"true\"\n pSortableColumn=\"started_at\">\n {{ 'Admin.Tracking.StartedAt' | transloco }}\n <p-sortIcon field=\"started_at\"></p-sortIcon>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-visits>\n <tr [class.d-none]=\"loading\">\n <td data-head=\"Browser\">{{ visits.browser }}</td>\n <td data-head=\"Device Type\">{{ visits.device_type }}</td>\n <td data-head=\"IP\">{{ visits.ip }}</td>\n <td data-head=\"OS\">{{ visits.os }}</td>\n <td data-head=\"User\">\n <span *ngIf=\"visits?.user_id\">\n <span *ngIf=\"visits?.user\"><a [routerLink]=\"['/members', visits?.user?.slug]\">{{ visits?.user?.first_name }} {{ visits?.user?.last_name }}</a></span>\n <span *ngIf=\"!visits?.user\">{{ visits?.user_id }}</span>\n </span>\n </td>\n <td data-head=\"Started At\">{{ visits.started_at }}</td>\n </tr>\n </ng-template>\n </p-table>\n <div *ngIf=\" data.object_count === 0 && data.unfiltered_count !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\" [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n <span *ngIf=\"data.object_count !== 0\" class=\"total-records-count\">{{ 'Label.Total' | transloco }}: {{ data.object_count }}</span>\n </div>\n</div>\n<div *ngIf=\"!loading && data.unfiltered_count === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Ahoy.NoVistitsDataMessage' | transloco\"> </pw-no-data>\n</div>\n", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}.table-responsive td,.table-responsive th{font-size:11px!important}\n"] }]
|
|
6096
|
+
args: [{ selector: 'pw-ahoy-visits', template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0 float-start\">Ahoy Visits</h2>\n </div>\n</div>\n<div class=\"w-100 text-center mt-3\"\n *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n</div>\n<div class=\"primeng-datatable-container mt-0\" [class.hideTable]=\"data.unfiltered_count === 0\">\n <div class=\"user-management-table table-responsive\">\n <p-table #dt\n [value]=\"data.visits\"\n [paginator]=\"data.object_count !== 0\"\n [lazy]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [totalRecords]=\"data.object_count\"\n [loading]=\"loading\"\n [sortField]=\"'started_at'\"\n [sortOrder]=\"-1\"\n [filterDelay]=\"1000\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template pTemplate=\"caption\">\n <div class=\"row\">\n <div *rbacAllow=\"'SuperAdmin'\"\n class=\"col-sm-2 mb-2 mb-md-0\">\n <select (change)=\"onServiceChange($event.target.value)\"\n class=\"form-control form-select\">\n <option *ngFor=\"let item of microServices\"\n [value]=\"item.name\">\n {{ item.name }}\n </option>\n </select>\n </div>\n <div class=\"col-sm-2\">\n <p-multiSelect #multiSelector [options]=\"searchOptions\"\n (onChange)=\"onSearchOptionChange($event)\"\n placeholder=\"Filter by users\"\n [(ngModel)]=\"filterSource\"\n [showToggleAll]=\"true\"\n [showHeader]=\"true\"\n appendTo=\"body\"\n [lazy]=\"true\"\n (scroll)=\"onScroll($event)\"\n (onPanelShow)=\"onPanelShow()\"\n [loading]=\"userLoading\"\n (onFilter)=\"handleFilter($event)\"\n >\n </p-multiSelect>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [showTime]=\"true\"\n [appendTo]=\"'body'\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'Start Date'\"\n [(ngModel)]=\"startDate\"\n [showIcon]=\"true\"\n dateFormat=\"yy-M-dd\"\n >\n </p-calendar>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [appendTo]=\"'body'\"\n [showTime]=\"true\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'End Date'\"\n [(ngModel)]=\"endDate\"\n [showIcon]=\"true\"\n dateFormat=\"yy-M-dd\">\n </p-calendar>\n </div>\n <div class=\"col d-flex align-items-center\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Visits...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90 form-control bg-white\" />\n </div>\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\"\n pSortableColumn=\"browser\">\n {{ 'Admin.Tracking.Browser' | transloco }}\n <p-sortIcon field=\"browser\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"device_type\">\n {{ 'Admin.Tracking.DeviceType' | transloco }}\n <p-sortIcon field=\"device_type\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"ip\">\n {{ 'Admin.Tracking.Ip' | transloco }}\n <p-sortIcon field=\"ip\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"os\">\n {{ 'Admin.Tracking.Os' | transloco }}\n <p-sortIcon field=\"os\"></p-sortIcon>\n </th>\n <th scope=\"true\">\n {{ 'Admin.Tracking.User' | transloco }}\n </th>\n <th scope=\"true\"\n pSortableColumn=\"started_at\">\n {{ 'Admin.Tracking.StartedAt' | transloco }}\n <p-sortIcon field=\"started_at\"></p-sortIcon>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-visits>\n <tr [class.d-none]=\"loading\">\n <td data-head=\"Browser\">{{ visits.browser }}</td>\n <td data-head=\"Device Type\">{{ visits.device_type }}</td>\n <td data-head=\"IP\">{{ visits.ip }}</td>\n <td data-head=\"OS\">{{ visits.os }}</td>\n <td data-head=\"User\">\n <span *ngIf=\"visits?.user_id\">\n <span *ngIf=\"visits?.user\"><a [routerLink]=\"['/members', visits?.user?.slug]\">{{ visits?.user?.first_name }} {{ visits?.user?.last_name }}</a></span>\n <span *ngIf=\"!visits?.user\">{{ visits?.user_id }}</span>\n </span>\n </td>\n <td data-head=\"Started At\">{{ visits.started_at | dateFormat : 'datetime' }}</td>\n </tr>\n </ng-template>\n </p-table>\n <div *ngIf=\" data.object_count === 0 && data.unfiltered_count !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\" [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n <span *ngIf=\"data.object_count !== 0\" class=\"total-records-count\">{{ 'Label.Total' | transloco }}: {{ data.object_count }}</span>\n </div>\n</div>\n<div *ngIf=\"!loading && data.unfiltered_count === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Ahoy.NoVistitsDataMessage' | transloco\"> </pw-no-data>\n</div>\n", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}.table-responsive td,.table-responsive th{font-size:11px!important}\n"] }]
|
|
6054
6097
|
}], ctorParameters: () => [{ type: i0.Injector }, { type: i1$1.AhoyService }, { type: i0.ChangeDetectorRef }, { type: i1.AdminDataService }] });
|
|
6055
6098
|
|
|
6056
6099
|
class EventsComponent extends AppBaseComponent {
|
|
@@ -6137,25 +6180,28 @@ class EventsComponent extends AppBaseComponent {
|
|
|
6137
6180
|
this.stopLoading = true;
|
|
6138
6181
|
}
|
|
6139
6182
|
else {
|
|
6140
|
-
|
|
6183
|
+
const validResults = result.filter(user => user.value && user.label);
|
|
6184
|
+
this.searchOptions = [...this.searchOptions, ...validResults];
|
|
6141
6185
|
this.userPage++;
|
|
6142
6186
|
}
|
|
6143
6187
|
});
|
|
6144
6188
|
}
|
|
6145
6189
|
getEvents(paging) {
|
|
6146
6190
|
this.isLoaded = false;
|
|
6147
|
-
|
|
6148
|
-
|
|
6149
|
-
|
|
6150
|
-
|
|
6151
|
-
|
|
6152
|
-
|
|
6153
|
-
|
|
6154
|
-
|
|
6155
|
-
|
|
6156
|
-
|
|
6157
|
-
|
|
6158
|
-
|
|
6191
|
+
const service = this.microServices.find(x => x.name === this.selectedMicroService) ||
|
|
6192
|
+
this.microServices.find(x => x.value === this.appConfig.links?.main_api);
|
|
6193
|
+
const obj = {
|
|
6194
|
+
...paging,
|
|
6195
|
+
...(this.startDate && this.endDate
|
|
6196
|
+
? {
|
|
6197
|
+
start_at: new Date(this.startDate).toISOString(),
|
|
6198
|
+
end_at: new Date(this.endDate).toISOString()
|
|
6199
|
+
}
|
|
6200
|
+
: {}),
|
|
6201
|
+
search: this.searchText || '',
|
|
6202
|
+
user_ids: this.selectedOption.length ? this.selectedOption.toString() : undefined // Only include if there are selected options
|
|
6203
|
+
};
|
|
6204
|
+
Object.keys(obj).forEach(key => obj[key] === undefined && delete obj[key]);
|
|
6159
6205
|
this.ahoyService
|
|
6160
6206
|
.getEvents(obj, service, paging)
|
|
6161
6207
|
.subscribe((response) => {
|
|
@@ -6188,16 +6234,26 @@ class EventsComponent extends AppBaseComponent {
|
|
|
6188
6234
|
}
|
|
6189
6235
|
handleFilter($event) {
|
|
6190
6236
|
this.userSearchText = $event.filter;
|
|
6191
|
-
this.userPage = 2;
|
|
6192
6237
|
this.stopLoading = false;
|
|
6238
|
+
this.userPage = 1;
|
|
6193
6239
|
this.adminDataService
|
|
6194
6240
|
.getUsers({
|
|
6195
|
-
page: this.
|
|
6241
|
+
page: this.userPage,
|
|
6196
6242
|
page_size: PAGE_SIZE,
|
|
6197
6243
|
search: this.userSearchText
|
|
6198
6244
|
}, this.subscriptionId)
|
|
6199
6245
|
.then(result => {
|
|
6200
|
-
|
|
6246
|
+
const newUsers = result.filter(user => user.value &&
|
|
6247
|
+
user.label &&
|
|
6248
|
+
!this.selectedOption.some(selected => selected.value === user.value));
|
|
6249
|
+
newUsers.forEach(user => {
|
|
6250
|
+
const index = this.searchOptions.findIndex(existing => existing.value === user.value);
|
|
6251
|
+
if (index !== -1) {
|
|
6252
|
+
console.log('Removing user');
|
|
6253
|
+
this.searchOptions.splice(index, 1);
|
|
6254
|
+
}
|
|
6255
|
+
});
|
|
6256
|
+
this.searchOptions = [...this.searchOptions, ...newUsers];
|
|
6201
6257
|
});
|
|
6202
6258
|
}
|
|
6203
6259
|
ngOnDestroy() {
|
|
@@ -6208,11 +6264,11 @@ class EventsComponent extends AppBaseComponent {
|
|
|
6208
6264
|
}
|
|
6209
6265
|
}
|
|
6210
6266
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: EventsComponent, deps: [{ token: i0.Injector }, { token: i1$1.AhoyService }, { token: i0.ChangeDetectorRef }, { token: i1.AdminDataService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
6211
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: EventsComponent, selector: "pw-events", usesInheritance: true, ngImport: i0, template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0 float-start\">Events</h2>\n </div>\n</div>\n<div class=\"w-100 text-center mt-3\"\n *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n</div>\n<div class=\"primeng-datatable-container mt-0\" [class.hideTable]=\"data.unfiltered_count === 0\">\n <div class=\"user-management-table table-responsive\">\n <p-table #dt\n [value]=\"data.events\"\n [paginator]=\"data.object_count !== 0\"\n [lazy]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [totalRecords]=\"data.object_count\"\n [loading]=\"loading\"\n [filterDelay]=\"1000\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template pTemplate=\"caption\">\n <div class=\"row\">\n <div *rbacAllow=\"'SuperAdmin'\"\n class=\"col-sm-2 mb-2 mb-md-0\">\n <select (change)=\"onServiceChange($event.target.value)\"\n class=\"form-control form-select\">\n <option *ngFor=\"let item of microServices\"\n [value]=\"item.name\">\n {{ item.name }}\n </option>\n </select>\n </div>\n <div class=\"col-sm-2\">\n <p-multiSelect #multiSelector [options]=\"searchOptions\"\n (onChange)=\"onSearchOptionChange($event)\"\n placeholder=\"Filter by users\"\n [(ngModel)]=\"filterSource\"\n [showToggleAll]=\"true\"\n [showHeader]=\"true\"\n appendTo=\"body\"\n [lazy]=\"true\"\n (scroll)=\"onScroll($event)\"\n (onPanelShow)=\"onPanelShow()\"\n [loading]=\"userLoading\"\n (onFilter)=\"handleFilter($event)\"\n >\n </p-multiSelect>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [showTime]=\"true\"\n [appendTo]=\"'body'\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'Start Date'\"\n [(ngModel)]=\"startDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [appendTo]=\"'body'\"\n [showTime]=\"true\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'End Date'\"\n [(ngModel)]=\"endDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col d-flex align-items-center\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Events...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90 form-control bg-white\" />\n </div>\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\"\n pSortableColumn=\"created_at\">\n {{ 'Admin.Tracking.CreatedAt' | transloco }}\n <p-sortIcon field=\"created_at\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"event_type\">\n {{ 'Admin.Tracking.EventType' | transloco }}\n <p-sortIcon field=\"event_type\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"related_entity_type\">\n {{ 'Admin.Tracking.EntityType' | transloco }}\n <p-sortIcon field=\"related_entity_type\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"updated_at\">\n {{ 'Admin.Tracking.UpdatedAt' | transloco }}\n <p-sortIcon field=\"updated_at\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"user_id\">\n {{ 'Admin.Tracking.User' | transloco }}\n <p-sortIcon field=\"user_id\"></p-sortIcon>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-events>\n <tr [class.d-none]=\"loading\">\n <td data-head=\"Created At\">{{ events.created_at }}</td>\n <td data-head=\"Event Type\">{{ events.event_type }}</td>\n <td data-head=\"Entity Type\">{{ events.related_entity_type }}</td>\n <td data-head=\"Updated At\">{{ events.updated_at }}</td>\n <td data-head=\"User\">\n <span *ngIf=\"events?.user_id\">\n <span *ngIf=\"events?.user\"><a [routerLink]=\"['/members', events?.user?.slug]\">{{ events?.user?.first_name }} {{ events?.user?.last_name }}</a></span>\n <span *ngIf=\"!events?.user\">{{ events?.user_id }}</span>\n </span>\n </td>\n </tr>\n </ng-template>\n </p-table>\n <div *ngIf=\" data.object_count === 0 && data.unfiltered_count !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\" [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n <span *ngIf=\"data.object_count !== 0\" class=\"total-records-count\">{{ 'Label.Total' | transloco }}: {{ data.object_count }}</span>\n </div>\n</div>\n<div *ngIf=\"!loading && data.unfiltered_count === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Ahoy.NoEventDataMessage' | transloco\"> </pw-no-data>\n</div>", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}@media (min-width: 767px){.table-responsive td,.table-responsive th{font-size:11px!important}}\n"], dependencies: [{ kind: "component", type: i2$1.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorStyleClass", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "groupRowsByOrder", "responsiveLayout", "breakpoint", "paginatorLocale", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll", "virtualRowHeight"], outputs: ["contextMenuSelectionChange", "selectAllChange", "selectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: i3$1.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "directive", type: i2$1.SortableColumn, selector: "[pSortableColumn]", inputs: ["pSortableColumn", "pSortableColumnDisabled"] }, { kind: "component", type: i2$1.SortIcon, selector: "p-sortIcon", inputs: ["field"] }, { kind: "component", type: i6.MultiSelect, selector: "p-multiSelect", inputs: ["id", "ariaLabel", "style", "styleClass", "panelStyle", "panelStyleClass", "inputId", "disabled", "readonly", "group", "filter", "filterPlaceHolder", "filterLocale", "overlayVisible", "tabindex", "variant", "appendTo", "dataKey", "name", "ariaLabelledBy", "displaySelectedLabel", "maxSelectedLabels", "selectionLimit", "selectedItemsLabel", "showToggleAll", "emptyFilterMessage", "emptyMessage", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "showHeader", "filterBy", "scrollHeight", "lazy", "virtualScroll", "loading", "virtualScrollItemSize", "loadingIcon", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "display", "autocomplete", "showClear", "autofocus", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "defaultLabel", "placeholder", "options", "filterValue", "itemSize", "selectAll", "focusOnHover", "filterFields", "selectOnFocus", "autoOptionFocus"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onClear", "onPanelShow", "onPanelHide", "onLazyLoad", "onRemove", "onSelectAllChange"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["variant"] }, { kind: "component", type: i7$2.Calendar, selector: "p-calendar", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepYearPicker", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.ProgressSpinner, selector: "p-progressSpinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "component", type: i9.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "directive", type: i10.RbacAllowDirective, selector: "[rbacAllow]", inputs: ["rbacAllow"] }, { kind: "pipe", type: i12.TranslocoPipe, name: "transloco" }] }); }
|
|
6267
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: EventsComponent, selector: "pw-events", usesInheritance: true, ngImport: i0, template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0 float-start\">Events</h2>\n </div>\n</div>\n<div class=\"w-100 text-center mt-3\"\n *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n</div>\n<div class=\"primeng-datatable-container mt-0\" [class.hideTable]=\"data.unfiltered_count === 0\">\n <div class=\"user-management-table table-responsive\">\n <p-table #dt\n [value]=\"data.events\"\n [paginator]=\"data.object_count !== 0\"\n [lazy]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [totalRecords]=\"data.object_count\"\n [loading]=\"loading\"\n [filterDelay]=\"1000\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template pTemplate=\"caption\">\n <div class=\"row\">\n <div *rbacAllow=\"'SuperAdmin'\"\n class=\"col-sm-2 mb-2 mb-md-0\">\n <select (change)=\"onServiceChange($event.target.value)\"\n class=\"form-control form-select\">\n <option *ngFor=\"let item of microServices\"\n [value]=\"item.name\">\n {{ item.name }}\n </option>\n </select>\n </div>\n <div class=\"col-sm-2\">\n <p-multiSelect #multiSelector [options]=\"searchOptions\"\n (onChange)=\"onSearchOptionChange($event)\"\n placeholder=\"Filter by users\"\n [(ngModel)]=\"filterSource\"\n [showToggleAll]=\"true\"\n [showHeader]=\"true\"\n appendTo=\"body\"\n [lazy]=\"true\"\n (scroll)=\"onScroll($event)\"\n (onPanelShow)=\"onPanelShow()\"\n [loading]=\"userLoading\"\n (onFilter)=\"handleFilter($event)\"\n >\n </p-multiSelect>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [showTime]=\"true\"\n [appendTo]=\"'body'\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'Start Date'\"\n [(ngModel)]=\"startDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [appendTo]=\"'body'\"\n [showTime]=\"true\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'End Date'\"\n [(ngModel)]=\"endDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col d-flex align-items-center\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Events...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90 form-control bg-white\" />\n </div>\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\"\n pSortableColumn=\"created_at\">\n {{ 'Admin.Tracking.CreatedAt' | transloco }}\n <p-sortIcon field=\"created_at\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"event_type\">\n {{ 'Admin.Tracking.EventType' | transloco }}\n <p-sortIcon field=\"event_type\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"related_entity_type\">\n {{ 'Admin.Tracking.EntityType' | transloco }}\n <p-sortIcon field=\"related_entity_type\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"updated_at\">\n {{ 'Admin.Tracking.UpdatedAt' | transloco }}\n <p-sortIcon field=\"updated_at\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"user_id\">\n {{ 'Admin.Tracking.User' | transloco }}\n <p-sortIcon field=\"user_id\"></p-sortIcon>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-events>\n <tr [class.d-none]=\"loading\">\n <td data-head=\"Created At\">{{ events.created_at | dateFormat: 'datetime' }}</td>\n <td data-head=\"Event Type\">{{ events.event_type }}</td>\n <td data-head=\"Entity Type\">{{ events.related_entity_type }}</td>\n <td data-head=\"Updated At\">{{ events.updated_at | dateFormat : 'datetime'}}</td>\n <td data-head=\"User\">\n <span *ngIf=\"events?.user_id\">\n <span *ngIf=\"events?.user\"><a [routerLink]=\"['/members', events?.user?.slug]\">{{ events?.user?.first_name }} {{ events?.user?.last_name }}</a></span>\n <span *ngIf=\"!events?.user\">{{ events?.user_id }}</span>\n </span>\n </td>\n </tr>\n </ng-template>\n </p-table>\n <div *ngIf=\" data.object_count === 0 && data.unfiltered_count !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\" [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n <span *ngIf=\"data.object_count !== 0\" class=\"total-records-count\">{{ 'Label.Total' | transloco }}: {{ data.object_count }}</span>\n </div>\n</div>\n<div *ngIf=\"!loading && data.unfiltered_count === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Ahoy.NoEventDataMessage' | transloco\"> </pw-no-data>\n</div>", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}@media (min-width: 767px){.table-responsive td,.table-responsive th{font-size:11px!important}}\n"], dependencies: [{ kind: "component", type: i2$1.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorStyleClass", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "groupRowsByOrder", "responsiveLayout", "breakpoint", "paginatorLocale", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll", "virtualRowHeight"], outputs: ["contextMenuSelectionChange", "selectAllChange", "selectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: i3$1.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "directive", type: i2$1.SortableColumn, selector: "[pSortableColumn]", inputs: ["pSortableColumn", "pSortableColumnDisabled"] }, { kind: "component", type: i2$1.SortIcon, selector: "p-sortIcon", inputs: ["field"] }, { kind: "component", type: i6.MultiSelect, selector: "p-multiSelect", inputs: ["id", "ariaLabel", "style", "styleClass", "panelStyle", "panelStyleClass", "inputId", "disabled", "readonly", "group", "filter", "filterPlaceHolder", "filterLocale", "overlayVisible", "tabindex", "variant", "appendTo", "dataKey", "name", "ariaLabelledBy", "displaySelectedLabel", "maxSelectedLabels", "selectionLimit", "selectedItemsLabel", "showToggleAll", "emptyFilterMessage", "emptyMessage", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "showHeader", "filterBy", "scrollHeight", "lazy", "virtualScroll", "loading", "virtualScrollItemSize", "loadingIcon", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "display", "autocomplete", "showClear", "autofocus", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "defaultLabel", "placeholder", "options", "filterValue", "itemSize", "selectAll", "focusOnHover", "filterFields", "selectOnFocus", "autoOptionFocus"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onClear", "onPanelShow", "onPanelHide", "onLazyLoad", "onRemove", "onSelectAllChange"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["variant"] }, { kind: "component", type: i7$2.Calendar, selector: "p-calendar", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepYearPicker", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.ProgressSpinner, selector: "p-progressSpinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "component", type: i9.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "directive", type: i10.RbacAllowDirective, selector: "[rbacAllow]", inputs: ["rbacAllow"] }, { kind: "pipe", type: i12.TranslocoPipe, name: "transloco" }, { kind: "pipe", type: i13.DateFormatPipe, name: "dateFormat" }] }); }
|
|
6212
6268
|
}
|
|
6213
6269
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: EventsComponent, decorators: [{
|
|
6214
6270
|
type: Component,
|
|
6215
|
-
args: [{ selector: 'pw-events', template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0 float-start\">Events</h2>\n </div>\n</div>\n<div class=\"w-100 text-center mt-3\"\n *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n</div>\n<div class=\"primeng-datatable-container mt-0\" [class.hideTable]=\"data.unfiltered_count === 0\">\n <div class=\"user-management-table table-responsive\">\n <p-table #dt\n [value]=\"data.events\"\n [paginator]=\"data.object_count !== 0\"\n [lazy]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [totalRecords]=\"data.object_count\"\n [loading]=\"loading\"\n [filterDelay]=\"1000\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template pTemplate=\"caption\">\n <div class=\"row\">\n <div *rbacAllow=\"'SuperAdmin'\"\n class=\"col-sm-2 mb-2 mb-md-0\">\n <select (change)=\"onServiceChange($event.target.value)\"\n class=\"form-control form-select\">\n <option *ngFor=\"let item of microServices\"\n [value]=\"item.name\">\n {{ item.name }}\n </option>\n </select>\n </div>\n <div class=\"col-sm-2\">\n <p-multiSelect #multiSelector [options]=\"searchOptions\"\n (onChange)=\"onSearchOptionChange($event)\"\n placeholder=\"Filter by users\"\n [(ngModel)]=\"filterSource\"\n [showToggleAll]=\"true\"\n [showHeader]=\"true\"\n appendTo=\"body\"\n [lazy]=\"true\"\n (scroll)=\"onScroll($event)\"\n (onPanelShow)=\"onPanelShow()\"\n [loading]=\"userLoading\"\n (onFilter)=\"handleFilter($event)\"\n >\n </p-multiSelect>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [showTime]=\"true\"\n [appendTo]=\"'body'\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'Start Date'\"\n [(ngModel)]=\"startDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [appendTo]=\"'body'\"\n [showTime]=\"true\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'End Date'\"\n [(ngModel)]=\"endDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col d-flex align-items-center\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Events...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90 form-control bg-white\" />\n </div>\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\"\n pSortableColumn=\"created_at\">\n {{ 'Admin.Tracking.CreatedAt' | transloco }}\n <p-sortIcon field=\"created_at\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"event_type\">\n {{ 'Admin.Tracking.EventType' | transloco }}\n <p-sortIcon field=\"event_type\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"related_entity_type\">\n {{ 'Admin.Tracking.EntityType' | transloco }}\n <p-sortIcon field=\"related_entity_type\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"updated_at\">\n {{ 'Admin.Tracking.UpdatedAt' | transloco }}\n <p-sortIcon field=\"updated_at\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"user_id\">\n {{ 'Admin.Tracking.User' | transloco }}\n <p-sortIcon field=\"user_id\"></p-sortIcon>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-events>\n <tr [class.d-none]=\"loading\">\n <td data-head=\"Created At\">{{ events.created_at }}</td>\n <td data-head=\"Event Type\">{{ events.event_type }}</td>\n <td data-head=\"Entity Type\">{{ events.related_entity_type }}</td>\n <td data-head=\"Updated At\">{{ events.updated_at }}</td>\n <td data-head=\"User\">\n <span *ngIf=\"events?.user_id\">\n <span *ngIf=\"events?.user\"><a [routerLink]=\"['/members', events?.user?.slug]\">{{ events?.user?.first_name }} {{ events?.user?.last_name }}</a></span>\n <span *ngIf=\"!events?.user\">{{ events?.user_id }}</span>\n </span>\n </td>\n </tr>\n </ng-template>\n </p-table>\n <div *ngIf=\" data.object_count === 0 && data.unfiltered_count !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\" [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n <span *ngIf=\"data.object_count !== 0\" class=\"total-records-count\">{{ 'Label.Total' | transloco }}: {{ data.object_count }}</span>\n </div>\n</div>\n<div *ngIf=\"!loading && data.unfiltered_count === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Ahoy.NoEventDataMessage' | transloco\"> </pw-no-data>\n</div>", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}@media (min-width: 767px){.table-responsive td,.table-responsive th{font-size:11px!important}}\n"] }]
|
|
6271
|
+
args: [{ selector: 'pw-events', template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0 float-start\">Events</h2>\n </div>\n</div>\n<div class=\"w-100 text-center mt-3\"\n *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n</div>\n<div class=\"primeng-datatable-container mt-0\" [class.hideTable]=\"data.unfiltered_count === 0\">\n <div class=\"user-management-table table-responsive\">\n <p-table #dt\n [value]=\"data.events\"\n [paginator]=\"data.object_count !== 0\"\n [lazy]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [totalRecords]=\"data.object_count\"\n [loading]=\"loading\"\n [filterDelay]=\"1000\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template pTemplate=\"caption\">\n <div class=\"row\">\n <div *rbacAllow=\"'SuperAdmin'\"\n class=\"col-sm-2 mb-2 mb-md-0\">\n <select (change)=\"onServiceChange($event.target.value)\"\n class=\"form-control form-select\">\n <option *ngFor=\"let item of microServices\"\n [value]=\"item.name\">\n {{ item.name }}\n </option>\n </select>\n </div>\n <div class=\"col-sm-2\">\n <p-multiSelect #multiSelector [options]=\"searchOptions\"\n (onChange)=\"onSearchOptionChange($event)\"\n placeholder=\"Filter by users\"\n [(ngModel)]=\"filterSource\"\n [showToggleAll]=\"true\"\n [showHeader]=\"true\"\n appendTo=\"body\"\n [lazy]=\"true\"\n (scroll)=\"onScroll($event)\"\n (onPanelShow)=\"onPanelShow()\"\n [loading]=\"userLoading\"\n (onFilter)=\"handleFilter($event)\"\n >\n </p-multiSelect>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [showTime]=\"true\"\n [appendTo]=\"'body'\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'Start Date'\"\n [(ngModel)]=\"startDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [appendTo]=\"'body'\"\n [showTime]=\"true\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'End Date'\"\n [(ngModel)]=\"endDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col d-flex align-items-center\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Events...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90 form-control bg-white\" />\n </div>\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\"\n pSortableColumn=\"created_at\">\n {{ 'Admin.Tracking.CreatedAt' | transloco }}\n <p-sortIcon field=\"created_at\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"event_type\">\n {{ 'Admin.Tracking.EventType' | transloco }}\n <p-sortIcon field=\"event_type\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"related_entity_type\">\n {{ 'Admin.Tracking.EntityType' | transloco }}\n <p-sortIcon field=\"related_entity_type\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"updated_at\">\n {{ 'Admin.Tracking.UpdatedAt' | transloco }}\n <p-sortIcon field=\"updated_at\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"user_id\">\n {{ 'Admin.Tracking.User' | transloco }}\n <p-sortIcon field=\"user_id\"></p-sortIcon>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-events>\n <tr [class.d-none]=\"loading\">\n <td data-head=\"Created At\">{{ events.created_at | dateFormat: 'datetime' }}</td>\n <td data-head=\"Event Type\">{{ events.event_type }}</td>\n <td data-head=\"Entity Type\">{{ events.related_entity_type }}</td>\n <td data-head=\"Updated At\">{{ events.updated_at | dateFormat : 'datetime'}}</td>\n <td data-head=\"User\">\n <span *ngIf=\"events?.user_id\">\n <span *ngIf=\"events?.user\"><a [routerLink]=\"['/members', events?.user?.slug]\">{{ events?.user?.first_name }} {{ events?.user?.last_name }}</a></span>\n <span *ngIf=\"!events?.user\">{{ events?.user_id }}</span>\n </span>\n </td>\n </tr>\n </ng-template>\n </p-table>\n <div *ngIf=\" data.object_count === 0 && data.unfiltered_count !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\" [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n <span *ngIf=\"data.object_count !== 0\" class=\"total-records-count\">{{ 'Label.Total' | transloco }}: {{ data.object_count }}</span>\n </div>\n</div>\n<div *ngIf=\"!loading && data.unfiltered_count === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Ahoy.NoEventDataMessage' | transloco\"> </pw-no-data>\n</div>", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}@media (min-width: 767px){.table-responsive td,.table-responsive th{font-size:11px!important}}\n"] }]
|
|
6216
6272
|
}], ctorParameters: () => [{ type: i0.Injector }, { type: i1$1.AhoyService }, { type: i0.ChangeDetectorRef }, { type: i1.AdminDataService }] });
|
|
6217
6273
|
|
|
6218
6274
|
class TrackingComponent {
|
|
@@ -6312,18 +6368,20 @@ class VersionsComponent extends AppBaseComponent {
|
|
|
6312
6368
|
}
|
|
6313
6369
|
getVersions(paging) {
|
|
6314
6370
|
this.isLoaded = false;
|
|
6315
|
-
|
|
6316
|
-
|
|
6317
|
-
|
|
6318
|
-
|
|
6319
|
-
|
|
6320
|
-
|
|
6321
|
-
|
|
6322
|
-
|
|
6323
|
-
|
|
6324
|
-
|
|
6325
|
-
|
|
6326
|
-
|
|
6371
|
+
const service = this.microServices.find(x => x.name === this.selectedMicroService) ||
|
|
6372
|
+
this.microServices.find(x => x.value === this.appConfig.links?.main_api);
|
|
6373
|
+
const obj = {
|
|
6374
|
+
...paging,
|
|
6375
|
+
...(this.startDate && this.endDate
|
|
6376
|
+
? {
|
|
6377
|
+
start_at: new Date(this.startDate).toISOString(),
|
|
6378
|
+
end_at: new Date(this.endDate).toISOString()
|
|
6379
|
+
}
|
|
6380
|
+
: {}),
|
|
6381
|
+
search: this.searchText || '',
|
|
6382
|
+
user_ids: this.selectedOption.length ? this.selectedOption.toString() : undefined
|
|
6383
|
+
};
|
|
6384
|
+
Object.keys(obj).forEach(key => obj[key] === undefined && delete obj[key]);
|
|
6327
6385
|
this.ahoyService
|
|
6328
6386
|
.getVersions(obj, service, paging)
|
|
6329
6387
|
.subscribe((response) => {
|
|
@@ -6374,7 +6432,8 @@ class VersionsComponent extends AppBaseComponent {
|
|
|
6374
6432
|
this.stopLoading = true;
|
|
6375
6433
|
}
|
|
6376
6434
|
else {
|
|
6377
|
-
|
|
6435
|
+
const validResults = result.filter(user => user.value && user.label);
|
|
6436
|
+
this.searchOptions = [...this.searchOptions, ...validResults];
|
|
6378
6437
|
this.userPage++;
|
|
6379
6438
|
}
|
|
6380
6439
|
});
|
|
@@ -6404,16 +6463,26 @@ class VersionsComponent extends AppBaseComponent {
|
|
|
6404
6463
|
}
|
|
6405
6464
|
handleFilter($event) {
|
|
6406
6465
|
this.userSearchText = $event.filter;
|
|
6407
|
-
this.userPage = 2;
|
|
6408
6466
|
this.stopLoading = false;
|
|
6467
|
+
this.userPage = 1;
|
|
6409
6468
|
this.adminDataService
|
|
6410
6469
|
.getUsers({
|
|
6411
|
-
page: this.
|
|
6470
|
+
page: this.userPage,
|
|
6412
6471
|
page_size: PAGE_SIZE,
|
|
6413
6472
|
search: this.userSearchText
|
|
6414
6473
|
}, this.subscriptionId)
|
|
6415
6474
|
.then(result => {
|
|
6416
|
-
|
|
6475
|
+
const newUsers = result.filter(user => user.value &&
|
|
6476
|
+
user.label &&
|
|
6477
|
+
!this.selectedOption.some(selected => selected.value === user.value));
|
|
6478
|
+
newUsers.forEach(user => {
|
|
6479
|
+
const index = this.searchOptions.findIndex(existing => existing.value === user.value);
|
|
6480
|
+
if (index !== -1) {
|
|
6481
|
+
console.log('Removing user');
|
|
6482
|
+
this.searchOptions.splice(index, 1);
|
|
6483
|
+
}
|
|
6484
|
+
});
|
|
6485
|
+
this.searchOptions = [...this.searchOptions, ...newUsers];
|
|
6417
6486
|
});
|
|
6418
6487
|
}
|
|
6419
6488
|
ngOnDestroy() {
|
|
@@ -6424,11 +6493,11 @@ class VersionsComponent extends AppBaseComponent {
|
|
|
6424
6493
|
}
|
|
6425
6494
|
}
|
|
6426
6495
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: VersionsComponent, deps: [{ token: i0.Injector }, { token: i1$1.AhoyService }, { token: i11.NgbModal }, { token: i0.ChangeDetectorRef }, { token: i1.AdminDataService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
6427
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: VersionsComponent, selector: "pw-versions", usesInheritance: true, ngImport: i0, template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0 float-start\">Versions</h2>\n </div>\n</div>\n<div class=\"w-100 text-center mt-3\"\n *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n</div>\n<div class=\"primeng-datatable-container mt-0\" [class.hideTable]=\"data.unfiltered_count === 0\">\n <div class=\"user-management-table table-responsive\">\n <p-table #dt\n [value]=\"data.versions\"\n [paginator]=\"data.object_count !== 0\"\n [lazy]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [totalRecords]=\"data.object_count\"\n [loading]=\"loading\"\n [filterDelay]=\"1000\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template pTemplate=\"caption\">\n <div class=\"row\">\n <div *rbacAllow=\"'SuperAdmin'\"\n class=\"col-sm-2 mb-2 mb-md-0\">\n <select (change)=\"onServiceChange($event.target.value)\"\n class=\"form-control form-select\">\n <option *ngFor=\"let item of microServices\"\n [value]=\"item.name\">\n {{ item.name }}\n </option>\n </select>\n </div>\n <div class=\"col-sm-2\">\n <p-multiSelect #multiSelector [options]=\"searchOptions\"\n (onChange)=\"onSearchOptionChange($event)\"\n placeholder=\"Filter by users\"\n [(ngModel)]=\"filterSource\"\n [showToggleAll]=\"true\"\n [showHeader]=\"true\"\n appendTo=\"body\"\n [lazy]=\"true\"\n (scroll)=\"onScroll($event)\"\n (onPanelShow)=\"onPanelShow()\"\n [loading]=\"userLoading\"\n (onFilter)=\"handleFilter($event)\"\n >\n </p-multiSelect>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [showTime]=\"true\"\n [appendTo]=\"'body'\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'Start Date'\"\n [(ngModel)]=\"startDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col-sm-2 \">\n <p-calendar [appendTo]=\"'body'\"\n [showTime]=\"true\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'End Date'\"\n [(ngModel)]=\"endDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col d-flex align-items-center\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Versions...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90 form-control bg-white\" />\n </div>\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\"\n pSortableColumn=\"author\">\n {{ 'Admin.Tracking.User' | transloco }}\n <p-sortIcon field=\"author\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"created_at\">\n {{ 'Admin.Tracking.CreatedAt' | transloco }}\n <p-sortIcon field=\"created_at\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"event\">\n {{ 'Admin.Tracking.Event' | transloco }}\n <p-sortIcon field=\"event\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"item_type\">\n {{ 'Admin.Tracking.ItemType' | transloco }}\n <p-sortIcon field=\"item_type\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"item_id\">\n {{ 'Admin.Tracking.ItemId' | transloco }}\n <p-sortIcon field=\"item_id\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"object\">\n {{ 'Admin.Tracking.Object' | transloco }}\n <p-sortIcon field=\"object\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"updated_at\">\n {{ 'Admin.Tracking.UpdatedAt' | transloco }}\n <p-sortIcon field=\"updated_at\"></p-sortIcon>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-version>\n <tr [class.d-none]=\"loading\">\n <td data-head=\"User\">\n <span *ngIf=\"version?.author\"><a [routerLink]=\"['/members', version?.author?.slug]\">{{ version?.author?.first_name }}\n {{ version?.author?.last_name }}</a></span>\n <span *ngIf=\"!version?.author && version?.whoDoneIt\">{{\n version?.whoDoneIt\n }}</span>\n </td>\n <td data-head=\"Created At\">{{ version.created_at }}</td>\n <td data-head=\"Event\">\n <span class=\"badge\"\n color=\"warning\"\n [appDynamicBadge]=\"{\n itemsArray: events,\n item: version?.event\n }\">{{version?.event}}</span>\n </td>\n <td data-head=\"Item Type\">{{ version.item_type }}</td>\n <td data-head=\"Item Id\">{{ version.item_id }}</td>\n <td data-head=\"Object\">\n <span (click)=\"openObjectModal(objModal, version?.object)\"\n class=\"badge bg-info cursor-pointer\">Open Object</span>\n </td>\n <td data-head=\"Updated At\">{{ version.updated_at }}</td>\n </tr>\n </ng-template>\n </p-table>\n <div *ngIf=\" data.object_count === 0 && data.unfiltered_count !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\" [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n <span *ngIf=\"data.object_count !== 0\" class=\"total-records-count\">{{ 'Label.Total' | transloco }}: {{ data.object_count }}</span>\n </div>\n</div>\n<div *ngIf=\"!loading && data.unfiltered_count === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Ahoy.NoVersionsDataMessage' | transloco\"> </pw-no-data>\n</div>\n<!-- Object Modal -->\n<ng-template #objModal\n let-modal>\n <div class=\"modal-header\">\n <h4 class=\"modal-title\">{{ 'Admin.Tracking.Object' | transloco }}</h4>\n <button type=\"button\"\n class=\"btn-close float-end\"\n aria-label=\"Close\"\n (click)=\"modal.dismiss()\">\n\n </button>\n </div>\n <div class=\"modal-body\">\n <div *ngIf=\"activeObject\">\n <ngx-json-viewer [json]=\"activeObject\"\n [expanded]=\"false\"></ngx-json-viewer>\n </div>\n </div>\n</ng-template>\n", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}@media (min-width: 767px){.table-responsive td,.table-responsive th{font-size:11px!important}}\n"], dependencies: [{ kind: "component", type: i2$1.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorStyleClass", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "groupRowsByOrder", "responsiveLayout", "breakpoint", "paginatorLocale", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll", "virtualRowHeight"], outputs: ["contextMenuSelectionChange", "selectAllChange", "selectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: i3$1.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "directive", type: i2$1.SortableColumn, selector: "[pSortableColumn]", inputs: ["pSortableColumn", "pSortableColumnDisabled"] }, { kind: "component", type: i2$1.SortIcon, selector: "p-sortIcon", inputs: ["field"] }, { kind: "component", type: i6.MultiSelect, selector: "p-multiSelect", inputs: ["id", "ariaLabel", "style", "styleClass", "panelStyle", "panelStyleClass", "inputId", "disabled", "readonly", "group", "filter", "filterPlaceHolder", "filterLocale", "overlayVisible", "tabindex", "variant", "appendTo", "dataKey", "name", "ariaLabelledBy", "displaySelectedLabel", "maxSelectedLabels", "selectionLimit", "selectedItemsLabel", "showToggleAll", "emptyFilterMessage", "emptyMessage", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "showHeader", "filterBy", "scrollHeight", "lazy", "virtualScroll", "loading", "virtualScrollItemSize", "loadingIcon", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "display", "autocomplete", "showClear", "autofocus", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "defaultLabel", "placeholder", "options", "filterValue", "itemSize", "selectAll", "focusOnHover", "filterFields", "selectOnFocus", "autoOptionFocus"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onClear", "onPanelShow", "onPanelHide", "onLazyLoad", "onRemove", "onSelectAllChange"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["variant"] }, { kind: "component", type: i8$1.NgxJsonViewerComponent, selector: "ngx-json-viewer", inputs: ["json", "expanded", "depth", "_currentDepth"] }, { kind: "component", type: i7$2.Calendar, selector: "p-calendar", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepYearPicker", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.ProgressSpinner, selector: "p-progressSpinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "component", type: i9.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "directive", type: i10.DynamicBadgeDirective, selector: "[appDynamicBadge]", inputs: ["appDynamicBadge", "color"] }, { kind: "directive", type: i10.RbacAllowDirective, selector: "[rbacAllow]", inputs: ["rbacAllow"] }, { kind: "pipe", type: i12.TranslocoPipe, name: "transloco" }] }); }
|
|
6496
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: VersionsComponent, selector: "pw-versions", usesInheritance: true, ngImport: i0, template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0 float-start\">Versions</h2>\n </div>\n</div>\n<div class=\"w-100 text-center mt-3\"\n *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n</div>\n<div class=\"primeng-datatable-container mt-0\" [class.hideTable]=\"data.unfiltered_count === 0\">\n <div class=\"user-management-table table-responsive\">\n <p-table #dt\n [value]=\"data.versions\"\n [paginator]=\"data.object_count !== 0\"\n [lazy]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [totalRecords]=\"data.object_count\"\n [loading]=\"loading\"\n [filterDelay]=\"1000\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template pTemplate=\"caption\">\n <div class=\"row\">\n <div *rbacAllow=\"'SuperAdmin'\"\n class=\"col-sm-2 mb-2 mb-md-0\">\n <select (change)=\"onServiceChange($event.target.value)\"\n class=\"form-control form-select\">\n <option *ngFor=\"let item of microServices\"\n [value]=\"item.name\">\n {{ item.name }}\n </option>\n </select>\n </div>\n <div class=\"col-sm-2\">\n <p-multiSelect #multiSelector [options]=\"searchOptions\"\n (onChange)=\"onSearchOptionChange($event)\"\n placeholder=\"Filter by users\"\n [(ngModel)]=\"filterSource\"\n [showToggleAll]=\"true\"\n [showHeader]=\"true\"\n appendTo=\"body\"\n [lazy]=\"true\"\n (scroll)=\"onScroll($event)\"\n (onPanelShow)=\"onPanelShow()\"\n [loading]=\"userLoading\"\n (onFilter)=\"handleFilter($event)\"\n >\n </p-multiSelect>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [showTime]=\"true\"\n [appendTo]=\"'body'\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'Start Date'\"\n [(ngModel)]=\"startDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col-sm-2 \">\n <p-calendar [appendTo]=\"'body'\"\n [showTime]=\"true\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'End Date'\"\n [(ngModel)]=\"endDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col d-flex align-items-center\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Versions...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90 form-control bg-white\" />\n </div>\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\"\n pSortableColumn=\"author\">\n {{ 'Admin.Tracking.User' | transloco }}\n <p-sortIcon field=\"author\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"created_at\">\n {{ 'Admin.Tracking.CreatedAt' | transloco }}\n <p-sortIcon field=\"created_at\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"event\">\n {{ 'Admin.Tracking.Event' | transloco }}\n <p-sortIcon field=\"event\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"item_type\">\n {{ 'Admin.Tracking.ItemType' | transloco }}\n <p-sortIcon field=\"item_type\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"item_id\">\n {{ 'Admin.Tracking.ItemId' | transloco }}\n <p-sortIcon field=\"item_id\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"object\">\n {{ 'Admin.Tracking.Object' | transloco }}\n <p-sortIcon field=\"object\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"updated_at\">\n {{ 'Admin.Tracking.UpdatedAt' | transloco }}\n <p-sortIcon field=\"updated_at\"></p-sortIcon>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-version>\n <tr [class.d-none]=\"loading\">\n <td data-head=\"User\">\n <span *ngIf=\"version?.author\"><a [routerLink]=\"['/members', version?.author?.slug]\">{{ version?.author?.first_name }}\n {{ version?.author?.last_name }}</a></span>\n <span *ngIf=\"!version?.author && version?.whoDoneIt\">{{\n version?.whoDoneIt\n }}</span>\n </td>\n <td data-head=\"Created At\">{{ version.created_at | dateFormat: 'datetime' }}</td>\n <td data-head=\"Event\">\n <span class=\"badge\"\n color=\"warning\"\n [appDynamicBadge]=\"{\n itemsArray: events,\n item: version?.event\n }\">{{version?.event}}</span>\n </td>\n <td data-head=\"Item Type\">{{ version.item_type }}</td>\n <td data-head=\"Item Id\">{{ version.item_id }}</td>\n <td data-head=\"Object\">\n <span (click)=\"openObjectModal(objModal, version?.object)\"\n class=\"badge bg-info cursor-pointer\">Open Object</span>\n </td>\n <td data-head=\"Updated At\">{{ version.updated_at | dateFormat: 'datetime' }}</td>\n </tr>\n </ng-template>\n </p-table>\n <div *ngIf=\" data.object_count === 0 && data.unfiltered_count !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\" [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n <span *ngIf=\"data.object_count !== 0\" class=\"total-records-count\">{{ 'Label.Total' | transloco }}: {{ data.object_count }}</span>\n </div>\n</div>\n<div *ngIf=\"!loading && data.unfiltered_count === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Ahoy.NoVersionsDataMessage' | transloco\"> </pw-no-data>\n</div>\n<!-- Object Modal -->\n<ng-template #objModal\n let-modal>\n <div class=\"modal-header\">\n <h4 class=\"modal-title\">{{ 'Admin.Tracking.Object' | transloco }}</h4>\n <button type=\"button\"\n class=\"btn-close float-end\"\n aria-label=\"Close\"\n (click)=\"modal.dismiss()\">\n\n </button>\n </div>\n <div class=\"modal-body\">\n <div *ngIf=\"activeObject\">\n <ngx-json-viewer [json]=\"activeObject\"\n [expanded]=\"false\"></ngx-json-viewer>\n </div>\n </div>\n</ng-template>\n", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}@media (min-width: 767px){.table-responsive td,.table-responsive th{font-size:11px!important}}\n"], dependencies: [{ kind: "component", type: i2$1.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorStyleClass", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "groupRowsByOrder", "responsiveLayout", "breakpoint", "paginatorLocale", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll", "virtualRowHeight"], outputs: ["contextMenuSelectionChange", "selectAllChange", "selectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: i3$1.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "directive", type: i2$1.SortableColumn, selector: "[pSortableColumn]", inputs: ["pSortableColumn", "pSortableColumnDisabled"] }, { kind: "component", type: i2$1.SortIcon, selector: "p-sortIcon", inputs: ["field"] }, { kind: "component", type: i6.MultiSelect, selector: "p-multiSelect", inputs: ["id", "ariaLabel", "style", "styleClass", "panelStyle", "panelStyleClass", "inputId", "disabled", "readonly", "group", "filter", "filterPlaceHolder", "filterLocale", "overlayVisible", "tabindex", "variant", "appendTo", "dataKey", "name", "ariaLabelledBy", "displaySelectedLabel", "maxSelectedLabels", "selectionLimit", "selectedItemsLabel", "showToggleAll", "emptyFilterMessage", "emptyMessage", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "showHeader", "filterBy", "scrollHeight", "lazy", "virtualScroll", "loading", "virtualScrollItemSize", "loadingIcon", "virtualScrollOptions", "overlayOptions", "ariaFilterLabel", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "display", "autocomplete", "showClear", "autofocus", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "defaultLabel", "placeholder", "options", "filterValue", "itemSize", "selectAll", "focusOnHover", "filterFields", "selectOnFocus", "autoOptionFocus"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onClear", "onPanelShow", "onPanelHide", "onLazyLoad", "onRemove", "onSelectAllChange"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["variant"] }, { kind: "component", type: i8$1.NgxJsonViewerComponent, selector: "ngx-json-viewer", inputs: ["json", "expanded", "depth", "_currentDepth"] }, { kind: "component", type: i7$2.Calendar, selector: "p-calendar", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepYearPicker", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "directive", type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.ProgressSpinner, selector: "p-progressSpinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "component", type: i9.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "directive", type: i10.DynamicBadgeDirective, selector: "[appDynamicBadge]", inputs: ["appDynamicBadge", "color"] }, { kind: "directive", type: i10.RbacAllowDirective, selector: "[rbacAllow]", inputs: ["rbacAllow"] }, { kind: "pipe", type: i12.TranslocoPipe, name: "transloco" }, { kind: "pipe", type: i13.DateFormatPipe, name: "dateFormat" }] }); }
|
|
6428
6497
|
}
|
|
6429
6498
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: VersionsComponent, decorators: [{
|
|
6430
6499
|
type: Component,
|
|
6431
|
-
args: [{ selector: 'pw-versions', template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0 float-start\">Versions</h2>\n </div>\n</div>\n<div class=\"w-100 text-center mt-3\"\n *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n</div>\n<div class=\"primeng-datatable-container mt-0\" [class.hideTable]=\"data.unfiltered_count === 0\">\n <div class=\"user-management-table table-responsive\">\n <p-table #dt\n [value]=\"data.versions\"\n [paginator]=\"data.object_count !== 0\"\n [lazy]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [totalRecords]=\"data.object_count\"\n [loading]=\"loading\"\n [filterDelay]=\"1000\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template pTemplate=\"caption\">\n <div class=\"row\">\n <div *rbacAllow=\"'SuperAdmin'\"\n class=\"col-sm-2 mb-2 mb-md-0\">\n <select (change)=\"onServiceChange($event.target.value)\"\n class=\"form-control form-select\">\n <option *ngFor=\"let item of microServices\"\n [value]=\"item.name\">\n {{ item.name }}\n </option>\n </select>\n </div>\n <div class=\"col-sm-2\">\n <p-multiSelect #multiSelector [options]=\"searchOptions\"\n (onChange)=\"onSearchOptionChange($event)\"\n placeholder=\"Filter by users\"\n [(ngModel)]=\"filterSource\"\n [showToggleAll]=\"true\"\n [showHeader]=\"true\"\n appendTo=\"body\"\n [lazy]=\"true\"\n (scroll)=\"onScroll($event)\"\n (onPanelShow)=\"onPanelShow()\"\n [loading]=\"userLoading\"\n (onFilter)=\"handleFilter($event)\"\n >\n </p-multiSelect>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [showTime]=\"true\"\n [appendTo]=\"'body'\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'Start Date'\"\n [(ngModel)]=\"startDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col-sm-2 \">\n <p-calendar [appendTo]=\"'body'\"\n [showTime]=\"true\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'End Date'\"\n [(ngModel)]=\"endDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col d-flex align-items-center\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Versions...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90 form-control bg-white\" />\n </div>\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\"\n pSortableColumn=\"author\">\n {{ 'Admin.Tracking.User' | transloco }}\n <p-sortIcon field=\"author\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"created_at\">\n {{ 'Admin.Tracking.CreatedAt' | transloco }}\n <p-sortIcon field=\"created_at\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"event\">\n {{ 'Admin.Tracking.Event' | transloco }}\n <p-sortIcon field=\"event\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"item_type\">\n {{ 'Admin.Tracking.ItemType' | transloco }}\n <p-sortIcon field=\"item_type\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"item_id\">\n {{ 'Admin.Tracking.ItemId' | transloco }}\n <p-sortIcon field=\"item_id\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"object\">\n {{ 'Admin.Tracking.Object' | transloco }}\n <p-sortIcon field=\"object\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"updated_at\">\n {{ 'Admin.Tracking.UpdatedAt' | transloco }}\n <p-sortIcon field=\"updated_at\"></p-sortIcon>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-version>\n <tr [class.d-none]=\"loading\">\n <td data-head=\"User\">\n <span *ngIf=\"version?.author\"><a [routerLink]=\"['/members', version?.author?.slug]\">{{ version?.author?.first_name }}\n {{ version?.author?.last_name }}</a></span>\n <span *ngIf=\"!version?.author && version?.whoDoneIt\">{{\n version?.whoDoneIt\n }}</span>\n </td>\n <td data-head=\"Created At\">{{ version.created_at }}</td>\n <td data-head=\"Event\">\n <span class=\"badge\"\n color=\"warning\"\n [appDynamicBadge]=\"{\n itemsArray: events,\n item: version?.event\n }\">{{version?.event}}</span>\n </td>\n <td data-head=\"Item Type\">{{ version.item_type }}</td>\n <td data-head=\"Item Id\">{{ version.item_id }}</td>\n <td data-head=\"Object\">\n <span (click)=\"openObjectModal(objModal, version?.object)\"\n class=\"badge bg-info cursor-pointer\">Open Object</span>\n </td>\n <td data-head=\"Updated At\">{{ version.updated_at }}</td>\n </tr>\n </ng-template>\n </p-table>\n <div *ngIf=\" data.object_count === 0 && data.unfiltered_count !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\" [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n <span *ngIf=\"data.object_count !== 0\" class=\"total-records-count\">{{ 'Label.Total' | transloco }}: {{ data.object_count }}</span>\n </div>\n</div>\n<div *ngIf=\"!loading && data.unfiltered_count === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Ahoy.NoVersionsDataMessage' | transloco\"> </pw-no-data>\n</div>\n<!-- Object Modal -->\n<ng-template #objModal\n let-modal>\n <div class=\"modal-header\">\n <h4 class=\"modal-title\">{{ 'Admin.Tracking.Object' | transloco }}</h4>\n <button type=\"button\"\n class=\"btn-close float-end\"\n aria-label=\"Close\"\n (click)=\"modal.dismiss()\">\n\n </button>\n </div>\n <div class=\"modal-body\">\n <div *ngIf=\"activeObject\">\n <ngx-json-viewer [json]=\"activeObject\"\n [expanded]=\"false\"></ngx-json-viewer>\n </div>\n </div>\n</ng-template>\n", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}@media (min-width: 767px){.table-responsive td,.table-responsive th{font-size:11px!important}}\n"] }]
|
|
6500
|
+
args: [{ selector: 'pw-versions', template: "<div class=\"row\">\n <div class=\"col-12 d-flex justify-content-between align-items-center\">\n <h2 class=\"card-title p-0 float-start\">Versions</h2>\n </div>\n</div>\n<div class=\"w-100 text-center mt-3\"\n *ngIf=\"!isLoaded\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n</div>\n<div class=\"primeng-datatable-container mt-0\" [class.hideTable]=\"data.unfiltered_count === 0\">\n <div class=\"user-management-table table-responsive\">\n <p-table #dt\n [value]=\"data.versions\"\n [paginator]=\"data.object_count !== 0\"\n [lazy]=\"true\"\n [rows]=\"PAGE_SIZE\"\n [totalRecords]=\"data.object_count\"\n [loading]=\"loading\"\n [filterDelay]=\"1000\"\n (onLazyLoad)=\"onLazyLoad($event)\">\n <ng-template pTemplate=\"caption\">\n <div class=\"row\">\n <div *rbacAllow=\"'SuperAdmin'\"\n class=\"col-sm-2 mb-2 mb-md-0\">\n <select (change)=\"onServiceChange($event.target.value)\"\n class=\"form-control form-select\">\n <option *ngFor=\"let item of microServices\"\n [value]=\"item.name\">\n {{ item.name }}\n </option>\n </select>\n </div>\n <div class=\"col-sm-2\">\n <p-multiSelect #multiSelector [options]=\"searchOptions\"\n (onChange)=\"onSearchOptionChange($event)\"\n placeholder=\"Filter by users\"\n [(ngModel)]=\"filterSource\"\n [showToggleAll]=\"true\"\n [showHeader]=\"true\"\n appendTo=\"body\"\n [lazy]=\"true\"\n (scroll)=\"onScroll($event)\"\n (onPanelShow)=\"onPanelShow()\"\n [loading]=\"userLoading\"\n (onFilter)=\"handleFilter($event)\"\n >\n </p-multiSelect>\n </div>\n <div class=\"col-sm-2\">\n <p-calendar [showTime]=\"true\"\n [appendTo]=\"'body'\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'Start Date'\"\n [(ngModel)]=\"startDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col-sm-2 \">\n <p-calendar [appendTo]=\"'body'\"\n [showTime]=\"true\"\n (onSelect)=\"onDateSelection()\"\n [placeholder]=\"'End Date'\"\n [(ngModel)]=\"endDate\"\n [showIcon]=\"true\"\n dateFormat=\"dd-M-yy\">\n </p-calendar>\n </div>\n <div class=\"col d-flex align-items-center\">\n <i class=\"fa fa-search mt-2 me-2\" aria-hidden=\"true\"></i>\n <input type=\"text\"\n [(ngModel)]=\"searchText\"\n pInputText\n size=\"50\"\n placeholder=\"Search Versions...\"\n (input)=\"dt.filterGlobal($event.target.value, 'contains')\"\n class=\"mw-90 form-control bg-white\" />\n </div>\n </div>\n </ng-template>\n <ng-template pTemplate=\"header\">\n <tr>\n <th scope=\"true\"\n pSortableColumn=\"author\">\n {{ 'Admin.Tracking.User' | transloco }}\n <p-sortIcon field=\"author\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"created_at\">\n {{ 'Admin.Tracking.CreatedAt' | transloco }}\n <p-sortIcon field=\"created_at\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"event\">\n {{ 'Admin.Tracking.Event' | transloco }}\n <p-sortIcon field=\"event\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"item_type\">\n {{ 'Admin.Tracking.ItemType' | transloco }}\n <p-sortIcon field=\"item_type\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"item_id\">\n {{ 'Admin.Tracking.ItemId' | transloco }}\n <p-sortIcon field=\"item_id\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"object\">\n {{ 'Admin.Tracking.Object' | transloco }}\n <p-sortIcon field=\"object\"></p-sortIcon>\n </th>\n <th scope=\"true\"\n pSortableColumn=\"updated_at\">\n {{ 'Admin.Tracking.UpdatedAt' | transloco }}\n <p-sortIcon field=\"updated_at\"></p-sortIcon>\n </th>\n </tr>\n </ng-template>\n <ng-template pTemplate=\"body\"\n let-version>\n <tr [class.d-none]=\"loading\">\n <td data-head=\"User\">\n <span *ngIf=\"version?.author\"><a [routerLink]=\"['/members', version?.author?.slug]\">{{ version?.author?.first_name }}\n {{ version?.author?.last_name }}</a></span>\n <span *ngIf=\"!version?.author && version?.whoDoneIt\">{{\n version?.whoDoneIt\n }}</span>\n </td>\n <td data-head=\"Created At\">{{ version.created_at | dateFormat: 'datetime' }}</td>\n <td data-head=\"Event\">\n <span class=\"badge\"\n color=\"warning\"\n [appDynamicBadge]=\"{\n itemsArray: events,\n item: version?.event\n }\">{{version?.event}}</span>\n </td>\n <td data-head=\"Item Type\">{{ version.item_type }}</td>\n <td data-head=\"Item Id\">{{ version.item_id }}</td>\n <td data-head=\"Object\">\n <span (click)=\"openObjectModal(objModal, version?.object)\"\n class=\"badge bg-info cursor-pointer\">Open Object</span>\n </td>\n <td data-head=\"Updated At\">{{ version.updated_at | dateFormat: 'datetime' }}</td>\n </tr>\n </ng-template>\n </p-table>\n <div *ngIf=\" data.object_count === 0 && data.unfiltered_count !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\" [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n <span *ngIf=\"data.object_count !== 0\" class=\"total-records-count\">{{ 'Label.Total' | transloco }}: {{ data.object_count }}</span>\n </div>\n</div>\n<div *ngIf=\"!loading && data.unfiltered_count === 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Admin.Ahoy.NoVersionsDataMessage' | transloco\"> </pw-no-data>\n</div>\n<!-- Object Modal -->\n<ng-template #objModal\n let-modal>\n <div class=\"modal-header\">\n <h4 class=\"modal-title\">{{ 'Admin.Tracking.Object' | transloco }}</h4>\n <button type=\"button\"\n class=\"btn-close float-end\"\n aria-label=\"Close\"\n (click)=\"modal.dismiss()\">\n\n </button>\n </div>\n <div class=\"modal-body\">\n <div *ngIf=\"activeObject\">\n <ngx-json-viewer [json]=\"activeObject\"\n [expanded]=\"false\"></ngx-json-viewer>\n </div>\n </div>\n</ng-template>\n", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}@media (min-width: 767px){.table-responsive td,.table-responsive th{font-size:11px!important}}\n"] }]
|
|
6432
6501
|
}], ctorParameters: () => [{ type: i0.Injector }, { type: i1$1.AhoyService }, { type: i11.NgbModal }, { type: i0.ChangeDetectorRef }, { type: i1.AdminDataService }] });
|
|
6433
6502
|
|
|
6434
6503
|
class UserDetailsComponent extends AppBaseComponent {
|
|
@@ -7043,11 +7112,11 @@ class IncidentListComponent extends AppBaseComponent {
|
|
|
7043
7112
|
});
|
|
7044
7113
|
}
|
|
7045
7114
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: IncidentListComponent, deps: [{ token: i0.Injector }, { token: i1$1.CommonService }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
7046
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: IncidentListComponent, selector: "pw-admin-incident-list", usesInheritance: true, ngImport: i0, template: "<div class=\"row\">\n\t<div *rbacAllow=\"'Pages.Admin.Incident.Create'\"\n\t\tclass=\"col-12 d-flex flex-wrap justify-content-between align-items-center\">\n\t\t<h2 class=\"card-title p-0 float-start\">Incidents</h2>\n\t\t<a [routerLink]=\"[routers.incidentDetails + 'add']\"\n\t\t\t(click)=\"showList = !showList\"\n\t\t\thref=\"javascript:void(0)\"\n\t\t\tclass=\"btn btn-sm btn-outline-primary float-end\"\n\t\t\trole=\"button\"\n\t\t\taria-expanded=\"false\">\n\t\t\t<i class=\"fa fa-plus-circle\"\n\t\t\t\taria-hidden=\"true\"></i>\n\t\t\t{{ 'Label.AddNew' | transloco }} Incident\n\t\t</a>\n\t</div>\n</div>\n<div *ngIf=\"!isLoaded\"\n\tclass=\"w-100 text-center mt-3\">\n\t<p-progressSpinner strokeWidth=\"2\"></p-progressSpinner>\n</div>\n<div *ngIf=\"showList\"\n\tclass=\"row faqlist primeng-datatable-container mt-0\" [class.hideTable]=\"totalRecordsUnFiltered === 0\">\n\t<div class=\"col-12 px-0\">\n\t\t<p-table #tt\n\t\t\t[paginator]=\"totalRecords !== 0\"\n\t\t\t[rows]=\"PAGE_SIZE\"\n\t\t\t[totalRecords]=\"totalRecords\"\n\t\t\t[loading]=\"loading\"\n\t\t\t[lazy]=\"true\"\n\t\t\t[filterDelay]=\"1000\"\n\t\t\t[customSort]=\"true\"\n\t\t\t[value]=\"openIncidents\"\n\t\t\t(onLazyLoad)=\"onLazyLoad($event)\">\n\t\t\t<ng-template pTemplate=\"caption\">\n\t\t\t\t<div class=\"search-filter justify-content-end\">\n\t\t\t\t\t<div class=\"text-end\">\n\t\t\t\t\t\t<i class=\"fa fa-search mt-2 me-2\"\n\t\t\t\t\t\t\taria-hidden=\"true\"></i>\n\t\t\t\t\t\t<input [(ngModel)]=\"searchText\"\n\t\t\t\t\t\t\t(input)=\"tt.filterGlobal($event.target.value, 'contains')\"\n\t\t\t\t\t\t\ttype=\"text\"\n\t\t\t\t\t\t\tpInputText\n\t\t\t\t\t\t\tsize=\"50\"\n\t\t\t\t\t\t\tplaceholder=\"Search Incident...\"\n\t\t\t\t\t\t\tdata-cy=\"incident-search\"\n\t\t\t\t\t\t\tclass=\"wd-90\">\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\t\t\t</ng-template>\n\t\t\t<ng-template pTemplate=\"header\">\n\t\t\t\t<tr>\n\t\t\t\t\t<th scope=\"true\">\n\t\t\t\t\t\t{{ 'Admin.Incident.Description' | transloco }}\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\">\n\t\t\t\t\t\t{{ 'Admin.Incident.ServiceImpacted' | transloco }}\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\"\n\t\t\t\t\t\tpSortableColumn=\"started_at\">\n\t\t\t\t\t\t{{ 'Admin.Incident.StartedAt' | transloco }}\n\t\t\t\t\t\t<p-sortIcon field=\"started_at\"></p-sortIcon>\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\"\n\t\t\t\t\t\tpSortableColumn=\"resolved_at\">\n\t\t\t\t\t\t{{ 'Admin.Incident.ResolvedAt' | transloco }}\n\t\t\t\t\t\t<p-sortIcon field=\"resolved_at\"></p-sortIcon>\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\"\n\t\t\t\t\t\tpSortableColumn=\"last_check_at\">\n\t\t\t\t\t\t{{ 'Admin.Incident.LastCheckedAt' | transloco }}\n\t\t\t\t\t\t<p-sortIcon field=\"last_check_at\"></p-sortIcon>\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\">\n\t\t\t\t\t\t{{ 'Admin.Incident.Duration' | transloco }}\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\"\n\t\t\t\t\t\tclass=\"actions-list-two\">\n\t\t\t\t\t\t{{ 'Label.Actions' | transloco }}\n\t\t\t\t\t</th>\n\t\t\t\t</tr>\n\t\t\t</ng-template>\n\t\t\t<ng-template pTemplate=\"body\"\n\t\t\t\tlet-incident>\n\t\t\t\t<tr>\n\t\t\t\t\t<td data-head=\"description\"\n\t\t\t\t\t\tclass=\"description\">\n\t\t\t\t\t\t{{(incident?.description | removeHtml)|textTruncate: 200}}\n\t\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"serviceImpacted\">\n\t\t\t\t\t\t{{ incident?.service_impacted ? incident?.service_impacted :\n incident?.url_impacted }}\n\t\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"startedAt\">\n\t\t\t\t\t\t<span class=\"text-nowrap\">\n\t\t\t\t\t\t\t{{ incident?.started_at | date: 'dd/MMM/YYYY, h:mm a' }}\n\t\t\t\t\t\t</span>\n\t\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"resolvedAt\">\n\t\t\t\t\t\t<span class=\"text-nowrap\">\n\t\t\t\t\t\t\t{{ incident?.resolved_at | date: 'dd/MMM/YYYY, h:mm a' }}\n\t\t\t\t\t\t</span>\n\t\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"lastCheckedAt\">\n\t\t\t\t\t<span class=\"text-nowrap\">\n\t\t\t\t\t\t{{ incident?.last_check_at | date: 'dd/MMM/YYYY, h:mm a' }}\n\t\t\t\t\t</span>\n\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"Duration\">\n\t\t\t\t\t\t<!-- {{ calculateDuration(incident?.resolved_at ? incident?.resolved_at :\n incident?.last_check_at, incident?.started_at) }} -->\n\t\t\t\t\t\t{{ calculateDuration(incident?.resolved_at,\n incident?.started_at) }}\n\t\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"Action\">\n\t\t\t\t\t\t<ul class=\"list-unstyled list-inline\">\n\t\t\t\t\t\t\t<li ngbTooltip=\"Edit\"\n\t\t\t\t\t\t\t\tclass=\"me-2 me-sm-2\">\n\t\t\t\t\t\t\t\t<i (click)=\"navigateToEdit(incident)\"\n\t\t\t\t\t\t\t\t\tclass=\"fa fa-edit edit-icon\"\n\t\t\t\t\t\t\t\t\taria-hidden=\"true\"></i>\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t<li ngbTooltip=\"Delete\"\n\t\t\t\t\t\t\t\tclass=\"me-2 me-sm-2\">\n\t\t\t\t\t\t\t\t<i (click)=\"onDelete(incident)\"\n\t\t\t\t\t\t\t\t\tclass=\"fa fa-trash delete-icon\"\n\t\t\t\t\t\t\t\t\taria-hidden=\"true\"></i>\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t</ul>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\t\t\t</ng-template>\n\t\t</p-table>\n <div *ngIf=\"openIncidents.length === 0 && totalRecordsUnFiltered !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\"\n [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n\t<span class=\"total-records-count\"*ngIf=\"openIncidents.length !== 0\" >Total: {{openIncidents.length }}</span>\n\t</div>\n <pw-no-data [withImage]=\"true\" *ngIf=\"totalRecordsUnFiltered === 0 && isLoaded\"\n [message]=\"'Admin.Incident.NoDataMessage' | transloco\">\n </pw-no-data>\n</div>\n", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}.incidents-wrapper .table thead th{border:0;border-bottom:1px solid rgb(222,226,230)}.incident-item{color:#3f3f44;font-size:14px;line-height:1.42857;padding:10px 0}.incident-item .description{color:var(--first)}.incident-item:last-child{border-bottom:0!important}.ql-editor.safe-html{margin:0;font-size:13px;padding:0}.safe-html p{margin:0;font-size:13px}\n"], dependencies: [{ kind: "component", type: i2$1.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorStyleClass", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "groupRowsByOrder", "responsiveLayout", "breakpoint", "paginatorLocale", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll", "virtualRowHeight"], outputs: ["contextMenuSelectionChange", "selectAllChange", "selectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: i3$1.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "directive", type: i2$1.SortableColumn, selector: "[pSortableColumn]", inputs: ["pSortableColumn", "pSortableColumnDisabled"] }, { kind: "component", type: i2$1.SortIcon, selector: "p-sortIcon", inputs: ["field"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["variant"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.ProgressSpinner, selector: "p-progressSpinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "component", type: i9.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "directive", type: i10.RbacAllowDirective, selector: "[rbacAllow]", inputs: ["rbacAllow"] }, { kind: "directive", type: i11.NgbTooltip, selector: "[ngbTooltip]", inputs: ["animation", "autoClose", "placement", "popperOptions", "triggers", "positionTarget", "container", "disableTooltip", "tooltipClass", "tooltipContext", "openDelay", "closeDelay", "ngbTooltip"], outputs: ["shown", "hidden"], exportAs: ["ngbTooltip"] }, { kind: "pipe", type: i2.DatePipe, name: "date" }, { kind: "pipe", type: i12.TranslocoPipe, name: "transloco" }, { kind: "pipe", type: i13.RemoveHtmlPipe, name: "removeHtml" }, { kind: "pipe", type: i13.TextTruncatePipe, name: "textTruncate" }] }); }
|
|
7115
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: IncidentListComponent, selector: "pw-admin-incident-list", usesInheritance: true, ngImport: i0, template: "<div class=\"row\">\n\t<div *rbacAllow=\"'Pages.Admin.Incident.Create'\"\n\t\tclass=\"col-12 d-flex flex-wrap justify-content-between align-items-center\">\n\t\t<h2 class=\"card-title p-0 float-start\">Incidents</h2>\n\t\t<a [routerLink]=\"[routers.incidentDetails + 'add']\"\n\t\t\t(click)=\"showList = !showList\"\n\t\t\thref=\"javascript:void(0)\"\n\t\t\tclass=\"btn btn-sm btn-outline-primary float-end\"\n\t\t\trole=\"button\"\n\t\t\taria-expanded=\"false\">\n\t\t\t<i class=\"fa fa-plus-circle\"\n\t\t\t\taria-hidden=\"true\"></i>\n\t\t\t{{ 'Label.AddNew' | transloco }} Incident\n\t\t</a>\n\t</div>\n</div>\n<div *ngIf=\"!isLoaded\"\n\tclass=\"w-100 text-center mt-3\">\n\t<p-progressSpinner strokeWidth=\"2\"></p-progressSpinner>\n</div>\n<div *ngIf=\"showList\"\n\tclass=\"row faqlist primeng-datatable-container mt-0\" [class.hideTable]=\"totalRecordsUnFiltered === 0\">\n\t<div class=\"col-12 px-0\">\n\t\t<p-table #tt\n\t\t\t[paginator]=\"totalRecords !== 0\"\n\t\t\t[rows]=\"PAGE_SIZE\"\n\t\t\t[totalRecords]=\"totalRecords\"\n\t\t\t[loading]=\"loading\"\n\t\t\t[lazy]=\"true\"\n\t\t\t[filterDelay]=\"1000\"\n\t\t\t[customSort]=\"true\"\n\t\t\t[value]=\"openIncidents\"\n\t\t\t(onLazyLoad)=\"onLazyLoad($event)\">\n\t\t\t<ng-template pTemplate=\"caption\">\n\t\t\t\t<div class=\"search-filter justify-content-end\">\n\t\t\t\t\t<div class=\"text-end\">\n\t\t\t\t\t\t<i class=\"fa fa-search mt-2 me-2\"\n\t\t\t\t\t\t\taria-hidden=\"true\"></i>\n\t\t\t\t\t\t<input [(ngModel)]=\"searchText\"\n\t\t\t\t\t\t\t(input)=\"tt.filterGlobal($event.target.value, 'contains')\"\n\t\t\t\t\t\t\ttype=\"text\"\n\t\t\t\t\t\t\tpInputText\n\t\t\t\t\t\t\tsize=\"50\"\n\t\t\t\t\t\t\tplaceholder=\"Search Incident...\"\n\t\t\t\t\t\t\tdata-cy=\"incident-search\"\n\t\t\t\t\t\t\tclass=\"wd-90\">\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\t\t\t</ng-template>\n\t\t\t<ng-template pTemplate=\"header\">\n\t\t\t\t<tr>\n\t\t\t\t\t<th scope=\"true\">\n\t\t\t\t\t\t{{ 'Admin.Incident.Description' | transloco }}\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\">\n\t\t\t\t\t\t{{ 'Admin.Incident.ServiceImpacted' | transloco }}\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\"\n\t\t\t\t\t\tpSortableColumn=\"started_at\">\n\t\t\t\t\t\t{{ 'Admin.Incident.StartedAt' | transloco }}\n\t\t\t\t\t\t<p-sortIcon field=\"started_at\"></p-sortIcon>\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\"\n\t\t\t\t\t\tpSortableColumn=\"resolved_at\">\n\t\t\t\t\t\t{{ 'Admin.Incident.ResolvedAt' | transloco }}\n\t\t\t\t\t\t<p-sortIcon field=\"resolved_at\"></p-sortIcon>\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\"\n\t\t\t\t\t\tpSortableColumn=\"last_check_at\">\n\t\t\t\t\t\t{{ 'Admin.Incident.LastCheckedAt' | transloco }}\n\t\t\t\t\t\t<p-sortIcon field=\"last_check_at\"></p-sortIcon>\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\">\n\t\t\t\t\t\t{{ 'Admin.Incident.Duration' | transloco }}\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\"\n\t\t\t\t\t\tclass=\"actions-list-two\">\n\t\t\t\t\t\t{{ 'Label.Actions' | transloco }}\n\t\t\t\t\t</th>\n\t\t\t\t</tr>\n\t\t\t</ng-template>\n\t\t\t<ng-template pTemplate=\"body\"\n\t\t\t\tlet-incident>\n\t\t\t\t<tr>\n\t\t\t\t\t<td data-head=\"description\"\n\t\t\t\t\t\tclass=\"description\">\n\t\t\t\t\t\t{{(incident?.description | removeHtml)|textTruncate: 200}}\n\t\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"serviceImpacted\">\n\t\t\t\t\t\t{{ incident?.service_impacted ? incident?.service_impacted :\n incident?.url_impacted }}\n\t\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"startedAt\">\n\t\t\t\t\t\t<span class=\"text-nowrap\">\n\t\t\t\t\t\t\t{{ incident?.started_at | date: 'dd-MMM-YYYY, h:mm a' }}\n\t\t\t\t\t\t</span>\n\t\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"resolvedAt\">\n\t\t\t\t\t\t<span class=\"text-nowrap\">\n\t\t\t\t\t\t\t{{ incident?.resolved_at | date: 'dd-MMM-YYYY, h:mm a' }}\n\t\t\t\t\t\t</span>\n\t\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"lastCheckedAt\">\n\t\t\t\t\t<span class=\"text-nowrap\">\n\t\t\t\t\t\t{{ incident?.last_check_at | date: 'dd-MMM-YYYY, h:mm a' }}\n\t\t\t\t\t</span>\n\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"Duration\">\n\t\t\t\t\t\t<!-- {{ calculateDuration(incident?.resolved_at ? incident?.resolved_at :\n incident?.last_check_at, incident?.started_at) }} -->\n\t\t\t\t\t\t{{ calculateDuration(incident?.resolved_at,\n incident?.started_at) }}\n\t\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"Action\">\n\t\t\t\t\t\t<ul class=\"list-unstyled list-inline\">\n\t\t\t\t\t\t\t<li ngbTooltip=\"Edit\"\n\t\t\t\t\t\t\t\tclass=\"me-2 me-sm-2\">\n\t\t\t\t\t\t\t\t<i (click)=\"navigateToEdit(incident)\"\n\t\t\t\t\t\t\t\t\tclass=\"fa fa-edit edit-icon\"\n\t\t\t\t\t\t\t\t\taria-hidden=\"true\"></i>\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t<li ngbTooltip=\"Delete\"\n\t\t\t\t\t\t\t\tclass=\"me-2 me-sm-2\">\n\t\t\t\t\t\t\t\t<i (click)=\"onDelete(incident)\"\n\t\t\t\t\t\t\t\t\tclass=\"fa fa-trash delete-icon\"\n\t\t\t\t\t\t\t\t\taria-hidden=\"true\"></i>\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t</ul>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\t\t\t</ng-template>\n\t\t</p-table>\n <div *ngIf=\"openIncidents.length === 0 && totalRecordsUnFiltered !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\"\n [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n\t<span class=\"total-records-count\"*ngIf=\"openIncidents.length !== 0\" >Total: {{openIncidents.length }}</span>\n\t</div>\n <pw-no-data [withImage]=\"true\" *ngIf=\"totalRecordsUnFiltered === 0 && isLoaded\"\n [message]=\"'Admin.Incident.NoDataMessage' | transloco\">\n </pw-no-data>\n</div>\n", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}.incidents-wrapper .table thead th{border:0;border-bottom:1px solid rgb(222,226,230)}.incident-item{color:#3f3f44;font-size:14px;line-height:1.42857;padding:10px 0}.incident-item .description{color:var(--first)}.incident-item:last-child{border-bottom:0!important}.ql-editor.safe-html{margin:0;font-size:13px;padding:0}.safe-html p{margin:0;font-size:13px}\n"], dependencies: [{ kind: "component", type: i2$1.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorStyleClass", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "groupRowsByOrder", "responsiveLayout", "breakpoint", "paginatorLocale", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll", "virtualRowHeight"], outputs: ["contextMenuSelectionChange", "selectAllChange", "selectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: i3$1.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "directive", type: i2$1.SortableColumn, selector: "[pSortableColumn]", inputs: ["pSortableColumn", "pSortableColumnDisabled"] }, { kind: "component", type: i2$1.SortIcon, selector: "p-sortIcon", inputs: ["field"] }, { kind: "directive", type: i4.InputText, selector: "[pInputText]", inputs: ["variant"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.ProgressSpinner, selector: "p-progressSpinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "component", type: i9.NoDataComponent, selector: "pw-no-data", inputs: ["message", "description", "withImage"] }, { kind: "directive", type: i10.RbacAllowDirective, selector: "[rbacAllow]", inputs: ["rbacAllow"] }, { kind: "directive", type: i11.NgbTooltip, selector: "[ngbTooltip]", inputs: ["animation", "autoClose", "placement", "popperOptions", "triggers", "positionTarget", "container", "disableTooltip", "tooltipClass", "tooltipContext", "openDelay", "closeDelay", "ngbTooltip"], outputs: ["shown", "hidden"], exportAs: ["ngbTooltip"] }, { kind: "pipe", type: i2.DatePipe, name: "date" }, { kind: "pipe", type: i12.TranslocoPipe, name: "transloco" }, { kind: "pipe", type: i13.RemoveHtmlPipe, name: "removeHtml" }, { kind: "pipe", type: i13.TextTruncatePipe, name: "textTruncate" }] }); }
|
|
7047
7116
|
}
|
|
7048
7117
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: IncidentListComponent, decorators: [{
|
|
7049
7118
|
type: Component,
|
|
7050
|
-
args: [{ selector: 'pw-admin-incident-list', template: "<div class=\"row\">\n\t<div *rbacAllow=\"'Pages.Admin.Incident.Create'\"\n\t\tclass=\"col-12 d-flex flex-wrap justify-content-between align-items-center\">\n\t\t<h2 class=\"card-title p-0 float-start\">Incidents</h2>\n\t\t<a [routerLink]=\"[routers.incidentDetails + 'add']\"\n\t\t\t(click)=\"showList = !showList\"\n\t\t\thref=\"javascript:void(0)\"\n\t\t\tclass=\"btn btn-sm btn-outline-primary float-end\"\n\t\t\trole=\"button\"\n\t\t\taria-expanded=\"false\">\n\t\t\t<i class=\"fa fa-plus-circle\"\n\t\t\t\taria-hidden=\"true\"></i>\n\t\t\t{{ 'Label.AddNew' | transloco }} Incident\n\t\t</a>\n\t</div>\n</div>\n<div *ngIf=\"!isLoaded\"\n\tclass=\"w-100 text-center mt-3\">\n\t<p-progressSpinner strokeWidth=\"2\"></p-progressSpinner>\n</div>\n<div *ngIf=\"showList\"\n\tclass=\"row faqlist primeng-datatable-container mt-0\" [class.hideTable]=\"totalRecordsUnFiltered === 0\">\n\t<div class=\"col-12 px-0\">\n\t\t<p-table #tt\n\t\t\t[paginator]=\"totalRecords !== 0\"\n\t\t\t[rows]=\"PAGE_SIZE\"\n\t\t\t[totalRecords]=\"totalRecords\"\n\t\t\t[loading]=\"loading\"\n\t\t\t[lazy]=\"true\"\n\t\t\t[filterDelay]=\"1000\"\n\t\t\t[customSort]=\"true\"\n\t\t\t[value]=\"openIncidents\"\n\t\t\t(onLazyLoad)=\"onLazyLoad($event)\">\n\t\t\t<ng-template pTemplate=\"caption\">\n\t\t\t\t<div class=\"search-filter justify-content-end\">\n\t\t\t\t\t<div class=\"text-end\">\n\t\t\t\t\t\t<i class=\"fa fa-search mt-2 me-2\"\n\t\t\t\t\t\t\taria-hidden=\"true\"></i>\n\t\t\t\t\t\t<input [(ngModel)]=\"searchText\"\n\t\t\t\t\t\t\t(input)=\"tt.filterGlobal($event.target.value, 'contains')\"\n\t\t\t\t\t\t\ttype=\"text\"\n\t\t\t\t\t\t\tpInputText\n\t\t\t\t\t\t\tsize=\"50\"\n\t\t\t\t\t\t\tplaceholder=\"Search Incident...\"\n\t\t\t\t\t\t\tdata-cy=\"incident-search\"\n\t\t\t\t\t\t\tclass=\"wd-90\">\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\t\t\t</ng-template>\n\t\t\t<ng-template pTemplate=\"header\">\n\t\t\t\t<tr>\n\t\t\t\t\t<th scope=\"true\">\n\t\t\t\t\t\t{{ 'Admin.Incident.Description' | transloco }}\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\">\n\t\t\t\t\t\t{{ 'Admin.Incident.ServiceImpacted' | transloco }}\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\"\n\t\t\t\t\t\tpSortableColumn=\"started_at\">\n\t\t\t\t\t\t{{ 'Admin.Incident.StartedAt' | transloco }}\n\t\t\t\t\t\t<p-sortIcon field=\"started_at\"></p-sortIcon>\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\"\n\t\t\t\t\t\tpSortableColumn=\"resolved_at\">\n\t\t\t\t\t\t{{ 'Admin.Incident.ResolvedAt' | transloco }}\n\t\t\t\t\t\t<p-sortIcon field=\"resolved_at\"></p-sortIcon>\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\"\n\t\t\t\t\t\tpSortableColumn=\"last_check_at\">\n\t\t\t\t\t\t{{ 'Admin.Incident.LastCheckedAt' | transloco }}\n\t\t\t\t\t\t<p-sortIcon field=\"last_check_at\"></p-sortIcon>\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\">\n\t\t\t\t\t\t{{ 'Admin.Incident.Duration' | transloco }}\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\"\n\t\t\t\t\t\tclass=\"actions-list-two\">\n\t\t\t\t\t\t{{ 'Label.Actions' | transloco }}\n\t\t\t\t\t</th>\n\t\t\t\t</tr>\n\t\t\t</ng-template>\n\t\t\t<ng-template pTemplate=\"body\"\n\t\t\t\tlet-incident>\n\t\t\t\t<tr>\n\t\t\t\t\t<td data-head=\"description\"\n\t\t\t\t\t\tclass=\"description\">\n\t\t\t\t\t\t{{(incident?.description | removeHtml)|textTruncate: 200}}\n\t\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"serviceImpacted\">\n\t\t\t\t\t\t{{ incident?.service_impacted ? incident?.service_impacted :\n incident?.url_impacted }}\n\t\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"startedAt\">\n\t\t\t\t\t\t<span class=\"text-nowrap\">\n\t\t\t\t\t\t\t{{ incident?.started_at | date: 'dd
|
|
7119
|
+
args: [{ selector: 'pw-admin-incident-list', template: "<div class=\"row\">\n\t<div *rbacAllow=\"'Pages.Admin.Incident.Create'\"\n\t\tclass=\"col-12 d-flex flex-wrap justify-content-between align-items-center\">\n\t\t<h2 class=\"card-title p-0 float-start\">Incidents</h2>\n\t\t<a [routerLink]=\"[routers.incidentDetails + 'add']\"\n\t\t\t(click)=\"showList = !showList\"\n\t\t\thref=\"javascript:void(0)\"\n\t\t\tclass=\"btn btn-sm btn-outline-primary float-end\"\n\t\t\trole=\"button\"\n\t\t\taria-expanded=\"false\">\n\t\t\t<i class=\"fa fa-plus-circle\"\n\t\t\t\taria-hidden=\"true\"></i>\n\t\t\t{{ 'Label.AddNew' | transloco }} Incident\n\t\t</a>\n\t</div>\n</div>\n<div *ngIf=\"!isLoaded\"\n\tclass=\"w-100 text-center mt-3\">\n\t<p-progressSpinner strokeWidth=\"2\"></p-progressSpinner>\n</div>\n<div *ngIf=\"showList\"\n\tclass=\"row faqlist primeng-datatable-container mt-0\" [class.hideTable]=\"totalRecordsUnFiltered === 0\">\n\t<div class=\"col-12 px-0\">\n\t\t<p-table #tt\n\t\t\t[paginator]=\"totalRecords !== 0\"\n\t\t\t[rows]=\"PAGE_SIZE\"\n\t\t\t[totalRecords]=\"totalRecords\"\n\t\t\t[loading]=\"loading\"\n\t\t\t[lazy]=\"true\"\n\t\t\t[filterDelay]=\"1000\"\n\t\t\t[customSort]=\"true\"\n\t\t\t[value]=\"openIncidents\"\n\t\t\t(onLazyLoad)=\"onLazyLoad($event)\">\n\t\t\t<ng-template pTemplate=\"caption\">\n\t\t\t\t<div class=\"search-filter justify-content-end\">\n\t\t\t\t\t<div class=\"text-end\">\n\t\t\t\t\t\t<i class=\"fa fa-search mt-2 me-2\"\n\t\t\t\t\t\t\taria-hidden=\"true\"></i>\n\t\t\t\t\t\t<input [(ngModel)]=\"searchText\"\n\t\t\t\t\t\t\t(input)=\"tt.filterGlobal($event.target.value, 'contains')\"\n\t\t\t\t\t\t\ttype=\"text\"\n\t\t\t\t\t\t\tpInputText\n\t\t\t\t\t\t\tsize=\"50\"\n\t\t\t\t\t\t\tplaceholder=\"Search Incident...\"\n\t\t\t\t\t\t\tdata-cy=\"incident-search\"\n\t\t\t\t\t\t\tclass=\"wd-90\">\n\t\t\t\t\t</div>\n\t\t\t\t</div>\n\t\t\t</ng-template>\n\t\t\t<ng-template pTemplate=\"header\">\n\t\t\t\t<tr>\n\t\t\t\t\t<th scope=\"true\">\n\t\t\t\t\t\t{{ 'Admin.Incident.Description' | transloco }}\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\">\n\t\t\t\t\t\t{{ 'Admin.Incident.ServiceImpacted' | transloco }}\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\"\n\t\t\t\t\t\tpSortableColumn=\"started_at\">\n\t\t\t\t\t\t{{ 'Admin.Incident.StartedAt' | transloco }}\n\t\t\t\t\t\t<p-sortIcon field=\"started_at\"></p-sortIcon>\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\"\n\t\t\t\t\t\tpSortableColumn=\"resolved_at\">\n\t\t\t\t\t\t{{ 'Admin.Incident.ResolvedAt' | transloco }}\n\t\t\t\t\t\t<p-sortIcon field=\"resolved_at\"></p-sortIcon>\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\"\n\t\t\t\t\t\tpSortableColumn=\"last_check_at\">\n\t\t\t\t\t\t{{ 'Admin.Incident.LastCheckedAt' | transloco }}\n\t\t\t\t\t\t<p-sortIcon field=\"last_check_at\"></p-sortIcon>\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\">\n\t\t\t\t\t\t{{ 'Admin.Incident.Duration' | transloco }}\n\t\t\t\t\t</th>\n\t\t\t\t\t<th scope=\"true\"\n\t\t\t\t\t\tclass=\"actions-list-two\">\n\t\t\t\t\t\t{{ 'Label.Actions' | transloco }}\n\t\t\t\t\t</th>\n\t\t\t\t</tr>\n\t\t\t</ng-template>\n\t\t\t<ng-template pTemplate=\"body\"\n\t\t\t\tlet-incident>\n\t\t\t\t<tr>\n\t\t\t\t\t<td data-head=\"description\"\n\t\t\t\t\t\tclass=\"description\">\n\t\t\t\t\t\t{{(incident?.description | removeHtml)|textTruncate: 200}}\n\t\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"serviceImpacted\">\n\t\t\t\t\t\t{{ incident?.service_impacted ? incident?.service_impacted :\n incident?.url_impacted }}\n\t\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"startedAt\">\n\t\t\t\t\t\t<span class=\"text-nowrap\">\n\t\t\t\t\t\t\t{{ incident?.started_at | date: 'dd-MMM-YYYY, h:mm a' }}\n\t\t\t\t\t\t</span>\n\t\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"resolvedAt\">\n\t\t\t\t\t\t<span class=\"text-nowrap\">\n\t\t\t\t\t\t\t{{ incident?.resolved_at | date: 'dd-MMM-YYYY, h:mm a' }}\n\t\t\t\t\t\t</span>\n\t\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"lastCheckedAt\">\n\t\t\t\t\t<span class=\"text-nowrap\">\n\t\t\t\t\t\t{{ incident?.last_check_at | date: 'dd-MMM-YYYY, h:mm a' }}\n\t\t\t\t\t</span>\n\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"Duration\">\n\t\t\t\t\t\t<!-- {{ calculateDuration(incident?.resolved_at ? incident?.resolved_at :\n incident?.last_check_at, incident?.started_at) }} -->\n\t\t\t\t\t\t{{ calculateDuration(incident?.resolved_at,\n incident?.started_at) }}\n\t\t\t\t\t</td>\n\t\t\t\t\t<td data-head=\"Action\">\n\t\t\t\t\t\t<ul class=\"list-unstyled list-inline\">\n\t\t\t\t\t\t\t<li ngbTooltip=\"Edit\"\n\t\t\t\t\t\t\t\tclass=\"me-2 me-sm-2\">\n\t\t\t\t\t\t\t\t<i (click)=\"navigateToEdit(incident)\"\n\t\t\t\t\t\t\t\t\tclass=\"fa fa-edit edit-icon\"\n\t\t\t\t\t\t\t\t\taria-hidden=\"true\"></i>\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t\t<li ngbTooltip=\"Delete\"\n\t\t\t\t\t\t\t\tclass=\"me-2 me-sm-2\">\n\t\t\t\t\t\t\t\t<i (click)=\"onDelete(incident)\"\n\t\t\t\t\t\t\t\t\tclass=\"fa fa-trash delete-icon\"\n\t\t\t\t\t\t\t\t\taria-hidden=\"true\"></i>\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t</ul>\n\t\t\t\t\t</td>\n\t\t\t\t</tr>\n\t\t\t</ng-template>\n\t\t</p-table>\n <div *ngIf=\"openIncidents.length === 0 && totalRecordsUnFiltered !== 0\">\n <pw-no-data [withImage]=\"true\" [message]=\"'Search.NoDataMessage' | transloco\"\n [description]=\"'Search.NoDataDescription' | transloco\">\n </pw-no-data>\n </div>\n\t<span class=\"total-records-count\"*ngIf=\"openIncidents.length !== 0\" >Total: {{openIncidents.length }}</span>\n\t</div>\n <pw-no-data [withImage]=\"true\" *ngIf=\"totalRecordsUnFiltered === 0 && isLoaded\"\n [message]=\"'Admin.Incident.NoDataMessage' | transloco\">\n </pw-no-data>\n</div>\n", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}.incidents-wrapper .table thead th{border:0;border-bottom:1px solid rgb(222,226,230)}.incident-item{color:#3f3f44;font-size:14px;line-height:1.42857;padding:10px 0}.incident-item .description{color:var(--first)}.incident-item:last-child{border-bottom:0!important}.ql-editor.safe-html{margin:0;font-size:13px;padding:0}.safe-html p{margin:0;font-size:13px}\n"] }]
|
|
7051
7120
|
}], ctorParameters: () => [{ type: i0.Injector }, { type: i1$1.CommonService }] });
|
|
7052
7121
|
|
|
7053
7122
|
class AddEditIncidentComponent extends AppBaseComponent {
|
|
@@ -7157,11 +7226,11 @@ class AddEditIncidentComponent extends AppBaseComponent {
|
|
|
7157
7226
|
this.router.navigate([`${this.routers.incidentConfig}`]);
|
|
7158
7227
|
}
|
|
7159
7228
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: AddEditIncidentComponent, deps: [{ token: i0.Injector }, { token: i1$1.CommonService }, { token: i2$3.DomSanitizer }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
7160
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: AddEditIncidentComponent, selector: "pw-admin-add-edit-incident", viewQueries: [{ propertyName: "editForm", first: true, predicate: ["editForm"], descendants: true }], usesInheritance: true, ngImport: i0, template: "<div class=\"container-fluid pw-tab overflow-hidden\">\n <div class=\"dashboard\">\n <div class=\"dashboard-body\">\n <div class=\"me-auto col-xs-6 mt-4\">\n <a href=\"javascript:void(0)\" routerLink=\"/admin/incident/list\" class=\"previous\"><i\n class=\"fa fa-arrow-alt-circle-left\" aria-hidden=\"true\"></i></a>\n <h3 class=\"mt-3\">{{ id ? 'Edit' : 'Add New' }} Incident</h3>\n </div>\n <div class=\"w-100 text-center mt-3\"\n *ngIf=\"isLoading\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div class=\"p-2 mt-3\">\n <form (ngSubmit)=\"onSubmit()\" [formGroup]=\"form\" *ngIf=\"!isLoading\">\n <div class=\"row\">\n <pw-input-container class=\"col-lg-6\" [label]=\"'Admin.Incident.UrlImpacted' | transloco\"\n name=\"url_impacted\" [errorMsg]=\"'Admin.Incident.Validation.UrlImpacted' | transloco\">\n <input type=\"text\" formControlName=\"url_impacted\" class=\"form-control\"\n [ngClass]=\"{ 'is-invalid': submitted && f['url_impacted'].errors }\" />\n </pw-input-container>\n <pw-input-container class=\"col-lg-6\" [label]=\"'Admin.Incident.ServiceImpacted' | transloco\"\n name=\"service_impacted\"\n [errorMsg]=\"'Admin.Incident.Validation.ServiceImpacted' | transloco\">\n <input type=\"text\" formControlName=\"service_impacted\" class=\"form-control\"\n [ngClass]=\"{ 'is-invalid': submitted && f['service_impacted'].errors }\" />\n </pw-input-container>\n <div class=\"col-lg-12\">\n <pw-input-container class=\"col-12 quill-editor\"\n [label]=\"'Admin.Incident.Description' | transloco\" name=\"description\"\n [errorMsg]=\"'Admin.Incident.Validation.Description' | transloco\">\n <quill-editor [styles]=\"{ height: '200px'}\" formControlName=\"description\"\n class=\"quillEditor d-block\"\n [ngClass]=\"{ 'is-invalid': submitted && f['description'].errors, 'w-100': true }\">\n </quill-editor>\n </pw-input-container>\n </div>\n <div class=\"row\">\n <div class=\"col-xs-12 col-sm-4 col-md-4 col-lg-4\">\n <pw-input-container [label]=\"'Admin.Incident.StartedAt' | transloco\" name=\"started_at\"\n [errorMsg]=\"'Admin.Incident.Validation.Date' | transloco\">\n <p-calendar class=\"addEditincident\" formControlName=\"started_at\" [showIcon]=\"true\" [placeholder]=\"'Admin.Incident.calender.placeholder' | transloco\"\n [showTime]=\"true\" [appendTo]=\"'body'\" dateFormat=\"dd
|
|
7229
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.11", type: AddEditIncidentComponent, selector: "pw-admin-add-edit-incident", viewQueries: [{ propertyName: "editForm", first: true, predicate: ["editForm"], descendants: true }], usesInheritance: true, ngImport: i0, template: "<div class=\"container-fluid pw-tab overflow-hidden\">\n <div class=\"dashboard\">\n <div class=\"dashboard-body\">\n <div class=\"me-auto col-xs-6 mt-4\">\n <a href=\"javascript:void(0)\" routerLink=\"/admin/incident/list\" class=\"previous\"><i\n class=\"fa fa-arrow-alt-circle-left\" aria-hidden=\"true\"></i></a>\n <h3 class=\"mt-3\">{{ id ? 'Edit' : 'Add New' }} Incident</h3>\n </div>\n <div class=\"w-100 text-center mt-3\"\n *ngIf=\"isLoading\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div class=\"p-2 mt-3\">\n <form (ngSubmit)=\"onSubmit()\" [formGroup]=\"form\" *ngIf=\"!isLoading\">\n <div class=\"row\">\n <pw-input-container class=\"col-lg-6\" [label]=\"'Admin.Incident.UrlImpacted' | transloco\"\n name=\"url_impacted\" [errorMsg]=\"'Admin.Incident.Validation.UrlImpacted' | transloco\">\n <input type=\"text\" formControlName=\"url_impacted\" class=\"form-control\"\n [ngClass]=\"{ 'is-invalid': submitted && f['url_impacted'].errors }\" />\n </pw-input-container>\n <pw-input-container class=\"col-lg-6\" [label]=\"'Admin.Incident.ServiceImpacted' | transloco\"\n name=\"service_impacted\"\n [errorMsg]=\"'Admin.Incident.Validation.ServiceImpacted' | transloco\">\n <input type=\"text\" formControlName=\"service_impacted\" class=\"form-control\"\n [ngClass]=\"{ 'is-invalid': submitted && f['service_impacted'].errors }\" />\n </pw-input-container>\n <div class=\"col-lg-12\">\n <pw-input-container class=\"col-12 quill-editor\"\n [label]=\"'Admin.Incident.Description' | transloco\" name=\"description\"\n [errorMsg]=\"'Admin.Incident.Validation.Description' | transloco\">\n <quill-editor [styles]=\"{ height: '200px'}\" formControlName=\"description\"\n class=\"quillEditor d-block\"\n [ngClass]=\"{ 'is-invalid': submitted && f['description'].errors, 'w-100': true }\">\n </quill-editor>\n </pw-input-container>\n </div>\n <div class=\"row\">\n <div class=\"col-xs-12 col-sm-4 col-md-4 col-lg-4\">\n <pw-input-container [label]=\"'Admin.Incident.StartedAt' | transloco\" name=\"started_at\"\n [errorMsg]=\"'Admin.Incident.Validation.Date' | transloco\">\n <p-calendar class=\"addEditincident\" formControlName=\"started_at\" [showIcon]=\"true\" [placeholder]=\"'Admin.Incident.calender.placeholder' | transloco\"\n [showTime]=\"true\" [appendTo]=\"'body'\" dateFormat=\"dd-M-yy\">\n </p-calendar>\n </pw-input-container>\n </div>\n <div class=\"col-xs-12 col-sm-4 col-md-4 col-lg-4\">\n <pw-input-container [label]=\"'Admin.Incident.ResolvedAt' | transloco\" name=\"resolved_at\"\n [errorMsg]=\"'Admin.Incident.Validation.Date' | transloco\">\n <p-calendar class=\"addEditincident\" formControlName=\"resolved_at\" [showIcon]=\"true\" [placeholder]=\"'Admin.Incident.calender.placeholder' | transloco\"\n [showTime]=\"true\" [appendTo]=\"'body'\" dateFormat=\"dd-M-yy\">\n </p-calendar>\n </pw-input-container>\n </div>\n <div class=\"col-xs-12 col-sm-4 col-md-4 col-lg-4\">\n <pw-input-container [label]=\"'Admin.Incident.LastCheckedAt' | transloco\"\n name=\"last_check_at\" [errorMsg]=\"'Admin.Incident.Validation.Date' | transloco\">\n <p-calendar class=\"addEditincident\" formControlName=\"last_check_at\"[placeholder]=\"'Admin.Incident.calender.placeholder' | transloco\"\n [showIcon]=\"true\" [showTime]=\"true\" [appendTo]=\"'body'\" dateFormat=\"dd-M-yy\">\n </p-calendar>\n </pw-input-container>\n </div>\n </div>\n </div>\n <div class=\"row\">\n <div class=\"col-12 mt-4\">\n <div class=\"mb-3 text-end\">\n <button type=\"button\" class=\"btn btn-outline-default me-2\" data-bs-toggle=\"collapse\"\n (click)=\"onCancel()\" role=\"button\" aria-expanded=\"false\"\n aria-controls=\"incidentCollapse\"> {{ 'Button.Cancel' | transloco }} </button>\n <button class=\"btn btn-primary\" [disabled]=\"!isSuperAdmin\" [buttonBusy]=\"buttonBusy\">{{\n 'Button.Save' | transloco }}</button>\n </div>\n </div>\n </div>\n </form>\n </div>\n </div>\n </div>\n</div>\n", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}\n"], dependencies: [{ kind: "component", type: i7$2.Calendar, selector: "p-calendar", inputs: ["iconDisplay", "style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "ariaLabel", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepYearPicker", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "startWeekFromFirstDayOfYear", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autofocus", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "variant", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale", "view", "defaultDate"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i3.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i7.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "component", type: i8.ProgressSpinner, selector: "p-progressSpinner", inputs: ["styleClass", "style", "strokeWidth", "fill", "animationDuration", "ariaLabel"] }, { kind: "component", type: i9.InputContainerComponent, selector: "pw-input-container", inputs: ["name", "label", "labelClass", "tooltipPosition", "required", "errorMsg", "isReadOnly", "showTooltip", "tooltipText", "showTriangle", "afterLabel", "showAfterLabel", "showTriangleText"] }, { kind: "directive", type: i10.ButtonBusyDirective, selector: "[buttonBusy]", inputs: ["buttonBusy", "busyText"] }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i3.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: i7$1.QuillEditorComponent, selector: "quill-editor" }, { kind: "pipe", type: i12.TranslocoPipe, name: "transloco" }] }); }
|
|
7161
7230
|
}
|
|
7162
7231
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.11", ngImport: i0, type: AddEditIncidentComponent, decorators: [{
|
|
7163
7232
|
type: Component,
|
|
7164
|
-
args: [{ selector: 'pw-admin-add-edit-incident', template: "<div class=\"container-fluid pw-tab overflow-hidden\">\n <div class=\"dashboard\">\n <div class=\"dashboard-body\">\n <div class=\"me-auto col-xs-6 mt-4\">\n <a href=\"javascript:void(0)\" routerLink=\"/admin/incident/list\" class=\"previous\"><i\n class=\"fa fa-arrow-alt-circle-left\" aria-hidden=\"true\"></i></a>\n <h3 class=\"mt-3\">{{ id ? 'Edit' : 'Add New' }} Incident</h3>\n </div>\n <div class=\"w-100 text-center mt-3\"\n *ngIf=\"isLoading\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div class=\"p-2 mt-3\">\n <form (ngSubmit)=\"onSubmit()\" [formGroup]=\"form\" *ngIf=\"!isLoading\">\n <div class=\"row\">\n <pw-input-container class=\"col-lg-6\" [label]=\"'Admin.Incident.UrlImpacted' | transloco\"\n name=\"url_impacted\" [errorMsg]=\"'Admin.Incident.Validation.UrlImpacted' | transloco\">\n <input type=\"text\" formControlName=\"url_impacted\" class=\"form-control\"\n [ngClass]=\"{ 'is-invalid': submitted && f['url_impacted'].errors }\" />\n </pw-input-container>\n <pw-input-container class=\"col-lg-6\" [label]=\"'Admin.Incident.ServiceImpacted' | transloco\"\n name=\"service_impacted\"\n [errorMsg]=\"'Admin.Incident.Validation.ServiceImpacted' | transloco\">\n <input type=\"text\" formControlName=\"service_impacted\" class=\"form-control\"\n [ngClass]=\"{ 'is-invalid': submitted && f['service_impacted'].errors }\" />\n </pw-input-container>\n <div class=\"col-lg-12\">\n <pw-input-container class=\"col-12 quill-editor\"\n [label]=\"'Admin.Incident.Description' | transloco\" name=\"description\"\n [errorMsg]=\"'Admin.Incident.Validation.Description' | transloco\">\n <quill-editor [styles]=\"{ height: '200px'}\" formControlName=\"description\"\n class=\"quillEditor d-block\"\n [ngClass]=\"{ 'is-invalid': submitted && f['description'].errors, 'w-100': true }\">\n </quill-editor>\n </pw-input-container>\n </div>\n <div class=\"row\">\n <div class=\"col-xs-12 col-sm-4 col-md-4 col-lg-4\">\n <pw-input-container [label]=\"'Admin.Incident.StartedAt' | transloco\" name=\"started_at\"\n [errorMsg]=\"'Admin.Incident.Validation.Date' | transloco\">\n <p-calendar class=\"addEditincident\" formControlName=\"started_at\" [showIcon]=\"true\" [placeholder]=\"'Admin.Incident.calender.placeholder' | transloco\"\n [showTime]=\"true\" [appendTo]=\"'body'\" dateFormat=\"dd
|
|
7233
|
+
args: [{ selector: 'pw-admin-add-edit-incident', template: "<div class=\"container-fluid pw-tab overflow-hidden\">\n <div class=\"dashboard\">\n <div class=\"dashboard-body\">\n <div class=\"me-auto col-xs-6 mt-4\">\n <a href=\"javascript:void(0)\" routerLink=\"/admin/incident/list\" class=\"previous\"><i\n class=\"fa fa-arrow-alt-circle-left\" aria-hidden=\"true\"></i></a>\n <h3 class=\"mt-3\">{{ id ? 'Edit' : 'Add New' }} Incident</h3>\n </div>\n <div class=\"w-100 text-center mt-3\"\n *ngIf=\"isLoading\">\n <p-progressSpinner strokeWidth=\"2\"> </p-progressSpinner>\n </div>\n <div class=\"p-2 mt-3\">\n <form (ngSubmit)=\"onSubmit()\" [formGroup]=\"form\" *ngIf=\"!isLoading\">\n <div class=\"row\">\n <pw-input-container class=\"col-lg-6\" [label]=\"'Admin.Incident.UrlImpacted' | transloco\"\n name=\"url_impacted\" [errorMsg]=\"'Admin.Incident.Validation.UrlImpacted' | transloco\">\n <input type=\"text\" formControlName=\"url_impacted\" class=\"form-control\"\n [ngClass]=\"{ 'is-invalid': submitted && f['url_impacted'].errors }\" />\n </pw-input-container>\n <pw-input-container class=\"col-lg-6\" [label]=\"'Admin.Incident.ServiceImpacted' | transloco\"\n name=\"service_impacted\"\n [errorMsg]=\"'Admin.Incident.Validation.ServiceImpacted' | transloco\">\n <input type=\"text\" formControlName=\"service_impacted\" class=\"form-control\"\n [ngClass]=\"{ 'is-invalid': submitted && f['service_impacted'].errors }\" />\n </pw-input-container>\n <div class=\"col-lg-12\">\n <pw-input-container class=\"col-12 quill-editor\"\n [label]=\"'Admin.Incident.Description' | transloco\" name=\"description\"\n [errorMsg]=\"'Admin.Incident.Validation.Description' | transloco\">\n <quill-editor [styles]=\"{ height: '200px'}\" formControlName=\"description\"\n class=\"quillEditor d-block\"\n [ngClass]=\"{ 'is-invalid': submitted && f['description'].errors, 'w-100': true }\">\n </quill-editor>\n </pw-input-container>\n </div>\n <div class=\"row\">\n <div class=\"col-xs-12 col-sm-4 col-md-4 col-lg-4\">\n <pw-input-container [label]=\"'Admin.Incident.StartedAt' | transloco\" name=\"started_at\"\n [errorMsg]=\"'Admin.Incident.Validation.Date' | transloco\">\n <p-calendar class=\"addEditincident\" formControlName=\"started_at\" [showIcon]=\"true\" [placeholder]=\"'Admin.Incident.calender.placeholder' | transloco\"\n [showTime]=\"true\" [appendTo]=\"'body'\" dateFormat=\"dd-M-yy\">\n </p-calendar>\n </pw-input-container>\n </div>\n <div class=\"col-xs-12 col-sm-4 col-md-4 col-lg-4\">\n <pw-input-container [label]=\"'Admin.Incident.ResolvedAt' | transloco\" name=\"resolved_at\"\n [errorMsg]=\"'Admin.Incident.Validation.Date' | transloco\">\n <p-calendar class=\"addEditincident\" formControlName=\"resolved_at\" [showIcon]=\"true\" [placeholder]=\"'Admin.Incident.calender.placeholder' | transloco\"\n [showTime]=\"true\" [appendTo]=\"'body'\" dateFormat=\"dd-M-yy\">\n </p-calendar>\n </pw-input-container>\n </div>\n <div class=\"col-xs-12 col-sm-4 col-md-4 col-lg-4\">\n <pw-input-container [label]=\"'Admin.Incident.LastCheckedAt' | transloco\"\n name=\"last_check_at\" [errorMsg]=\"'Admin.Incident.Validation.Date' | transloco\">\n <p-calendar class=\"addEditincident\" formControlName=\"last_check_at\"[placeholder]=\"'Admin.Incident.calender.placeholder' | transloco\"\n [showIcon]=\"true\" [showTime]=\"true\" [appendTo]=\"'body'\" dateFormat=\"dd-M-yy\">\n </p-calendar>\n </pw-input-container>\n </div>\n </div>\n </div>\n <div class=\"row\">\n <div class=\"col-12 mt-4\">\n <div class=\"mb-3 text-end\">\n <button type=\"button\" class=\"btn btn-outline-default me-2\" data-bs-toggle=\"collapse\"\n (click)=\"onCancel()\" role=\"button\" aria-expanded=\"false\"\n aria-controls=\"incidentCollapse\"> {{ 'Button.Cancel' | transloco }} </button>\n <button class=\"btn btn-primary\" [disabled]=\"!isSuperAdmin\" [buttonBusy]=\"buttonBusy\">{{\n 'Button.Save' | transloco }}</button>\n </div>\n </div>\n </div>\n </form>\n </div>\n </div>\n </div>\n</div>\n", styles: [":root{--first: rgb(23 105 225);--second: rgb(54 194 131);--third: rgb(255 171 0);--text: rgb(34 34 34);--tabs_bg: rgb(23 105 225);--tabs_text: rgb(255 255 255);--titles: rgb(34 34 34);--sidebar_bg: rgb(0, 48, 63);--sidebar_text: rgb(255 255 255)}\n"] }]
|
|
7165
7234
|
}], ctorParameters: () => [{ type: i0.Injector }, { type: i1$1.CommonService }, { type: i2$3.DomSanitizer }], propDecorators: { editForm: [{
|
|
7166
7235
|
type: ViewChild,
|
|
7167
7236
|
args: ['editForm', { static: false }]
|