vue2-client 1.8.319 → 1.8.321
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/package.json +1 -1
- package/src/base-client/components/common/LowCodeComponent/LowCodeEditorModal.vue +108 -108
- package/src/base-client/components/common/LowCodeComponent/modal/lowCodeAddPageModal.vue +117 -117
- package/src/base-client/components/common/LowCodeComponent/modal/lowCodeCustomJSModal.vue +80 -80
- package/src/base-client/components/common/LowCodeComponent/modal/lowCodeEventEditorModal.vue +398 -398
- package/src/base-client/components/common/LowCodeComponent/modal/lowCodeLifeCycleModal.vue +65 -65
- package/src/base-client/components/common/LowCodeComponent/modal/lowCodeLogicCallbackModal.vue +64 -64
- package/src/base-client/components/common/LowCodeComponent/modal/lowCodeLogicParamModal.vue +73 -73
- package/src/base-client/components/common/LowCodeComponent/modal/lowCodeRunFunctionParamModal.vue +76 -76
- package/src/base-client/components/common/XDataCard/XDataCard.vue +355 -355
- package/src/base-client/components/common/XDescriptions/lowcodeEditorRegister.js +31 -31
- package/src/base-client/components/common/XReportSlot/index.md +48 -48
- package/src/base-client/components/common/XSimpleDescriptions/XSimpleDescriptions.vue +18 -2
- package/src/components/CodeMirror/inedx.vue +118 -118
- package/src/components/CodeMirror/setting.js +40 -40
- package/src/config/CreateQueryConfig.js +322 -322
- package/src/pages/Example/index.vue +18 -127
- package/src/pages/NewDynamicStatistics/ChartSelector.vue +331 -331
- package/src/pages/NewDynamicStatistics/DataTabs.vue +122 -122
- package/src/pages/NewDynamicStatistics/DynamicTable.vue +128 -128
- package/src/pages/NewDynamicStatistics/EvaluationArea.vue +69 -69
- package/src/pages/NewDynamicStatistics/FavoriteList.vue +51 -51
- package/src/pages/NewDynamicStatistics/QuestionHistoryAndFavorites.vue +289 -289
- package/src/pages/NewDynamicStatistics/SearchBar.vue +193 -193
- package/src/pages/NewDynamicStatistics/index.vue +258 -258
- package/vue.config.js +6 -0
package/package.json
CHANGED
|
@@ -1,108 +1,108 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div>
|
|
3
|
-
<!-- 事件编辑弹窗 -->
|
|
4
|
-
<LowCodeEventEditorModal
|
|
5
|
-
ref="eventEditor"
|
|
6
|
-
@changeOuterValue="changeOuterValue"
|
|
7
|
-
@refresh="refresh"
|
|
8
|
-
@openModal="changeModalVisible"
|
|
9
|
-
:event-editor-current="eventEditorCurrent"
|
|
10
|
-
:editor-properties-config="editorPropertiesConfig"/>
|
|
11
|
-
<!-- 增加页面弹窗 -->
|
|
12
|
-
<LowCodeAddPageModal
|
|
13
|
-
ref="addPage"
|
|
14
|
-
@refresh="refresh"/>
|
|
15
|
-
<!-- 生命周期函数弹窗 -->
|
|
16
|
-
<LowCodeLifeCycleModal ref="lifeCycle"/>
|
|
17
|
-
<!-- Logic回调弹窗 -->
|
|
18
|
-
<LowCodeLogicCallbackModal ref="logicCallBack"/>
|
|
19
|
-
<!-- Logic参数弹窗 -->
|
|
20
|
-
<LowCodeLogicParamModal ref="logicParam"/>
|
|
21
|
-
<!-- 自定义JS弹窗 -->
|
|
22
|
-
<LowCodeCustomJSModal ref="customJS"/>
|
|
23
|
-
<LowCodeRunFunctionParamModal ref="functionParam" />
|
|
24
|
-
</div>
|
|
25
|
-
</template>
|
|
26
|
-
|
|
27
|
-
<script>
|
|
28
|
-
import LowCodeEventEditorModal from '@vue2-client/base-client/components/common/LowCodeComponent/modal/lowCodeEventEditorModal.vue'
|
|
29
|
-
import LowCodeAddPageModal from '@vue2-client/base-client/components/common/LowCodeComponent/modal/lowCodeAddPageModal.vue'
|
|
30
|
-
import LowCodeLifeCycleModal from '@vue2-client/base-client/components/common/LowCodeComponent/modal/lowCodeLifeCycleModal.vue'
|
|
31
|
-
import LowCodeLogicCallbackModal from '@vue2-client/base-client/components/common/LowCodeComponent/modal/lowCodeLogicCallbackModal.vue'
|
|
32
|
-
import LowCodeLogicParamModal from '@vue2-client/base-client/components/common/LowCodeComponent/modal/lowCodeLogicParamModal.vue'
|
|
33
|
-
import LowCodeCustomJSModal from '@vue2-client/base-client/components/common/LowCodeComponent/modal/lowCodeCustomJSModal.vue'
|
|
34
|
-
import LowCodeRunFunctionParamModal from '@vue2-client/base-client/components/common/LowCodeComponent/modal/lowCodeRunFunctionParamModal.vue'
|
|
35
|
-
|
|
36
|
-
export default {
|
|
37
|
-
name: 'LowCodeEditorModal',
|
|
38
|
-
components: {
|
|
39
|
-
LowCodeLogicCallbackModal,
|
|
40
|
-
LowCodeLifeCycleModal,
|
|
41
|
-
LowCodeEventEditorModal,
|
|
42
|
-
LowCodeAddPageModal,
|
|
43
|
-
LowCodeLogicParamModal,
|
|
44
|
-
LowCodeCustomJSModal,
|
|
45
|
-
LowCodeRunFunctionParamModal
|
|
46
|
-
},
|
|
47
|
-
props: {
|
|
48
|
-
// 用于保存右侧编辑组件的属性
|
|
49
|
-
// eslint-disable-next-line vue/require-default-prop
|
|
50
|
-
editorPropertiesConfig: {
|
|
51
|
-
type: Object,
|
|
52
|
-
require: true
|
|
53
|
-
},
|
|
54
|
-
// 用于事件编辑的回显,在点击事件编辑按钮后,会将此变量赋值
|
|
55
|
-
eventEditorCurrent: {
|
|
56
|
-
type: Object,
|
|
57
|
-
default: undefined
|
|
58
|
-
}
|
|
59
|
-
},
|
|
60
|
-
inject: [
|
|
61
|
-
'componentsMap'
|
|
62
|
-
],
|
|
63
|
-
methods: {
|
|
64
|
-
// 打开弹框
|
|
65
|
-
changeModalVisible (modalName) {
|
|
66
|
-
switch (modalName) {
|
|
67
|
-
case 'eventEditor' :
|
|
68
|
-
this.$refs.eventEditor.changeVisible()
|
|
69
|
-
return
|
|
70
|
-
case 'addPage':
|
|
71
|
-
this.$refs.addPage.changeVisible()
|
|
72
|
-
return
|
|
73
|
-
case 'lifeCycle':
|
|
74
|
-
this.$refs.lifeCycle.changeVisible()
|
|
75
|
-
return
|
|
76
|
-
case 'logicCallBack':
|
|
77
|
-
this.$refs.logicCallBack.changeVisible()
|
|
78
|
-
return
|
|
79
|
-
case 'logicParam':
|
|
80
|
-
this.$refs.logicParam.changeVisible()
|
|
81
|
-
return
|
|
82
|
-
case 'customJS':
|
|
83
|
-
this.$refs.customJS.changeVisible()
|
|
84
|
-
return
|
|
85
|
-
case 'functionParam':
|
|
86
|
-
this.$refs.functionParam.changeVisible()
|
|
87
|
-
}
|
|
88
|
-
},
|
|
89
|
-
// 刷新组件
|
|
90
|
-
refresh (type) {
|
|
91
|
-
this.$emit('refresh', type)
|
|
92
|
-
},
|
|
93
|
-
// 修改外侧(编辑器)的值
|
|
94
|
-
changeOuterValue (key, value) {
|
|
95
|
-
this.$emit('changeOuterValue', key, value)
|
|
96
|
-
}
|
|
97
|
-
},
|
|
98
|
-
computed: {
|
|
99
|
-
config () {
|
|
100
|
-
return this.$store.state.lowCode.config
|
|
101
|
-
}
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
|
-
</script>
|
|
105
|
-
|
|
106
|
-
<style scoped lang="less">
|
|
107
|
-
|
|
108
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<div>
|
|
3
|
+
<!-- 事件编辑弹窗 -->
|
|
4
|
+
<LowCodeEventEditorModal
|
|
5
|
+
ref="eventEditor"
|
|
6
|
+
@changeOuterValue="changeOuterValue"
|
|
7
|
+
@refresh="refresh"
|
|
8
|
+
@openModal="changeModalVisible"
|
|
9
|
+
:event-editor-current="eventEditorCurrent"
|
|
10
|
+
:editor-properties-config="editorPropertiesConfig"/>
|
|
11
|
+
<!-- 增加页面弹窗 -->
|
|
12
|
+
<LowCodeAddPageModal
|
|
13
|
+
ref="addPage"
|
|
14
|
+
@refresh="refresh"/>
|
|
15
|
+
<!-- 生命周期函数弹窗 -->
|
|
16
|
+
<LowCodeLifeCycleModal ref="lifeCycle"/>
|
|
17
|
+
<!-- Logic回调弹窗 -->
|
|
18
|
+
<LowCodeLogicCallbackModal ref="logicCallBack"/>
|
|
19
|
+
<!-- Logic参数弹窗 -->
|
|
20
|
+
<LowCodeLogicParamModal ref="logicParam"/>
|
|
21
|
+
<!-- 自定义JS弹窗 -->
|
|
22
|
+
<LowCodeCustomJSModal ref="customJS"/>
|
|
23
|
+
<LowCodeRunFunctionParamModal ref="functionParam" />
|
|
24
|
+
</div>
|
|
25
|
+
</template>
|
|
26
|
+
|
|
27
|
+
<script>
|
|
28
|
+
import LowCodeEventEditorModal from '@vue2-client/base-client/components/common/LowCodeComponent/modal/lowCodeEventEditorModal.vue'
|
|
29
|
+
import LowCodeAddPageModal from '@vue2-client/base-client/components/common/LowCodeComponent/modal/lowCodeAddPageModal.vue'
|
|
30
|
+
import LowCodeLifeCycleModal from '@vue2-client/base-client/components/common/LowCodeComponent/modal/lowCodeLifeCycleModal.vue'
|
|
31
|
+
import LowCodeLogicCallbackModal from '@vue2-client/base-client/components/common/LowCodeComponent/modal/lowCodeLogicCallbackModal.vue'
|
|
32
|
+
import LowCodeLogicParamModal from '@vue2-client/base-client/components/common/LowCodeComponent/modal/lowCodeLogicParamModal.vue'
|
|
33
|
+
import LowCodeCustomJSModal from '@vue2-client/base-client/components/common/LowCodeComponent/modal/lowCodeCustomJSModal.vue'
|
|
34
|
+
import LowCodeRunFunctionParamModal from '@vue2-client/base-client/components/common/LowCodeComponent/modal/lowCodeRunFunctionParamModal.vue'
|
|
35
|
+
|
|
36
|
+
export default {
|
|
37
|
+
name: 'LowCodeEditorModal',
|
|
38
|
+
components: {
|
|
39
|
+
LowCodeLogicCallbackModal,
|
|
40
|
+
LowCodeLifeCycleModal,
|
|
41
|
+
LowCodeEventEditorModal,
|
|
42
|
+
LowCodeAddPageModal,
|
|
43
|
+
LowCodeLogicParamModal,
|
|
44
|
+
LowCodeCustomJSModal,
|
|
45
|
+
LowCodeRunFunctionParamModal
|
|
46
|
+
},
|
|
47
|
+
props: {
|
|
48
|
+
// 用于保存右侧编辑组件的属性
|
|
49
|
+
// eslint-disable-next-line vue/require-default-prop
|
|
50
|
+
editorPropertiesConfig: {
|
|
51
|
+
type: Object,
|
|
52
|
+
require: true
|
|
53
|
+
},
|
|
54
|
+
// 用于事件编辑的回显,在点击事件编辑按钮后,会将此变量赋值
|
|
55
|
+
eventEditorCurrent: {
|
|
56
|
+
type: Object,
|
|
57
|
+
default: undefined
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
inject: [
|
|
61
|
+
'componentsMap'
|
|
62
|
+
],
|
|
63
|
+
methods: {
|
|
64
|
+
// 打开弹框
|
|
65
|
+
changeModalVisible (modalName) {
|
|
66
|
+
switch (modalName) {
|
|
67
|
+
case 'eventEditor' :
|
|
68
|
+
this.$refs.eventEditor.changeVisible()
|
|
69
|
+
return
|
|
70
|
+
case 'addPage':
|
|
71
|
+
this.$refs.addPage.changeVisible()
|
|
72
|
+
return
|
|
73
|
+
case 'lifeCycle':
|
|
74
|
+
this.$refs.lifeCycle.changeVisible()
|
|
75
|
+
return
|
|
76
|
+
case 'logicCallBack':
|
|
77
|
+
this.$refs.logicCallBack.changeVisible()
|
|
78
|
+
return
|
|
79
|
+
case 'logicParam':
|
|
80
|
+
this.$refs.logicParam.changeVisible()
|
|
81
|
+
return
|
|
82
|
+
case 'customJS':
|
|
83
|
+
this.$refs.customJS.changeVisible()
|
|
84
|
+
return
|
|
85
|
+
case 'functionParam':
|
|
86
|
+
this.$refs.functionParam.changeVisible()
|
|
87
|
+
}
|
|
88
|
+
},
|
|
89
|
+
// 刷新组件
|
|
90
|
+
refresh (type) {
|
|
91
|
+
this.$emit('refresh', type)
|
|
92
|
+
},
|
|
93
|
+
// 修改外侧(编辑器)的值
|
|
94
|
+
changeOuterValue (key, value) {
|
|
95
|
+
this.$emit('changeOuterValue', key, value)
|
|
96
|
+
}
|
|
97
|
+
},
|
|
98
|
+
computed: {
|
|
99
|
+
config () {
|
|
100
|
+
return this.$store.state.lowCode.config
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
</script>
|
|
105
|
+
|
|
106
|
+
<style scoped lang="less">
|
|
107
|
+
|
|
108
|
+
</style>
|
|
@@ -1,117 +1,117 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div>
|
|
3
|
-
<!-- 新增页面容器弹框 -->
|
|
4
|
-
<a-modal
|
|
5
|
-
title="新增页面容器"
|
|
6
|
-
width="60%"
|
|
7
|
-
:z-index="1001"
|
|
8
|
-
:destroyOnClose="true"
|
|
9
|
-
@ok="handleAddPageContainerModalOk"
|
|
10
|
-
@cancel="() => { showPageContainerAddModal = false }"
|
|
11
|
-
:visible="showPageContainerAddModal">
|
|
12
|
-
<a-form :label-col="{ span: 7 }" :wrapper-col="{ span: 12 }">
|
|
13
|
-
<!-- 容器类型 -->
|
|
14
|
-
<a-form-item label="容器类型">
|
|
15
|
-
<a-select v-model="addComponentTemp.type" @change="pageContainerAddTypeChange">
|
|
16
|
-
<a-select-option value="page">
|
|
17
|
-
页面
|
|
18
|
-
</a-select-option>
|
|
19
|
-
<a-select-option value="modal">
|
|
20
|
-
弹框
|
|
21
|
-
</a-select-option>
|
|
22
|
-
<a-select-option value="draw">
|
|
23
|
-
抽屉
|
|
24
|
-
</a-select-option>
|
|
25
|
-
</a-select>
|
|
26
|
-
</a-form-item>
|
|
27
|
-
<!-- 标题 -->
|
|
28
|
-
<a-form-item label="标题">
|
|
29
|
-
<a-input v-model="addComponentTemp.title"/>
|
|
30
|
-
</a-form-item>
|
|
31
|
-
<template v-if="addComponentTemp.type !== 'page'">
|
|
32
|
-
<!-- 宽度 -->
|
|
33
|
-
<a-form-item label="宽度">
|
|
34
|
-
<a-input v-model="addComponentTemp.width"/>
|
|
35
|
-
</a-form-item>
|
|
36
|
-
</template>
|
|
37
|
-
</a-form>
|
|
38
|
-
</a-modal>
|
|
39
|
-
</div>
|
|
40
|
-
</template>
|
|
41
|
-
|
|
42
|
-
<script>
|
|
43
|
-
import codeMirror from '@vue2-client/components/CodeMirror/inedx.vue'
|
|
44
|
-
import * as lowcodeUtils from '@vue2-client/utils/lowcode/lowcodeUtils'
|
|
45
|
-
|
|
46
|
-
export default {
|
|
47
|
-
name: 'LowCodeAddPageModal',
|
|
48
|
-
components: {
|
|
49
|
-
codeMirror
|
|
50
|
-
},
|
|
51
|
-
props: {
|
|
52
|
-
},
|
|
53
|
-
inject: [
|
|
54
|
-
'componentsMap'
|
|
55
|
-
],
|
|
56
|
-
data () {
|
|
57
|
-
return {
|
|
58
|
-
// 控制弹框显隐
|
|
59
|
-
showPageContainerAddModal: false,
|
|
60
|
-
// 添加页面容器参数
|
|
61
|
-
addComponentTemp: { type: 'page' }
|
|
62
|
-
}
|
|
63
|
-
},
|
|
64
|
-
methods: {
|
|
65
|
-
changeVisible () {
|
|
66
|
-
this.addComponentTemp = { type: 'page' }
|
|
67
|
-
this.showPageContainerAddModal = !this.showPageContainerAddModal
|
|
68
|
-
},
|
|
69
|
-
// 添加页面容器弹框确认
|
|
70
|
-
handleAddPageContainerModalOk () {
|
|
71
|
-
const pageId = 'page_' + lowcodeUtils.nanoidWithoutSymbol(6)
|
|
72
|
-
const result = {
|
|
73
|
-
id: pageId,
|
|
74
|
-
type: this.addComponentTemp.type,
|
|
75
|
-
title: this.addComponentTemp.title,
|
|
76
|
-
width: this.addComponentTemp.width,
|
|
77
|
-
body: [
|
|
78
|
-
{
|
|
79
|
-
id: pageId + '_0',
|
|
80
|
-
config: {
|
|
81
|
-
align: 'top',
|
|
82
|
-
gutter: 0,
|
|
83
|
-
justify: 'start'
|
|
84
|
-
},
|
|
85
|
-
type: 'row',
|
|
86
|
-
body: [
|
|
87
|
-
lowcodeUtils.newContainer()
|
|
88
|
-
]
|
|
89
|
-
}
|
|
90
|
-
]
|
|
91
|
-
}
|
|
92
|
-
this.addComponentTemp = { type: 'page' }
|
|
93
|
-
this.config.page.push(result)
|
|
94
|
-
this.$store.commit('setConfig', this.config)
|
|
95
|
-
this.$emit('refresh', 'Organization')
|
|
96
|
-
this.changeVisible()
|
|
97
|
-
},
|
|
98
|
-
// 添加页面容器类型修改
|
|
99
|
-
pageContainerAddTypeChange (value) {
|
|
100
|
-
if (value !== 'page') {
|
|
101
|
-
this.addComponentTemp = { width: '70%', type: value }
|
|
102
|
-
} else {
|
|
103
|
-
this.addComponentTemp = { type: value }
|
|
104
|
-
}
|
|
105
|
-
},
|
|
106
|
-
},
|
|
107
|
-
computed: {
|
|
108
|
-
config () {
|
|
109
|
-
return this.$store.state.lowCode.config
|
|
110
|
-
}
|
|
111
|
-
}
|
|
112
|
-
}
|
|
113
|
-
</script>
|
|
114
|
-
|
|
115
|
-
<style scoped lang="less">
|
|
116
|
-
|
|
117
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<div>
|
|
3
|
+
<!-- 新增页面容器弹框 -->
|
|
4
|
+
<a-modal
|
|
5
|
+
title="新增页面容器"
|
|
6
|
+
width="60%"
|
|
7
|
+
:z-index="1001"
|
|
8
|
+
:destroyOnClose="true"
|
|
9
|
+
@ok="handleAddPageContainerModalOk"
|
|
10
|
+
@cancel="() => { showPageContainerAddModal = false }"
|
|
11
|
+
:visible="showPageContainerAddModal">
|
|
12
|
+
<a-form :label-col="{ span: 7 }" :wrapper-col="{ span: 12 }">
|
|
13
|
+
<!-- 容器类型 -->
|
|
14
|
+
<a-form-item label="容器类型">
|
|
15
|
+
<a-select v-model="addComponentTemp.type" @change="pageContainerAddTypeChange">
|
|
16
|
+
<a-select-option value="page">
|
|
17
|
+
页面
|
|
18
|
+
</a-select-option>
|
|
19
|
+
<a-select-option value="modal">
|
|
20
|
+
弹框
|
|
21
|
+
</a-select-option>
|
|
22
|
+
<a-select-option value="draw">
|
|
23
|
+
抽屉
|
|
24
|
+
</a-select-option>
|
|
25
|
+
</a-select>
|
|
26
|
+
</a-form-item>
|
|
27
|
+
<!-- 标题 -->
|
|
28
|
+
<a-form-item label="标题">
|
|
29
|
+
<a-input v-model="addComponentTemp.title"/>
|
|
30
|
+
</a-form-item>
|
|
31
|
+
<template v-if="addComponentTemp.type !== 'page'">
|
|
32
|
+
<!-- 宽度 -->
|
|
33
|
+
<a-form-item label="宽度">
|
|
34
|
+
<a-input v-model="addComponentTemp.width"/>
|
|
35
|
+
</a-form-item>
|
|
36
|
+
</template>
|
|
37
|
+
</a-form>
|
|
38
|
+
</a-modal>
|
|
39
|
+
</div>
|
|
40
|
+
</template>
|
|
41
|
+
|
|
42
|
+
<script>
|
|
43
|
+
import codeMirror from '@vue2-client/components/CodeMirror/inedx.vue'
|
|
44
|
+
import * as lowcodeUtils from '@vue2-client/utils/lowcode/lowcodeUtils'
|
|
45
|
+
|
|
46
|
+
export default {
|
|
47
|
+
name: 'LowCodeAddPageModal',
|
|
48
|
+
components: {
|
|
49
|
+
codeMirror
|
|
50
|
+
},
|
|
51
|
+
props: {
|
|
52
|
+
},
|
|
53
|
+
inject: [
|
|
54
|
+
'componentsMap'
|
|
55
|
+
],
|
|
56
|
+
data () {
|
|
57
|
+
return {
|
|
58
|
+
// 控制弹框显隐
|
|
59
|
+
showPageContainerAddModal: false,
|
|
60
|
+
// 添加页面容器参数
|
|
61
|
+
addComponentTemp: { type: 'page' }
|
|
62
|
+
}
|
|
63
|
+
},
|
|
64
|
+
methods: {
|
|
65
|
+
changeVisible () {
|
|
66
|
+
this.addComponentTemp = { type: 'page' }
|
|
67
|
+
this.showPageContainerAddModal = !this.showPageContainerAddModal
|
|
68
|
+
},
|
|
69
|
+
// 添加页面容器弹框确认
|
|
70
|
+
handleAddPageContainerModalOk () {
|
|
71
|
+
const pageId = 'page_' + lowcodeUtils.nanoidWithoutSymbol(6)
|
|
72
|
+
const result = {
|
|
73
|
+
id: pageId,
|
|
74
|
+
type: this.addComponentTemp.type,
|
|
75
|
+
title: this.addComponentTemp.title,
|
|
76
|
+
width: this.addComponentTemp.width,
|
|
77
|
+
body: [
|
|
78
|
+
{
|
|
79
|
+
id: pageId + '_0',
|
|
80
|
+
config: {
|
|
81
|
+
align: 'top',
|
|
82
|
+
gutter: 0,
|
|
83
|
+
justify: 'start'
|
|
84
|
+
},
|
|
85
|
+
type: 'row',
|
|
86
|
+
body: [
|
|
87
|
+
lowcodeUtils.newContainer()
|
|
88
|
+
]
|
|
89
|
+
}
|
|
90
|
+
]
|
|
91
|
+
}
|
|
92
|
+
this.addComponentTemp = { type: 'page' }
|
|
93
|
+
this.config.page.push(result)
|
|
94
|
+
this.$store.commit('setConfig', this.config)
|
|
95
|
+
this.$emit('refresh', 'Organization')
|
|
96
|
+
this.changeVisible()
|
|
97
|
+
},
|
|
98
|
+
// 添加页面容器类型修改
|
|
99
|
+
pageContainerAddTypeChange (value) {
|
|
100
|
+
if (value !== 'page') {
|
|
101
|
+
this.addComponentTemp = { width: '70%', type: value }
|
|
102
|
+
} else {
|
|
103
|
+
this.addComponentTemp = { type: value }
|
|
104
|
+
}
|
|
105
|
+
},
|
|
106
|
+
},
|
|
107
|
+
computed: {
|
|
108
|
+
config () {
|
|
109
|
+
return this.$store.state.lowCode.config
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
}
|
|
113
|
+
</script>
|
|
114
|
+
|
|
115
|
+
<style scoped lang="less">
|
|
116
|
+
|
|
117
|
+
</style>
|
|
@@ -1,80 +1,80 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div>
|
|
3
|
-
<!-- 自定义JS事件弹框 -->
|
|
4
|
-
<a-modal
|
|
5
|
-
title="事件编辑器"
|
|
6
|
-
width="60%"
|
|
7
|
-
:destroyOnClose="true"
|
|
8
|
-
:z-index="1002"
|
|
9
|
-
@ok="handleOK"
|
|
10
|
-
@cancel="changeVisible"
|
|
11
|
-
:visible="showJSEventEditor">
|
|
12
|
-
<a-popover title="参数说明" style="margin-right: 5%">
|
|
13
|
-
<template slot="content">
|
|
14
|
-
<p>该方法有以下几个参数:</p>
|
|
15
|
-
<p>eventType:事件类型,比如:changeValue代表修改目标组件的值</p>
|
|
16
|
-
<p>data:由事件源发出的参数列表</p>
|
|
17
|
-
<p>targetKey:修改目标组件值所对应的key</p>
|
|
18
|
-
<p>sourceVM:事件源的vue对象</p>
|
|
19
|
-
<p>targetVM:目标的vue对象</p>
|
|
20
|
-
</template>
|
|
21
|
-
<a-button type="primary">
|
|
22
|
-
参数说明
|
|
23
|
-
</a-button>
|
|
24
|
-
</a-popover>
|
|
25
|
-
<a-popover title="返回值说明" style="margin-bottom: 5%">
|
|
26
|
-
<template slot="content">
|
|
27
|
-
<p>该方法需要的返回值:</p>
|
|
28
|
-
<p>eventType:事件类型</p>
|
|
29
|
-
<p>data:传递给目标组件的数据</p>
|
|
30
|
-
<p>targetKey:修改目标组件值所对应的key</p>
|
|
31
|
-
</template>
|
|
32
|
-
<a-button type="primary">
|
|
33
|
-
返回值说明
|
|
34
|
-
</a-button>
|
|
35
|
-
</a-popover>
|
|
36
|
-
<code-mirror
|
|
37
|
-
:style-obj="{height:'80%',fontSize:'18px',marginBottom:'15px'}"
|
|
38
|
-
:mode="'javascript'"
|
|
39
|
-
:theme="'monokai'"
|
|
40
|
-
v-model="eventEditorContent.JSFunction"
|
|
41
|
-
:value="eventEditorContent.JSFunction"/>
|
|
42
|
-
</a-modal>
|
|
43
|
-
</div>
|
|
44
|
-
</template>
|
|
45
|
-
|
|
46
|
-
<script>
|
|
47
|
-
import codeMirror from '@vue2-client/components/CodeMirror/inedx.vue'
|
|
48
|
-
|
|
49
|
-
export default {
|
|
50
|
-
components: {
|
|
51
|
-
codeMirror
|
|
52
|
-
},
|
|
53
|
-
props: {
|
|
54
|
-
},
|
|
55
|
-
data () {
|
|
56
|
-
return {
|
|
57
|
-
// 控制自定义JS函数弹框显隐
|
|
58
|
-
showJSEventEditor: false,
|
|
59
|
-
}
|
|
60
|
-
},
|
|
61
|
-
methods: {
|
|
62
|
-
changeVisible () {
|
|
63
|
-
this.showJSEventEditor = !this.showJSEventEditor
|
|
64
|
-
},
|
|
65
|
-
handleOK () {
|
|
66
|
-
this.$store.commit('setEventEditorContent', this.eventEditorContent)
|
|
67
|
-
this.changeVisible()
|
|
68
|
-
}
|
|
69
|
-
},
|
|
70
|
-
computed: {
|
|
71
|
-
eventEditorContent () {
|
|
72
|
-
return this.$store.state.lowCode.eventEditorContent
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
</script>
|
|
77
|
-
|
|
78
|
-
<style scoped lang="less">
|
|
79
|
-
|
|
80
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<div>
|
|
3
|
+
<!-- 自定义JS事件弹框 -->
|
|
4
|
+
<a-modal
|
|
5
|
+
title="事件编辑器"
|
|
6
|
+
width="60%"
|
|
7
|
+
:destroyOnClose="true"
|
|
8
|
+
:z-index="1002"
|
|
9
|
+
@ok="handleOK"
|
|
10
|
+
@cancel="changeVisible"
|
|
11
|
+
:visible="showJSEventEditor">
|
|
12
|
+
<a-popover title="参数说明" style="margin-right: 5%">
|
|
13
|
+
<template slot="content">
|
|
14
|
+
<p>该方法有以下几个参数:</p>
|
|
15
|
+
<p>eventType:事件类型,比如:changeValue代表修改目标组件的值</p>
|
|
16
|
+
<p>data:由事件源发出的参数列表</p>
|
|
17
|
+
<p>targetKey:修改目标组件值所对应的key</p>
|
|
18
|
+
<p>sourceVM:事件源的vue对象</p>
|
|
19
|
+
<p>targetVM:目标的vue对象</p>
|
|
20
|
+
</template>
|
|
21
|
+
<a-button type="primary">
|
|
22
|
+
参数说明
|
|
23
|
+
</a-button>
|
|
24
|
+
</a-popover>
|
|
25
|
+
<a-popover title="返回值说明" style="margin-bottom: 5%">
|
|
26
|
+
<template slot="content">
|
|
27
|
+
<p>该方法需要的返回值:</p>
|
|
28
|
+
<p>eventType:事件类型</p>
|
|
29
|
+
<p>data:传递给目标组件的数据</p>
|
|
30
|
+
<p>targetKey:修改目标组件值所对应的key</p>
|
|
31
|
+
</template>
|
|
32
|
+
<a-button type="primary">
|
|
33
|
+
返回值说明
|
|
34
|
+
</a-button>
|
|
35
|
+
</a-popover>
|
|
36
|
+
<code-mirror
|
|
37
|
+
:style-obj="{height:'80%',fontSize:'18px',marginBottom:'15px'}"
|
|
38
|
+
:mode="'javascript'"
|
|
39
|
+
:theme="'monokai'"
|
|
40
|
+
v-model="eventEditorContent.JSFunction"
|
|
41
|
+
:value="eventEditorContent.JSFunction"/>
|
|
42
|
+
</a-modal>
|
|
43
|
+
</div>
|
|
44
|
+
</template>
|
|
45
|
+
|
|
46
|
+
<script>
|
|
47
|
+
import codeMirror from '@vue2-client/components/CodeMirror/inedx.vue'
|
|
48
|
+
|
|
49
|
+
export default {
|
|
50
|
+
components: {
|
|
51
|
+
codeMirror
|
|
52
|
+
},
|
|
53
|
+
props: {
|
|
54
|
+
},
|
|
55
|
+
data () {
|
|
56
|
+
return {
|
|
57
|
+
// 控制自定义JS函数弹框显隐
|
|
58
|
+
showJSEventEditor: false,
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
methods: {
|
|
62
|
+
changeVisible () {
|
|
63
|
+
this.showJSEventEditor = !this.showJSEventEditor
|
|
64
|
+
},
|
|
65
|
+
handleOK () {
|
|
66
|
+
this.$store.commit('setEventEditorContent', this.eventEditorContent)
|
|
67
|
+
this.changeVisible()
|
|
68
|
+
}
|
|
69
|
+
},
|
|
70
|
+
computed: {
|
|
71
|
+
eventEditorContent () {
|
|
72
|
+
return this.$store.state.lowCode.eventEditorContent
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
</script>
|
|
77
|
+
|
|
78
|
+
<style scoped lang="less">
|
|
79
|
+
|
|
80
|
+
</style>
|