tin-spa 2.6.13 → 2.6.15
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/esm2020/lib/classes/Classes.mjs +36 -34
- package/esm2020/lib/classes/TinCore.mjs +74 -9
- package/esm2020/lib/components/form/form.component.mjs +34 -37
- package/esm2020/lib/components/select/select.component.mjs +27 -15
- package/esm2020/lib/components/select-common/select-common.component.mjs +2 -2
- package/esm2020/lib/components/select-internal/select-internal.component.mjs +27 -15
- package/esm2020/lib/components/table/detailsDialog.component.mjs +23 -21
- package/esm2020/lib/components/table/table.component.mjs +24 -19
- package/esm2020/lib/components/table-action/table-action.component.mjs +2 -2
- package/esm2020/lib/components/table-header/table-header.component.mjs +2 -2
- package/esm2020/lib/components/table-internal/detailsDialog-internal.component.mjs +23 -21
- package/esm2020/lib/components/table-internal/table-internal.component.mjs +24 -19
- package/esm2020/lib/components/table-lite/detailsDialog-lite.component.mjs +20 -18
- package/esm2020/lib/components/table-lite/table-lite.component.mjs +24 -19
- package/esm2020/lib/components/table-row/table-row.component.mjs +3 -3
- package/esm2020/lib/pages/approvals/approvals.component.mjs +5 -3
- package/esm2020/lib/pages/approvals-config/approvals-config.component.mjs +6 -2
- package/esm2020/lib/pages/departments/departments.component.mjs +1 -3
- package/esm2020/lib/pages/employees/employees.component.mjs +1 -2
- package/esm2020/lib/pages/login/login.component.mjs +2 -1
- package/esm2020/lib/pages/positions/positions.component.mjs +2 -2
- package/esm2020/lib/pages/tenant-settings/tenant-settings.component.mjs +3 -2
- package/esm2020/lib/services/button.service.mjs +27 -6
- package/esm2020/lib/services/datalib.service.mjs +70 -62
- package/fesm2015/tin-spa.mjs +351 -210
- package/fesm2015/tin-spa.mjs.map +1 -1
- package/fesm2020/tin-spa.mjs +345 -216
- package/fesm2020/tin-spa.mjs.map +1 -1
- package/lib/classes/Classes.d.ts +138 -138
- package/lib/classes/TinCore.d.ts +6 -3
- package/lib/components/form/form.component.d.ts +5 -2
- package/lib/components/select/select.component.d.ts +4 -1
- package/lib/components/select-internal/select-internal.component.d.ts +4 -1
- package/lib/components/table/detailsDialog.component.d.ts +3 -1
- package/lib/components/table/table.component.d.ts +4 -2
- package/lib/components/table-internal/detailsDialog-internal.component.d.ts +3 -1
- package/lib/components/table-internal/table-internal.component.d.ts +4 -2
- package/lib/components/table-lite/detailsDialog-lite.component.d.ts +3 -1
- package/lib/components/table-lite/table-lite.component.d.ts +4 -2
- package/lib/services/button.service.d.ts +4 -1
- package/lib/services/datalib.service.d.ts +9 -6
- package/package.json +1 -1
package/lib/classes/Classes.d.ts
CHANGED
|
@@ -1,26 +1,12 @@
|
|
|
1
1
|
import { BehaviorSubject } from "rxjs";
|
|
2
|
-
export declare class ApiResponse {
|
|
3
|
-
success: boolean;
|
|
4
|
-
message: string;
|
|
5
|
-
data: any;
|
|
6
|
-
}
|
|
7
|
-
export declare class Constants {
|
|
8
|
-
static readonly AUTH_USER = "a";
|
|
9
|
-
static readonly AUTH_NAME = "b";
|
|
10
|
-
static readonly AUTH_ROLES = "c";
|
|
11
|
-
static readonly AUTH_TOKEN = "d";
|
|
12
|
-
static readonly AUTH_TOKEN_EXPIRE = "e";
|
|
13
|
-
static readonly AUTH_TENANT_NAME = "f";
|
|
14
|
-
}
|
|
15
|
-
export declare class ListDialogConfig {
|
|
16
|
-
name: string;
|
|
17
|
-
title: string;
|
|
18
|
-
listName: string;
|
|
19
|
-
}
|
|
20
2
|
export declare enum DetailsSource {
|
|
21
3
|
Row = 0,
|
|
22
4
|
Url = 1
|
|
23
5
|
}
|
|
6
|
+
export declare class dialogOptions {
|
|
7
|
+
width?: string;
|
|
8
|
+
height?: string;
|
|
9
|
+
}
|
|
24
10
|
export declare class DetailsDialogConfig {
|
|
25
11
|
stepConfig?: StepConfig;
|
|
26
12
|
formConfig: FormConfig;
|
|
@@ -35,10 +21,6 @@ export declare class DetailsDialogConfig {
|
|
|
35
21
|
detailsSource?: DetailsSource;
|
|
36
22
|
options?: dialogOptions;
|
|
37
23
|
}
|
|
38
|
-
export declare class dialogOptions {
|
|
39
|
-
width?: string;
|
|
40
|
-
height?: string;
|
|
41
|
-
}
|
|
42
24
|
export declare class Action {
|
|
43
25
|
method?: 'get' | 'post';
|
|
44
26
|
url: string;
|
|
@@ -47,24 +29,76 @@ export declare class Action {
|
|
|
47
29
|
isFormData?: boolean;
|
|
48
30
|
skipCache?: boolean;
|
|
49
31
|
}
|
|
32
|
+
export interface SearchField extends Field {
|
|
33
|
+
show?: boolean;
|
|
34
|
+
}
|
|
50
35
|
export declare class SearchConfig {
|
|
51
36
|
fields: SearchField[];
|
|
52
37
|
searchAction?: Action;
|
|
53
38
|
emailResults?: boolean;
|
|
54
39
|
tileConfig?: TileConfig;
|
|
55
40
|
}
|
|
56
|
-
export
|
|
57
|
-
|
|
41
|
+
export declare class SecurityConfig {
|
|
42
|
+
allow?: CapItem[];
|
|
43
|
+
deny?: CapItem[];
|
|
58
44
|
}
|
|
59
|
-
export
|
|
60
|
-
|
|
61
|
-
|
|
45
|
+
export interface ChildField {
|
|
46
|
+
childField?: string;
|
|
47
|
+
childValueField?: string;
|
|
48
|
+
}
|
|
49
|
+
export interface Field {
|
|
50
|
+
securityConfig?: SecurityConfig;
|
|
51
|
+
name: string;
|
|
52
|
+
type: 'text' | 'multi-text' | 'password' | 'date' | 'datetime' | 'datetimesec' | 'checkbox' | 'select' | 'multi-select' | 'money' | 'number' | 'section' | 'blank' | 'chip' | 'file' | 'file-view' | 'icon' | 'spinner' | 'button' | 'label' | 'email' | 'composite' | 'string';
|
|
53
|
+
alias?: string;
|
|
54
|
+
options?: any[];
|
|
55
|
+
optionDisplay?: string;
|
|
56
|
+
optionValue?: string;
|
|
57
|
+
masterOptionValue?: string;
|
|
58
|
+
defaultValue?: any;
|
|
59
|
+
defaultFirstValue?: boolean;
|
|
60
|
+
required?: boolean;
|
|
61
|
+
min?: any;
|
|
62
|
+
max?: any;
|
|
63
|
+
rows?: number;
|
|
64
|
+
span?: boolean;
|
|
65
|
+
width?: string;
|
|
66
|
+
size?: string;
|
|
67
|
+
readonly?: boolean;
|
|
68
|
+
hidden?: boolean;
|
|
69
|
+
strict?: boolean;
|
|
70
|
+
path?: string;
|
|
71
|
+
keyField?: string;
|
|
72
|
+
hint?: string;
|
|
73
|
+
masterField?: string;
|
|
74
|
+
child?: ChildField;
|
|
75
|
+
children?: ChildField[];
|
|
76
|
+
masterOptions?: any[];
|
|
77
|
+
nullable?: boolean;
|
|
78
|
+
copyContent?: boolean;
|
|
79
|
+
clearContent?: boolean;
|
|
80
|
+
format?: 'text' | 'money' | 'date' | 'datetime' | 'number';
|
|
81
|
+
hideOnCreate?: boolean;
|
|
82
|
+
hideOnExists?: boolean;
|
|
83
|
+
hiddenCondition?: (value: any) => boolean;
|
|
84
|
+
readonlyCondition?: (value: any) => boolean;
|
|
85
|
+
detailsConfig?: DetailsDialogConfig;
|
|
86
|
+
loadAction?: Action;
|
|
87
|
+
infoMessage?: string;
|
|
88
|
+
suffix?: string;
|
|
89
|
+
subfields?: Field[];
|
|
90
|
+
optionsSubject?: BehaviorSubject<any[]>;
|
|
91
|
+
section?: string;
|
|
62
92
|
}
|
|
63
93
|
export declare class AlertMessage {
|
|
64
94
|
type?: 'success' | 'info' | 'warn' | 'critical';
|
|
65
95
|
content: string;
|
|
66
96
|
hiddenCondition?: (value: any) => boolean;
|
|
67
97
|
}
|
|
98
|
+
export declare class AlertMessages {
|
|
99
|
+
subject?: string;
|
|
100
|
+
messages: AlertMessage[];
|
|
101
|
+
}
|
|
68
102
|
export declare class FormConfig {
|
|
69
103
|
title?: string;
|
|
70
104
|
fixedTitle?: boolean;
|
|
@@ -77,6 +111,10 @@ export declare class FormConfig {
|
|
|
77
111
|
loadAction?: Action;
|
|
78
112
|
heroField?: any;
|
|
79
113
|
heroValue?: any;
|
|
114
|
+
security?: SecurityConfig;
|
|
115
|
+
}
|
|
116
|
+
export interface Confirm {
|
|
117
|
+
message: string;
|
|
80
118
|
}
|
|
81
119
|
export interface Button {
|
|
82
120
|
name: string;
|
|
@@ -94,62 +132,60 @@ export interface Button {
|
|
|
94
132
|
detailsConfig?: DetailsDialogConfig;
|
|
95
133
|
setHeroField?: boolean;
|
|
96
134
|
}
|
|
97
|
-
export interface
|
|
98
|
-
|
|
135
|
+
export interface Tile {
|
|
136
|
+
name: string;
|
|
137
|
+
alias?: string;
|
|
138
|
+
value?: string;
|
|
139
|
+
color?: string;
|
|
140
|
+
selectedTile?: string;
|
|
141
|
+
hidden?: boolean;
|
|
142
|
+
info?: string;
|
|
143
|
+
prefix?: string;
|
|
144
|
+
suffix?: string;
|
|
145
|
+
action?: Action;
|
|
99
146
|
}
|
|
100
|
-
export
|
|
147
|
+
export declare class TileConfig {
|
|
148
|
+
tiles: Tile[];
|
|
149
|
+
loadAction?: Action;
|
|
150
|
+
loadInit?: boolean;
|
|
151
|
+
clickable?: boolean;
|
|
152
|
+
}
|
|
153
|
+
export declare class Step {
|
|
154
|
+
name: string;
|
|
155
|
+
value?: any;
|
|
156
|
+
icon?: string;
|
|
157
|
+
hiddenCondition?: (value: any) => boolean;
|
|
158
|
+
}
|
|
159
|
+
export declare class StepConfig {
|
|
160
|
+
steps: Step[];
|
|
161
|
+
valueField?: string;
|
|
162
|
+
}
|
|
163
|
+
export interface Icon {
|
|
164
|
+
name: string;
|
|
165
|
+
color?: string;
|
|
166
|
+
tip?: string;
|
|
167
|
+
tipField?: string;
|
|
168
|
+
bannerField?: string;
|
|
101
169
|
condition?: (value: any) => boolean;
|
|
102
170
|
}
|
|
103
|
-
export
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
searchTableConfig?: TableConfig;
|
|
171
|
+
export interface Color {
|
|
172
|
+
name: string;
|
|
173
|
+
condition?: (value: any) => boolean;
|
|
107
174
|
}
|
|
108
|
-
export interface
|
|
175
|
+
export interface Column {
|
|
109
176
|
name: string;
|
|
110
|
-
type
|
|
177
|
+
type?: 'text' | 'date' | 'datetime' | 'datetimesec' | 'checkbox' | 'select' | 'money' | 'number' | 'chip' | 'icon' | 'spinner' | 'button';
|
|
111
178
|
alias?: string;
|
|
179
|
+
maxLength?: number;
|
|
180
|
+
icon?: Icon;
|
|
181
|
+
color?: Color;
|
|
182
|
+
colors?: Color[];
|
|
183
|
+
icons?: Icon[];
|
|
112
184
|
options?: any[];
|
|
113
185
|
optionDisplay?: string;
|
|
114
186
|
optionValue?: string;
|
|
115
|
-
masterOptionValue?: string;
|
|
116
|
-
defaultValue?: any;
|
|
117
|
-
defaultFirstValue?: boolean;
|
|
118
|
-
required?: boolean;
|
|
119
|
-
min?: any;
|
|
120
|
-
max?: any;
|
|
121
|
-
rows?: number;
|
|
122
|
-
span?: boolean;
|
|
123
|
-
width?: string;
|
|
124
|
-
size?: string;
|
|
125
|
-
readonly?: boolean;
|
|
126
|
-
hidden?: boolean;
|
|
127
|
-
strict?: boolean;
|
|
128
|
-
path?: string;
|
|
129
|
-
keyField?: string;
|
|
130
|
-
hint?: string;
|
|
131
|
-
masterField?: string;
|
|
132
|
-
child?: ChildField;
|
|
133
|
-
children?: ChildField[];
|
|
134
|
-
masterOptions?: any[];
|
|
135
|
-
nullable?: boolean;
|
|
136
|
-
copyContent?: boolean;
|
|
137
|
-
clearContent?: boolean;
|
|
138
|
-
format?: 'text' | 'money' | 'date' | 'datetime' | 'number';
|
|
139
|
-
hideOnCreate?: boolean;
|
|
140
|
-
hideOnExists?: boolean;
|
|
141
|
-
hiddenCondition?: (value: any) => boolean;
|
|
142
|
-
readonlyCondition?: (value: any) => boolean;
|
|
143
187
|
detailsConfig?: DetailsDialogConfig;
|
|
144
|
-
|
|
145
|
-
infoMessage?: string;
|
|
146
|
-
suffix?: string;
|
|
147
|
-
subfields?: Field[];
|
|
148
|
-
optionsSubject?: BehaviorSubject<any[]>;
|
|
149
|
-
}
|
|
150
|
-
export interface ChildField {
|
|
151
|
-
childField?: string;
|
|
152
|
-
childValueField?: string;
|
|
188
|
+
hiddenCondition?: (parentData: any) => boolean;
|
|
153
189
|
}
|
|
154
190
|
export declare class TableConfig {
|
|
155
191
|
tabTitle?: string;
|
|
@@ -191,64 +227,41 @@ export declare class TableConfig {
|
|
|
191
227
|
hiddenCondition?: (value: any) => boolean;
|
|
192
228
|
};
|
|
193
229
|
}
|
|
194
|
-
export
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
maxLength?: number;
|
|
199
|
-
icon?: Icon;
|
|
200
|
-
color?: Color;
|
|
201
|
-
colors?: Color[];
|
|
202
|
-
icons?: Icon[];
|
|
203
|
-
options?: any[];
|
|
204
|
-
optionDisplay?: string;
|
|
205
|
-
optionValue?: string;
|
|
206
|
-
detailsConfig?: DetailsDialogConfig;
|
|
207
|
-
hiddenCondition?: (parentData: any) => boolean;
|
|
208
|
-
}
|
|
209
|
-
export interface Icon {
|
|
210
|
-
name: string;
|
|
211
|
-
color?: string;
|
|
212
|
-
tip?: string;
|
|
213
|
-
tipField?: string;
|
|
214
|
-
bannerField?: string;
|
|
215
|
-
condition?: (value: any) => boolean;
|
|
216
|
-
}
|
|
217
|
-
export interface Color {
|
|
218
|
-
name: string;
|
|
219
|
-
condition?: (value: any) => boolean;
|
|
220
|
-
}
|
|
221
|
-
export declare class TileConfig {
|
|
222
|
-
tiles: Tile[];
|
|
223
|
-
loadAction?: Action;
|
|
224
|
-
loadInit?: boolean;
|
|
225
|
-
clickable?: boolean;
|
|
230
|
+
export declare class PageConfig {
|
|
231
|
+
title?: string;
|
|
232
|
+
tableConfig?: TableConfig;
|
|
233
|
+
searchTableConfig?: TableConfig;
|
|
226
234
|
}
|
|
227
|
-
export
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
color?: string;
|
|
232
|
-
selectedTile?: string;
|
|
233
|
-
hidden?: boolean;
|
|
234
|
-
info?: string;
|
|
235
|
-
prefix?: string;
|
|
236
|
-
suffix?: string;
|
|
237
|
-
action?: Action;
|
|
235
|
+
export declare class ApiResponse {
|
|
236
|
+
success: boolean;
|
|
237
|
+
message: string;
|
|
238
|
+
data: any;
|
|
238
239
|
}
|
|
239
|
-
export declare class
|
|
240
|
-
|
|
241
|
-
|
|
240
|
+
export declare class Constants {
|
|
241
|
+
static readonly AUTH_USER = "a";
|
|
242
|
+
static readonly AUTH_NAME = "b";
|
|
243
|
+
static readonly AUTH_ROLES = "c";
|
|
244
|
+
static readonly AUTH_TOKEN = "d";
|
|
245
|
+
static readonly AUTH_TOKEN_EXPIRE = "e";
|
|
246
|
+
static readonly AUTH_TENANT_NAME = "f";
|
|
242
247
|
}
|
|
243
|
-
export declare class
|
|
248
|
+
export declare class ListDialogConfig {
|
|
244
249
|
name: string;
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
hiddenCondition?: (value: any) => boolean;
|
|
250
|
+
title: string;
|
|
251
|
+
listName: string;
|
|
248
252
|
}
|
|
249
|
-
export declare class
|
|
253
|
+
export declare class CapItem {
|
|
254
|
+
constructor();
|
|
250
255
|
name: string;
|
|
251
|
-
|
|
256
|
+
display: string;
|
|
257
|
+
enabled: boolean;
|
|
258
|
+
showMenu: boolean;
|
|
259
|
+
ignoreSubsDisplay: boolean;
|
|
260
|
+
type: string;
|
|
261
|
+
newLine: boolean;
|
|
262
|
+
link: string;
|
|
263
|
+
icon: string;
|
|
264
|
+
capSubItems: CapItem[];
|
|
252
265
|
}
|
|
253
266
|
export declare class AppConfig {
|
|
254
267
|
constructor();
|
|
@@ -265,19 +278,6 @@ export declare class AppConfig {
|
|
|
265
278
|
progressLine: boolean;
|
|
266
279
|
docsBaseUrl: string;
|
|
267
280
|
}
|
|
268
|
-
export declare class CapItem {
|
|
269
|
-
constructor();
|
|
270
|
-
name: string;
|
|
271
|
-
display: string;
|
|
272
|
-
enabled: boolean;
|
|
273
|
-
showMenu: boolean;
|
|
274
|
-
ignoreSubsDisplay: boolean;
|
|
275
|
-
type: string;
|
|
276
|
-
newLine: boolean;
|
|
277
|
-
link: string;
|
|
278
|
-
icon: string;
|
|
279
|
-
capSubItems: CapItem[];
|
|
280
|
-
}
|
|
281
281
|
export declare class Transaction {
|
|
282
282
|
constructor();
|
|
283
283
|
transactionID: number;
|
package/lib/classes/TinCore.d.ts
CHANGED
|
@@ -1,13 +1,16 @@
|
|
|
1
|
-
import { DetailsDialogConfig, Field, FormConfig } from "./Classes";
|
|
1
|
+
import { DetailsDialogConfig, Field, FormConfig, SecurityConfig } from "./Classes";
|
|
2
2
|
export declare class Core {
|
|
3
3
|
static deepClone(obj: any): any;
|
|
4
4
|
static deepClone2(obj: any): any;
|
|
5
5
|
static camelToWords(value: string): string;
|
|
6
6
|
static generateObject(fields: Field[]): {};
|
|
7
7
|
static resetObject(fields: Field[], data: any): void;
|
|
8
|
-
static
|
|
8
|
+
static checkSecurity(security: SecurityConfig, currentRole: any): boolean;
|
|
9
|
+
static checkFormAccess(config: FormConfig, currentRole: any): boolean;
|
|
10
|
+
static testVisible(config: FormConfig, data: any, field: Field, currentRole: any): boolean;
|
|
11
|
+
static testReadOnly(config: FormConfig, data: any, field: Field): boolean;
|
|
9
12
|
static testVisibleHeaderButton(data: any, btn: any): boolean;
|
|
10
|
-
static getVisibleSubfields(config: FormConfig, data: any, field: Field): Field[];
|
|
13
|
+
static getVisibleSubfields(config: FormConfig, data: any, field: Field, currentRole: any): Field[];
|
|
11
14
|
static validateObject(fields: Field[], data: any): string;
|
|
12
15
|
static getInitialValue(field: Field): any;
|
|
13
16
|
static getClone(x: any): any;
|
|
@@ -2,17 +2,20 @@ import { EventEmitter, OnInit, TemplateRef } from '@angular/core';
|
|
|
2
2
|
import { FormConfig, Field, Button } from '../../classes/Classes';
|
|
3
3
|
import { MessageService } from '../../services/message.service';
|
|
4
4
|
import { DataServiceLib } from '../../services/datalib.service';
|
|
5
|
+
import { AuthService } from '../../services/auth.service';
|
|
5
6
|
import * as i0 from "@angular/core";
|
|
6
7
|
export declare class FormComponent implements OnInit {
|
|
7
8
|
private messageService;
|
|
8
9
|
private dataService;
|
|
9
|
-
|
|
10
|
+
private authService;
|
|
11
|
+
constructor(messageService: MessageService, dataService: DataServiceLib, authService: AuthService);
|
|
10
12
|
ngOnInit(): void;
|
|
11
13
|
initializeCompositeFields(): void;
|
|
12
14
|
getVisibleSubfields(field: Field): Field[];
|
|
13
15
|
getVisibleFields(): Field[];
|
|
14
|
-
testReadOnly(
|
|
16
|
+
testReadOnly(field: Field): boolean;
|
|
15
17
|
dynamicSelectTemplate: TemplateRef<any>;
|
|
18
|
+
hasAccess: boolean;
|
|
16
19
|
fileNames: any;
|
|
17
20
|
fileField: Field;
|
|
18
21
|
fileViewField: Field;
|
|
@@ -3,15 +3,18 @@ import { MessageService } from '../../services/message.service';
|
|
|
3
3
|
import { DialogService } from '../../services/dialog.service';
|
|
4
4
|
import { SelectCommonComponent } from '../select-common/select-common.component';
|
|
5
5
|
import { DataServiceLib } from '../../services/datalib.service';
|
|
6
|
+
import { ButtonService } from '../../services/button.service';
|
|
6
7
|
import * as i0 from "@angular/core";
|
|
7
8
|
export declare class SelectComponent extends SelectCommonComponent {
|
|
8
9
|
protected messageService: MessageService;
|
|
9
10
|
protected dataService: DataServiceLib;
|
|
10
11
|
private dialogService;
|
|
11
|
-
|
|
12
|
+
private buttonService;
|
|
13
|
+
constructor(messageService: MessageService, dataService: DataServiceLib, dialogService: DialogService, buttonService: ButtonService);
|
|
12
14
|
detailsConfig: DetailsDialogConfig;
|
|
13
15
|
onHoverChange(isHovered: boolean): void;
|
|
14
16
|
canCreate(): boolean;
|
|
17
|
+
canView(): boolean;
|
|
15
18
|
onPeekClick(event: MouseEvent, mode: 'create' | 'view'): void;
|
|
16
19
|
static ɵfac: i0.ɵɵFactoryDeclaration<SelectComponent, never>;
|
|
17
20
|
static ɵcmp: i0.ɵɵComponentDeclaration<SelectComponent, "spa-select", never, { "detailsConfig": "detailsConfig"; }, {}, never, never, false>;
|
|
@@ -3,15 +3,18 @@ import { MessageService } from '../../services/message.service';
|
|
|
3
3
|
import { DialogService } from '../../services/dialog.service';
|
|
4
4
|
import { SelectCommonComponent } from '../select-common/select-common.component';
|
|
5
5
|
import { DataServiceLib } from '../../services/datalib.service';
|
|
6
|
+
import { ButtonService } from '../../services/button.service';
|
|
6
7
|
import * as i0 from "@angular/core";
|
|
7
8
|
export declare class SelectInternalComponent extends SelectCommonComponent {
|
|
8
9
|
protected messageService: MessageService;
|
|
9
10
|
protected dataService: DataServiceLib;
|
|
10
11
|
private dialogService;
|
|
11
|
-
|
|
12
|
+
private buttonService;
|
|
13
|
+
constructor(messageService: MessageService, dataService: DataServiceLib, dialogService: DialogService, buttonService: ButtonService);
|
|
12
14
|
detailsConfig: DetailsDialogConfig;
|
|
13
15
|
onHoverChange(isHovered: boolean): void;
|
|
14
16
|
canCreate(): boolean;
|
|
17
|
+
canView(): boolean;
|
|
15
18
|
onPeekClick(event: MouseEvent, mode: 'create' | 'view'): void;
|
|
16
19
|
static ɵfac: i0.ɵɵFactoryDeclaration<SelectInternalComponent, never>;
|
|
17
20
|
static ɵcmp: i0.ɵɵComponentDeclaration<SelectInternalComponent, "spa-select-internal", never, { "detailsConfig": "detailsConfig"; }, {}, never, never, false>;
|
|
@@ -8,6 +8,7 @@ import { BreakpointObserver } from '@angular/cdk/layout';
|
|
|
8
8
|
import { Subject } from 'rxjs';
|
|
9
9
|
import { ButtonService } from '../../services/button.service';
|
|
10
10
|
import { DialogService } from '../../services/dialog.service';
|
|
11
|
+
import { AuthService } from '../../services/auth.service';
|
|
11
12
|
import * as i0 from "@angular/core";
|
|
12
13
|
export declare class DetailsDialog implements OnInit {
|
|
13
14
|
private breakpointObserver;
|
|
@@ -18,7 +19,8 @@ export declare class DetailsDialog implements OnInit {
|
|
|
18
19
|
detailsConfig: DetailsDialogConfig;
|
|
19
20
|
private buttonService;
|
|
20
21
|
private dialogService;
|
|
21
|
-
|
|
22
|
+
private authService;
|
|
23
|
+
constructor(breakpointObserver: BreakpointObserver, loaderService: LoaderService, dataService: DataServiceLib, messageService: MessageService, dialogRef: MatDialogRef<DetailsDialog>, detailsConfig: DetailsDialogConfig, buttonService: ButtonService, dialogService: DialogService, authService: AuthService);
|
|
22
24
|
ngOnInit(): void;
|
|
23
25
|
titleAction: string;
|
|
24
26
|
loadByAction: boolean;
|
|
@@ -10,6 +10,7 @@ import { ButtonService } from '../../services/button.service';
|
|
|
10
10
|
import { DialogService } from '../../services/dialog.service';
|
|
11
11
|
import { TableConfigService } from '../../services/table-config.service';
|
|
12
12
|
import { ConditionService } from '../../services/condition.service';
|
|
13
|
+
import { AuthService } from '../../services/auth.service';
|
|
13
14
|
import * as i0 from "@angular/core";
|
|
14
15
|
export declare class TableComponent implements OnInit {
|
|
15
16
|
private dataService;
|
|
@@ -20,7 +21,8 @@ export declare class TableComponent implements OnInit {
|
|
|
20
21
|
private dialogService;
|
|
21
22
|
private tableConfigService;
|
|
22
23
|
private conditionService;
|
|
23
|
-
|
|
24
|
+
private authService;
|
|
25
|
+
constructor(dataService: DataServiceLib, messageService: MessageService, breakpointObserver: BreakpointObserver, dialog: MatDialog, buttonService: ButtonService, dialogService: DialogService, tableConfigService: TableConfigService, conditionService: ConditionService, authService: AuthService);
|
|
24
26
|
ngOnInit(): void;
|
|
25
27
|
ngOnChanges(): void;
|
|
26
28
|
elevation: string;
|
|
@@ -28,6 +30,7 @@ export declare class TableComponent implements OnInit {
|
|
|
28
30
|
showFilterButton: boolean;
|
|
29
31
|
tileReload: Subject<boolean>;
|
|
30
32
|
smallScreen: boolean;
|
|
33
|
+
hasFormAccess: boolean;
|
|
31
34
|
tableDataSource: any;
|
|
32
35
|
dataSource: any[];
|
|
33
36
|
displayedColumns: any[];
|
|
@@ -62,7 +65,6 @@ export declare class TableComponent implements OnInit {
|
|
|
62
65
|
testColorCondition(row: any, color: Color): boolean;
|
|
63
66
|
showBanner(message: string): void;
|
|
64
67
|
testDisabled(row: any, buttonName: string): boolean;
|
|
65
|
-
testVisible(row: any, buttonName: string): boolean;
|
|
66
68
|
lastSearch: any;
|
|
67
69
|
searchClicked(x: any): void;
|
|
68
70
|
tileClicked(tile: any): void;
|
|
@@ -8,6 +8,7 @@ import { BreakpointObserver } from '@angular/cdk/layout';
|
|
|
8
8
|
import { DialogService } from '../../services/dialog.service';
|
|
9
9
|
import { ButtonService } from '../../services/button.service';
|
|
10
10
|
import { Subject } from 'rxjs';
|
|
11
|
+
import { AuthService } from '../../services/auth.service';
|
|
11
12
|
import * as i0 from "@angular/core";
|
|
12
13
|
export declare class DetailsDialogInternal implements OnInit {
|
|
13
14
|
private breakpointObserver;
|
|
@@ -18,7 +19,8 @@ export declare class DetailsDialogInternal implements OnInit {
|
|
|
18
19
|
detailsConfig: DetailsDialogConfig;
|
|
19
20
|
private buttonService;
|
|
20
21
|
private dialogService;
|
|
21
|
-
|
|
22
|
+
private authService;
|
|
23
|
+
constructor(breakpointObserver: BreakpointObserver, loaderService: LoaderService, dataService: DataServiceLib, messageService: MessageService, dialogRef: MatDialogRef<DetailsDialogInternal>, detailsConfig: DetailsDialogConfig, buttonService: ButtonService, dialogService: DialogService, authService: AuthService);
|
|
22
24
|
ngOnInit(): void;
|
|
23
25
|
titleAction: string;
|
|
24
26
|
loadByAction: boolean;
|
|
@@ -10,6 +10,7 @@ import { ButtonService } from '../../services/button.service';
|
|
|
10
10
|
import { DialogService } from '../../services/dialog.service';
|
|
11
11
|
import { TableConfigService } from '../../services/table-config.service';
|
|
12
12
|
import { ConditionService } from '../../services/condition.service';
|
|
13
|
+
import { AuthService } from '../../services/auth.service';
|
|
13
14
|
import * as i0 from "@angular/core";
|
|
14
15
|
export declare class TableInternalComponent implements OnInit {
|
|
15
16
|
private dataService;
|
|
@@ -20,7 +21,8 @@ export declare class TableInternalComponent implements OnInit {
|
|
|
20
21
|
private dialogService;
|
|
21
22
|
private tableConfigService;
|
|
22
23
|
private conditionService;
|
|
23
|
-
|
|
24
|
+
private authService;
|
|
25
|
+
constructor(dataService: DataServiceLib, messageService: MessageService, breakpointObserver: BreakpointObserver, dialog: MatDialog, buttonService: ButtonService, dialogService: DialogService, tableConfigService: TableConfigService, conditionService: ConditionService, authService: AuthService);
|
|
24
26
|
ngOnInit(): void;
|
|
25
27
|
ngOnChanges(): void;
|
|
26
28
|
elevation: string;
|
|
@@ -28,6 +30,7 @@ export declare class TableInternalComponent implements OnInit {
|
|
|
28
30
|
showFilterButton: boolean;
|
|
29
31
|
tileReload: Subject<boolean>;
|
|
30
32
|
smallScreen: boolean;
|
|
33
|
+
hasFormAccess: boolean;
|
|
31
34
|
tableDataSource: any;
|
|
32
35
|
dataSource: any[];
|
|
33
36
|
displayedColumns: any[];
|
|
@@ -62,7 +65,6 @@ export declare class TableInternalComponent implements OnInit {
|
|
|
62
65
|
testColorCondition(row: any, color: Color): boolean;
|
|
63
66
|
showBanner(message: string): void;
|
|
64
67
|
testDisabled(row: any, buttonName: string): boolean;
|
|
65
|
-
testVisible(row: any, buttonName: string): boolean;
|
|
66
68
|
lastSearch: any;
|
|
67
69
|
searchClicked(x: any): void;
|
|
68
70
|
tileClicked(tile: any): void;
|
|
@@ -8,6 +8,7 @@ import { BreakpointObserver } from '@angular/cdk/layout';
|
|
|
8
8
|
import { DialogService } from '../../services/dialog.service';
|
|
9
9
|
import { ButtonService } from '../../services/button.service';
|
|
10
10
|
import { Subject } from 'rxjs';
|
|
11
|
+
import { AuthService } from '../../services/auth.service';
|
|
11
12
|
import * as i0 from "@angular/core";
|
|
12
13
|
export declare class DetailsDialogLite implements OnInit {
|
|
13
14
|
private breakpointObserver;
|
|
@@ -18,7 +19,8 @@ export declare class DetailsDialogLite implements OnInit {
|
|
|
18
19
|
detailsConfig: DetailsDialogConfig;
|
|
19
20
|
private buttonService;
|
|
20
21
|
private dialogService;
|
|
21
|
-
|
|
22
|
+
private authService;
|
|
23
|
+
constructor(breakpointObserver: BreakpointObserver, loaderService: LoaderService, dataService: DataServiceLib, messageService: MessageService, dialogRef: MatDialogRef<DetailsDialogLite>, detailsConfig: DetailsDialogConfig, buttonService: ButtonService, dialogService: DialogService, authService: AuthService);
|
|
22
24
|
ngOnInit(): void;
|
|
23
25
|
titleAction: string;
|
|
24
26
|
loadByAction: boolean;
|
|
@@ -10,6 +10,7 @@ import { ButtonService } from '../../services/button.service';
|
|
|
10
10
|
import { DialogService } from '../../services/dialog.service';
|
|
11
11
|
import { TableConfigService } from '../../services/table-config.service';
|
|
12
12
|
import { ConditionService } from '../../services/condition.service';
|
|
13
|
+
import { AuthService } from '../../services/auth.service';
|
|
13
14
|
import * as i0 from "@angular/core";
|
|
14
15
|
export declare class TableLiteComponent implements OnInit {
|
|
15
16
|
private dataService;
|
|
@@ -20,7 +21,8 @@ export declare class TableLiteComponent implements OnInit {
|
|
|
20
21
|
private dialogService;
|
|
21
22
|
private tableConfigService;
|
|
22
23
|
private conditionService;
|
|
23
|
-
|
|
24
|
+
private authService;
|
|
25
|
+
constructor(dataService: DataServiceLib, messageService: MessageService, breakpointObserver: BreakpointObserver, dialog: MatDialog, buttonService: ButtonService, dialogService: DialogService, tableConfigService: TableConfigService, conditionService: ConditionService, authService: AuthService);
|
|
24
26
|
ngOnInit(): void;
|
|
25
27
|
ngOnChanges(): void;
|
|
26
28
|
elevation: string;
|
|
@@ -28,6 +30,7 @@ export declare class TableLiteComponent implements OnInit {
|
|
|
28
30
|
showFilterButton: boolean;
|
|
29
31
|
tileReload: Subject<boolean>;
|
|
30
32
|
smallScreen: boolean;
|
|
33
|
+
hasFormAccess: boolean;
|
|
31
34
|
tableDataSource: any;
|
|
32
35
|
dataSource: any[];
|
|
33
36
|
displayedColumns: any[];
|
|
@@ -62,7 +65,6 @@ export declare class TableLiteComponent implements OnInit {
|
|
|
62
65
|
testColorCondition(row: any, color: Color): boolean;
|
|
63
66
|
showBanner(message: string): void;
|
|
64
67
|
testDisabled(row: any, buttonName: string): boolean;
|
|
65
|
-
testVisible(row: any, buttonName: string): boolean;
|
|
66
68
|
lastSearch: any;
|
|
67
69
|
searchClicked(x: any): void;
|
|
68
70
|
tileClicked(tile: any): void;
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import { Button, TableConfig } from '../classes/Classes';
|
|
2
|
+
import { AuthService } from './auth.service';
|
|
2
3
|
import * as i0 from "@angular/core";
|
|
3
4
|
export declare class ButtonService {
|
|
5
|
+
private authService;
|
|
6
|
+
constructor(authService: AuthService);
|
|
4
7
|
getButton(buttons: Button[], name: string): Button | null;
|
|
5
8
|
getButtonProperties(button: Button, row: any, config: TableConfig): {
|
|
6
9
|
color: string;
|
|
@@ -15,7 +18,7 @@ export declare class ButtonService {
|
|
|
15
18
|
isTabVisible(tableConfig: TableConfig): boolean;
|
|
16
19
|
getIcon(button: Button, config: TableConfig): string;
|
|
17
20
|
testDisabled(button: Button, row: any): boolean;
|
|
18
|
-
testVisible(button: Button, row: any): boolean;
|
|
21
|
+
testVisible(button: Button, row: any, config?: TableConfig): boolean;
|
|
19
22
|
private getDefaultColor;
|
|
20
23
|
private getDefaultIcon;
|
|
21
24
|
getCreateButton(buttons: Button[]): Button | undefined;
|
|
@@ -38,26 +38,28 @@ export declare class DataServiceLib {
|
|
|
38
38
|
capApprovalsConfig: CapItem;
|
|
39
39
|
tmpProfileuserName: string;
|
|
40
40
|
isProcessing: boolean;
|
|
41
|
-
|
|
41
|
+
departmentFormConfig: FormConfig;
|
|
42
|
+
editDepartmentButton: Button;
|
|
43
|
+
departmentDetailsConfig: DetailsDialogConfig;
|
|
44
|
+
positionFormConfig: FormConfig;
|
|
45
|
+
editPositionButton: Button;
|
|
46
|
+
positionDetailsConfig: DetailsDialogConfig;
|
|
42
47
|
genders: {
|
|
43
48
|
name: string;
|
|
44
49
|
value: number;
|
|
45
50
|
}[];
|
|
46
51
|
employeeFormConfig: FormConfig;
|
|
47
52
|
employeeTableConfig: TableConfig;
|
|
48
|
-
loadPositionMeta(): void;
|
|
49
|
-
positionFormConfig: FormConfig;
|
|
50
|
-
editPositionButton: Button;
|
|
51
53
|
positionsTableConfig: TableConfig;
|
|
52
|
-
departmentFormConfig: FormConfig;
|
|
53
|
-
editDepartmentButton: Button;
|
|
54
54
|
departmentTableConfig: TableConfig;
|
|
55
55
|
contactPersonFormConfig: FormConfig;
|
|
56
56
|
contactPersonTableConfig: TableConfig;
|
|
57
57
|
customerFormConfig: FormConfig;
|
|
58
|
+
customerEditButton: Button;
|
|
58
59
|
customerDetailsConfig: DetailsDialogConfig;
|
|
59
60
|
customersTableConfig: TableConfig;
|
|
60
61
|
supplierFormConfig: FormConfig;
|
|
62
|
+
supplierEditButton: Button;
|
|
61
63
|
supplierDetailsConfig: DetailsDialogConfig;
|
|
62
64
|
suppliersTableConfig: TableConfig;
|
|
63
65
|
private listCache;
|
|
@@ -66,6 +68,7 @@ export declare class DataServiceLib {
|
|
|
66
68
|
CallApi(action: Action, data?: any): Observable<any>;
|
|
67
69
|
private handleListCall;
|
|
68
70
|
invalidateListCache(entityUrl: string): void;
|
|
71
|
+
ClearCache(): void;
|
|
69
72
|
CheckWelcomed(path?: string): void;
|
|
70
73
|
Navigate(path: string): void;
|
|
71
74
|
NavigateWithValue(path: string, value: string): void;
|