@dignite-ng/expand.cms 3.1.5 → 3.1.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/esm2022/lib/cms.module.mjs +10 -3
- package/esm2022/lib/components/admin/entries/create-or-edit-entries.component.mjs +22 -3
- package/esm2022/lib/components/admin/entries/edit.component.mjs +6 -5
- package/esm2022/lib/components/admin/entries/entries.component.mjs +250 -27
- package/esm2022/lib/components/dynamic-form/entry/entry-control.component.mjs +74 -10
- package/esm2022/lib/components/dynamic-form/entry/entry-search.component.mjs +62 -7
- package/esm2022/lib/components/index.mjs +1 -1
- package/esm2022/lib/pipes/get-slug-by-id.pipe.mjs +17 -0
- package/fesm2022/dignite-ng-expand.cms.mjs +425 -48
- package/fesm2022/dignite-ng-expand.cms.mjs.map +1 -1
- package/lib/cms.module.d.ts +3 -1
- package/lib/components/admin/entries/create-or-edit-entries.component.d.ts +1 -0
- package/lib/components/admin/entries/entries.component.d.ts +63 -0
- package/lib/components/dynamic-form/entry/entry-control.component.d.ts +17 -2
- package/lib/components/dynamic-form/entry/entry-search.component.d.ts +17 -2
- package/lib/pipes/get-slug-by-id.pipe.d.ts +7 -0
- package/package.json +1 -1
package/lib/cms.module.d.ts
CHANGED
|
@@ -35,10 +35,12 @@ import * as i32 from "@swimlane/ngx-datatable";
|
|
|
35
35
|
import * as i33 from "@ckeditor/ckeditor5-angular";
|
|
36
36
|
import * as i34 from "@angular/forms";
|
|
37
37
|
import * as i35 from "./pipes/get-localized-entries-by-slug.pipe";
|
|
38
|
+
import * as i36 from "./pipes/get-slug-by-id.pipe";
|
|
39
|
+
import * as i37 from "ng-zorro-antd/tree-select";
|
|
38
40
|
export declare class CmsModule {
|
|
39
41
|
static forChild(options?: any): ModuleWithProviders<CmsModule>;
|
|
40
42
|
static forLazy(options?: any): NgModuleFactory<CmsModule>;
|
|
41
43
|
static ɵfac: i0.ɵɵFactoryDeclaration<CmsModule, never>;
|
|
42
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<CmsModule, [typeof i1.EntriesComponent, typeof i2.FieldsComponent, typeof i3.SectionsComponent, typeof i4.FieldsGroupComponent, typeof i5.CreateFieldComponent, typeof i6.EditFieldComponent, typeof i7.CreateOrEditFieldComponent, typeof i8.CreateOrEditComponent, typeof i9.CreateComponent, typeof i10.EditComponent, typeof i11.CreateOrEditEntriesComponent, typeof i12.TableConfigComponent, typeof i13.TableControlComponent, typeof i14.MatrixConfigComponent, typeof i15.MatrixControlComponent, typeof i16.EntryConfigComponent, typeof i17.EntryControlComponent, typeof i18.EntryViewComponent, typeof i19.CreateOrEditSectionsModalComponent, typeof i20.MatrixViewComponent, typeof i21.TableViewComponent, typeof i22.EntrySearchComponent], [typeof i23.CoreModule, typeof i24.ThemeSharedModule, typeof i25.CmsRoutingModule, typeof i26.NgbNavModule, typeof i26.NgbAccordionModule, typeof i26.NgbDropdownModule, typeof i27.PageModule, typeof i28.NzSelectModule, typeof i29.DynamicFormModule, typeof i30.ExtensibleModule, typeof i31.DragDropModule, typeof i32.NgxDatatableModule, typeof i33.CKEditorModule, typeof i34.FormsModule, typeof i35.GetLocalizedEntriesBySlugPipe], [typeof i12.TableConfigComponent, typeof i13.TableControlComponent, typeof i14.MatrixConfigComponent, typeof i15.MatrixControlComponent, typeof i16.EntryConfigComponent, typeof i17.EntryControlComponent, typeof i18.EntryViewComponent, typeof i20.MatrixViewComponent, typeof i21.TableViewComponent, typeof i22.EntrySearchComponent]>;
|
|
44
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<CmsModule, [typeof i1.EntriesComponent, typeof i2.FieldsComponent, typeof i3.SectionsComponent, typeof i4.FieldsGroupComponent, typeof i5.CreateFieldComponent, typeof i6.EditFieldComponent, typeof i7.CreateOrEditFieldComponent, typeof i8.CreateOrEditComponent, typeof i9.CreateComponent, typeof i10.EditComponent, typeof i11.CreateOrEditEntriesComponent, typeof i12.TableConfigComponent, typeof i13.TableControlComponent, typeof i14.MatrixConfigComponent, typeof i15.MatrixControlComponent, typeof i16.EntryConfigComponent, typeof i17.EntryControlComponent, typeof i18.EntryViewComponent, typeof i19.CreateOrEditSectionsModalComponent, typeof i20.MatrixViewComponent, typeof i21.TableViewComponent, typeof i22.EntrySearchComponent], [typeof i23.CoreModule, typeof i24.ThemeSharedModule, typeof i25.CmsRoutingModule, typeof i26.NgbNavModule, typeof i26.NgbAccordionModule, typeof i26.NgbDropdownModule, typeof i27.PageModule, typeof i28.NzSelectModule, typeof i29.DynamicFormModule, typeof i30.ExtensibleModule, typeof i31.DragDropModule, typeof i32.NgxDatatableModule, typeof i33.CKEditorModule, typeof i34.FormsModule, typeof i35.GetLocalizedEntriesBySlugPipe, typeof i36.GetSlugByIdPipe, typeof i37.NzTreeSelectModule], [typeof i12.TableConfigComponent, typeof i13.TableControlComponent, typeof i14.MatrixConfigComponent, typeof i15.MatrixControlComponent, typeof i16.EntryConfigComponent, typeof i17.EntryControlComponent, typeof i18.EntryViewComponent, typeof i20.MatrixViewComponent, typeof i21.TableViewComponent, typeof i22.EntrySearchComponent]>;
|
|
43
45
|
static ɵinj: i0.ɵɵInjectorDeclaration<CmsModule>;
|
|
44
46
|
}
|
|
@@ -75,6 +75,7 @@ export declare class CreateOrEditEntriesComponent {
|
|
|
75
75
|
getSectionInfo(): Promise<unknown>;
|
|
76
76
|
/**获取板块下所有条目 */
|
|
77
77
|
getEntryList(): Promise<unknown>;
|
|
78
|
+
onChange($event: string[]): void;
|
|
78
79
|
/**对数组按照父子关系进行分组 */
|
|
79
80
|
groupByParentId(arr: any, id: string, layer: any): any[];
|
|
80
81
|
/**别名转化 */
|
|
@@ -90,16 +90,79 @@ export declare class EntriesComponent implements OnInit {
|
|
|
90
90
|
data: PagedResultDto<EntryDto> | any;
|
|
91
91
|
filters: GetEntriesInput;
|
|
92
92
|
maxResultCount: number;
|
|
93
|
+
copylistItem: any[];
|
|
94
|
+
shouldScrollToTop: boolean;
|
|
93
95
|
hookToQuery(): void;
|
|
94
96
|
scrollToTop(): void;
|
|
95
97
|
/**判断某个类型的条目是否存在 */
|
|
96
98
|
isEntryTypeExist(entryTypeId: string): any;
|
|
97
99
|
/**删除条目 */
|
|
98
100
|
deletefield(row: any): void;
|
|
101
|
+
/** 当前拖拽目标节点的ID */
|
|
102
|
+
dropTargetId: string | null;
|
|
103
|
+
/** 拖拽位置:above-上方, below-下方, inside-内部 */
|
|
104
|
+
dropPosition: 'above' | 'below' | 'inside' | null;
|
|
105
|
+
/** 当前被拖拽的节点 */
|
|
106
|
+
draggedItem: any;
|
|
107
|
+
/** 是否正在拖拽 */
|
|
108
|
+
isDragging: boolean;
|
|
109
|
+
/** 是否为无效拖拽目标(拖拽到自身或子节点) */
|
|
110
|
+
isInvalidDropTarget: boolean;
|
|
111
|
+
/**
|
|
112
|
+
* CDK拖拽开始事件
|
|
113
|
+
*/
|
|
114
|
+
onDragStarted(event: any): void;
|
|
115
|
+
/**
|
|
116
|
+
* CDK拖拽结束事件
|
|
117
|
+
*/
|
|
118
|
+
onDragEnded(event: any): void;
|
|
119
|
+
/**
|
|
120
|
+
* CDK拖拽进入事件
|
|
121
|
+
*/
|
|
122
|
+
onDragEntered(event: any, targetItem: any): void;
|
|
123
|
+
/**
|
|
124
|
+
* 鼠标移动事件,判断位置
|
|
125
|
+
*/
|
|
126
|
+
onMouseMove(event: MouseEvent, targetItem: any): void;
|
|
127
|
+
/**
|
|
128
|
+
* 拖拽离开事件处理
|
|
129
|
+
* 清除拖拽目标和位置标识
|
|
130
|
+
*/
|
|
131
|
+
onDragLeave(event: DragEvent): void;
|
|
132
|
+
/**
|
|
133
|
+
* 拖拽释放事件处理
|
|
134
|
+
* 根据拖拽位置调用后端API移动节点
|
|
135
|
+
* @param event CDK拖拽事件
|
|
136
|
+
*/
|
|
99
137
|
drop(event: any): void;
|
|
138
|
+
/**
|
|
139
|
+
* 清除拖拽状态
|
|
140
|
+
*/
|
|
141
|
+
private clearDropState;
|
|
142
|
+
/**
|
|
143
|
+
* 检查目标节点是否是拖拽节点的后代或自身
|
|
144
|
+
*/
|
|
145
|
+
private isDescendantOrSelf;
|
|
146
|
+
/**
|
|
147
|
+
* 递归检查目标节点是否是拖拽节点的子节点
|
|
148
|
+
*/
|
|
149
|
+
private isDescendant;
|
|
150
|
+
/**
|
|
151
|
+
* 在树形结构或平铺数组中递归查找指定ID的节点
|
|
152
|
+
* @param items 节点数组
|
|
153
|
+
* @param id 要查找的节点ID
|
|
154
|
+
* @returns 找到的节点或null
|
|
155
|
+
*/
|
|
156
|
+
findItemById(items: any[], id: string): any;
|
|
157
|
+
/**
|
|
158
|
+
* 更新本地数据
|
|
159
|
+
*/
|
|
160
|
+
private updateLocalData;
|
|
100
161
|
isexpanded: boolean | any;
|
|
101
162
|
/**高级筛选切换 */
|
|
102
163
|
expandedChange(event: any): void;
|
|
164
|
+
/**将平铺数据转换为树形结构并排序 */
|
|
165
|
+
buildTree(items: any[]): any[];
|
|
103
166
|
static ɵfac: i0.ɵɵFactoryDeclaration<EntriesComponent, never>;
|
|
104
167
|
static ɵcmp: i0.ɵɵComponentDeclaration<EntriesComponent, "cms-entries", never, {}, {}, never, never, false, never>;
|
|
105
168
|
}
|
|
@@ -1,10 +1,13 @@
|
|
|
1
1
|
import { ElementRef } from '@angular/core';
|
|
2
2
|
import { FormControl, FormGroup } from '@angular/forms';
|
|
3
|
+
import { SectionType } from '../../../proxy/dignite/cms/sections';
|
|
3
4
|
import * as i0 from "@angular/core";
|
|
4
5
|
export declare class EntryControlComponent {
|
|
5
6
|
private fb;
|
|
6
7
|
private _EntryAdminService;
|
|
8
|
+
private _SectionAdminService;
|
|
7
9
|
private _LocalizationService;
|
|
10
|
+
SectionType: typeof SectionType;
|
|
8
11
|
/**表单实体 */
|
|
9
12
|
_entity: FormGroup | any;
|
|
10
13
|
set entity(v: any);
|
|
@@ -22,18 +25,30 @@ export declare class EntryControlComponent {
|
|
|
22
25
|
set culture(v: any);
|
|
23
26
|
submitclick: ElementRef;
|
|
24
27
|
extraProperties: FormGroup | undefined;
|
|
28
|
+
/**板块信息 */
|
|
29
|
+
sectionInfo: any;
|
|
25
30
|
/** */
|
|
26
31
|
listOfOption: any[];
|
|
32
|
+
/**树形节点 */
|
|
33
|
+
treeNodes: any[];
|
|
34
|
+
treeSelectValue: any;
|
|
35
|
+
selectValue: any;
|
|
27
36
|
private cdr;
|
|
28
37
|
dataLoaded(): Promise<void>;
|
|
29
38
|
AfterInit(): Promise<unknown>;
|
|
30
39
|
get selectInput(): FormControl;
|
|
31
|
-
|
|
32
|
-
ModelChange(event: any): void;
|
|
40
|
+
onSelectChange(value: any): void;
|
|
33
41
|
/**获取对应的条目 */
|
|
34
42
|
getEntryAssignList(filter?: string): Promise<unknown>;
|
|
43
|
+
/**判断是否为结构类型 */
|
|
44
|
+
isStructureType(): boolean;
|
|
45
|
+
/**转换为树形节点 */
|
|
46
|
+
private convertToTreeNodes;
|
|
47
|
+
onTreeSelectChange(value: any): void;
|
|
35
48
|
/** */
|
|
36
49
|
SelectChange(event: any): Promise<void>;
|
|
50
|
+
/**获取对应的板块 */
|
|
51
|
+
getSectionById(): Promise<unknown>;
|
|
37
52
|
static ɵfac: i0.ɵɵFactoryDeclaration<EntryControlComponent, never>;
|
|
38
53
|
static ɵcmp: i0.ɵɵComponentDeclaration<EntryControlComponent, "cms-entry-control", never, { "entity": { "alias": "entity"; "required": false; }; "fields": { "alias": "fields"; "required": false; }; "parentFiledName": { "alias": "parentFiledName"; "required": false; }; "selected": { "alias": "selected"; "required": false; }; "culture": { "alias": "culture"; "required": false; }; }, {}, never, never, false, never>;
|
|
39
54
|
}
|
|
@@ -1,10 +1,13 @@
|
|
|
1
1
|
import { ElementRef } from '@angular/core';
|
|
2
2
|
import { FormControl, FormGroup } from '@angular/forms';
|
|
3
|
+
import { SectionType } from '../../../proxy/dignite/cms/sections';
|
|
3
4
|
import * as i0 from "@angular/core";
|
|
4
5
|
export declare class EntrySearchComponent {
|
|
5
6
|
constructor();
|
|
6
7
|
private fb;
|
|
7
8
|
private _EntryAdminService;
|
|
9
|
+
private _SectionAdminService;
|
|
10
|
+
SectionType: typeof SectionType;
|
|
8
11
|
/**表单实体 */
|
|
9
12
|
_entity: FormGroup | any;
|
|
10
13
|
set entity(v: any);
|
|
@@ -19,16 +22,28 @@ export declare class EntrySearchComponent {
|
|
|
19
22
|
set culture(v: any);
|
|
20
23
|
submitclick: ElementRef;
|
|
21
24
|
extraProperties: FormGroup | undefined;
|
|
25
|
+
/**板块信息 */
|
|
26
|
+
sectionInfo: any;
|
|
22
27
|
/** */
|
|
23
28
|
listOfOption: any[];
|
|
29
|
+
/**树形节点 */
|
|
30
|
+
treeNodes: any[];
|
|
31
|
+
treeSelectValue: any;
|
|
32
|
+
selectValue: any;
|
|
24
33
|
private cdr;
|
|
25
34
|
dataLoaded(): Promise<void>;
|
|
26
35
|
AfterInit(): Promise<unknown>;
|
|
27
36
|
get selectInput(): FormControl;
|
|
28
|
-
|
|
29
|
-
|
|
37
|
+
onSelectChange(value: any): void;
|
|
38
|
+
onTreeSelectChange(value: any): void;
|
|
30
39
|
/**获取对应的条目 */
|
|
31
40
|
getEntryAssignList(filter?: string): Promise<unknown>;
|
|
41
|
+
/**判断是否为结构类型 */
|
|
42
|
+
isStructureType(): boolean;
|
|
43
|
+
/**转换为树形节点 */
|
|
44
|
+
private convertToTreeNodes;
|
|
45
|
+
/**获取对应的板块 */
|
|
46
|
+
getSectionById(): Promise<unknown>;
|
|
32
47
|
/** */
|
|
33
48
|
SelectChange(event: any): Promise<void>;
|
|
34
49
|
static ɵfac: i0.ɵɵFactoryDeclaration<EntrySearchComponent, never>;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { PipeTransform } from '@angular/core';
|
|
2
|
+
import * as i0 from "@angular/core";
|
|
3
|
+
export declare class GetSlugByIdPipe implements PipeTransform {
|
|
4
|
+
transform(parentId: string, items: any[]): string;
|
|
5
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<GetSlugByIdPipe, never>;
|
|
6
|
+
static ɵpipe: i0.ɵɵPipeDeclaration<GetSlugByIdPipe, "getSlugById", true>;
|
|
7
|
+
}
|