vue2-client 1.11.2 → 1.11.4
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/XForm/XFormItem.vue +15 -9
- package/src/base-client/components/common/XForm/XTreeSelect.vue +18 -4
- package/src/base-client/components/common/XFormGroupDetails/XFormGroupDetails.vue +1 -1
- package/src/base-client/components/common/XFormTable/demo.vue +60 -60
- package/src/components/STable/index.js +426 -390
- package/src/mock/common/reportData.js +8 -8
- package/src/pages/ReportView.vue +1 -1
- package/src/pages/resourceManage/depListManage.vue +1 -1
- package/src/pages/resourceManage/funListManage.vue +1 -1
- package/src/pages/resourceManage/orgListManage.vue +1 -1
- package/src/pages/resourceManage/roleListManage.vue +1 -1
- package/src/pages/resourceManage/staffListManage.vue +1 -1
- package/src/router/async/router.map.js +92 -166
- package/src/utils/theme-color-replacer-extend.js +92 -91
package/package.json
CHANGED
|
@@ -774,7 +774,9 @@ export default {
|
|
|
774
774
|
},
|
|
775
775
|
labelCol: {
|
|
776
776
|
type: Object,
|
|
777
|
-
default: () => {
|
|
777
|
+
default: () => {
|
|
778
|
+
return { span: 8 }
|
|
779
|
+
}
|
|
778
780
|
}
|
|
779
781
|
},
|
|
780
782
|
provide () {
|
|
@@ -1095,6 +1097,8 @@ export default {
|
|
|
1095
1097
|
} else if (this.attr.keyName.indexOf('async ') !== -1 || this.attr.keyName.indexOf('function ') !== -1) {
|
|
1096
1098
|
this.updateOptions()
|
|
1097
1099
|
}
|
|
1100
|
+
} else if (this.attr.keys) {
|
|
1101
|
+
this.getDataCallback(this.attr.keys)
|
|
1098
1102
|
}
|
|
1099
1103
|
this.focusInput()
|
|
1100
1104
|
},
|
|
@@ -1110,14 +1114,16 @@ export default {
|
|
|
1110
1114
|
getDataCallback (res) {
|
|
1111
1115
|
this.option = res
|
|
1112
1116
|
if (this.attr.type === 'treeSelect') {
|
|
1113
|
-
this.$
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1117
|
+
this.$nextTick(() => {
|
|
1118
|
+
this.$refs.xTreeSelect.init({
|
|
1119
|
+
option: this.option,
|
|
1120
|
+
form: this.form,
|
|
1121
|
+
queryType: this.attr.queryType,
|
|
1122
|
+
name: this.attr.name,
|
|
1123
|
+
model: this.attr.model,
|
|
1124
|
+
mode: this.mode,
|
|
1125
|
+
disabled: this.disabled
|
|
1126
|
+
})
|
|
1121
1127
|
})
|
|
1122
1128
|
} else if (this.attr.type === 'radio' || ['radioGroup', 'clickChange'].includes(this.attr.showMode)) {
|
|
1123
1129
|
this.initRadioValue()
|
|
@@ -89,6 +89,7 @@ export default {
|
|
|
89
89
|
if (this.mode === '查询') {
|
|
90
90
|
const values = []
|
|
91
91
|
this.getValues(option, value, values)
|
|
92
|
+
this.$emit('onChange', values)
|
|
92
93
|
} else {
|
|
93
94
|
this.value = value
|
|
94
95
|
}
|
|
@@ -101,14 +102,25 @@ export default {
|
|
|
101
102
|
this.$emit('mounted', this)
|
|
102
103
|
this.loaded = true
|
|
103
104
|
},
|
|
104
|
-
getValues (option, value, values
|
|
105
|
+
getValues (option, value, values) {
|
|
105
106
|
for (const item of option) {
|
|
106
107
|
if (value.includes(item.value)) {
|
|
107
108
|
values.push(item.value)
|
|
108
|
-
|
|
109
|
+
// 找到匹配节点后,递归添加所有子节点的值
|
|
110
|
+
if (item.children && item.children.length) {
|
|
111
|
+
this.getAllChildrenValues(item.children, values)
|
|
112
|
+
}
|
|
109
113
|
}
|
|
110
114
|
if (item.children && item.children.length) {
|
|
111
|
-
this.getValues(item.children, value, values
|
|
115
|
+
this.getValues(item.children, value, values)
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
},
|
|
119
|
+
getAllChildrenValues (children, values) {
|
|
120
|
+
for (const child of children) {
|
|
121
|
+
values.push(child.value)
|
|
122
|
+
if (child.children && child.children.length) {
|
|
123
|
+
this.getAllChildrenValues(child.children, values)
|
|
112
124
|
}
|
|
113
125
|
}
|
|
114
126
|
},
|
|
@@ -181,7 +193,9 @@ export default {
|
|
|
181
193
|
const values = []
|
|
182
194
|
if (extra.allCheckedNodes) {
|
|
183
195
|
for (const item of extra.allCheckedNodes) {
|
|
184
|
-
|
|
196
|
+
console.log(item.node.key, '=====', item.children)
|
|
197
|
+
if (item.node.key) {
|
|
198
|
+
// if (item.node.key && item.node?.data?.props?.label !== item.node?.data?.props?.value) {
|
|
185
199
|
values.push(`${item.node.key}`)
|
|
186
200
|
}
|
|
187
201
|
if (item.children && item.children.length) {
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
<a-rate disabled v-model="formJson.default[item.groupName][col.model]" />
|
|
9
9
|
</template>
|
|
10
10
|
<template v-else>
|
|
11
|
-
{{formJson.default[item.groupName][col.model]}}
|
|
11
|
+
{{ formJson.default[item.groupName][col.model] }}
|
|
12
12
|
</template>
|
|
13
13
|
</a-descriptions-item>
|
|
14
14
|
</template>
|
|
@@ -1,60 +1,60 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<a-card :bordered="false">
|
|
3
|
-
<!-- <a-button @click="()=>{queryParamsName = 'MeterBookUnallocatedUserCRUD'}">测试1</a-button>-->
|
|
4
|
-
<!-- <a-button @click="()=>{queryParamsName = 'MeterBookUnallocatedAreaCRUD'}">测试2</a-button>-->
|
|
5
|
-
<x-form-table
|
|
6
|
-
title="示例表单"
|
|
7
|
-
:queryParamsName="queryParamsName"
|
|
8
|
-
:fixedAddForm="fixedAddForm"
|
|
9
|
-
service-name="af-system"
|
|
10
|
-
@action="action"
|
|
11
|
-
@columnClick="columnClick"
|
|
12
|
-
ref="xFormTable">
|
|
13
|
-
</x-form-table>
|
|
14
|
-
</a-card>
|
|
15
|
-
</template>
|
|
16
|
-
|
|
17
|
-
<script>
|
|
18
|
-
import XFormTable from '@vue2-client/base-client/components/common/XFormTable/XFormTable.vue'
|
|
19
|
-
import { microDispatch } from '@vue2-client/utils/microAppUtils'
|
|
20
|
-
export default {
|
|
21
|
-
name: 'Demo',
|
|
22
|
-
components: {
|
|
23
|
-
XFormTable
|
|
24
|
-
},
|
|
25
|
-
data () {
|
|
26
|
-
return {
|
|
27
|
-
// 查询配置文件名
|
|
28
|
-
queryParamsName: 'ceshiCRUD',
|
|
29
|
-
// 查询配置左侧tree
|
|
30
|
-
// xTreeConfigName: 'addressType',
|
|
31
|
-
// 新增表单固定值
|
|
32
|
-
fixedAddForm: {},
|
|
33
|
-
// 是否显示详情抽屉
|
|
34
|
-
detailVisible: false,
|
|
35
|
-
// 当前记录
|
|
36
|
-
record: {}
|
|
37
|
-
}
|
|
38
|
-
},
|
|
39
|
-
methods: {
|
|
40
|
-
columnClick (key, value, record) {
|
|
41
|
-
microDispatch({ type: 'v3route', path: '/bingliguanli/dianzibingliluru', props: { selected: arguments[0].his_f_admission_id } })
|
|
42
|
-
},
|
|
43
|
-
action (record, id, actionType) {
|
|
44
|
-
this.detailVisible = true
|
|
45
|
-
console.log('触发了详情操作', record, id, actionType)
|
|
46
|
-
},
|
|
47
|
-
onClose () {
|
|
48
|
-
this.detailVisible = false
|
|
49
|
-
// 关闭详情之后重新查询表单
|
|
50
|
-
this.$refs.xFormTable.refreshTable(true)
|
|
51
|
-
}
|
|
52
|
-
},
|
|
53
|
-
computed: {
|
|
54
|
-
},
|
|
55
|
-
}
|
|
56
|
-
</script>
|
|
57
|
-
|
|
58
|
-
<style scoped>
|
|
59
|
-
|
|
60
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<a-card :bordered="false">
|
|
3
|
+
<!-- <a-button @click="()=>{queryParamsName = 'MeterBookUnallocatedUserCRUD'}">测试1</a-button>-->
|
|
4
|
+
<!-- <a-button @click="()=>{queryParamsName = 'MeterBookUnallocatedAreaCRUD'}">测试2</a-button>-->
|
|
5
|
+
<x-form-table
|
|
6
|
+
title="示例表单"
|
|
7
|
+
:queryParamsName="queryParamsName"
|
|
8
|
+
:fixedAddForm="fixedAddForm"
|
|
9
|
+
service-name="af-system"
|
|
10
|
+
@action="action"
|
|
11
|
+
@columnClick="columnClick"
|
|
12
|
+
ref="xFormTable">
|
|
13
|
+
</x-form-table>
|
|
14
|
+
</a-card>
|
|
15
|
+
</template>
|
|
16
|
+
|
|
17
|
+
<script>
|
|
18
|
+
import XFormTable from '@vue2-client/base-client/components/common/XFormTable/XFormTable.vue'
|
|
19
|
+
import { microDispatch } from '@vue2-client/utils/microAppUtils'
|
|
20
|
+
export default {
|
|
21
|
+
name: 'Demo',
|
|
22
|
+
components: {
|
|
23
|
+
XFormTable
|
|
24
|
+
},
|
|
25
|
+
data () {
|
|
26
|
+
return {
|
|
27
|
+
// 查询配置文件名
|
|
28
|
+
queryParamsName: 'ceshiCRUD',
|
|
29
|
+
// 查询配置左侧tree
|
|
30
|
+
// xTreeConfigName: 'addressType',
|
|
31
|
+
// 新增表单固定值
|
|
32
|
+
fixedAddForm: {},
|
|
33
|
+
// 是否显示详情抽屉
|
|
34
|
+
detailVisible: false,
|
|
35
|
+
// 当前记录
|
|
36
|
+
record: {}
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
methods: {
|
|
40
|
+
columnClick (key, value, record) {
|
|
41
|
+
microDispatch({ type: 'v3route', path: '/bingliguanli/dianzibingliluru', props: { selected: arguments[0].his_f_admission_id } })
|
|
42
|
+
},
|
|
43
|
+
action (record, id, actionType) {
|
|
44
|
+
this.detailVisible = true
|
|
45
|
+
console.log('触发了详情操作', record, id, actionType)
|
|
46
|
+
},
|
|
47
|
+
onClose () {
|
|
48
|
+
this.detailVisible = false
|
|
49
|
+
// 关闭详情之后重新查询表单
|
|
50
|
+
this.$refs.xFormTable.refreshTable(true)
|
|
51
|
+
}
|
|
52
|
+
},
|
|
53
|
+
computed: {
|
|
54
|
+
},
|
|
55
|
+
}
|
|
56
|
+
</script>
|
|
57
|
+
|
|
58
|
+
<style scoped>
|
|
59
|
+
|
|
60
|
+
</style>
|