af-mobile-client-vue3 1.1.38 → 1.1.40
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/components/data/XCellList/index.vue +3 -7
- package/src/components/data/XFormItem/index.vue +0 -1
- package/src/components/data/XReportGrid/XReportDemo.vue +33 -33
- package/src/components/data/XReportGrid/print.js +184 -184
- package/src/utils/queryFormDefaultRangePicker.ts +57 -57
- package/src/views/component/XCellListView/index.vue +122 -425
- package/src/views/component/XFormGroupView/index.vue +7 -4
- package/tsconfig.json +43 -43
- package/vite.config.ts +2 -2
package/package.json
CHANGED
|
@@ -211,11 +211,8 @@ function initComponent() {
|
|
|
211
211
|
|
|
212
212
|
// 初始化条件参数
|
|
213
213
|
function initConditionParams(formItems, isQuery) {
|
|
214
|
-
if (!formItems || !Array.isArray(formItems) || formItems.length === 0)
|
|
215
|
-
return
|
|
216
|
-
|
|
217
214
|
const defaultParams = {}
|
|
218
|
-
let hasDefaults
|
|
215
|
+
let hasDefaults: boolean
|
|
219
216
|
|
|
220
217
|
// 从表单配置中获取所有默认值
|
|
221
218
|
formItems.forEach((item) => {
|
|
@@ -239,12 +236,11 @@ function initConditionParams(formItems, isQuery) {
|
|
|
239
236
|
else {
|
|
240
237
|
defaultParams[item.model] = item.queryFormDefault
|
|
241
238
|
}
|
|
242
|
-
hasDefaults = true
|
|
243
239
|
}
|
|
244
|
-
hasDefaults = true
|
|
245
240
|
}
|
|
246
|
-
hasDefaults = true
|
|
247
241
|
})
|
|
242
|
+
// eslint-disable-next-line prefer-const
|
|
243
|
+
hasDefaults = true
|
|
248
244
|
|
|
249
245
|
// 如果有默认值,则设置到条件参数中并立即执行查询
|
|
250
246
|
queryDefaultParams.value = defaultParams
|
|
@@ -1,33 +1,33 @@
|
|
|
1
|
-
<script setup lang="ts">
|
|
2
|
-
import { onMounted, ref } from 'vue'
|
|
3
|
-
import XReport from './XReport.vue'
|
|
4
|
-
|
|
5
|
-
const mainRef = ref()
|
|
6
|
-
|
|
7
|
-
onMounted(() => {
|
|
8
|
-
// 初始化逻辑
|
|
9
|
-
})
|
|
10
|
-
</script>
|
|
11
|
-
|
|
12
|
-
<template>
|
|
13
|
-
<div id="test">
|
|
14
|
-
<van-card :bordered="false">
|
|
15
|
-
<XReport
|
|
16
|
-
ref="mainRef"
|
|
17
|
-
:use-oss-for-img="false"
|
|
18
|
-
config-name="nurseWorkstationCover"
|
|
19
|
-
server-name="af-his"
|
|
20
|
-
:show-img-in-cell="true"
|
|
21
|
-
:display-only="true"
|
|
22
|
-
:edit-mode="false"
|
|
23
|
-
:show-save-button="false"
|
|
24
|
-
:no-padding="true"
|
|
25
|
-
:dont-format="true"
|
|
26
|
-
/>
|
|
27
|
-
</van-card>
|
|
28
|
-
</div>
|
|
29
|
-
</template>
|
|
30
|
-
|
|
31
|
-
<style scoped>
|
|
32
|
-
|
|
33
|
-
</style>
|
|
1
|
+
<script setup lang="ts">
|
|
2
|
+
import { onMounted, ref } from 'vue'
|
|
3
|
+
import XReport from './XReport.vue'
|
|
4
|
+
|
|
5
|
+
const mainRef = ref()
|
|
6
|
+
|
|
7
|
+
onMounted(() => {
|
|
8
|
+
// 初始化逻辑
|
|
9
|
+
})
|
|
10
|
+
</script>
|
|
11
|
+
|
|
12
|
+
<template>
|
|
13
|
+
<div id="test">
|
|
14
|
+
<van-card :bordered="false">
|
|
15
|
+
<XReport
|
|
16
|
+
ref="mainRef"
|
|
17
|
+
:use-oss-for-img="false"
|
|
18
|
+
config-name="nurseWorkstationCover"
|
|
19
|
+
server-name="af-his"
|
|
20
|
+
:show-img-in-cell="true"
|
|
21
|
+
:display-only="true"
|
|
22
|
+
:edit-mode="false"
|
|
23
|
+
:show-save-button="false"
|
|
24
|
+
:no-padding="true"
|
|
25
|
+
:dont-format="true"
|
|
26
|
+
/>
|
|
27
|
+
</van-card>
|
|
28
|
+
</div>
|
|
29
|
+
</template>
|
|
30
|
+
|
|
31
|
+
<style scoped>
|
|
32
|
+
|
|
33
|
+
</style>
|
|
@@ -1,184 +1,184 @@
|
|
|
1
|
-
// print.js
|
|
2
|
-
|
|
3
|
-
export function printElement(elementToPrint) {
|
|
4
|
-
// 创建一个新的浏览器窗口
|
|
5
|
-
const printWindow = window.open('', '_blank', 'height=1024,width=768')
|
|
6
|
-
// 设置新窗口的文档内容
|
|
7
|
-
printWindow.document.write(`
|
|
8
|
-
<html>
|
|
9
|
-
<head>
|
|
10
|
-
<title>Print</title>
|
|
11
|
-
<style>
|
|
12
|
-
@page {
|
|
13
|
-
size: auto;
|
|
14
|
-
margin: 0mm;
|
|
15
|
-
}
|
|
16
|
-
html, body {
|
|
17
|
-
margin: 0;
|
|
18
|
-
padding: 0;
|
|
19
|
-
width: 100%;
|
|
20
|
-
height: 100%;
|
|
21
|
-
}
|
|
22
|
-
#print-container {
|
|
23
|
-
display: none
|
|
24
|
-
}
|
|
25
|
-
.img{
|
|
26
|
-
width: 95%;
|
|
27
|
-
height: 180px;
|
|
28
|
-
object-fit: cover;
|
|
29
|
-
}
|
|
30
|
-
.reportMain {
|
|
31
|
-
text-align: center;
|
|
32
|
-
margin: 0 auto;
|
|
33
|
-
font-size: 16px;
|
|
34
|
-
color: #000;
|
|
35
|
-
background-color: #fff;
|
|
36
|
-
border-radius: 8px;
|
|
37
|
-
|
|
38
|
-
.reportTitle {
|
|
39
|
-
font-weight: bold;
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
.subTitle {
|
|
43
|
-
display: flex;
|
|
44
|
-
justify-content: space-between;
|
|
45
|
-
margin-bottom: 1%;
|
|
46
|
-
|
|
47
|
-
.subTitleItems {
|
|
48
|
-
max-width: 30%;
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
.inputsDiv {
|
|
53
|
-
display: flex;
|
|
54
|
-
justify-content: space-between;
|
|
55
|
-
.inputsDivItem {
|
|
56
|
-
display: flex;
|
|
57
|
-
align-items: center;
|
|
58
|
-
padding: 0 4px;
|
|
59
|
-
white-space: nowrap;
|
|
60
|
-
.inputsDivItemLabel {
|
|
61
|
-
padding: 0 4px;
|
|
62
|
-
}
|
|
63
|
-
}
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
.reportTable {
|
|
67
|
-
width: 100%;
|
|
68
|
-
border-collapse: collapse;
|
|
69
|
-
table-layout:fixed;
|
|
70
|
-
word-break:break-all;
|
|
71
|
-
text-align: center;
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
.reportMainForDisplay {
|
|
75
|
-
text-align: center;
|
|
76
|
-
margin: 10% auto;
|
|
77
|
-
font-size: 16px;
|
|
78
|
-
color: #000;
|
|
79
|
-
background-color: #fff;
|
|
80
|
-
border-radius: 8px;
|
|
81
|
-
|
|
82
|
-
.reportTitle {
|
|
83
|
-
font-weight: bold;
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
.subTitle {
|
|
87
|
-
display: flex;
|
|
88
|
-
justify-content: space-between;
|
|
89
|
-
|
|
90
|
-
.subTitleItems {
|
|
91
|
-
max-width: 30%;
|
|
92
|
-
}
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
.inputsDiv {
|
|
96
|
-
display: flex;
|
|
97
|
-
justify-content: space-around;
|
|
98
|
-
.inputsDivItem {
|
|
99
|
-
display: flex;
|
|
100
|
-
align-items: center;
|
|
101
|
-
padding: 0 4px;
|
|
102
|
-
white-space: nowrap;
|
|
103
|
-
.inputsDivItemLabel {
|
|
104
|
-
padding: 0 4px;
|
|
105
|
-
}
|
|
106
|
-
}
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
.reportTable {
|
|
110
|
-
width: 100%;
|
|
111
|
-
border-collapse: collapse;
|
|
112
|
-
table-layout:fixed;
|
|
113
|
-
word-break:break-all;
|
|
114
|
-
}
|
|
115
|
-
}
|
|
116
|
-
.reportMainNoPadding {
|
|
117
|
-
text-align: center;
|
|
118
|
-
margin: 0 auto;
|
|
119
|
-
font-size: 16px;
|
|
120
|
-
color: #000;
|
|
121
|
-
background-color: #fff;
|
|
122
|
-
border-radius: 8px;
|
|
123
|
-
|
|
124
|
-
.reportTitle {
|
|
125
|
-
font-weight: bold;
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
.subTitle {
|
|
129
|
-
display: flex;
|
|
130
|
-
justify-content: space-between;
|
|
131
|
-
|
|
132
|
-
.subTitleItems {
|
|
133
|
-
max-width: 30%;
|
|
134
|
-
}
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
.inputsDiv {
|
|
138
|
-
display: flex;
|
|
139
|
-
justify-content: space-between;
|
|
140
|
-
.inputsDivItem {
|
|
141
|
-
display: flex;
|
|
142
|
-
align-items: center;
|
|
143
|
-
padding: 0 4px;
|
|
144
|
-
white-space: nowrap;
|
|
145
|
-
.inputsDivItemLabel {
|
|
146
|
-
padding: 0 4px;
|
|
147
|
-
}
|
|
148
|
-
}
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
.reportTable {
|
|
152
|
-
width: 100%;
|
|
153
|
-
border-collapse: collapse;
|
|
154
|
-
table-layout:fixed;
|
|
155
|
-
word-break:break-all;
|
|
156
|
-
}
|
|
157
|
-
}
|
|
158
|
-
.tools{
|
|
159
|
-
position: fixed;
|
|
160
|
-
right: 2%;
|
|
161
|
-
text-align: right;
|
|
162
|
-
width: 60%;
|
|
163
|
-
cursor: pointer;
|
|
164
|
-
.toolsItem{
|
|
165
|
-
width: 15%;
|
|
166
|
-
margin-right: 3%;
|
|
167
|
-
display: inline-block;
|
|
168
|
-
}
|
|
169
|
-
}
|
|
170
|
-
</style>
|
|
171
|
-
</head>
|
|
172
|
-
<body>
|
|
173
|
-
<!-- 将需要打印的元素内容复制到新窗口中 -->
|
|
174
|
-
${elementToPrint.innerHTML}
|
|
175
|
-
</body>
|
|
176
|
-
</html>
|
|
177
|
-
`)
|
|
178
|
-
// 延迟执行打印,以确保新窗口的内容已加载完成
|
|
179
|
-
printWindow.document.close() // 关闭文档流,确保内容完全加载
|
|
180
|
-
setTimeout(() => {
|
|
181
|
-
printWindow.print() // 调用打印方法
|
|
182
|
-
printWindow.close()
|
|
183
|
-
}, 500) // 延迟500毫秒后执行打印
|
|
184
|
-
}
|
|
1
|
+
// print.js
|
|
2
|
+
|
|
3
|
+
export function printElement(elementToPrint) {
|
|
4
|
+
// 创建一个新的浏览器窗口
|
|
5
|
+
const printWindow = window.open('', '_blank', 'height=1024,width=768')
|
|
6
|
+
// 设置新窗口的文档内容
|
|
7
|
+
printWindow.document.write(`
|
|
8
|
+
<html>
|
|
9
|
+
<head>
|
|
10
|
+
<title>Print</title>
|
|
11
|
+
<style>
|
|
12
|
+
@page {
|
|
13
|
+
size: auto;
|
|
14
|
+
margin: 0mm;
|
|
15
|
+
}
|
|
16
|
+
html, body {
|
|
17
|
+
margin: 0;
|
|
18
|
+
padding: 0;
|
|
19
|
+
width: 100%;
|
|
20
|
+
height: 100%;
|
|
21
|
+
}
|
|
22
|
+
#print-container {
|
|
23
|
+
display: none
|
|
24
|
+
}
|
|
25
|
+
.img{
|
|
26
|
+
width: 95%;
|
|
27
|
+
height: 180px;
|
|
28
|
+
object-fit: cover;
|
|
29
|
+
}
|
|
30
|
+
.reportMain {
|
|
31
|
+
text-align: center;
|
|
32
|
+
margin: 0 auto;
|
|
33
|
+
font-size: 16px;
|
|
34
|
+
color: #000;
|
|
35
|
+
background-color: #fff;
|
|
36
|
+
border-radius: 8px;
|
|
37
|
+
|
|
38
|
+
.reportTitle {
|
|
39
|
+
font-weight: bold;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.subTitle {
|
|
43
|
+
display: flex;
|
|
44
|
+
justify-content: space-between;
|
|
45
|
+
margin-bottom: 1%;
|
|
46
|
+
|
|
47
|
+
.subTitleItems {
|
|
48
|
+
max-width: 30%;
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.inputsDiv {
|
|
53
|
+
display: flex;
|
|
54
|
+
justify-content: space-between;
|
|
55
|
+
.inputsDivItem {
|
|
56
|
+
display: flex;
|
|
57
|
+
align-items: center;
|
|
58
|
+
padding: 0 4px;
|
|
59
|
+
white-space: nowrap;
|
|
60
|
+
.inputsDivItemLabel {
|
|
61
|
+
padding: 0 4px;
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
.reportTable {
|
|
67
|
+
width: 100%;
|
|
68
|
+
border-collapse: collapse;
|
|
69
|
+
table-layout:fixed;
|
|
70
|
+
word-break:break-all;
|
|
71
|
+
text-align: center;
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
.reportMainForDisplay {
|
|
75
|
+
text-align: center;
|
|
76
|
+
margin: 10% auto;
|
|
77
|
+
font-size: 16px;
|
|
78
|
+
color: #000;
|
|
79
|
+
background-color: #fff;
|
|
80
|
+
border-radius: 8px;
|
|
81
|
+
|
|
82
|
+
.reportTitle {
|
|
83
|
+
font-weight: bold;
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
.subTitle {
|
|
87
|
+
display: flex;
|
|
88
|
+
justify-content: space-between;
|
|
89
|
+
|
|
90
|
+
.subTitleItems {
|
|
91
|
+
max-width: 30%;
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
.inputsDiv {
|
|
96
|
+
display: flex;
|
|
97
|
+
justify-content: space-around;
|
|
98
|
+
.inputsDivItem {
|
|
99
|
+
display: flex;
|
|
100
|
+
align-items: center;
|
|
101
|
+
padding: 0 4px;
|
|
102
|
+
white-space: nowrap;
|
|
103
|
+
.inputsDivItemLabel {
|
|
104
|
+
padding: 0 4px;
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
.reportTable {
|
|
110
|
+
width: 100%;
|
|
111
|
+
border-collapse: collapse;
|
|
112
|
+
table-layout:fixed;
|
|
113
|
+
word-break:break-all;
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
.reportMainNoPadding {
|
|
117
|
+
text-align: center;
|
|
118
|
+
margin: 0 auto;
|
|
119
|
+
font-size: 16px;
|
|
120
|
+
color: #000;
|
|
121
|
+
background-color: #fff;
|
|
122
|
+
border-radius: 8px;
|
|
123
|
+
|
|
124
|
+
.reportTitle {
|
|
125
|
+
font-weight: bold;
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
.subTitle {
|
|
129
|
+
display: flex;
|
|
130
|
+
justify-content: space-between;
|
|
131
|
+
|
|
132
|
+
.subTitleItems {
|
|
133
|
+
max-width: 30%;
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
.inputsDiv {
|
|
138
|
+
display: flex;
|
|
139
|
+
justify-content: space-between;
|
|
140
|
+
.inputsDivItem {
|
|
141
|
+
display: flex;
|
|
142
|
+
align-items: center;
|
|
143
|
+
padding: 0 4px;
|
|
144
|
+
white-space: nowrap;
|
|
145
|
+
.inputsDivItemLabel {
|
|
146
|
+
padding: 0 4px;
|
|
147
|
+
}
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
.reportTable {
|
|
152
|
+
width: 100%;
|
|
153
|
+
border-collapse: collapse;
|
|
154
|
+
table-layout:fixed;
|
|
155
|
+
word-break:break-all;
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
.tools{
|
|
159
|
+
position: fixed;
|
|
160
|
+
right: 2%;
|
|
161
|
+
text-align: right;
|
|
162
|
+
width: 60%;
|
|
163
|
+
cursor: pointer;
|
|
164
|
+
.toolsItem{
|
|
165
|
+
width: 15%;
|
|
166
|
+
margin-right: 3%;
|
|
167
|
+
display: inline-block;
|
|
168
|
+
}
|
|
169
|
+
}
|
|
170
|
+
</style>
|
|
171
|
+
</head>
|
|
172
|
+
<body>
|
|
173
|
+
<!-- 将需要打印的元素内容复制到新窗口中 -->
|
|
174
|
+
${elementToPrint.innerHTML}
|
|
175
|
+
</body>
|
|
176
|
+
</html>
|
|
177
|
+
`)
|
|
178
|
+
// 延迟执行打印,以确保新窗口的内容已加载完成
|
|
179
|
+
printWindow.document.close() // 关闭文档流,确保内容完全加载
|
|
180
|
+
setTimeout(() => {
|
|
181
|
+
printWindow.print() // 调用打印方法
|
|
182
|
+
printWindow.close()
|
|
183
|
+
}, 500) // 延迟500毫秒后执行打印
|
|
184
|
+
}
|
|
@@ -1,57 +1,57 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* 根据类型获取日期区间字符串
|
|
3
|
-
* @param type '当年' | 'curMonth' | '当日'
|
|
4
|
-
* @param show 区分实际值还是显示值, true为实际值, false为显示值
|
|
5
|
-
* @returns [start, end] 例:['2024-01-01 00:00:00', '2024-12-31 23:59:59']
|
|
6
|
-
*/
|
|
7
|
-
export function getRangeByType(type: string, show: boolean): [string, string] {
|
|
8
|
-
const now = new Date()
|
|
9
|
-
const year = now.getFullYear()
|
|
10
|
-
const month = (now.getMonth() + 1).toString().padStart(2, '0')
|
|
11
|
-
const day = now.getDate().toString().padStart(2, '0')
|
|
12
|
-
|
|
13
|
-
if (!show) {
|
|
14
|
-
if (type === 'curYear') {
|
|
15
|
-
return [
|
|
16
|
-
`${year}-01-01 00:00:00`,
|
|
17
|
-
`${year}-12-31 23:59:59`,
|
|
18
|
-
]
|
|
19
|
-
}
|
|
20
|
-
if (type === 'curMonth') {
|
|
21
|
-
const lastDay = new Date(year, now.getMonth() + 1, 0).getDate()
|
|
22
|
-
return [
|
|
23
|
-
`${year}-${month}-01 00:00:00`,
|
|
24
|
-
`${year}-${month}-${lastDay.toString().padStart(2, '0')} 23:59:59`,
|
|
25
|
-
]
|
|
26
|
-
}
|
|
27
|
-
if (type === 'curDay') {
|
|
28
|
-
return [
|
|
29
|
-
`${year}-${month}-${day} 00:00:00`,
|
|
30
|
-
`${year}-${month}-${day} 23:59:59`,
|
|
31
|
-
]
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
if (show) {
|
|
35
|
-
if (type === 'curYear') {
|
|
36
|
-
return [
|
|
37
|
-
`${year}-01-01`,
|
|
38
|
-
`${year}-12-31`,
|
|
39
|
-
]
|
|
40
|
-
}
|
|
41
|
-
if (type === 'curMonth') {
|
|
42
|
-
const lastDay = new Date(year, now.getMonth() + 1, 0).getDate()
|
|
43
|
-
return [
|
|
44
|
-
`${year}-${month}-01`,
|
|
45
|
-
`${year}-${month}-${lastDay.toString().padStart(2, '0')}`,
|
|
46
|
-
]
|
|
47
|
-
}
|
|
48
|
-
if (type === 'curDay') {
|
|
49
|
-
return [
|
|
50
|
-
`${year}-${month}-${day}`,
|
|
51
|
-
`${year}-${month}-${day}`,
|
|
52
|
-
]
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
// 兜底返回空字符串数组
|
|
56
|
-
return ['', '']
|
|
57
|
-
}
|
|
1
|
+
/**
|
|
2
|
+
* 根据类型获取日期区间字符串
|
|
3
|
+
* @param type '当年' | 'curMonth' | '当日'
|
|
4
|
+
* @param show 区分实际值还是显示值, true为实际值, false为显示值
|
|
5
|
+
* @returns [start, end] 例:['2024-01-01 00:00:00', '2024-12-31 23:59:59']
|
|
6
|
+
*/
|
|
7
|
+
export function getRangeByType(type: string, show: boolean): [string, string] {
|
|
8
|
+
const now = new Date()
|
|
9
|
+
const year = now.getFullYear()
|
|
10
|
+
const month = (now.getMonth() + 1).toString().padStart(2, '0')
|
|
11
|
+
const day = now.getDate().toString().padStart(2, '0')
|
|
12
|
+
|
|
13
|
+
if (!show) {
|
|
14
|
+
if (type === 'curYear') {
|
|
15
|
+
return [
|
|
16
|
+
`${year}-01-01 00:00:00`,
|
|
17
|
+
`${year}-12-31 23:59:59`,
|
|
18
|
+
]
|
|
19
|
+
}
|
|
20
|
+
if (type === 'curMonth') {
|
|
21
|
+
const lastDay = new Date(year, now.getMonth() + 1, 0).getDate()
|
|
22
|
+
return [
|
|
23
|
+
`${year}-${month}-01 00:00:00`,
|
|
24
|
+
`${year}-${month}-${lastDay.toString().padStart(2, '0')} 23:59:59`,
|
|
25
|
+
]
|
|
26
|
+
}
|
|
27
|
+
if (type === 'curDay') {
|
|
28
|
+
return [
|
|
29
|
+
`${year}-${month}-${day} 00:00:00`,
|
|
30
|
+
`${year}-${month}-${day} 23:59:59`,
|
|
31
|
+
]
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
if (show) {
|
|
35
|
+
if (type === 'curYear') {
|
|
36
|
+
return [
|
|
37
|
+
`${year}-01-01`,
|
|
38
|
+
`${year}-12-31`,
|
|
39
|
+
]
|
|
40
|
+
}
|
|
41
|
+
if (type === 'curMonth') {
|
|
42
|
+
const lastDay = new Date(year, now.getMonth() + 1, 0).getDate()
|
|
43
|
+
return [
|
|
44
|
+
`${year}-${month}-01`,
|
|
45
|
+
`${year}-${month}-${lastDay.toString().padStart(2, '0')}`,
|
|
46
|
+
]
|
|
47
|
+
}
|
|
48
|
+
if (type === 'curDay') {
|
|
49
|
+
return [
|
|
50
|
+
`${year}-${month}-${day}`,
|
|
51
|
+
`${year}-${month}-${day}`,
|
|
52
|
+
]
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
// 兜底返回空字符串数组
|
|
56
|
+
return ['', '']
|
|
57
|
+
}
|
|
@@ -1,451 +1,148 @@
|
|
|
1
1
|
<script setup lang="ts">
|
|
2
2
|
import XCellList from '@af-mobile-client-vue3/components/data/XCellList/index.vue'
|
|
3
|
-
import
|
|
4
|
-
import { post } from '@af-mobile-client-vue3/services/restTools'
|
|
3
|
+
import NormalDataLayout from '@af-mobile-client-vue3/components/layout/NormalDataLayout/index.vue'
|
|
5
4
|
import { useUserStore } from '@af-mobile-client-vue3/stores/modules/user'
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
showNotify,
|
|
9
|
-
Badge as VanBadge,
|
|
10
|
-
Dialog as VanDialog,
|
|
11
|
-
Field as VanField,
|
|
12
|
-
Icon as VanIcon,
|
|
13
|
-
Radio as VanRadio,
|
|
14
|
-
RadioGroup as VanRadioGroup,
|
|
15
|
-
} from 'vant'
|
|
16
|
-
import { defineEmits, onMounted, onUnmounted, reactive, ref } from 'vue'
|
|
5
|
+
import { defineEmits, ref } from 'vue'
|
|
6
|
+
import { useRouter } from 'vue-router'
|
|
17
7
|
|
|
18
8
|
// 定义事件
|
|
19
9
|
const emit = defineEmits(['deleteRow'])
|
|
20
|
-
const
|
|
21
|
-
|
|
22
|
-
const
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
const
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
//
|
|
33
|
-
const
|
|
34
|
-
|
|
35
|
-
//
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
//
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
10
|
+
const userInfo = useUserStore().getUserInfo()
|
|
11
|
+
// 访问路由
|
|
12
|
+
const router = useRouter()
|
|
13
|
+
// 获取默认值
|
|
14
|
+
const idKey = ref('o_id')
|
|
15
|
+
|
|
16
|
+
// 简易crud表单测试
|
|
17
|
+
// const configName = ref('orderCarInMobileCRUD')
|
|
18
|
+
// const serviceName = ref('af-gaslink')
|
|
19
|
+
// const configName = ref('lngPriceManageMobileCRUD')
|
|
20
|
+
const configName = ref('测试')
|
|
21
|
+
const serviceName = ref('af-gaslink')
|
|
22
|
+
// const configName = ref('mobile_liushuiQueryCRUD')
|
|
23
|
+
// const serviceName = ref('af-revenue')
|
|
24
|
+
|
|
25
|
+
// 资源权限测试
|
|
26
|
+
// const configName = ref('crud_sources_test')
|
|
27
|
+
// const serviceName = ref('af-system')
|
|
28
|
+
|
|
29
|
+
// 实际业务测试
|
|
30
|
+
// const configName = ref('lngChargeAuditMobileCRUD')
|
|
31
|
+
// const serviceName = ref('af-gaslink')
|
|
32
|
+
|
|
33
|
+
// 跳转到详情页面
|
|
34
|
+
// function toDetail(item) {
|
|
35
|
+
// router.push({
|
|
36
|
+
// name: 'XCellDetailView',
|
|
37
|
+
// params: { id: item[idKey.value] }, // 如果使用命名路由,推荐使用路由参数而不是直接构建 URL
|
|
38
|
+
// query: {
|
|
39
|
+
// operName: item[operNameKey.value],
|
|
40
|
+
// method:item[methodKey.value],
|
|
41
|
+
// requestMethod:item[requestMethodKey.value],
|
|
42
|
+
// operatorType:item[operatorTypeKey.value],
|
|
43
|
+
// operUrl:item[operUrlKey.value],
|
|
44
|
+
// operIp:item[operIpKey.value],
|
|
45
|
+
// costTime:item[costTimeKey.value],
|
|
46
|
+
// operTime:item[operTimeKey.value],
|
|
47
|
+
//
|
|
48
|
+
// title: item[titleKey.value],
|
|
49
|
+
// businessType: item[businessTypeKey.value],
|
|
50
|
+
// status:item[statusKey.value]
|
|
51
|
+
// }
|
|
52
|
+
// })
|
|
53
|
+
// }
|
|
54
|
+
|
|
55
|
+
// 跳转到表单——以表单组来渲染纯表单
|
|
56
|
+
function toDetail(item) {
|
|
57
|
+
router.push({
|
|
58
|
+
name: 'XFormGroupView',
|
|
59
|
+
// query: {
|
|
60
|
+
// id: item[idKey.value],
|
|
61
|
+
// id: item.rr_id,
|
|
62
|
+
// o_id: item.o_id,
|
|
63
|
+
// },
|
|
59
64
|
})
|
|
60
65
|
}
|
|
61
66
|
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
67
|
+
// 新增功能
|
|
68
|
+
// function addOption(totalCount) {
|
|
69
|
+
// router.push({
|
|
70
|
+
// name: 'XFormView',
|
|
71
|
+
// params: { id: totalCount, openid: totalCount },
|
|
72
|
+
// query: {
|
|
73
|
+
// configName: configName.value,
|
|
74
|
+
// serviceName: serviceName.value,
|
|
75
|
+
// mode: '新增',
|
|
76
|
+
// },
|
|
77
|
+
// })
|
|
78
|
+
// }
|
|
79
|
+
function addOption(callback) {
|
|
80
|
+
router.push({
|
|
81
|
+
name: 'XFormGroupView',
|
|
82
|
+
// params: { id: totalCount.value },
|
|
83
|
+
// query: {
|
|
84
|
+
// configName: configName.value,
|
|
85
|
+
// serviceName: serviceName.value,
|
|
86
|
+
// mode: '新增',
|
|
87
|
+
// },
|
|
77
88
|
})
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
onUnmounted(() => {
|
|
82
|
-
if (timer) {
|
|
83
|
-
clearInterval(timer)
|
|
84
|
-
timer = null
|
|
89
|
+
// 如果存在回调函数,调用它并传递true表示已处理
|
|
90
|
+
if (typeof callback === 'function') {
|
|
91
|
+
callback(true)
|
|
85
92
|
}
|
|
86
|
-
})
|
|
87
|
-
|
|
88
|
-
// 添加新的状态变量
|
|
89
|
-
const showCompleteDialog = ref(false)
|
|
90
|
-
const showInvalidateDialog = ref(false)
|
|
91
|
-
const currentItem = ref(null)
|
|
92
|
-
const completeForm = reactive({
|
|
93
|
-
result: '',
|
|
94
|
-
problemDesc: '',
|
|
95
|
-
remark: '',
|
|
96
|
-
})
|
|
97
|
-
const invalidateForm = reactive({
|
|
98
|
-
reason: '',
|
|
99
|
-
remark: '',
|
|
100
|
-
})
|
|
101
|
-
|
|
102
|
-
// 安检结果选项
|
|
103
|
-
const inspectionResults = ref([])
|
|
104
|
-
|
|
105
|
-
// 作废原因选项
|
|
106
|
-
const invalidateReasons = ref([])
|
|
107
|
-
|
|
108
|
-
// 开始安检
|
|
109
|
-
function accept(item) {
|
|
110
|
-
currentItem.value = item
|
|
111
|
-
showCompleteDialog.value = true
|
|
112
|
-
}
|
|
113
|
-
// 作废安检
|
|
114
|
-
function showInvalidated(item) {
|
|
115
|
-
currentItem.value = item
|
|
116
|
-
showInvalidateDialog.value = true
|
|
117
93
|
}
|
|
118
|
-
// 完成安检
|
|
119
|
-
function completed() {
|
|
120
|
-
if (!completeForm.result) {
|
|
121
|
-
showNotify({
|
|
122
|
-
type: 'warning',
|
|
123
|
-
message: '请选择安检结果',
|
|
124
|
-
duration: 2000,
|
|
125
|
-
})
|
|
126
|
-
return false
|
|
127
|
-
}
|
|
128
|
-
|
|
129
|
-
const currentResult = inspectionResults.value.find(item => item.value === completeForm.result)
|
|
130
|
-
if (currentResult?.showProblemDesc && !completeForm.problemDesc) {
|
|
131
|
-
showNotify({
|
|
132
|
-
type: 'warning',
|
|
133
|
-
message: '请填写问题描述',
|
|
134
|
-
duration: 2000,
|
|
135
|
-
})
|
|
136
|
-
return false
|
|
137
|
-
}
|
|
138
94
|
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
message: '安检完成',
|
|
151
|
-
duration: 2000,
|
|
152
|
-
})
|
|
153
|
-
// 刷新列表
|
|
154
|
-
cellListRef.value?.updateConditionAndRefresh()
|
|
155
|
-
fetchTodoData()
|
|
156
|
-
// 关闭弹窗并重置表单
|
|
157
|
-
showCompleteDialog.value = false
|
|
158
|
-
resetCompleteForm()
|
|
95
|
+
// 修改功能
|
|
96
|
+
function updateRow(result, callback) {
|
|
97
|
+
console.log('用户----', userInfo)
|
|
98
|
+
router.push({
|
|
99
|
+
name: 'XFormGroupView',
|
|
100
|
+
// params: { id: result.o_id, openid: result.o_id },
|
|
101
|
+
// query: {
|
|
102
|
+
// configName: configName.value,
|
|
103
|
+
// serviceName: serviceName.value,
|
|
104
|
+
// mode: '修改',
|
|
105
|
+
// },
|
|
159
106
|
})
|
|
160
|
-
return true
|
|
161
|
-
}
|
|
162
107
|
|
|
163
|
-
//
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
showNotify({
|
|
167
|
-
type: 'warning',
|
|
168
|
-
message: '请选择作废原因',
|
|
169
|
-
duration: 2000,
|
|
170
|
-
})
|
|
171
|
-
return false
|
|
108
|
+
// 如果存在回调函数,调用它并传递true表示已处理
|
|
109
|
+
if (typeof callback === 'function') {
|
|
110
|
+
callback(true)
|
|
172
111
|
}
|
|
173
|
-
|
|
174
|
-
// TODO: 调用后端API保存作废信息
|
|
175
|
-
post('/af-safecheck/entity/save/t_order_safecheck', {
|
|
176
|
-
id: currentItem.value.os_id,
|
|
177
|
-
f_accept_status: '已作废',
|
|
178
|
-
f_problem_desc: `${invalidateForm.reason}-${invalidateForm.remark}`,
|
|
179
|
-
version: currentItem.value.os_version,
|
|
180
|
-
}).then(() => {
|
|
181
|
-
showNotify({
|
|
182
|
-
type: 'success',
|
|
183
|
-
message: '安检已作废',
|
|
184
|
-
duration: 2000,
|
|
185
|
-
})
|
|
186
|
-
// 刷新列表
|
|
187
|
-
cellListRef.value?.updateConditionAndRefresh()
|
|
188
|
-
fetchTodoData()
|
|
189
|
-
// 关闭弹窗并重置表单
|
|
190
|
-
showInvalidateDialog.value = false
|
|
191
|
-
resetInvalidateForm()
|
|
192
|
-
})
|
|
193
|
-
return true
|
|
194
112
|
}
|
|
195
113
|
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
id: item.os_id,
|
|
200
|
-
f_accept_status: '待安检',
|
|
201
|
-
f_accept_user_id: userState.f.resources.id,
|
|
202
|
-
f_accept_user_name: userState.f.resources.name,
|
|
203
|
-
version: item.os_version,
|
|
204
|
-
}).then(() => {
|
|
205
|
-
showNotify({
|
|
206
|
-
type: 'success',
|
|
207
|
-
message: '已成功受理,请及时安检!',
|
|
208
|
-
duration: 2000,
|
|
209
|
-
})
|
|
210
|
-
// 刷新列表
|
|
211
|
-
cellListRef.value?.updateConditionAndRefresh()
|
|
212
|
-
fetchTodoData()
|
|
213
|
-
})
|
|
214
|
-
return true
|
|
215
|
-
}
|
|
216
|
-
function cancelAccept(item) {
|
|
217
|
-
// TODO: 调用后端API保存作废信息
|
|
218
|
-
post('/af-safecheck/entity/save/t_order_safecheck', {
|
|
219
|
-
id: item.os_id,
|
|
220
|
-
f_accept_status: '待受理',
|
|
221
|
-
f_accept_user_id: null,
|
|
222
|
-
f_accept_user_name: null,
|
|
223
|
-
version: item.os_version,
|
|
224
|
-
}).then(() => {
|
|
225
|
-
showNotify({
|
|
226
|
-
type: 'success',
|
|
227
|
-
message: '已成功取消受理!',
|
|
228
|
-
duration: 2000,
|
|
229
|
-
})
|
|
230
|
-
// 刷新列表
|
|
231
|
-
cellListRef.value?.updateConditionAndRefresh()
|
|
232
|
-
fetchTodoData()
|
|
233
|
-
})
|
|
234
|
-
return true
|
|
235
|
-
}
|
|
236
|
-
function getConfig() {
|
|
237
|
-
getConfigByName('invalidateReasonsConfig', (result) => {
|
|
238
|
-
if (result?.value)
|
|
239
|
-
invalidateReasons.value = result.value
|
|
240
|
-
}, 'af-safecheck')
|
|
241
|
-
getConfigByName('inspectionResultsConfig', (result) => {
|
|
242
|
-
if (result?.value)
|
|
243
|
-
inspectionResults.value = result.value
|
|
244
|
-
}, 'af-safecheck')
|
|
245
|
-
}
|
|
246
|
-
// 重置完成安检表单
|
|
247
|
-
function resetCompleteForm() {
|
|
248
|
-
completeForm.result = ''
|
|
249
|
-
completeForm.problemDesc = ''
|
|
250
|
-
completeForm.remark = ''
|
|
251
|
-
}
|
|
252
|
-
|
|
253
|
-
// 重置作废安检表单
|
|
254
|
-
function resetInvalidateForm() {
|
|
255
|
-
invalidateForm.reason = ''
|
|
256
|
-
invalidateForm.remark = ''
|
|
257
|
-
}
|
|
258
|
-
// 退出登录
|
|
259
|
-
async function exit_login() {
|
|
260
|
-
showDialog({
|
|
261
|
-
title: '提示',
|
|
262
|
-
message: '确定要退出登录吗?',
|
|
263
|
-
confirmButtonText: '确定',
|
|
264
|
-
cancelButtonText: '取消',
|
|
265
|
-
showCancelButton: true,
|
|
266
|
-
}).then(async () => {
|
|
267
|
-
await useUserStore().logout()
|
|
268
|
-
}).catch(() => {
|
|
269
|
-
// 用户点击取消,不做任何操作
|
|
270
|
-
})
|
|
114
|
+
// 删除功能
|
|
115
|
+
function deleteRow(result) {
|
|
116
|
+
emit('deleteRow', result.o_id)
|
|
271
117
|
}
|
|
272
118
|
</script>
|
|
273
119
|
|
|
274
120
|
<template>
|
|
275
|
-
<
|
|
276
|
-
<
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
</VanBadge>
|
|
300
|
-
</template>
|
|
301
|
-
</XCellList>
|
|
302
|
-
|
|
303
|
-
<!-- 完成安检弹窗 -->
|
|
304
|
-
<VanDialog
|
|
305
|
-
v-model:show="showCompleteDialog"
|
|
306
|
-
title="完成安检"
|
|
307
|
-
show-cancel-button
|
|
308
|
-
:close-on-click-overlay="false"
|
|
309
|
-
:close-on-popstate="false"
|
|
310
|
-
:before-close="(action) => action === 'confirm' ? completed() : true"
|
|
311
|
-
class="inspection-dialog"
|
|
312
|
-
@cancel="resetCompleteForm"
|
|
313
|
-
>
|
|
314
|
-
<div class="dialog-content">
|
|
315
|
-
<div class="form-item">
|
|
316
|
-
<div class="form-label">
|
|
317
|
-
安检结果
|
|
318
|
-
</div>
|
|
319
|
-
<VanRadioGroup v-model="completeForm.result" class="radio-group">
|
|
320
|
-
<VanRadio
|
|
321
|
-
v-for="item in inspectionResults"
|
|
322
|
-
:key="item.value"
|
|
323
|
-
:name="item.value"
|
|
324
|
-
class="radio-item"
|
|
325
|
-
>
|
|
326
|
-
{{ item.label }}
|
|
327
|
-
</VanRadio>
|
|
328
|
-
</VanRadioGroup>
|
|
329
|
-
</div>
|
|
330
|
-
|
|
331
|
-
<div v-if="inspectionResults.find(item => item.value === completeForm.result)?.showProblemDesc" class="form-item">
|
|
332
|
-
<div class="form-label">
|
|
333
|
-
问题描述
|
|
334
|
-
</div>
|
|
335
|
-
<VanField
|
|
336
|
-
v-model="completeForm.problemDesc"
|
|
337
|
-
type="textarea"
|
|
338
|
-
rows="3"
|
|
339
|
-
placeholder="请详细描述发现的问题"
|
|
340
|
-
class="field-item"
|
|
341
|
-
/>
|
|
342
|
-
</div>
|
|
343
|
-
|
|
344
|
-
<div class="form-item">
|
|
345
|
-
<div class="form-label">
|
|
346
|
-
备注信息
|
|
347
|
-
</div>
|
|
348
|
-
<VanField
|
|
349
|
-
v-model="completeForm.remark"
|
|
350
|
-
type="textarea"
|
|
351
|
-
rows="3"
|
|
352
|
-
placeholder="请输入其他备注信息(选填)"
|
|
353
|
-
class="field-item"
|
|
354
|
-
/>
|
|
355
|
-
</div>
|
|
356
|
-
</div>
|
|
357
|
-
</VanDialog>
|
|
358
|
-
|
|
359
|
-
<!-- 作废安检弹窗 -->
|
|
360
|
-
<VanDialog
|
|
361
|
-
v-model:show="showInvalidateDialog"
|
|
362
|
-
title="作废安检"
|
|
363
|
-
show-cancel-button
|
|
364
|
-
:close-on-click-overlay="false"
|
|
365
|
-
:close-on-popstate="false"
|
|
366
|
-
:before-close="(action) => action === 'confirm' ? invalidated() : true"
|
|
367
|
-
class="inspection-dialog"
|
|
368
|
-
@cancel="resetInvalidateForm"
|
|
369
|
-
>
|
|
370
|
-
<div class="dialog-content">
|
|
371
|
-
<div class="form-item">
|
|
372
|
-
<div class="form-label">
|
|
373
|
-
作废原因
|
|
374
|
-
</div>
|
|
375
|
-
<VanRadioGroup v-model="invalidateForm.reason" class="radio-group">
|
|
376
|
-
<VanRadio
|
|
377
|
-
v-for="item in invalidateReasons"
|
|
378
|
-
:key="item.value"
|
|
379
|
-
:name="item.value"
|
|
380
|
-
class="radio-item"
|
|
381
|
-
>
|
|
382
|
-
{{ item.label }}
|
|
383
|
-
</VanRadio>
|
|
384
|
-
</VanRadioGroup>
|
|
385
|
-
</div>
|
|
386
|
-
|
|
387
|
-
<div class="form-item">
|
|
388
|
-
<div class="form-label">
|
|
389
|
-
补充说明
|
|
390
|
-
</div>
|
|
391
|
-
<VanField
|
|
392
|
-
v-model="invalidateForm.remark"
|
|
393
|
-
type="textarea"
|
|
394
|
-
rows="3"
|
|
395
|
-
placeholder="请详细说明作废原因(选填)"
|
|
396
|
-
class="field-item"
|
|
397
|
-
/>
|
|
398
|
-
</div>
|
|
399
|
-
</div>
|
|
400
|
-
</VanDialog>
|
|
401
|
-
</div>
|
|
121
|
+
<NormalDataLayout id="XCellListView" title="工作计划">
|
|
122
|
+
<template #layout_content>
|
|
123
|
+
<XCellList
|
|
124
|
+
:config-name="configName"
|
|
125
|
+
:service-name="serviceName"
|
|
126
|
+
:id-key="idKey"
|
|
127
|
+
@to-detail="toDetail"
|
|
128
|
+
@delete-row="deleteRow"
|
|
129
|
+
@update="updateRow"
|
|
130
|
+
@add="addOption"
|
|
131
|
+
/>
|
|
132
|
+
|
|
133
|
+
<!-- :fix-query-form="{ u_f_price_state: ['生效', '待生效'] }" -->
|
|
134
|
+
|
|
135
|
+
<!-- <XCellList -->
|
|
136
|
+
<!-- :config-name="configName" -->
|
|
137
|
+
<!-- :service-name="serviceName" -->
|
|
138
|
+
<!-- :fix-query-form="{ o_f_oper_name: 'edu_test' }" -->
|
|
139
|
+
<!-- :id-key="idKey" -->
|
|
140
|
+
<!-- @to-detail="toDetail" -->
|
|
141
|
+
<!-- @delete-row="deleteRow" -->
|
|
142
|
+
<!-- /> -->
|
|
143
|
+
</template>
|
|
144
|
+
</NormalDataLayout>
|
|
402
145
|
</template>
|
|
403
146
|
|
|
404
147
|
<style scoped lang="less">
|
|
405
|
-
.xlv_t{
|
|
406
|
-
--van-cell-horizontal-padding: 0;
|
|
407
|
-
--van-cell-vertical-padding: 0;
|
|
408
|
-
.dialog-content {
|
|
409
|
-
padding: 8%;
|
|
410
|
-
.form-item {
|
|
411
|
-
margin-bottom: 20px;
|
|
412
|
-
|
|
413
|
-
&:last-child {
|
|
414
|
-
margin-bottom: 0;
|
|
415
|
-
}
|
|
416
|
-
}
|
|
417
|
-
|
|
418
|
-
.form-label {
|
|
419
|
-
font-size: 14px;
|
|
420
|
-
color: #323233;
|
|
421
|
-
margin-bottom: 12px;
|
|
422
|
-
font-weight: 500;
|
|
423
|
-
}
|
|
424
|
-
|
|
425
|
-
.radio-group {
|
|
426
|
-
display: flex;
|
|
427
|
-
flex-direction: column;
|
|
428
|
-
gap: 12px;
|
|
429
|
-
}
|
|
430
|
-
|
|
431
|
-
.radio-item {
|
|
432
|
-
font-size: 14px;
|
|
433
|
-
color: #323233;
|
|
434
|
-
}
|
|
435
|
-
|
|
436
|
-
.field-item {
|
|
437
|
-
:deep(.van-field__control) {
|
|
438
|
-
min-height: 80px;
|
|
439
|
-
border: 1px solid #ebedf0;
|
|
440
|
-
border-radius: 4px;
|
|
441
|
-
padding: 8px 12px;
|
|
442
|
-
background-color: #f7f8fa;
|
|
443
|
-
}
|
|
444
|
-
|
|
445
|
-
:deep(.van-field__placeholder) {
|
|
446
|
-
color: #969799;
|
|
447
|
-
}
|
|
448
|
-
}
|
|
449
|
-
}
|
|
450
|
-
}
|
|
451
148
|
</style>
|
|
@@ -5,16 +5,19 @@ import { showDialog } from 'vant'
|
|
|
5
5
|
import { ref } from 'vue'
|
|
6
6
|
import { useRoute } from 'vue-router'
|
|
7
7
|
|
|
8
|
+
// const configName = ref('reviewFormGroup')
|
|
9
|
+
// const serviceName = ref('af-revenue')
|
|
10
|
+
|
|
8
11
|
// 纯表单
|
|
9
|
-
const configName = ref('form_check_test')
|
|
10
|
-
const serviceName = ref('af-system')
|
|
12
|
+
// const configName = ref('form_check_test')
|
|
13
|
+
// const serviceName = ref('af-system')
|
|
11
14
|
|
|
12
15
|
// const configName = ref("计划下发Form")
|
|
13
16
|
// const serviceName = ref("af-linepatrol")
|
|
14
17
|
|
|
15
18
|
// 表单组
|
|
16
|
-
|
|
17
|
-
|
|
19
|
+
const configName = ref('lngChargeAuditMobileFormGroup')
|
|
20
|
+
const serviceName = ref('af-gaslink')
|
|
18
21
|
|
|
19
22
|
const formData = ref({})
|
|
20
23
|
const formGroup = ref(null)
|
package/tsconfig.json
CHANGED
|
@@ -1,43 +1,43 @@
|
|
|
1
|
-
{
|
|
2
|
-
"compilerOptions": {
|
|
3
|
-
"target": "esnext",
|
|
4
|
-
"jsx": "preserve",
|
|
5
|
-
"lib": ["esnext", "dom", "dom.iterable", "scripthost"],
|
|
6
|
-
"experimentalDecorators": true,
|
|
7
|
-
"baseUrl": ".",
|
|
8
|
-
"module": "esnext",
|
|
9
|
-
"moduleResolution": "Bundler",
|
|
10
|
-
"paths": {
|
|
11
|
-
"@af-mobile-client-vue3/*": ["src/*"]
|
|
12
|
-
},
|
|
13
|
-
"types": [
|
|
14
|
-
"node",
|
|
15
|
-
"unplugin-vue-router/client",
|
|
16
|
-
"vite-plugin-vue-layouts/client",
|
|
17
|
-
"vite-plugin-pwa/client"
|
|
18
|
-
],
|
|
19
|
-
"allowJs": true,
|
|
20
|
-
"strictNullChecks": false,
|
|
21
|
-
"noImplicitAny": false,
|
|
22
|
-
"noUnusedLocals": false,
|
|
23
|
-
"noUnusedParameters": false,
|
|
24
|
-
"importHelpers": true,
|
|
25
|
-
"sourceMap": true,
|
|
26
|
-
"allowSyntheticDefaultImports": true,
|
|
27
|
-
"esModuleInterop": true,
|
|
28
|
-
"verbatimModuleSyntax": true,
|
|
29
|
-
"skipLibCheck": true
|
|
30
|
-
},
|
|
31
|
-
"include": [
|
|
32
|
-
"src/App.vue",
|
|
33
|
-
"src/**/*.ts",
|
|
34
|
-
"src/**/*.tsx",
|
|
35
|
-
"src/**/*.vue",
|
|
36
|
-
"tests/**/*.ts",
|
|
37
|
-
"tests/**/*.tsx",
|
|
38
|
-
"src/components.d.ts",
|
|
39
|
-
"src/auto-imports.d.ts",
|
|
40
|
-
"src/typed-router.d.ts",
|
|
41
|
-
"tests/*.ts"
|
|
42
|
-
]
|
|
43
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"target": "esnext",
|
|
4
|
+
"jsx": "preserve",
|
|
5
|
+
"lib": ["esnext", "dom", "dom.iterable", "scripthost"],
|
|
6
|
+
"experimentalDecorators": true,
|
|
7
|
+
"baseUrl": ".",
|
|
8
|
+
"module": "esnext",
|
|
9
|
+
"moduleResolution": "Bundler",
|
|
10
|
+
"paths": {
|
|
11
|
+
"@af-mobile-client-vue3/*": ["src/*"]
|
|
12
|
+
},
|
|
13
|
+
"types": [
|
|
14
|
+
"node",
|
|
15
|
+
"unplugin-vue-router/client",
|
|
16
|
+
"vite-plugin-vue-layouts/client",
|
|
17
|
+
"vite-plugin-pwa/client"
|
|
18
|
+
],
|
|
19
|
+
"allowJs": true,
|
|
20
|
+
"strictNullChecks": false,
|
|
21
|
+
"noImplicitAny": false,
|
|
22
|
+
"noUnusedLocals": false,
|
|
23
|
+
"noUnusedParameters": false,
|
|
24
|
+
"importHelpers": true,
|
|
25
|
+
"sourceMap": true,
|
|
26
|
+
"allowSyntheticDefaultImports": true,
|
|
27
|
+
"esModuleInterop": true,
|
|
28
|
+
"verbatimModuleSyntax": true,
|
|
29
|
+
"skipLibCheck": true
|
|
30
|
+
},
|
|
31
|
+
"include": [
|
|
32
|
+
"src/App.vue",
|
|
33
|
+
"src/**/*.ts",
|
|
34
|
+
"src/**/*.tsx",
|
|
35
|
+
"src/**/*.vue",
|
|
36
|
+
"tests/**/*.ts",
|
|
37
|
+
"tests/**/*.tsx",
|
|
38
|
+
"src/components.d.ts",
|
|
39
|
+
"src/auto-imports.d.ts",
|
|
40
|
+
"src/typed-router.d.ts",
|
|
41
|
+
"tests/*.ts"
|
|
42
|
+
]
|
|
43
|
+
}
|
package/vite.config.ts
CHANGED
|
@@ -13,8 +13,8 @@ export default ({ mode }: ConfigEnv): UserConfig => {
|
|
|
13
13
|
|
|
14
14
|
const appProxys = {}
|
|
15
15
|
|
|
16
|
-
const v4Server = '
|
|
17
|
-
const v3Server = '
|
|
16
|
+
const v4Server = 'http://aote-office.8866.org:31567'
|
|
17
|
+
const v3Server = 'http://aote-office.8866.org:31567'
|
|
18
18
|
const OSSServerDev = 'http://192.168.50.67:30351'
|
|
19
19
|
const geoserver = 'http://39.104.49.8:30372'
|
|
20
20
|
// const OSSServerProd = 'http://192.168.50.67:31351'
|