vue2-client 1.16.84 → 1.16.85
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 +112 -112
- package/src/assets/svg/female.svg +1 -1
- package/src/assets/svg/male.svg +1 -1
- package/src/base-client/components/common/HIS/HButtons/HButtons.vue +381 -381
- package/src/base-client/components/common/HIS/HForm/HForm.vue +492 -348
- package/src/base-client/components/common/HIS/HFormGroup/index.js +3 -3
- package/src/base-client/components/common/HIS/HFormTable/HFormTable.vue +10 -1
- package/src/base-client/components/common/HIS/HTab/HTab.vue +26 -1
- package/src/base-client/components/common/XCollapse/XCollapse.vue +833 -833
- package/src/base-client/components/common/XInput/XInput.vue +194 -194
- package/src/base-client/components/common/XTable/XTable.vue +1610 -1610
- package/src/base-client/components/common/XTimeline/XTimeline.vue +478 -462
- package/src/base-client/components/common/XTree/XTreePro.vue +4 -4
- package/src/base-client/components/his/XCheckbox/XCheckbox.vue +181 -181
- package/src/base-client/components/his/XHisEditor/XHisEditor.vue +705 -705
- package/src/base-client/components/his/XList/XList.vue +829 -829
- package/src/base-client/components/his/XRadio/XRadio.vue +389 -389
- package/src/base-client/components/his/XSimpleTable/XSimpleTable.vue +159 -159
- package/src/base-client/components/his/XTimeSelect/XTimeSelect.vue +306 -306
- package/src/base-client/components/his/XTitle/XTitle.vue +274 -269
- package/src/base-client/components/his/XTreeRows/XTreeRows.vue +341 -341
- package/src/base-client/components/his/threeTestOrders/editor.vue +113 -113
- package/src/pages/userInfoDetailManage/ExceptionRecordQuery/index.vue +45 -45
- package/src-base-client/components/common/HIS/HForm/HForm.vue +0 -348
- package/src-base-client/components/common/XCollapse/XCollapse.vue +0 -0
|
@@ -22,11 +22,11 @@
|
|
|
22
22
|
@change="onChange">
|
|
23
23
|
<a-icon slot="prefix" type="search"/>
|
|
24
24
|
</a-input>
|
|
25
|
-
<span v-if="config.addParent
|
|
25
|
+
<span v-if="config.addParent?.isShow" style="margin-left: 10px;">
|
|
26
26
|
<a-icon
|
|
27
|
-
:type="config.addParent
|
|
28
|
-
:style="{ fontSize: config.addParent
|
|
29
|
-
@click="addParent(config.addParent
|
|
27
|
+
:type="config.addParent?.icon || 'plus-square'"
|
|
28
|
+
:style="{ fontSize: config.addParent?.size || '30px', color: config.addParent?.color }"
|
|
29
|
+
@click="addParent(config.addParent?.func)"
|
|
30
30
|
/>
|
|
31
31
|
</span>
|
|
32
32
|
</div>
|
|
@@ -1,181 +1,181 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<div class="x-checkbox-container" :class="wrapperClassObject()">
|
|
3
|
-
<a-checkbox-group v-model="innerValue" @change="onChange" class="x-checkbox-group">
|
|
4
|
-
<div v-for="item in data" :key="item.value" class="x-checkbox-item-container">
|
|
5
|
-
<a-checkbox :value="item.value" class="x-checkbox-item">
|
|
6
|
-
{{ item.label }}
|
|
7
|
-
</a-checkbox>
|
|
8
|
-
</div>
|
|
9
|
-
</a-checkbox-group>
|
|
10
|
-
</div>
|
|
11
|
-
</template>
|
|
12
|
-
|
|
13
|
-
<script>
|
|
14
|
-
import { getConfigByName } from '@vue2-client/services/api/common'
|
|
15
|
-
import { Checkbox } from 'ant-design-vue'
|
|
16
|
-
|
|
17
|
-
export default {
|
|
18
|
-
name: 'XCheckbox',
|
|
19
|
-
components: {
|
|
20
|
-
ACheckboxGroup: Checkbox.Group,
|
|
21
|
-
ACheckbox: Checkbox
|
|
22
|
-
},
|
|
23
|
-
props: {
|
|
24
|
-
queryParamsName: {
|
|
25
|
-
type: Object,
|
|
26
|
-
default: null
|
|
27
|
-
},
|
|
28
|
-
value: {
|
|
29
|
-
type: Array,
|
|
30
|
-
default: () => []
|
|
31
|
-
}
|
|
32
|
-
},
|
|
33
|
-
data () {
|
|
34
|
-
return {
|
|
35
|
-
data: [],
|
|
36
|
-
innerValue: [],
|
|
37
|
-
config: null
|
|
38
|
-
}
|
|
39
|
-
},
|
|
40
|
-
created () {
|
|
41
|
-
this.getData(this.queryParamsName)
|
|
42
|
-
},
|
|
43
|
-
watch: {
|
|
44
|
-
value: {
|
|
45
|
-
handler (val) {
|
|
46
|
-
this.innerValue = val
|
|
47
|
-
},
|
|
48
|
-
deep: true
|
|
49
|
-
}
|
|
50
|
-
},
|
|
51
|
-
emits: ['change', 'init'],
|
|
52
|
-
methods: {
|
|
53
|
-
async getData (data) {
|
|
54
|
-
getConfigByName(data, 'af-his', res => {
|
|
55
|
-
// 1. 加载选项
|
|
56
|
-
if (res.checkbox && Array.isArray(res.checkbox)) {
|
|
57
|
-
this.data = res.checkbox
|
|
58
|
-
// 2. 初始化默认值(优先级: 配置defaultValue > 空数组)
|
|
59
|
-
if (res.defaultValue !== undefined && Array.isArray(res.defaultValue)) {
|
|
60
|
-
this.innerValue = res.defaultValue
|
|
61
|
-
}
|
|
62
|
-
// 3. 触发初始化事件
|
|
63
|
-
this.$emit('init', {
|
|
64
|
-
config: res,
|
|
65
|
-
options: this.data,
|
|
66
|
-
value: this.innerValue
|
|
67
|
-
})
|
|
68
|
-
} else {
|
|
69
|
-
this.$message.error('配置错误,checkbox字段不是数组')
|
|
70
|
-
}
|
|
71
|
-
})
|
|
72
|
-
},
|
|
73
|
-
wrapperClassObject () {
|
|
74
|
-
const attrs = this.$attrs || {}
|
|
75
|
-
const classes = {}
|
|
76
|
-
const booleanStyleKeys = [
|
|
77
|
-
'compact', 'out-checkbox'
|
|
78
|
-
]
|
|
79
|
-
booleanStyleKeys.forEach(key => {
|
|
80
|
-
const val = attrs[key]
|
|
81
|
-
const truthy = val === true || val === '' || val === 'true'
|
|
82
|
-
if (truthy) classes[`x-checkbox-${key}`] = true
|
|
83
|
-
})
|
|
84
|
-
return classes
|
|
85
|
-
},
|
|
86
|
-
onChange (checkedValues) {
|
|
87
|
-
this.innerValue = checkedValues
|
|
88
|
-
this.$emit('change', checkedValues)
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
}
|
|
92
|
-
</script>
|
|
93
|
-
|
|
94
|
-
<style scoped lang="less">
|
|
95
|
-
.x-checkbox-container {
|
|
96
|
-
display: flex;
|
|
97
|
-
flex-direction: column;
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
.x-checkbox-group {
|
|
101
|
-
display: flex;
|
|
102
|
-
justify-content: space-around;
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
.x-checkbox-item-container {
|
|
106
|
-
flex: 1;
|
|
107
|
-
display: flex;
|
|
108
|
-
flex-direction: column;
|
|
109
|
-
align-items: center;
|
|
110
|
-
text-align: center;
|
|
111
|
-
padding: 0 8px;
|
|
112
|
-
box-sizing: border-box;
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
.x-checkbox-item {
|
|
116
|
-
margin-bottom: 8px;
|
|
117
|
-
}
|
|
118
|
-
.x-checkbox-compact {
|
|
119
|
-
&.x-checkbox-container,
|
|
120
|
-
.x-checkbox-container {
|
|
121
|
-
:deep(.x-checkbox-item-container){
|
|
122
|
-
padding: 0px !important;
|
|
123
|
-
flex: auto !important;
|
|
124
|
-
}
|
|
125
|
-
:deep(.x-checkbox-item){
|
|
126
|
-
margin: 0px;
|
|
127
|
-
}
|
|
128
|
-
:deep(.x-checkbox-item) > span:last-child {
|
|
129
|
-
padding-right: 2px;
|
|
130
|
-
padding-left: 2px;
|
|
131
|
-
}
|
|
132
|
-
}
|
|
133
|
-
}
|
|
134
|
-
|
|
135
|
-
/* out-checkbox:外排版紧凑风格,与表单风格配置保持一致的布尔开关用法 */
|
|
136
|
-
.x-checkbox-container.x-checkbox-out-checkbox {
|
|
137
|
-
margin-top: 9px;
|
|
138
|
-
|
|
139
|
-
:deep(.x-checkbox-group) {
|
|
140
|
-
justify-content: flex-start;
|
|
141
|
-
flex-wrap: wrap;
|
|
142
|
-
gap: 0 46px;
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
:deep(.x-checkbox-item-container) {
|
|
146
|
-
flex: 0 0 auto;
|
|
147
|
-
align-items: flex-start;
|
|
148
|
-
text-align: left;
|
|
149
|
-
padding: 0;
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
:deep(.x-checkbox-item) {
|
|
153
|
-
margin: 0;
|
|
154
|
-
display: flex;
|
|
155
|
-
align-items: center;
|
|
156
|
-
|
|
157
|
-
.ant-checkbox {
|
|
158
|
-
width: 20px;
|
|
159
|
-
height: 20px;
|
|
160
|
-
margin-right: 10px;
|
|
161
|
-
|
|
162
|
-
.ant-checkbox-inner {
|
|
163
|
-
width: 20px;
|
|
164
|
-
height: 20px;
|
|
165
|
-
}
|
|
166
|
-
}
|
|
167
|
-
|
|
168
|
-
/* 文字标签样式 */
|
|
169
|
-
span {
|
|
170
|
-
height: 23px;
|
|
171
|
-
opacity: 1;
|
|
172
|
-
font-family: 'Source Han Sans', sans-serif;
|
|
173
|
-
font-size: 16px;
|
|
174
|
-
font-weight: normal;
|
|
175
|
-
line-height: normal;
|
|
176
|
-
letter-spacing: 0em;
|
|
177
|
-
color: #313131;
|
|
178
|
-
}
|
|
179
|
-
}
|
|
180
|
-
}
|
|
181
|
-
</style>
|
|
1
|
+
<template>
|
|
2
|
+
<div class="x-checkbox-container" :class="wrapperClassObject()">
|
|
3
|
+
<a-checkbox-group v-model="innerValue" @change="onChange" class="x-checkbox-group">
|
|
4
|
+
<div v-for="item in data" :key="item.value" class="x-checkbox-item-container">
|
|
5
|
+
<a-checkbox :value="item.value" class="x-checkbox-item">
|
|
6
|
+
{{ item.label }}
|
|
7
|
+
</a-checkbox>
|
|
8
|
+
</div>
|
|
9
|
+
</a-checkbox-group>
|
|
10
|
+
</div>
|
|
11
|
+
</template>
|
|
12
|
+
|
|
13
|
+
<script>
|
|
14
|
+
import { getConfigByName } from '@vue2-client/services/api/common'
|
|
15
|
+
import { Checkbox } from 'ant-design-vue'
|
|
16
|
+
|
|
17
|
+
export default {
|
|
18
|
+
name: 'XCheckbox',
|
|
19
|
+
components: {
|
|
20
|
+
ACheckboxGroup: Checkbox.Group,
|
|
21
|
+
ACheckbox: Checkbox
|
|
22
|
+
},
|
|
23
|
+
props: {
|
|
24
|
+
queryParamsName: {
|
|
25
|
+
type: Object,
|
|
26
|
+
default: null
|
|
27
|
+
},
|
|
28
|
+
value: {
|
|
29
|
+
type: Array,
|
|
30
|
+
default: () => []
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
data () {
|
|
34
|
+
return {
|
|
35
|
+
data: [],
|
|
36
|
+
innerValue: [],
|
|
37
|
+
config: null
|
|
38
|
+
}
|
|
39
|
+
},
|
|
40
|
+
created () {
|
|
41
|
+
this.getData(this.queryParamsName)
|
|
42
|
+
},
|
|
43
|
+
watch: {
|
|
44
|
+
value: {
|
|
45
|
+
handler (val) {
|
|
46
|
+
this.innerValue = val
|
|
47
|
+
},
|
|
48
|
+
deep: true
|
|
49
|
+
}
|
|
50
|
+
},
|
|
51
|
+
emits: ['change', 'init'],
|
|
52
|
+
methods: {
|
|
53
|
+
async getData (data) {
|
|
54
|
+
getConfigByName(data, 'af-his', res => {
|
|
55
|
+
// 1. 加载选项
|
|
56
|
+
if (res.checkbox && Array.isArray(res.checkbox)) {
|
|
57
|
+
this.data = res.checkbox
|
|
58
|
+
// 2. 初始化默认值(优先级: 配置defaultValue > 空数组)
|
|
59
|
+
if (res.defaultValue !== undefined && Array.isArray(res.defaultValue)) {
|
|
60
|
+
this.innerValue = res.defaultValue
|
|
61
|
+
}
|
|
62
|
+
// 3. 触发初始化事件
|
|
63
|
+
this.$emit('init', {
|
|
64
|
+
config: res,
|
|
65
|
+
options: this.data,
|
|
66
|
+
value: this.innerValue
|
|
67
|
+
})
|
|
68
|
+
} else {
|
|
69
|
+
this.$message.error('配置错误,checkbox字段不是数组')
|
|
70
|
+
}
|
|
71
|
+
})
|
|
72
|
+
},
|
|
73
|
+
wrapperClassObject () {
|
|
74
|
+
const attrs = this.$attrs || {}
|
|
75
|
+
const classes = {}
|
|
76
|
+
const booleanStyleKeys = [
|
|
77
|
+
'compact', 'out-checkbox'
|
|
78
|
+
]
|
|
79
|
+
booleanStyleKeys.forEach(key => {
|
|
80
|
+
const val = attrs[key]
|
|
81
|
+
const truthy = val === true || val === '' || val === 'true'
|
|
82
|
+
if (truthy) classes[`x-checkbox-${key}`] = true
|
|
83
|
+
})
|
|
84
|
+
return classes
|
|
85
|
+
},
|
|
86
|
+
onChange (checkedValues) {
|
|
87
|
+
this.innerValue = checkedValues
|
|
88
|
+
this.$emit('change', checkedValues)
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
</script>
|
|
93
|
+
|
|
94
|
+
<style scoped lang="less">
|
|
95
|
+
.x-checkbox-container {
|
|
96
|
+
display: flex;
|
|
97
|
+
flex-direction: column;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.x-checkbox-group {
|
|
101
|
+
display: flex;
|
|
102
|
+
justify-content: space-around;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
.x-checkbox-item-container {
|
|
106
|
+
flex: 1;
|
|
107
|
+
display: flex;
|
|
108
|
+
flex-direction: column;
|
|
109
|
+
align-items: center;
|
|
110
|
+
text-align: center;
|
|
111
|
+
padding: 0 8px;
|
|
112
|
+
box-sizing: border-box;
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
.x-checkbox-item {
|
|
116
|
+
margin-bottom: 8px;
|
|
117
|
+
}
|
|
118
|
+
.x-checkbox-compact {
|
|
119
|
+
&.x-checkbox-container,
|
|
120
|
+
.x-checkbox-container {
|
|
121
|
+
:deep(.x-checkbox-item-container){
|
|
122
|
+
padding: 0px !important;
|
|
123
|
+
flex: auto !important;
|
|
124
|
+
}
|
|
125
|
+
:deep(.x-checkbox-item){
|
|
126
|
+
margin: 0px;
|
|
127
|
+
}
|
|
128
|
+
:deep(.x-checkbox-item) > span:last-child {
|
|
129
|
+
padding-right: 2px;
|
|
130
|
+
padding-left: 2px;
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
/* out-checkbox:外排版紧凑风格,与表单风格配置保持一致的布尔开关用法 */
|
|
136
|
+
.x-checkbox-container.x-checkbox-out-checkbox {
|
|
137
|
+
margin-top: 9px;
|
|
138
|
+
|
|
139
|
+
:deep(.x-checkbox-group) {
|
|
140
|
+
justify-content: flex-start;
|
|
141
|
+
flex-wrap: wrap;
|
|
142
|
+
gap: 0 46px;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
:deep(.x-checkbox-item-container) {
|
|
146
|
+
flex: 0 0 auto;
|
|
147
|
+
align-items: flex-start;
|
|
148
|
+
text-align: left;
|
|
149
|
+
padding: 0;
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
:deep(.x-checkbox-item) {
|
|
153
|
+
margin: 0;
|
|
154
|
+
display: flex;
|
|
155
|
+
align-items: center;
|
|
156
|
+
|
|
157
|
+
.ant-checkbox {
|
|
158
|
+
width: 20px;
|
|
159
|
+
height: 20px;
|
|
160
|
+
margin-right: 10px;
|
|
161
|
+
|
|
162
|
+
.ant-checkbox-inner {
|
|
163
|
+
width: 20px;
|
|
164
|
+
height: 20px;
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
/* 文字标签样式 */
|
|
169
|
+
span {
|
|
170
|
+
height: 23px;
|
|
171
|
+
opacity: 1;
|
|
172
|
+
font-family: 'Source Han Sans', sans-serif;
|
|
173
|
+
font-size: 16px;
|
|
174
|
+
font-weight: normal;
|
|
175
|
+
line-height: normal;
|
|
176
|
+
letter-spacing: 0em;
|
|
177
|
+
color: #313131;
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
}
|
|
181
|
+
</style>
|