@zgfe/modules-whole 1.0.10-zhongyuan.0
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/README.md +37 -0
- package/es/components/dataUpdateTime/index.d.ts +3 -0
- package/es/components/dataUpdateTime/index.js +53 -0
- package/es/components/eventFilter/index.d.ts +5 -0
- package/es/components/eventFilter/index.js +263 -0
- package/es/components/eventFilter/styles/index.less +36 -0
- package/es/components/eventFilter/types.d.ts +20 -0
- package/es/components/eventFilter/types.js +1 -0
- package/es/components/index.d.ts +4 -0
- package/es/components/index.js +4 -0
- package/es/components/renderContent/index.d.ts +5 -0
- package/es/components/renderContent/index.js +44 -0
- package/es/components/renderContent/styles/index.less +20 -0
- package/es/components/renderContent/types.d.ts +9 -0
- package/es/components/renderContent/types.js +1 -0
- package/es/components/searchPanel/index.d.ts +5 -0
- package/es/components/searchPanel/index.js +164 -0
- package/es/components/searchPanel/styles/index.less +22 -0
- package/es/components/searchPanel/types.d.ts +23 -0
- package/es/components/searchPanel/types.js +1 -0
- package/es/components/table/index.d.ts +5 -0
- package/es/components/table/index.js +130 -0
- package/es/components/table/styles/index.less +193 -0
- package/es/components/table/types.d.ts +9 -0
- package/es/components/table/types.js +1 -0
- package/es/components/topBar/index.d.ts +5 -0
- package/es/components/topBar/index.js +163 -0
- package/es/components/topBar/styles/index.less +71 -0
- package/es/components/topBar/types.d.ts +8 -0
- package/es/components/topBar/types.js +1 -0
- package/es/constants/apis.d.ts +8 -0
- package/es/constants/apis.js +8 -0
- package/es/constants/chart.d.ts +2 -0
- package/es/constants/chart.js +31 -0
- package/es/constants/color.d.ts +1 -0
- package/es/constants/color.js +1 -0
- package/es/constants/fields.d.ts +271 -0
- package/es/constants/fields.js +260 -0
- package/es/constants/index.d.ts +6 -0
- package/es/constants/index.js +6 -0
- package/es/constants/initData.d.ts +2 -0
- package/es/constants/initData.js +9 -0
- package/es/constants/json/line.d.ts +20 -0
- package/es/constants/json/line.js +25 -0
- package/es/index.d.ts +5 -0
- package/es/index.js +4 -0
- package/es/modules/chart/demo/data.d.ts +78 -0
- package/es/modules/chart/demo/data.js +489 -0
- package/es/modules/chart/demo/index.d.ts +3 -0
- package/es/modules/chart/demo/index.js +12 -0
- package/es/modules/chart/demo/panel.d.ts +3 -0
- package/es/modules/chart/demo/panel.js +11 -0
- package/es/modules/chart/index.d.ts +4 -0
- package/es/modules/chart/index.js +246 -0
- package/es/modules/chart/types.d.ts +15 -0
- package/es/modules/chart/types.js +1 -0
- package/es/modules/content/index.d.ts +5 -0
- package/es/modules/content/index.js +234 -0
- package/es/modules/content/styles/index.less +7 -0
- package/es/modules/content/types.d.ts +11 -0
- package/es/modules/content/types.js +1 -0
- package/es/modules/content/utils.d.ts +17 -0
- package/es/modules/content/utils.js +107 -0
- package/es/modules/home/demo/create.d.ts +3 -0
- package/es/modules/home/demo/create.js +58 -0
- package/es/modules/home/demo/edit.d.ts +3 -0
- package/es/modules/home/demo/edit.js +86 -0
- package/es/modules/home/demo/index.d.ts +4 -0
- package/es/modules/home/demo/index.js +83 -0
- package/es/modules/home/demo/scene.d.ts +3 -0
- package/es/modules/home/demo/scene.js +89 -0
- package/es/modules/home/demo/styles/index.less +33 -0
- package/es/modules/home/index.d.ts +5 -0
- package/es/modules/home/index.js +218 -0
- package/es/modules/home/styles/index.less +39 -0
- package/es/modules/home/types.d.ts +34 -0
- package/es/modules/home/types.js +1 -0
- package/es/modules/topPanel/index.d.ts +5 -0
- package/es/modules/topPanel/index.js +154 -0
- package/es/modules/topPanel/styles/index.less +41 -0
- package/es/modules/topPanel/types.d.ts +39 -0
- package/es/modules/topPanel/types.js +1 -0
- package/es/style/image/ring.svg +9 -0
- package/es/style/index.less +62 -0
- package/es/style/theme.d.ts +15 -0
- package/es/style/theme.js +14 -0
- package/es/types.d.ts +79 -0
- package/es/types.js +6 -0
- package/es/utils/ajaxConfig.d.ts +8 -0
- package/es/utils/ajaxConfig.js +12 -0
- package/es/utils/base64.d.ts +23 -0
- package/es/utils/base64.js +125 -0
- package/es/utils/formData.d.ts +21 -0
- package/es/utils/formData.js +366 -0
- package/es/utils/util.d.ts +36 -0
- package/es/utils/util.js +167 -0
- package/package.json +63 -0
|
@@ -0,0 +1,260 @@
|
|
|
1
|
+
export var platformOption = [{
|
|
2
|
+
key: 0,
|
|
3
|
+
value: '全部平台'
|
|
4
|
+
}, {
|
|
5
|
+
key: 3,
|
|
6
|
+
value: 'JS'
|
|
7
|
+
}, {
|
|
8
|
+
key: 2,
|
|
9
|
+
value: 'IOS'
|
|
10
|
+
}, {
|
|
11
|
+
key: 1,
|
|
12
|
+
value: 'Android'
|
|
13
|
+
}];
|
|
14
|
+
export var chartTypes = [{
|
|
15
|
+
label: '趋势图',
|
|
16
|
+
value: 'line',
|
|
17
|
+
icon: 'qushitu1',
|
|
18
|
+
optionList: [{
|
|
19
|
+
label: '合计',
|
|
20
|
+
value: 'total',
|
|
21
|
+
disabled: false,
|
|
22
|
+
select: true
|
|
23
|
+
}, {
|
|
24
|
+
label: '环比',
|
|
25
|
+
value: 'huanbi',
|
|
26
|
+
disabled: false,
|
|
27
|
+
select: true
|
|
28
|
+
}]
|
|
29
|
+
}, {
|
|
30
|
+
label: '汇总图',
|
|
31
|
+
value: 'bar',
|
|
32
|
+
icon: 'huizongtu',
|
|
33
|
+
optionList: [{
|
|
34
|
+
label: '合计',
|
|
35
|
+
value: 'total',
|
|
36
|
+
disabled: false,
|
|
37
|
+
select: true
|
|
38
|
+
}, {
|
|
39
|
+
label: '环比',
|
|
40
|
+
value: 'huanbi',
|
|
41
|
+
disabled: false,
|
|
42
|
+
select: true
|
|
43
|
+
}]
|
|
44
|
+
}, {
|
|
45
|
+
label: '占比图',
|
|
46
|
+
value: 'pie',
|
|
47
|
+
icon: 'bingtu',
|
|
48
|
+
optionList: [{
|
|
49
|
+
label: '合计',
|
|
50
|
+
value: 'total',
|
|
51
|
+
disabled: false,
|
|
52
|
+
select: true
|
|
53
|
+
}, {
|
|
54
|
+
label: '环比',
|
|
55
|
+
value: 'huanbi',
|
|
56
|
+
disabled: false,
|
|
57
|
+
select: true
|
|
58
|
+
}]
|
|
59
|
+
}, {
|
|
60
|
+
label: '地图',
|
|
61
|
+
value: 'map',
|
|
62
|
+
icon: 'ditu',
|
|
63
|
+
disabled: true,
|
|
64
|
+
optionList: [{
|
|
65
|
+
label: '合计',
|
|
66
|
+
value: 'total',
|
|
67
|
+
disabled: false,
|
|
68
|
+
select: true
|
|
69
|
+
}, {
|
|
70
|
+
label: '环比',
|
|
71
|
+
value: 'huanbi',
|
|
72
|
+
disabled: false,
|
|
73
|
+
select: true
|
|
74
|
+
}]
|
|
75
|
+
}, {
|
|
76
|
+
label: '表格',
|
|
77
|
+
icon: 'biaoge',
|
|
78
|
+
value: 'grid',
|
|
79
|
+
children: [{
|
|
80
|
+
label: '',
|
|
81
|
+
value: 'line',
|
|
82
|
+
icon: 'qushitu1'
|
|
83
|
+
}, {
|
|
84
|
+
label: '',
|
|
85
|
+
value: 'bar',
|
|
86
|
+
icon: 'huizongtu'
|
|
87
|
+
}, {
|
|
88
|
+
label: '',
|
|
89
|
+
value: 'pie',
|
|
90
|
+
icon: 'bingtu'
|
|
91
|
+
}, {
|
|
92
|
+
label: '',
|
|
93
|
+
value: 'map',
|
|
94
|
+
icon: 'ditu',
|
|
95
|
+
disabled: true
|
|
96
|
+
}],
|
|
97
|
+
optionList: [{
|
|
98
|
+
label: '合计',
|
|
99
|
+
value: 'total',
|
|
100
|
+
disabled: false,
|
|
101
|
+
select: true
|
|
102
|
+
}, {
|
|
103
|
+
label: '环比',
|
|
104
|
+
value: 'huanbi',
|
|
105
|
+
disabled: false,
|
|
106
|
+
select: true
|
|
107
|
+
}]
|
|
108
|
+
}, {
|
|
109
|
+
label: '数值',
|
|
110
|
+
value: 'number',
|
|
111
|
+
icon: 'fenshu',
|
|
112
|
+
disabled: false,
|
|
113
|
+
optionList: [{
|
|
114
|
+
label: '合计',
|
|
115
|
+
value: 'total',
|
|
116
|
+
disabled: true,
|
|
117
|
+
select: true
|
|
118
|
+
}, {
|
|
119
|
+
label: '环比',
|
|
120
|
+
value: 'huanbi',
|
|
121
|
+
disabled: false,
|
|
122
|
+
select: true
|
|
123
|
+
}, {
|
|
124
|
+
label: '同比',
|
|
125
|
+
value: 'tongbi',
|
|
126
|
+
disabled: false,
|
|
127
|
+
select: true
|
|
128
|
+
}]
|
|
129
|
+
}];
|
|
130
|
+
export var addPanelFields = [{
|
|
131
|
+
label: '看板',
|
|
132
|
+
name: 'panel',
|
|
133
|
+
extendName: 'range',
|
|
134
|
+
type: 'selectToInput',
|
|
135
|
+
options: [],
|
|
136
|
+
children: ['range'],
|
|
137
|
+
fieldNames: {
|
|
138
|
+
label: 'name',
|
|
139
|
+
value: 'id'
|
|
140
|
+
},
|
|
141
|
+
rules: [{
|
|
142
|
+
required: true,
|
|
143
|
+
message: '请选择看板'
|
|
144
|
+
}]
|
|
145
|
+
}, {
|
|
146
|
+
label: '名称',
|
|
147
|
+
name: 'name',
|
|
148
|
+
type: 'input',
|
|
149
|
+
rules: [{
|
|
150
|
+
required: true,
|
|
151
|
+
message: '请输入名称'
|
|
152
|
+
}]
|
|
153
|
+
}, {
|
|
154
|
+
label: '样式',
|
|
155
|
+
name: 'chart',
|
|
156
|
+
type: 'tab',
|
|
157
|
+
options: chartTypes,
|
|
158
|
+
rules: [{
|
|
159
|
+
required: true,
|
|
160
|
+
message: '请选择图表'
|
|
161
|
+
}]
|
|
162
|
+
}, {
|
|
163
|
+
label: '显示',
|
|
164
|
+
name: 'show',
|
|
165
|
+
type: 'radio',
|
|
166
|
+
direction: 'vertical',
|
|
167
|
+
dependenceFields: {
|
|
168
|
+
chart: 'line'
|
|
169
|
+
},
|
|
170
|
+
options: [{
|
|
171
|
+
label: '动态显示数据最多的10个分组',
|
|
172
|
+
value: 'dynamic'
|
|
173
|
+
}, {
|
|
174
|
+
label: '固定显示当前选择的分组',
|
|
175
|
+
value: 'fix'
|
|
176
|
+
}],
|
|
177
|
+
rules: [{
|
|
178
|
+
required: true,
|
|
179
|
+
message: '请选择'
|
|
180
|
+
}]
|
|
181
|
+
}];
|
|
182
|
+
export var editPanelFields = [{
|
|
183
|
+
label: '样式',
|
|
184
|
+
name: 'chart',
|
|
185
|
+
type: 'tab',
|
|
186
|
+
options: chartTypes,
|
|
187
|
+
rules: [{
|
|
188
|
+
required: true,
|
|
189
|
+
message: '请选择图表'
|
|
190
|
+
}]
|
|
191
|
+
}, {
|
|
192
|
+
label: '显示',
|
|
193
|
+
name: 'show',
|
|
194
|
+
type: 'radio',
|
|
195
|
+
direction: 'vertical',
|
|
196
|
+
dependenceFields: {
|
|
197
|
+
chart: 'line'
|
|
198
|
+
},
|
|
199
|
+
options: [{
|
|
200
|
+
label: '动态显示数据最多的10个分组',
|
|
201
|
+
value: 'dynamic'
|
|
202
|
+
}, {
|
|
203
|
+
label: '固定显示当前选择的分组',
|
|
204
|
+
value: 'fix'
|
|
205
|
+
}],
|
|
206
|
+
rules: [{
|
|
207
|
+
required: true,
|
|
208
|
+
message: '请选择'
|
|
209
|
+
}]
|
|
210
|
+
}];
|
|
211
|
+
export var addSceneFields = [{
|
|
212
|
+
label: '场景分类',
|
|
213
|
+
name: 'class',
|
|
214
|
+
type: 'selectToInput',
|
|
215
|
+
options: [],
|
|
216
|
+
fieldNames: {
|
|
217
|
+
label: 'groupName',
|
|
218
|
+
value: 'groupId'
|
|
219
|
+
},
|
|
220
|
+
rules: [{
|
|
221
|
+
required: true,
|
|
222
|
+
message: '请选择场景分类'
|
|
223
|
+
}]
|
|
224
|
+
}, {
|
|
225
|
+
label: '场景名称',
|
|
226
|
+
name: 'name',
|
|
227
|
+
type: 'input',
|
|
228
|
+
rules: [{
|
|
229
|
+
required: true,
|
|
230
|
+
message: '请输入场景名称'
|
|
231
|
+
}]
|
|
232
|
+
}];
|
|
233
|
+
export var getBuiltinIndicators = function getBuiltinIndicators(type) {
|
|
234
|
+
return [{
|
|
235
|
+
name: "".concat(type === 'user' ? '新增用户' : '新增主体'),
|
|
236
|
+
id: -201,
|
|
237
|
+
module: 'add',
|
|
238
|
+
analysisIndex: 'number'
|
|
239
|
+
}, {
|
|
240
|
+
name: "".concat(type === 'user' ? '活跃用户' : '活跃主体'),
|
|
241
|
+
id: -202,
|
|
242
|
+
module: 'active',
|
|
243
|
+
analysisIndex: 'number'
|
|
244
|
+
}, {
|
|
245
|
+
name: '访问次数',
|
|
246
|
+
id: -203,
|
|
247
|
+
module: 'active',
|
|
248
|
+
analysisIndex: 'times'
|
|
249
|
+
}, {
|
|
250
|
+
name: '平均使用时长',
|
|
251
|
+
id: -204,
|
|
252
|
+
module: 'duration_avg',
|
|
253
|
+
analysisIndex: null
|
|
254
|
+
}, {
|
|
255
|
+
name: '使用时长分布',
|
|
256
|
+
id: -205,
|
|
257
|
+
module: 'duration',
|
|
258
|
+
analysisIndex: 'number,times'
|
|
259
|
+
}];
|
|
260
|
+
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import Apis from './apis';
|
|
2
|
+
import { chartTypeOptions } from './chart';
|
|
3
|
+
import { chartColors } from './color';
|
|
4
|
+
import { chartTypes, addPanelFields, editPanelFields, addSceneFields } from './fields';
|
|
5
|
+
import { getInitDate } from './initData';
|
|
6
|
+
export { Apis, chartTypeOptions, chartColors, chartTypes, addPanelFields, editPanelFields, addSceneFields, getInitDate, };
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import Apis from './apis';
|
|
2
|
+
import { chartTypeOptions } from './chart';
|
|
3
|
+
import { chartColors } from './color';
|
|
4
|
+
import { chartTypes, addPanelFields, editPanelFields, addSceneFields } from './fields';
|
|
5
|
+
import { getInitDate } from './initData';
|
|
6
|
+
export { Apis, chartTypeOptions, chartColors, chartTypes, addPanelFields, editPanelFields, addSceneFields, getInitDate };
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import moment from 'moment';
|
|
2
|
+
export function getInitDate(includeToday) {
|
|
3
|
+
return {
|
|
4
|
+
unit: 'day',
|
|
5
|
+
relative: [7, includeToday ? 0 : 1],
|
|
6
|
+
begin: moment().subtract(7, 'days').format('YYYY-MM-DD'),
|
|
7
|
+
end: moment().subtract(includeToday ? 0 : 1, 'days').format('YYYY-MM-DD')
|
|
8
|
+
};
|
|
9
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
msg: string;
|
|
3
|
+
code: number;
|
|
4
|
+
app_data: {
|
|
5
|
+
xAxis: string[];
|
|
6
|
+
x_axis: string[];
|
|
7
|
+
series: {
|
|
8
|
+
names: string[];
|
|
9
|
+
original_names: string[];
|
|
10
|
+
values: number[];
|
|
11
|
+
total: never[];
|
|
12
|
+
p_total: never[];
|
|
13
|
+
}[];
|
|
14
|
+
tongbi: never[];
|
|
15
|
+
huanbi: never[];
|
|
16
|
+
total: never[];
|
|
17
|
+
yesterDay: never[];
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
export default _default;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
export default {
|
|
2
|
+
msg: 'Request success',
|
|
3
|
+
code: 10001,
|
|
4
|
+
app_data: {
|
|
5
|
+
xAxis: ['2024-05-28', '2024-05-29', '2024-05-30', '2024-05-31', '2024-06-01', '2024-06-02', '2024-06-03', '2024-06-04'],
|
|
6
|
+
x_axis: ['2024-05-28', '2024-05-29', '2024-05-30', '2024-05-31', '2024-06-01', '2024-06-02', '2024-06-03', '2024-06-04'],
|
|
7
|
+
series: [{
|
|
8
|
+
names: ['所有用户', '活跃用户'],
|
|
9
|
+
original_names: ['活跃用户'],
|
|
10
|
+
values: [375, 368, 391, 351, 889, 880, 382, 306],
|
|
11
|
+
total: [],
|
|
12
|
+
p_total: []
|
|
13
|
+
}, {
|
|
14
|
+
names: ['近7天新增的活跃用户', '活跃用户'],
|
|
15
|
+
original_names: ['活跃用户'],
|
|
16
|
+
values: [375, 368, 391, 351, 889, 880, 382, 306],
|
|
17
|
+
total: [],
|
|
18
|
+
p_total: []
|
|
19
|
+
}],
|
|
20
|
+
tongbi: [],
|
|
21
|
+
huanbi: [],
|
|
22
|
+
total: [],
|
|
23
|
+
yesterDay: []
|
|
24
|
+
}
|
|
25
|
+
};
|
package/es/index.d.ts
ADDED
package/es/index.js
ADDED
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
export declare const result: {
|
|
2
|
+
xAxis: string[];
|
|
3
|
+
series: ({
|
|
4
|
+
duration: never[];
|
|
5
|
+
index: string;
|
|
6
|
+
names: string[];
|
|
7
|
+
values: number[];
|
|
8
|
+
} | {
|
|
9
|
+
duration: {
|
|
10
|
+
name: string;
|
|
11
|
+
values: number[];
|
|
12
|
+
}[];
|
|
13
|
+
index: null;
|
|
14
|
+
names: string[];
|
|
15
|
+
values: number[];
|
|
16
|
+
})[];
|
|
17
|
+
};
|
|
18
|
+
export declare const totalResult: {
|
|
19
|
+
xAxis: string[];
|
|
20
|
+
series: ({
|
|
21
|
+
duration: never[];
|
|
22
|
+
index: string;
|
|
23
|
+
names: string[];
|
|
24
|
+
original_names: never[];
|
|
25
|
+
p_total: never[];
|
|
26
|
+
total: never[];
|
|
27
|
+
values: number[];
|
|
28
|
+
} | {
|
|
29
|
+
duration: never[];
|
|
30
|
+
index: null;
|
|
31
|
+
names: string[];
|
|
32
|
+
original_names: never[];
|
|
33
|
+
p_total: never[];
|
|
34
|
+
total: never[];
|
|
35
|
+
values: number[];
|
|
36
|
+
})[];
|
|
37
|
+
};
|
|
38
|
+
export declare const searchData: {
|
|
39
|
+
appId: number;
|
|
40
|
+
platform: number;
|
|
41
|
+
name: string;
|
|
42
|
+
id: number;
|
|
43
|
+
module: string;
|
|
44
|
+
analysisIndex: null;
|
|
45
|
+
userGroup: number[];
|
|
46
|
+
time: {
|
|
47
|
+
begin: string;
|
|
48
|
+
end: string;
|
|
49
|
+
relative: number[];
|
|
50
|
+
unit: string;
|
|
51
|
+
};
|
|
52
|
+
chartType: string;
|
|
53
|
+
overall: boolean;
|
|
54
|
+
refresh: boolean;
|
|
55
|
+
extendTarget: string[];
|
|
56
|
+
};
|
|
57
|
+
export declare const totalSearchData: {
|
|
58
|
+
appId: number;
|
|
59
|
+
platform: number;
|
|
60
|
+
targets: {
|
|
61
|
+
type: string;
|
|
62
|
+
alias: string;
|
|
63
|
+
eventId: number;
|
|
64
|
+
eventName: string;
|
|
65
|
+
eventGroupId: number;
|
|
66
|
+
analysisDimension: {
|
|
67
|
+
analysisIndex: string;
|
|
68
|
+
};
|
|
69
|
+
}[];
|
|
70
|
+
userGroup: number[];
|
|
71
|
+
time: {
|
|
72
|
+
unit: string;
|
|
73
|
+
relative: number[];
|
|
74
|
+
begin: string;
|
|
75
|
+
end: string;
|
|
76
|
+
};
|
|
77
|
+
chartType: string;
|
|
78
|
+
};
|