zek 17.3.7 → 17.3.9
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/base.component.mjs +11 -10
- package/esm2022/lib/components/edit-base.component.mjs +14 -22
- package/esm2022/lib/components/list-base.component.mjs +9 -10
- package/esm2022/lib/modules/modal/filter-modal/filter-modal.component.mjs +1 -4
- package/esm2022/lib/zek.module.mjs +1 -1
- package/fesm2022/zek.mjs +27 -36
- package/fesm2022/zek.mjs.map +1 -1
- package/lib/components/base.component.d.ts +1 -1
- package/lib/components/edit-base.component.d.ts +3 -4
- package/lib/components/list-base.component.d.ts +3 -4
- package/lib/modules/modal/filter-modal/filter-modal.component.d.ts +0 -1
- package/package.json +1 -1
package/fesm2022/zek.mjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
import { Injectable, InjectionToken, Inject, Directive, inject, Input, EventEmitter, Output, ViewChild, Pipe, Component, forwardRef, NgModule, HostListener, ViewEncapsulation, ChangeDetectionStrategy, Optional } from '@angular/core';
|
|
3
|
-
import { BehaviorSubject, Subject, catchError, of, firstValueFrom, timer } from 'rxjs';
|
|
4
3
|
import * as i1 from '@angular/router';
|
|
5
|
-
import { NavigationStart, RouterModule } from '@angular/router';
|
|
4
|
+
import { NavigationStart, ActivatedRoute, Router, RouterModule } from '@angular/router';
|
|
5
|
+
import { BehaviorSubject, Subject, catchError, of, firstValueFrom, timer } from 'rxjs';
|
|
6
6
|
import * as i1$1 from '@ngx-translate/core';
|
|
7
|
-
import { TranslateModule } from '@ngx-translate/core';
|
|
7
|
+
import { TranslateService, TranslateModule } from '@ngx-translate/core';
|
|
8
8
|
import * as i1$2 from '@angular/common/http';
|
|
9
9
|
import { HttpParams, HttpHeaders, HTTP_INTERCEPTORS } from '@angular/common/http';
|
|
10
10
|
import * as i1$3 from '@angular/common';
|
|
@@ -1936,10 +1936,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.4", ngImpor
|
|
|
1936
1936
|
}] });
|
|
1937
1937
|
|
|
1938
1938
|
class BaseComponent extends CoreComponent {
|
|
1939
|
-
constructor(
|
|
1940
|
-
super();
|
|
1941
|
-
this.
|
|
1942
|
-
this.
|
|
1939
|
+
constructor() {
|
|
1940
|
+
super(...arguments);
|
|
1941
|
+
this._api = inject(WebApiClient);
|
|
1942
|
+
this.route = inject(ActivatedRoute);
|
|
1943
|
+
this.router = inject(Router);
|
|
1943
1944
|
this._readOnly = false;
|
|
1944
1945
|
this._url = null;
|
|
1945
1946
|
}
|
|
@@ -1983,7 +1984,7 @@ class BaseComponent extends CoreComponent {
|
|
|
1983
1984
|
return;
|
|
1984
1985
|
}
|
|
1985
1986
|
const template = split[1];
|
|
1986
|
-
let api = inject(WebApiClient);
|
|
1987
|
+
// let api = inject(WebApiClient);
|
|
1987
1988
|
let actionName;
|
|
1988
1989
|
switch (printType) {
|
|
1989
1990
|
case PrintType.Pdf:
|
|
@@ -1993,18 +1994,18 @@ class BaseComponent extends CoreComponent {
|
|
|
1993
1994
|
actionName = 'ShowIdLink';
|
|
1994
1995
|
break;
|
|
1995
1996
|
}
|
|
1996
|
-
|
|
1997
|
+
this._api.getString(`api/Reports/${actionName}`, { template, id }).subscribe(url => {
|
|
1997
1998
|
if (url) {
|
|
1998
1999
|
window.open(url, '_blank');
|
|
1999
2000
|
}
|
|
2000
2001
|
});
|
|
2001
2002
|
}
|
|
2002
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.4", ngImport: i0, type: BaseComponent, deps:
|
|
2003
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.4", ngImport: i0, type: BaseComponent, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
|
|
2003
2004
|
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "17.3.4", type: BaseComponent, inputs: { readOnly: "readOnly", model: "model" }, usesInheritance: true, ngImport: i0 }); }
|
|
2004
2005
|
}
|
|
2005
2006
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.4", ngImport: i0, type: BaseComponent, decorators: [{
|
|
2006
2007
|
type: Directive
|
|
2007
|
-
}],
|
|
2008
|
+
}], propDecorators: { readOnly: [{
|
|
2008
2009
|
type: Input
|
|
2009
2010
|
}], model: [{
|
|
2010
2011
|
type: Input
|
|
@@ -2200,13 +2201,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.4", ngImpor
|
|
|
2200
2201
|
type: Input
|
|
2201
2202
|
}] } });
|
|
2202
2203
|
|
|
2203
|
-
// import { IObjectConstructor } from '../models/ctor';
|
|
2204
|
-
// import { IService } from '../services/base.service';
|
|
2205
|
-
// import { AlertService } from '../modules/alert/shared/alert.service';
|
|
2206
|
-
// import { Area } from '../models/area.model';
|
|
2207
|
-
// import { PrintType } from '../models/print.model';
|
|
2208
|
-
// import { TranslateService } from '@ngx-translate/core';
|
|
2209
|
-
// import { ModalComponent } from '../modules/modal/modal.component';
|
|
2210
2204
|
class EditFormComponent extends BaseComponent {
|
|
2211
2205
|
constructor() {
|
|
2212
2206
|
super(...arguments);
|
|
@@ -2306,11 +2300,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.4", ngImpor
|
|
|
2306
2300
|
args: ['disapproveModal', { static: false }]
|
|
2307
2301
|
}] } });
|
|
2308
2302
|
class EditBaseComponent extends EditFormComponent {
|
|
2309
|
-
constructor(service
|
|
2310
|
-
super(
|
|
2303
|
+
constructor(service) {
|
|
2304
|
+
super();
|
|
2311
2305
|
this.service = service;
|
|
2312
|
-
this.translate =
|
|
2313
|
-
this.alert =
|
|
2306
|
+
this.translate = inject(TranslateService);
|
|
2307
|
+
this.alert = inject(AlertService);
|
|
2314
2308
|
}
|
|
2315
2309
|
async internalSave(navigateToReturnUrl) {
|
|
2316
2310
|
this.alert.clear();
|
|
@@ -2411,21 +2405,21 @@ class EditBaseComponent extends EditFormComponent {
|
|
|
2411
2405
|
}
|
|
2412
2406
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.4", ngImport: i0, type: EditBaseComponent, decorators: [{
|
|
2413
2407
|
type: Directive
|
|
2414
|
-
}], ctorParameters: () => [{ type: undefined }
|
|
2408
|
+
}], ctorParameters: () => [{ type: undefined }] });
|
|
2415
2409
|
class EditComponent extends EditBaseComponent {
|
|
2416
|
-
constructor(
|
|
2417
|
-
super(service
|
|
2418
|
-
this.
|
|
2410
|
+
constructor(_ctorModel, service) {
|
|
2411
|
+
super(service);
|
|
2412
|
+
this._ctorModel = _ctorModel;
|
|
2419
2413
|
}
|
|
2420
2414
|
initCreate() {
|
|
2421
|
-
this.model = new this.
|
|
2415
|
+
this.model = new this._ctorModel();
|
|
2422
2416
|
}
|
|
2423
2417
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.4", ngImport: i0, type: EditComponent, deps: "invalid", target: i0.ɵɵFactoryTarget.Directive }); }
|
|
2424
2418
|
static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "17.3.4", type: EditComponent, usesInheritance: true, ngImport: i0 }); }
|
|
2425
2419
|
}
|
|
2426
2420
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.4", ngImport: i0, type: EditComponent, decorators: [{
|
|
2427
2421
|
type: Directive
|
|
2428
|
-
}], ctorParameters: () => [{ type: undefined }, { type: undefined }
|
|
2422
|
+
}], ctorParameters: () => [{ type: undefined }, { type: undefined }] });
|
|
2429
2423
|
|
|
2430
2424
|
class EditBase {
|
|
2431
2425
|
}
|
|
@@ -2557,11 +2551,9 @@ class ValidEventArgs {
|
|
|
2557
2551
|
|
|
2558
2552
|
// declare let bootstrap: any;
|
|
2559
2553
|
class ListBaseComponent extends BaseComponent {
|
|
2560
|
-
constructor(service
|
|
2561
|
-
super(
|
|
2554
|
+
constructor(service) {
|
|
2555
|
+
super();
|
|
2562
2556
|
this.service = service;
|
|
2563
|
-
this.translate = translate;
|
|
2564
|
-
this.alert = alert;
|
|
2565
2557
|
this.filter = new FilterBase();
|
|
2566
2558
|
this.saveFilter = true;
|
|
2567
2559
|
this.internalFilter = new FilterBase();
|
|
@@ -2571,6 +2563,8 @@ class ListBaseComponent extends BaseComponent {
|
|
|
2571
2563
|
this.approveModel = {};
|
|
2572
2564
|
this.approvedMesage = 'Alert.Approved';
|
|
2573
2565
|
this.disapprovedMesage = 'Alert.Disapproved';
|
|
2566
|
+
this.translate = inject(TranslateService);
|
|
2567
|
+
this.alert = inject(AlertService);
|
|
2574
2568
|
}
|
|
2575
2569
|
init() {
|
|
2576
2570
|
super.init();
|
|
@@ -2796,7 +2790,7 @@ class ListBaseComponent extends BaseComponent {
|
|
|
2796
2790
|
}
|
|
2797
2791
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.4", ngImport: i0, type: ListBaseComponent, decorators: [{
|
|
2798
2792
|
type: Directive
|
|
2799
|
-
}], ctorParameters: () => [{ type: undefined }
|
|
2793
|
+
}], ctorParameters: () => [{ type: undefined }], propDecorators: { filterModal: [{
|
|
2800
2794
|
type: ViewChild,
|
|
2801
2795
|
args: ['filterModal', { static: false }]
|
|
2802
2796
|
}], approveModal: [{
|
|
@@ -4143,9 +4137,6 @@ class ZekFilterModal extends ZekModal {
|
|
|
4143
4137
|
reset() {
|
|
4144
4138
|
this.onReset.emit();
|
|
4145
4139
|
}
|
|
4146
|
-
getModalElement() {
|
|
4147
|
-
return document.getElementById('filter-modal');
|
|
4148
|
-
}
|
|
4149
4140
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.4", ngImport: i0, type: ZekFilterModal, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
4150
4141
|
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.4", type: ZekFilterModal, selector: "zek-filter-modal", outputs: { onReset: "onReset" }, usesInheritance: true, ngImport: i0, template: "<div (keydown.enter)=\"keyDown($event)\" class=\"modal fade\" data-bs-backdrop=\"static\" id=\"{{modalId}}\" tabindex=\"-1\" attr.aria-labelledby=\"{{lableId}}\" aria-hidden=\"true\">\r\n <div class=\"modal-dialog\" [class.modal-lg]=\"large\" [class.modal-xl]=\"xl\" [class.modal-dialog-scrollable]=\"scrollable\" [class.modal-fullscreen]=\"fullscreen\">\r\n <div class=\"modal-content\">\r\n <div class=\"modal-header\" *ngIf=\"showHeader\">\r\n <ng-content select=\"header\"></ng-content>\r\n <h5 class=\"modal-title\" id=\"{{lableId}}\">{{ 'Action.Filter' | translate }}</h5>\r\n <button type=\"button\" class=\"btn-close\" data-bs-dismiss=\"modal\" aria-label=\"Close\"></button>\r\n </div>\r\n <div class=\"modal-body\">\r\n {{text}}\r\n <ng-content></ng-content>\r\n </div>\r\n <div class=\"modal-footer\" *ngIf=\"showFooter\">\r\n <ng-content select=\"footer\"></ng-content>\r\n <button type=\"button\" class=\"btn btn-primary\" (click)=\"ok()\"><i class=\"fa-solid fa-filter\"></i> {{ 'Action.Filter' | translate }}</button>\r\n <button *ngIf=\"showCancel\" type=\"button\" class=\"btn btn-secondary\" id=\"modal-cancel-button-{{elementId}}\" data-bs-dismiss=\"modal\"><i class=\"fa-solid fa-ban\"></i> {{ 'Action.Cancel' | translate }}</button>\r\n <button type=\"button\" class=\"btn btn-secondary\" (click)=\"reset()\"><i class=\"fa-solid fa-xmark\"></i> {{ 'Action.Reset' | translate }}</button>\r\n </div>\r\n </div>\r\n </div>\r\n</div>", dependencies: [{ kind: "directive", type: i1$3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "pipe", type: i1$1.TranslatePipe, name: "translate" }] }); }
|
|
4151
4142
|
}
|