fantasy-ngzorro 1.3.29 → 1.3.31
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/bundles/fantasy-ngzorro.umd.js +6049 -6035
- package/bundles/fantasy-ngzorro.umd.js.map +1 -1
- package/bundles/fantasy-ngzorro.umd.min.js +1 -1
- package/bundles/fantasy-ngzorro.umd.min.js.map +1 -1
- package/esm2015/fantasy-ngzorro.js +39 -39
- package/esm2015/fantasy-ngzorro.module.js +18 -18
- package/esm2015/hd-button/hd-button.component.js +91 -91
- package/esm2015/hd-button/hd-button.module.js +22 -22
- package/esm2015/hd-button/hd-button.service.js +36 -36
- package/esm2015/hd-button-group/hd-button-group.component.js +32 -32
- package/esm2015/hd-button-group/hd-button-group.module.js +22 -22
- package/esm2015/hd-component.module.js +44 -44
- package/esm2015/hd-current-table/hd-current-table.component.js +224 -224
- package/esm2015/hd-current-table/hd-current-table.module.js +23 -23
- package/esm2015/hd-current-table/hd-current-table.service.js +34 -34
- package/esm2015/hd-detail-form/hd-detail-form.component.js +64 -64
- package/esm2015/hd-detail-form/hd-detail-form.module.js +20 -20
- package/esm2015/hd-detail-form/hd-detail-form.service.js +17 -17
- package/esm2015/hd-detail-lines/hd-detail-lines.component.js +266 -266
- package/esm2015/hd-detail-lines/hd-detail-lines.module.js +23 -23
- package/esm2015/hd-detail-lines/hd-detail-lines.service.js +18 -18
- package/esm2015/hd-detail-tip/hd-detail-tip.component.js +61 -61
- package/esm2015/hd-detail-tip/hd-detail-tip.module.js +22 -22
- package/esm2015/hd-filter/hd-filter.component.js +193 -193
- package/esm2015/hd-filter/hd-filter.module.js +25 -25
- package/esm2015/hd-filter/hd-filter.service.js +80 -70
- package/esm2015/hd-form/hd-form.component.js +369 -369
- package/esm2015/hd-form/hd-form.module.js +25 -25
- package/esm2015/hd-form/hd-form.service.js +129 -129
- package/esm2015/hd-form-lines/hd-form-lines.component.js +1537 -1537
- package/esm2015/hd-form-lines/hd-form-lines.module.js +29 -29
- package/esm2015/hd-form-lines/hd-form-lines.service.js +121 -121
- package/esm2015/hd-log/hd-log.component.js +30 -30
- package/esm2015/hd-log/hd-log.module.js +25 -25
- package/esm2015/hd-log/hd-log.service.js +47 -47
- package/esm2015/hd-popconfirm/hd-popconfirm.component.js +52 -52
- package/esm2015/hd-popconfirm/hd-popconfirm.module.js +27 -27
- package/esm2015/hd-space/hd-space.component.js +51 -51
- package/esm2015/hd-space/hd-space.module.js +23 -23
- package/esm2015/hd-space/hd-space.service.js +33 -33
- package/esm2015/hd-status/hd-status.component.js +50 -50
- package/esm2015/hd-status/hd-status.module.js +27 -27
- package/esm2015/hd-status/hd-status.service.js +33 -33
- package/esm2015/hd-table/hd-table.component.js +972 -972
- package/esm2015/hd-table/hd-table.module.js +43 -43
- package/esm2015/hd-table/hd-table.service.js +116 -116
- package/esm2015/hd-tip/hd-tip.component.js +37 -37
- package/esm2015/hd-tip/hd-tip.module.js +20 -20
- package/esm2015/index.js +7 -7
- package/esm2015/model/colWidth.js +36 -36
- package/esm2015/model/common-type.js +122 -122
- package/esm2015/model/staticConst.js +8 -8
- package/esm2015/public-api.js +20 -20
- package/esm2015/service/common-session.service.js +37 -37
- package/esm2015/utils.js +128 -128
- package/esm5/fantasy-ngzorro.js +39 -39
- package/esm5/fantasy-ngzorro.module.js +22 -22
- package/esm5/hd-button/hd-button.component.js +104 -104
- package/esm5/hd-button/hd-button.module.js +26 -26
- package/esm5/hd-button/hd-button.service.js +39 -39
- package/esm5/hd-button-group/hd-button-group.component.js +38 -38
- package/esm5/hd-button-group/hd-button-group.module.js +26 -26
- package/esm5/hd-component.module.js +48 -48
- package/esm5/hd-current-table/hd-current-table.component.js +260 -260
- package/esm5/hd-current-table/hd-current-table.module.js +27 -27
- package/esm5/hd-current-table/hd-current-table.service.js +46 -46
- package/esm5/hd-detail-form/hd-detail-form.component.js +77 -77
- package/esm5/hd-detail-form/hd-detail-form.module.js +24 -24
- package/esm5/hd-detail-form/hd-detail-form.service.js +20 -20
- package/esm5/hd-detail-lines/hd-detail-lines.component.js +314 -314
- package/esm5/hd-detail-lines/hd-detail-lines.module.js +27 -27
- package/esm5/hd-detail-lines/hd-detail-lines.service.js +22 -22
- package/esm5/hd-detail-tip/hd-detail-tip.component.js +72 -72
- package/esm5/hd-detail-tip/hd-detail-tip.module.js +26 -26
- package/esm5/hd-filter/hd-filter.component.js +232 -232
- package/esm5/hd-filter/hd-filter.module.js +29 -29
- package/esm5/hd-filter/hd-filter.service.js +92 -78
- package/esm5/hd-form/hd-form.component.js +424 -424
- package/esm5/hd-form/hd-form.module.js +29 -29
- package/esm5/hd-form/hd-form.service.js +141 -141
- package/esm5/hd-form-lines/hd-form-lines.component.js +1844 -1844
- package/esm5/hd-form-lines/hd-form-lines.module.js +33 -33
- package/esm5/hd-form-lines/hd-form-lines.service.js +137 -137
- package/esm5/hd-log/hd-log.component.js +35 -35
- package/esm5/hd-log/hd-log.module.js +29 -29
- package/esm5/hd-log/hd-log.service.js +50 -50
- package/esm5/hd-popconfirm/hd-popconfirm.component.js +65 -65
- package/esm5/hd-popconfirm/hd-popconfirm.module.js +31 -31
- package/esm5/hd-space/hd-space.component.js +56 -56
- package/esm5/hd-space/hd-space.module.js +27 -27
- package/esm5/hd-space/hd-space.service.js +40 -40
- package/esm5/hd-status/hd-status.component.js +62 -62
- package/esm5/hd-status/hd-status.module.js +31 -31
- package/esm5/hd-status/hd-status.service.js +35 -35
- package/esm5/hd-table/hd-table.component.js +1100 -1100
- package/esm5/hd-table/hd-table.module.js +47 -47
- package/esm5/hd-table/hd-table.service.js +136 -136
- package/esm5/hd-tip/hd-tip.component.js +42 -42
- package/esm5/hd-tip/hd-tip.module.js +24 -24
- package/esm5/index.js +7 -7
- package/esm5/model/colWidth.js +36 -36
- package/esm5/model/common-type.js +146 -146
- package/esm5/model/staticConst.js +8 -8
- package/esm5/public-api.js +20 -20
- package/esm5/service/common-session.service.js +54 -54
- package/esm5/utils.js +128 -128
- package/fantasy-ngzorro.d.ts +34 -34
- package/fantasy-ngzorro.metadata.json +1 -1
- package/fantasy-ngzorro.module.d.ts +2 -2
- package/fesm2015/fantasy-ngzorro.js +5234 -5224
- package/fesm2015/fantasy-ngzorro.js.map +1 -1
- package/fesm5/fantasy-ngzorro.js +6058 -6045
- package/fesm5/fantasy-ngzorro.js.map +1 -1
- package/hd-button/hd-button.component.d.ts +14 -14
- package/hd-button/hd-button.module.d.ts +2 -2
- package/hd-button/hd-button.service.d.ts +17 -17
- package/hd-button-group/hd-button-group.component.d.ts +7 -7
- package/hd-button-group/hd-button-group.module.d.ts +2 -2
- package/hd-component.module.d.ts +2 -2
- package/hd-current-table/hd-current-table.component.d.ts +43 -43
- package/hd-current-table/hd-current-table.module.d.ts +2 -2
- package/hd-current-table/hd-current-table.service.d.ts +13 -13
- package/hd-detail-form/hd-detail-form.component.d.ts +9 -9
- package/hd-detail-form/hd-detail-form.module.d.ts +2 -2
- package/hd-detail-form/hd-detail-form.service.d.ts +3 -3
- package/hd-detail-lines/hd-detail-lines.component.d.ts +48 -48
- package/hd-detail-lines/hd-detail-lines.module.d.ts +2 -2
- package/hd-detail-lines/hd-detail-lines.service.d.ts +7 -7
- package/hd-detail-tip/hd-detail-tip.component.d.ts +12 -12
- package/hd-detail-tip/hd-detail-tip.module.d.ts +2 -2
- package/hd-filter/hd-filter.component.d.ts +23 -23
- package/hd-filter/hd-filter.module.d.ts +2 -2
- package/hd-filter/hd-filter.service.d.ts +30 -25
- package/hd-form/hd-form.component.d.ts +25 -25
- package/hd-form/hd-form.module.d.ts +2 -2
- package/hd-form/hd-form.service.d.ts +51 -51
- package/hd-form-lines/hd-form-lines.component.d.ts +147 -147
- package/hd-form-lines/hd-form-lines.module.d.ts +2 -2
- package/hd-form-lines/hd-form-lines.service.d.ts +53 -53
- package/hd-log/hd-log.component.d.ts +6 -6
- package/hd-log/hd-log.module.d.ts +2 -2
- package/hd-log/hd-log.service.d.ts +6 -6
- package/hd-popconfirm/hd-popconfirm.component.d.ts +10 -10
- package/hd-popconfirm/hd-popconfirm.module.d.ts +2 -2
- package/hd-space/hd-space.component.d.ts +10 -10
- package/hd-space/hd-space.module.d.ts +2 -2
- package/hd-space/hd-space.service.d.ts +12 -12
- package/hd-status/hd-status.component.d.ts +9 -9
- package/hd-status/hd-status.module.d.ts +2 -2
- package/hd-status/hd-status.service.d.ts +11 -11
- package/hd-table/hd-table.component.d.ts +91 -91
- package/hd-table/hd-table.module.d.ts +2 -2
- package/hd-table/hd-table.service.d.ts +42 -42
- package/hd-tip/hd-tip.component.d.ts +8 -8
- package/hd-tip/hd-tip.module.d.ts +2 -2
- package/index.d.ts +2 -2
- package/model/colWidth.d.ts +17 -17
- package/model/common-type.d.ts +46 -46
- package/model/staticConst.d.ts +3 -3
- package/package.json +1 -1
- package/public-api.d.ts +15 -15
- package/service/common-session.service.d.ts +5 -5
- package/utils.d.ts +28 -28
|
@@ -1,51 +1,51 @@
|
|
|
1
|
-
import { ValidatorFn } from '@angular/forms';
|
|
2
|
-
import { InputNumber, SelectOption } from '../model/common-type';
|
|
3
|
-
export declare class FormItem {
|
|
4
|
-
type: FormListType;
|
|
5
|
-
label: string;
|
|
6
|
-
name: string;
|
|
7
|
-
require?: boolean;
|
|
8
|
-
placeholder?: string;
|
|
9
|
-
width?: number;
|
|
10
|
-
hide?: boolean;
|
|
11
|
-
totalWidth?: number;
|
|
12
|
-
isRowFirst?: number;
|
|
13
|
-
columnItems?: Array<any>;
|
|
14
|
-
value?: string | boolean | number | Date | Array<string | Date> | null;
|
|
15
|
-
disabled?: boolean;
|
|
16
|
-
color?: string;
|
|
17
|
-
maxLength?: number;
|
|
18
|
-
selectOption?: SelectOption;
|
|
19
|
-
inputNumber?: InputNumber;
|
|
20
|
-
onChangeEvent?: Function;
|
|
21
|
-
onSearchEvent?: Function;
|
|
22
|
-
defaultLabel?: string | Array<string>;
|
|
23
|
-
hdDisabledDate?: Function;
|
|
24
|
-
explain?: string;
|
|
25
|
-
textAreaRows?: number;
|
|
26
|
-
showTime?: boolean;
|
|
27
|
-
labelColor?: string;
|
|
28
|
-
validatorKeys?: Array<ValidatorKey>;
|
|
29
|
-
validator?: ValidatorFn;
|
|
30
|
-
onChangeEventDebounceTime?: number;
|
|
31
|
-
onSearchEventEventDebounceTime?: number;
|
|
32
|
-
}
|
|
33
|
-
export declare class ValidatorKey {
|
|
34
|
-
key: string;
|
|
35
|
-
label: string;
|
|
36
|
-
}
|
|
37
|
-
export declare enum FormListType {
|
|
38
|
-
Input = 0,
|
|
39
|
-
Select = 1,
|
|
40
|
-
Date = 2,
|
|
41
|
-
DateRange = 3,
|
|
42
|
-
TextArea = 4,
|
|
43
|
-
InputNumber = 5,
|
|
44
|
-
MultipleSelect = 6,
|
|
45
|
-
ViewDom = 7,
|
|
46
|
-
Switch = 8,
|
|
47
|
-
Time = 9
|
|
48
|
-
}
|
|
49
|
-
export declare class HdFormService {
|
|
50
|
-
constructor();
|
|
51
|
-
}
|
|
1
|
+
import { ValidatorFn } from '@angular/forms';
|
|
2
|
+
import { InputNumber, SelectOption } from '../model/common-type';
|
|
3
|
+
export declare class FormItem {
|
|
4
|
+
type: FormListType;
|
|
5
|
+
label: string;
|
|
6
|
+
name: string;
|
|
7
|
+
require?: boolean;
|
|
8
|
+
placeholder?: string;
|
|
9
|
+
width?: number;
|
|
10
|
+
hide?: boolean;
|
|
11
|
+
totalWidth?: number;
|
|
12
|
+
isRowFirst?: number;
|
|
13
|
+
columnItems?: Array<any>;
|
|
14
|
+
value?: string | boolean | number | Date | Array<string | Date> | null;
|
|
15
|
+
disabled?: boolean;
|
|
16
|
+
color?: string;
|
|
17
|
+
maxLength?: number;
|
|
18
|
+
selectOption?: SelectOption;
|
|
19
|
+
inputNumber?: InputNumber;
|
|
20
|
+
onChangeEvent?: Function;
|
|
21
|
+
onSearchEvent?: Function;
|
|
22
|
+
defaultLabel?: string | Array<string>;
|
|
23
|
+
hdDisabledDate?: Function;
|
|
24
|
+
explain?: string;
|
|
25
|
+
textAreaRows?: number;
|
|
26
|
+
showTime?: boolean;
|
|
27
|
+
labelColor?: string;
|
|
28
|
+
validatorKeys?: Array<ValidatorKey>;
|
|
29
|
+
validator?: ValidatorFn;
|
|
30
|
+
onChangeEventDebounceTime?: number;
|
|
31
|
+
onSearchEventEventDebounceTime?: number;
|
|
32
|
+
}
|
|
33
|
+
export declare class ValidatorKey {
|
|
34
|
+
key: string;
|
|
35
|
+
label: string;
|
|
36
|
+
}
|
|
37
|
+
export declare enum FormListType {
|
|
38
|
+
Input = 0,
|
|
39
|
+
Select = 1,
|
|
40
|
+
Date = 2,
|
|
41
|
+
DateRange = 3,
|
|
42
|
+
TextArea = 4,
|
|
43
|
+
InputNumber = 5,
|
|
44
|
+
MultipleSelect = 6,
|
|
45
|
+
ViewDom = 7,
|
|
46
|
+
Switch = 8,
|
|
47
|
+
Time = 9
|
|
48
|
+
}
|
|
49
|
+
export declare class HdFormService {
|
|
50
|
+
constructor();
|
|
51
|
+
}
|
|
@@ -1,147 +1,147 @@
|
|
|
1
|
-
import { ChangeDetectorRef, ElementRef, EventEmitter, OnInit, QueryList, SimpleChanges, TemplateRef } from '@angular/core';
|
|
2
|
-
import { FormBuilder, FormGroup } from '@angular/forms';
|
|
3
|
-
import { NzDatePickerComponent, NzInputNumberComponent, NzRangePickerComponent, NzSelectComponent, NzTimePickerComponent } from 'ng-zorro-antd';
|
|
4
|
-
import { TotalOption } from '../hd-detail-lines/hd-detail-lines.service';
|
|
5
|
-
import { FormLine } from './hd-form-lines.service';
|
|
6
|
-
export declare class HdFormLinesComponent implements OnInit {
|
|
7
|
-
private fb;
|
|
8
|
-
private cdr;
|
|
9
|
-
formInputDomList: QueryList<ElementRef>;
|
|
10
|
-
showLineNumber: boolean;
|
|
11
|
-
allowEmpty: boolean;
|
|
12
|
-
deleteLastLineEvent: EventEmitter<{}>;
|
|
13
|
-
showKeyboardOperateTip: boolean;
|
|
14
|
-
tableLoading: boolean;
|
|
15
|
-
showSearch: boolean;
|
|
16
|
-
formLines: Array<FormLine>;
|
|
17
|
-
formLinesData: any;
|
|
18
|
-
operateButtons: Array<string>;
|
|
19
|
-
scroll: {
|
|
20
|
-
[key: string]: string;
|
|
21
|
-
};
|
|
22
|
-
changeEvent: EventEmitter<{}>;
|
|
23
|
-
showDeleteConfirm: boolean;
|
|
24
|
-
paginationPageIndex: number;
|
|
25
|
-
paginationPageSize: number;
|
|
26
|
-
validateHdFormLines: FormGroup;
|
|
27
|
-
newLine: any;
|
|
28
|
-
inputValue: string;
|
|
29
|
-
showTotal: boolean;
|
|
30
|
-
totalOption: Array<TotalOption>;
|
|
31
|
-
columnsNumber: number | string;
|
|
32
|
-
totalOptionList: any[];
|
|
33
|
-
showForm: boolean;
|
|
34
|
-
filterStr: string;
|
|
35
|
-
storeFormLinesData: any;
|
|
36
|
-
filterStoreFormLinesData: any;
|
|
37
|
-
filterIndexStore: Array<number>;
|
|
38
|
-
isFilterData: boolean;
|
|
39
|
-
formValid: boolean;
|
|
40
|
-
private searchSubject;
|
|
41
|
-
private debounceTimeout;
|
|
42
|
-
private searchSubscription;
|
|
43
|
-
collectDomList: Array<Array<ElementRef | NzSelectComponent | NzInputNumberComponent | NzDatePickerComponent | NzRangePickerComponent | NzTimePickerComponent>>;
|
|
44
|
-
activeDomX: number;
|
|
45
|
-
activeDomY: number;
|
|
46
|
-
activeDom: ElementRef | NzSelectComponent | NzInputNumberComponent | NzDatePickerComponent | NzRangePickerComponent | NzTimePickerComponent;
|
|
47
|
-
activeSelectedComponentOpen: boolean;
|
|
48
|
-
ViewDomRightTemplate: TemplateRef<any>;
|
|
49
|
-
constructor(fb: FormBuilder, cdr: ChangeDetectorRef);
|
|
50
|
-
ngOnInit(): void;
|
|
51
|
-
ngAfterViewInit(): void;
|
|
52
|
-
readonly formLinesLength: any;
|
|
53
|
-
setActiveSelectedComponentOpen(value: boolean): void;
|
|
54
|
-
createDOMStructure(formItem: any, line: any): HTMLDivElement;
|
|
55
|
-
collectDomData(): void;
|
|
56
|
-
jumpToNextInput(x: number, y: number): void;
|
|
57
|
-
/**
|
|
58
|
-
* 增加新行并且聚焦到第一个元素,
|
|
59
|
-
* 这里要注意,如果存在翻页情况,需要处理
|
|
60
|
-
*/
|
|
61
|
-
addNewLineAndFocus(): void;
|
|
62
|
-
jumpToPrevInput(x: number, y: number): void;
|
|
63
|
-
/**
|
|
64
|
-
* 聚焦到某个dom
|
|
65
|
-
* @param x 坐标x
|
|
66
|
-
* @param y 坐标y
|
|
67
|
-
* @param jumpDirection 跳转方向
|
|
68
|
-
*/
|
|
69
|
-
focusDom(x: number, y: number, jumpDirection?: string): void;
|
|
70
|
-
cleanFocusDom(x: number, y: number): void;
|
|
71
|
-
setActiveDom(x: number, y: number): void;
|
|
72
|
-
/**
|
|
73
|
-
* 根据行号和列号名称获取当前聚焦的dom位置
|
|
74
|
-
* @param rowNumber 行号
|
|
75
|
-
* @param colNumber 列号
|
|
76
|
-
*/
|
|
77
|
-
setActiveDomInFormLines(rowNumber: number, colNumber: number): void;
|
|
78
|
-
/**
|
|
79
|
-
* 键盘点击事件
|
|
80
|
-
* @param event 键盘事件
|
|
81
|
-
* @returns
|
|
82
|
-
*/
|
|
83
|
-
onKeyDown(event: KeyboardEvent): void;
|
|
84
|
-
/**
|
|
85
|
-
* 根据在初始dom下标和数据集 获取在collectDomList中的下标
|
|
86
|
-
* @param index 初始下标
|
|
87
|
-
* @param list 老数据集
|
|
88
|
-
* @returns
|
|
89
|
-
*/
|
|
90
|
-
private getDomIndex;
|
|
91
|
-
/**
|
|
92
|
-
* 根据在collectDomList中的下标和数据集 获取初始dom下标
|
|
93
|
-
* @param index 新下标
|
|
94
|
-
* @param list 老数据集
|
|
95
|
-
* @returns
|
|
96
|
-
*/
|
|
97
|
-
private getOldDomIndex;
|
|
98
|
-
readonly linesFormArray: any;
|
|
99
|
-
readonly LodashRound: any;
|
|
100
|
-
getValid(): boolean;
|
|
101
|
-
onSearchEvent(fn: any, event: any, line: any, onSearchEventDebounceTime: any): void;
|
|
102
|
-
/**
|
|
103
|
-
*
|
|
104
|
-
* @param fn 父组件函数
|
|
105
|
-
* @param event 事件值
|
|
106
|
-
* @param line 触发的行
|
|
107
|
-
*/
|
|
108
|
-
triggerEvent(fn: any, event: any, line: any): void;
|
|
109
|
-
innerGetValid(): boolean;
|
|
110
|
-
getLines(): any[];
|
|
111
|
-
searchLines(): void;
|
|
112
|
-
setStoreData(): void;
|
|
113
|
-
getStyle(line: FormGroup, formItem: any, width: string): {
|
|
114
|
-
'min-width': string;
|
|
115
|
-
};
|
|
116
|
-
ngOnChanges(changes: SimpleChanges): void;
|
|
117
|
-
calculateTotal(): void;
|
|
118
|
-
private init;
|
|
119
|
-
/**
|
|
120
|
-
* 创建表单
|
|
121
|
-
*/
|
|
122
|
-
private createForm;
|
|
123
|
-
delayJumpToNextInput(): void;
|
|
124
|
-
/**
|
|
125
|
-
* 定义空的newLineItem 结构
|
|
126
|
-
*/
|
|
127
|
-
private newLineItem;
|
|
128
|
-
private calculateLineNumber;
|
|
129
|
-
/**
|
|
130
|
-
* 编辑的时候数据处理
|
|
131
|
-
*/
|
|
132
|
-
addFormLineWithData(): void;
|
|
133
|
-
addFormLine(index?: any, isFocus?: boolean): void;
|
|
134
|
-
deleteLineEvent: EventEmitter<{}>;
|
|
135
|
-
deleteFormLine(index: any): void;
|
|
136
|
-
pageIndexChange(event: number): void;
|
|
137
|
-
pageSizeChange(event: number): void;
|
|
138
|
-
private onHdFormValueChanged;
|
|
139
|
-
private checkList;
|
|
140
|
-
submitForm(): void;
|
|
141
|
-
resetForm(): void;
|
|
142
|
-
inputClean(formItem: any, line: any): void;
|
|
143
|
-
selectValue(id: string, rowNumber: number, colNumber: number): void;
|
|
144
|
-
private textWidthCache;
|
|
145
|
-
isTextOverflow(text: string, maxWidth: number): boolean;
|
|
146
|
-
judgeColEmpty(str: any): any;
|
|
147
|
-
}
|
|
1
|
+
import { ChangeDetectorRef, ElementRef, EventEmitter, OnInit, QueryList, SimpleChanges, TemplateRef } from '@angular/core';
|
|
2
|
+
import { FormBuilder, FormGroup } from '@angular/forms';
|
|
3
|
+
import { NzDatePickerComponent, NzInputNumberComponent, NzRangePickerComponent, NzSelectComponent, NzTimePickerComponent } from 'ng-zorro-antd';
|
|
4
|
+
import { TotalOption } from '../hd-detail-lines/hd-detail-lines.service';
|
|
5
|
+
import { FormLine } from './hd-form-lines.service';
|
|
6
|
+
export declare class HdFormLinesComponent implements OnInit {
|
|
7
|
+
private fb;
|
|
8
|
+
private cdr;
|
|
9
|
+
formInputDomList: QueryList<ElementRef>;
|
|
10
|
+
showLineNumber: boolean;
|
|
11
|
+
allowEmpty: boolean;
|
|
12
|
+
deleteLastLineEvent: EventEmitter<{}>;
|
|
13
|
+
showKeyboardOperateTip: boolean;
|
|
14
|
+
tableLoading: boolean;
|
|
15
|
+
showSearch: boolean;
|
|
16
|
+
formLines: Array<FormLine>;
|
|
17
|
+
formLinesData: any;
|
|
18
|
+
operateButtons: Array<string>;
|
|
19
|
+
scroll: {
|
|
20
|
+
[key: string]: string;
|
|
21
|
+
};
|
|
22
|
+
changeEvent: EventEmitter<{}>;
|
|
23
|
+
showDeleteConfirm: boolean;
|
|
24
|
+
paginationPageIndex: number;
|
|
25
|
+
paginationPageSize: number;
|
|
26
|
+
validateHdFormLines: FormGroup;
|
|
27
|
+
newLine: any;
|
|
28
|
+
inputValue: string;
|
|
29
|
+
showTotal: boolean;
|
|
30
|
+
totalOption: Array<TotalOption>;
|
|
31
|
+
columnsNumber: number | string;
|
|
32
|
+
totalOptionList: any[];
|
|
33
|
+
showForm: boolean;
|
|
34
|
+
filterStr: string;
|
|
35
|
+
storeFormLinesData: any;
|
|
36
|
+
filterStoreFormLinesData: any;
|
|
37
|
+
filterIndexStore: Array<number>;
|
|
38
|
+
isFilterData: boolean;
|
|
39
|
+
formValid: boolean;
|
|
40
|
+
private searchSubject;
|
|
41
|
+
private debounceTimeout;
|
|
42
|
+
private searchSubscription;
|
|
43
|
+
collectDomList: Array<Array<ElementRef | NzSelectComponent | NzInputNumberComponent | NzDatePickerComponent | NzRangePickerComponent | NzTimePickerComponent>>;
|
|
44
|
+
activeDomX: number;
|
|
45
|
+
activeDomY: number;
|
|
46
|
+
activeDom: ElementRef | NzSelectComponent | NzInputNumberComponent | NzDatePickerComponent | NzRangePickerComponent | NzTimePickerComponent;
|
|
47
|
+
activeSelectedComponentOpen: boolean;
|
|
48
|
+
ViewDomRightTemplate: TemplateRef<any>;
|
|
49
|
+
constructor(fb: FormBuilder, cdr: ChangeDetectorRef);
|
|
50
|
+
ngOnInit(): void;
|
|
51
|
+
ngAfterViewInit(): void;
|
|
52
|
+
readonly formLinesLength: any;
|
|
53
|
+
setActiveSelectedComponentOpen(value: boolean): void;
|
|
54
|
+
createDOMStructure(formItem: any, line: any): HTMLDivElement;
|
|
55
|
+
collectDomData(): void;
|
|
56
|
+
jumpToNextInput(x: number, y: number): void;
|
|
57
|
+
/**
|
|
58
|
+
* 增加新行并且聚焦到第一个元素,
|
|
59
|
+
* 这里要注意,如果存在翻页情况,需要处理
|
|
60
|
+
*/
|
|
61
|
+
addNewLineAndFocus(): void;
|
|
62
|
+
jumpToPrevInput(x: number, y: number): void;
|
|
63
|
+
/**
|
|
64
|
+
* 聚焦到某个dom
|
|
65
|
+
* @param x 坐标x
|
|
66
|
+
* @param y 坐标y
|
|
67
|
+
* @param jumpDirection 跳转方向
|
|
68
|
+
*/
|
|
69
|
+
focusDom(x: number, y: number, jumpDirection?: string): void;
|
|
70
|
+
cleanFocusDom(x: number, y: number): void;
|
|
71
|
+
setActiveDom(x: number, y: number): void;
|
|
72
|
+
/**
|
|
73
|
+
* 根据行号和列号名称获取当前聚焦的dom位置
|
|
74
|
+
* @param rowNumber 行号
|
|
75
|
+
* @param colNumber 列号
|
|
76
|
+
*/
|
|
77
|
+
setActiveDomInFormLines(rowNumber: number, colNumber: number): void;
|
|
78
|
+
/**
|
|
79
|
+
* 键盘点击事件
|
|
80
|
+
* @param event 键盘事件
|
|
81
|
+
* @returns
|
|
82
|
+
*/
|
|
83
|
+
onKeyDown(event: KeyboardEvent): void;
|
|
84
|
+
/**
|
|
85
|
+
* 根据在初始dom下标和数据集 获取在collectDomList中的下标
|
|
86
|
+
* @param index 初始下标
|
|
87
|
+
* @param list 老数据集
|
|
88
|
+
* @returns
|
|
89
|
+
*/
|
|
90
|
+
private getDomIndex;
|
|
91
|
+
/**
|
|
92
|
+
* 根据在collectDomList中的下标和数据集 获取初始dom下标
|
|
93
|
+
* @param index 新下标
|
|
94
|
+
* @param list 老数据集
|
|
95
|
+
* @returns
|
|
96
|
+
*/
|
|
97
|
+
private getOldDomIndex;
|
|
98
|
+
readonly linesFormArray: any;
|
|
99
|
+
readonly LodashRound: any;
|
|
100
|
+
getValid(): boolean;
|
|
101
|
+
onSearchEvent(fn: any, event: any, line: any, onSearchEventDebounceTime: any): void;
|
|
102
|
+
/**
|
|
103
|
+
*
|
|
104
|
+
* @param fn 父组件函数
|
|
105
|
+
* @param event 事件值
|
|
106
|
+
* @param line 触发的行
|
|
107
|
+
*/
|
|
108
|
+
triggerEvent(fn: any, event: any, line: any): void;
|
|
109
|
+
innerGetValid(): boolean;
|
|
110
|
+
getLines(): any[];
|
|
111
|
+
searchLines(): void;
|
|
112
|
+
setStoreData(): void;
|
|
113
|
+
getStyle(line: FormGroup, formItem: any, width: string): {
|
|
114
|
+
'min-width': string;
|
|
115
|
+
};
|
|
116
|
+
ngOnChanges(changes: SimpleChanges): void;
|
|
117
|
+
calculateTotal(): void;
|
|
118
|
+
private init;
|
|
119
|
+
/**
|
|
120
|
+
* 创建表单
|
|
121
|
+
*/
|
|
122
|
+
private createForm;
|
|
123
|
+
delayJumpToNextInput(): void;
|
|
124
|
+
/**
|
|
125
|
+
* 定义空的newLineItem 结构
|
|
126
|
+
*/
|
|
127
|
+
private newLineItem;
|
|
128
|
+
private calculateLineNumber;
|
|
129
|
+
/**
|
|
130
|
+
* 编辑的时候数据处理
|
|
131
|
+
*/
|
|
132
|
+
addFormLineWithData(): void;
|
|
133
|
+
addFormLine(index?: any, isFocus?: boolean): void;
|
|
134
|
+
deleteLineEvent: EventEmitter<{}>;
|
|
135
|
+
deleteFormLine(index: any): void;
|
|
136
|
+
pageIndexChange(event: number): void;
|
|
137
|
+
pageSizeChange(event: number): void;
|
|
138
|
+
private onHdFormValueChanged;
|
|
139
|
+
private checkList;
|
|
140
|
+
submitForm(): void;
|
|
141
|
+
resetForm(): void;
|
|
142
|
+
inputClean(formItem: any, line: any): void;
|
|
143
|
+
selectValue(id: string, rowNumber: number, colNumber: number): void;
|
|
144
|
+
private textWidthCache;
|
|
145
|
+
isTextOverflow(text: string, maxWidth: number): boolean;
|
|
146
|
+
judgeColEmpty(str: any): any;
|
|
147
|
+
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare class HdFormLinesModule {
|
|
2
|
-
}
|
|
1
|
+
export declare class HdFormLinesModule {
|
|
2
|
+
}
|
|
@@ -1,53 +1,53 @@
|
|
|
1
|
-
import { InputNumber, SelectOption } from '../model/common-type';
|
|
2
|
-
export declare class FormLine {
|
|
3
|
-
type: FormLineType;
|
|
4
|
-
label: string;
|
|
5
|
-
name: string;
|
|
6
|
-
placeholder?: string;
|
|
7
|
-
require?: boolean;
|
|
8
|
-
hide?: boolean;
|
|
9
|
-
align?: 'left' | 'right' | 'center';
|
|
10
|
-
value?: string | boolean | number | Date | Array<string | Date> | null;
|
|
11
|
-
isSelect?: boolean;
|
|
12
|
-
selectOption?: SelectOption;
|
|
13
|
-
explainOptionRight?: ExplainOption;
|
|
14
|
-
explainOption?: ExplainOption;
|
|
15
|
-
colorOption?: ColorOption;
|
|
16
|
-
maxLength?: number;
|
|
17
|
-
preserveNumber?: number;
|
|
18
|
-
inputNumber?: InputNumber;
|
|
19
|
-
onChangeEvent?: Function;
|
|
20
|
-
onSearchEvent?: Function;
|
|
21
|
-
defaultLabel?: any;
|
|
22
|
-
hdDisabledDate?: Function;
|
|
23
|
-
disabled?: boolean;
|
|
24
|
-
showTime?: boolean;
|
|
25
|
-
style?: object;
|
|
26
|
-
canSearch?: boolean;
|
|
27
|
-
onChangeEventDebounceTime?: number;
|
|
28
|
-
onSearchEventEventDebounceTime?: number;
|
|
29
|
-
}
|
|
30
|
-
export declare class ColorOption {
|
|
31
|
-
name: string;
|
|
32
|
-
color?: string;
|
|
33
|
-
}
|
|
34
|
-
export declare class ExplainOption {
|
|
35
|
-
show: boolean;
|
|
36
|
-
name: string;
|
|
37
|
-
color?: string;
|
|
38
|
-
}
|
|
39
|
-
export declare enum FormLineType {
|
|
40
|
-
Input = "Input",
|
|
41
|
-
Select = "Select",
|
|
42
|
-
Date = "Date",
|
|
43
|
-
DateRange = "DateRange",
|
|
44
|
-
TextArea = "TextArea",
|
|
45
|
-
InputNumber = "InputNumber",
|
|
46
|
-
MultipleSelect = "MultipleSelect",
|
|
47
|
-
ViewDom = "ViewDom",
|
|
48
|
-
Switch = "Switch",
|
|
49
|
-
Time = "Time"
|
|
50
|
-
}
|
|
51
|
-
export declare class HdFormLinesService {
|
|
52
|
-
constructor();
|
|
53
|
-
}
|
|
1
|
+
import { InputNumber, SelectOption } from '../model/common-type';
|
|
2
|
+
export declare class FormLine {
|
|
3
|
+
type: FormLineType;
|
|
4
|
+
label: string;
|
|
5
|
+
name: string;
|
|
6
|
+
placeholder?: string;
|
|
7
|
+
require?: boolean;
|
|
8
|
+
hide?: boolean;
|
|
9
|
+
align?: 'left' | 'right' | 'center';
|
|
10
|
+
value?: string | boolean | number | Date | Array<string | Date> | null;
|
|
11
|
+
isSelect?: boolean;
|
|
12
|
+
selectOption?: SelectOption;
|
|
13
|
+
explainOptionRight?: ExplainOption;
|
|
14
|
+
explainOption?: ExplainOption;
|
|
15
|
+
colorOption?: ColorOption;
|
|
16
|
+
maxLength?: number;
|
|
17
|
+
preserveNumber?: number;
|
|
18
|
+
inputNumber?: InputNumber;
|
|
19
|
+
onChangeEvent?: Function;
|
|
20
|
+
onSearchEvent?: Function;
|
|
21
|
+
defaultLabel?: any;
|
|
22
|
+
hdDisabledDate?: Function;
|
|
23
|
+
disabled?: boolean;
|
|
24
|
+
showTime?: boolean;
|
|
25
|
+
style?: object;
|
|
26
|
+
canSearch?: boolean;
|
|
27
|
+
onChangeEventDebounceTime?: number;
|
|
28
|
+
onSearchEventEventDebounceTime?: number;
|
|
29
|
+
}
|
|
30
|
+
export declare class ColorOption {
|
|
31
|
+
name: string;
|
|
32
|
+
color?: string;
|
|
33
|
+
}
|
|
34
|
+
export declare class ExplainOption {
|
|
35
|
+
show: boolean;
|
|
36
|
+
name: string;
|
|
37
|
+
color?: string;
|
|
38
|
+
}
|
|
39
|
+
export declare enum FormLineType {
|
|
40
|
+
Input = "Input",
|
|
41
|
+
Select = "Select",
|
|
42
|
+
Date = "Date",
|
|
43
|
+
DateRange = "DateRange",
|
|
44
|
+
TextArea = "TextArea",
|
|
45
|
+
InputNumber = "InputNumber",
|
|
46
|
+
MultipleSelect = "MultipleSelect",
|
|
47
|
+
ViewDom = "ViewDom",
|
|
48
|
+
Switch = "Switch",
|
|
49
|
+
Time = "Time"
|
|
50
|
+
}
|
|
51
|
+
export declare class HdFormLinesService {
|
|
52
|
+
constructor();
|
|
53
|
+
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { OnInit } from '@angular/core';
|
|
2
|
-
export declare class HdLogComponent implements OnInit {
|
|
3
|
-
logs: any[];
|
|
4
|
-
constructor();
|
|
5
|
-
ngOnInit(): void;
|
|
6
|
-
}
|
|
1
|
+
import { OnInit } from '@angular/core';
|
|
2
|
+
export declare class HdLogComponent implements OnInit {
|
|
3
|
+
logs: any[];
|
|
4
|
+
constructor();
|
|
5
|
+
ngOnInit(): void;
|
|
6
|
+
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare class HdLogModule {
|
|
2
|
-
}
|
|
1
|
+
export declare class HdLogModule {
|
|
2
|
+
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { NzModalService } from 'ng-zorro-antd';
|
|
2
|
-
export declare class HdLogService {
|
|
3
|
-
private modalService;
|
|
4
|
-
constructor(modalService: NzModalService);
|
|
5
|
-
showLogs(logs: any[]): void;
|
|
6
|
-
}
|
|
1
|
+
import { NzModalService } from 'ng-zorro-antd';
|
|
2
|
+
export declare class HdLogService {
|
|
3
|
+
private modalService;
|
|
4
|
+
constructor(modalService: NzModalService);
|
|
5
|
+
showLogs(logs: any[]): void;
|
|
6
|
+
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { OnInit, EventEmitter } from '@angular/core';
|
|
2
|
-
export declare class HdPopconfirmComponent implements OnInit {
|
|
3
|
-
message: string;
|
|
4
|
-
confirmOption: EventEmitter<any>;
|
|
5
|
-
cancelOption: EventEmitter<any>;
|
|
6
|
-
constructor();
|
|
7
|
-
ngOnInit(): void;
|
|
8
|
-
cancel(e: any): void;
|
|
9
|
-
confirm(e: any): void;
|
|
10
|
-
}
|
|
1
|
+
import { OnInit, EventEmitter } from '@angular/core';
|
|
2
|
+
export declare class HdPopconfirmComponent implements OnInit {
|
|
3
|
+
message: string;
|
|
4
|
+
confirmOption: EventEmitter<any>;
|
|
5
|
+
cancelOption: EventEmitter<any>;
|
|
6
|
+
constructor();
|
|
7
|
+
ngOnInit(): void;
|
|
8
|
+
cancel(e: any): void;
|
|
9
|
+
confirm(e: any): void;
|
|
10
|
+
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare class HdPopconfirmModule {
|
|
2
|
-
}
|
|
1
|
+
export declare class HdPopconfirmModule {
|
|
2
|
+
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { OnInit } from '@angular/core';
|
|
2
|
-
import { Style, SpaceType } from "./hd-space.service";
|
|
3
|
-
export declare class HdSpaceComponent implements OnInit {
|
|
4
|
-
type: SpaceType;
|
|
5
|
-
size: number;
|
|
6
|
-
background: string;
|
|
7
|
-
style: Style;
|
|
8
|
-
constructor();
|
|
9
|
-
ngOnInit(): void;
|
|
10
|
-
}
|
|
1
|
+
import { OnInit } from '@angular/core';
|
|
2
|
+
import { Style, SpaceType } from "./hd-space.service";
|
|
3
|
+
export declare class HdSpaceComponent implements OnInit {
|
|
4
|
+
type: SpaceType;
|
|
5
|
+
size: number;
|
|
6
|
+
background: string;
|
|
7
|
+
style: Style;
|
|
8
|
+
constructor();
|
|
9
|
+
ngOnInit(): void;
|
|
10
|
+
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare class HdSpaceModule {
|
|
2
|
-
}
|
|
1
|
+
export declare class HdSpaceModule {
|
|
2
|
+
}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
export declare enum SpaceType {
|
|
2
|
-
row = "row",
|
|
3
|
-
column = "column"
|
|
4
|
-
}
|
|
5
|
-
export declare class Style {
|
|
6
|
-
background: string;
|
|
7
|
-
width: string;
|
|
8
|
-
height: string;
|
|
9
|
-
}
|
|
10
|
-
export declare class HdSpaceService {
|
|
11
|
-
constructor();
|
|
12
|
-
}
|
|
1
|
+
export declare enum SpaceType {
|
|
2
|
+
row = "row",
|
|
3
|
+
column = "column"
|
|
4
|
+
}
|
|
5
|
+
export declare class Style {
|
|
6
|
+
background: string;
|
|
7
|
+
width: string;
|
|
8
|
+
height: string;
|
|
9
|
+
}
|
|
10
|
+
export declare class HdSpaceService {
|
|
11
|
+
constructor();
|
|
12
|
+
}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { OnInit } from '@angular/core';
|
|
2
|
-
export declare class HdStatusComponent implements OnInit {
|
|
3
|
-
status: string;
|
|
4
|
-
statusColor: string;
|
|
5
|
-
constructor();
|
|
6
|
-
ngOnInit(): void;
|
|
7
|
-
ngOnChanges(): void;
|
|
8
|
-
setStatusColor(): void;
|
|
9
|
-
}
|
|
1
|
+
import { OnInit } from '@angular/core';
|
|
2
|
+
export declare class HdStatusComponent implements OnInit {
|
|
3
|
+
status: string;
|
|
4
|
+
statusColor: string;
|
|
5
|
+
constructor();
|
|
6
|
+
ngOnInit(): void;
|
|
7
|
+
ngOnChanges(): void;
|
|
8
|
+
setStatusColor(): void;
|
|
9
|
+
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare class HdStatusModule {
|
|
2
|
-
}
|
|
1
|
+
export declare class HdStatusModule {
|
|
2
|
+
}
|