feat:上报日志
Showing
10 changed files
with
791 additions
and
0 deletions
... | @@ -10,6 +10,7 @@ | ... | @@ -10,6 +10,7 @@ |
10 | "dependencies": { | 10 | "dependencies": { |
11 | "@jiaminghi/data-view": "^2.10.0", | 11 | "@jiaminghi/data-view": "^2.10.0", |
12 | "axios": "^0.21.1", | 12 | "axios": "^0.21.1", |
13 | "clipboard": "^2.0.11", | ||
13 | "core-js": "^3.6.5", | 14 | "core-js": "^3.6.5", |
14 | "echarts": "^4.6.0", | 15 | "echarts": "^4.6.0", |
15 | "js-cookie": "2.2.0", | 16 | "js-cookie": "2.2.0", | ... | ... |
... | @@ -59,6 +59,19 @@ export const asyncRoutes = [ | ... | @@ -59,6 +59,19 @@ export const asyncRoutes = [ |
59 | } | 59 | } |
60 | ] | 60 | ] |
61 | }, | 61 | }, |
62 | // 上报日志 | ||
63 | { | ||
64 | path: '/reportLog', | ||
65 | component: Layout, | ||
66 | children: [ | ||
67 | { | ||
68 | path: 'index', | ||
69 | component: () => import('@/views/reportLog/index'), | ||
70 | name: 'reportLog', | ||
71 | meta: { title: '上报日志', icon: 'zsgl' } | ||
72 | } | ||
73 | ] | ||
74 | }, | ||
62 | // 接入业务信息 | 75 | // 接入业务信息 |
63 | { | 76 | { |
64 | path: '/busineInfo', | 77 | path: '/busineInfo', | ... | ... |
1 | <template> | ||
2 | <!-- 错误日志 --> | ||
3 | <dialogBox ref="error" isReset saveButton="关闭" divider width="50%" @submitForm="handleResclose" multiple title="错误日志"> | ||
4 | <div class="xmlMessage"> | ||
5 | {{ errorData }} | ||
6 | </div> | ||
7 | </dialogBox> | ||
8 | </template> | ||
9 | |||
10 | <script> | ||
11 | export default { | ||
12 | props: { | ||
13 | errorData: { | ||
14 | type: String, | ||
15 | default: '' | ||
16 | } | ||
17 | }, | ||
18 | data () { | ||
19 | return { | ||
20 | } | ||
21 | }, | ||
22 | methods: { | ||
23 | handleResclose () { | ||
24 | this.$refs.error.isHide(); | ||
25 | } | ||
26 | } | ||
27 | } | ||
28 | </script> | ||
... | \ No newline at end of file | ... | \ No newline at end of file |
1 | <template> | ||
2 | <!-- 预览 --> | ||
3 | <dialogBox ref="preview" :isReset="false" divider :isButton="false" multiple title="XML报文"> | ||
4 | <div class="xmlMessage"> | ||
5 | {{ content }} | ||
6 | </div> | ||
7 | <div class="preview-dialog-button"> | ||
8 | <el-button id="copy_text" type="primary" plain @click="handleSubmit" | ||
9 | :data-clipboard-text="content">复制报文</el-button> | ||
10 | <el-button @click="handleclose">关闭</el-button> | ||
11 | </div> | ||
12 | </dialogBox> | ||
13 | </template> | ||
14 | |||
15 | <script> | ||
16 | import Clipboard from 'clipboard' | ||
17 | export default { | ||
18 | props: { | ||
19 | content: { | ||
20 | type: String, | ||
21 | default: '' | ||
22 | }, | ||
23 | }, | ||
24 | data () { | ||
25 | return { | ||
26 | } | ||
27 | }, | ||
28 | methods: { | ||
29 | handleSubmit () { | ||
30 | var _this = this; | ||
31 | var clipboard = new Clipboard('#copy_text'); | ||
32 | clipboard.on('success', e => { | ||
33 | // 释放内存 | ||
34 | this.$message({ | ||
35 | message: '复制成功!', | ||
36 | type: 'success' | ||
37 | }) | ||
38 | clipboard.destroy() | ||
39 | _this.$refs.preview.isHide() | ||
40 | }) | ||
41 | clipboard.on('error', e => { | ||
42 | // 不支持复制 | ||
43 | this.$message({ | ||
44 | message: '该浏览器不支持自动复制', | ||
45 | type: 'warning' | ||
46 | }); | ||
47 | // 释放内存 | ||
48 | clipboard.destroy() | ||
49 | }) | ||
50 | }, | ||
51 | handleclose () { | ||
52 | this.$refs.preview.isHide(); | ||
53 | } | ||
54 | } | ||
55 | } | ||
56 | </script> | ||
57 | <style scoped lang="scss"> | ||
58 | .preview-dialog-button { | ||
59 | text-align: center; | ||
60 | margin: 20px 0; | ||
61 | } | ||
62 | </style> | ||
... | \ No newline at end of file | ... | \ No newline at end of file |
1 | <template> | ||
2 | <!-- 重新发报 --> | ||
3 | <dialogBox ref="resend" saveButton="确定" width="500px" divider @submitForm="handleResclose" multiple title="提示"> | ||
4 | <div class="confirmDialog">您确定重新发送报文吗?</div> | ||
5 | </dialogBox> | ||
6 | </template> | ||
7 | |||
8 | <script> | ||
9 | import journal from '@/api/journal.js' | ||
10 | export default { | ||
11 | props: { | ||
12 | msgid: { | ||
13 | type: String, | ||
14 | default: '' | ||
15 | } | ||
16 | }, | ||
17 | data () { | ||
18 | return { | ||
19 | } | ||
20 | }, | ||
21 | methods: { | ||
22 | async handleResclose () { | ||
23 | try { | ||
24 | let res = await journal.sendXmlForPlat(this.msgid) | ||
25 | if (res.code == 200) { | ||
26 | this.$message({ | ||
27 | message: res.message, | ||
28 | type: 'success' | ||
29 | }) | ||
30 | this.$parent.featchData(); | ||
31 | this.$refs.resend.isHide() | ||
32 | } | ||
33 | } catch (error) { | ||
34 | this.$message({ | ||
35 | showClose: true, | ||
36 | message: '服务器出错,请稍后重试', | ||
37 | type: 'error' | ||
38 | }) | ||
39 | this.$refs.resend.isHide() | ||
40 | } | ||
41 | } | ||
42 | } | ||
43 | } | ||
44 | </script> | ||
... | \ No newline at end of file | ... | \ No newline at end of file |
1 | <template> | ||
2 | <!-- 相应日志 --> | ||
3 | <dialogBox ref="response" isReset saveButton="关闭" divider @submitForm="handleResclose" multiple title="相应日志"> | ||
4 | <div class="xmlMessage"> | ||
5 | {{ journalData }} | ||
6 | </div> | ||
7 | </dialogBox> | ||
8 | </template> | ||
9 | |||
10 | <script> | ||
11 | export default { | ||
12 | props: { | ||
13 | journalData: { | ||
14 | type: String, | ||
15 | default: '' | ||
16 | } | ||
17 | }, | ||
18 | data () { | ||
19 | return { | ||
20 | } | ||
21 | }, | ||
22 | methods: { | ||
23 | handleResclose () { | ||
24 | this.$refs.response.isHide(); | ||
25 | } | ||
26 | } | ||
27 | } | ||
28 | </script> | ||
... | \ No newline at end of file | ... | \ No newline at end of file |
1 | <template> | ||
2 | <!-- 重新转换 --> | ||
3 | <dialogBox ref="resend" saveButton="确定" width="500px" divider @submitForm="handleResclose" multiple title="提示"> | ||
4 | <div class="confirmDialog">您确定重新抽取业务转换报文吗?</div> | ||
5 | </dialogBox> | ||
6 | </template> | ||
7 | |||
8 | <script> | ||
9 | import journal from '@/api/journal.js' | ||
10 | export default { | ||
11 | props: { | ||
12 | msgid: { | ||
13 | type: String, | ||
14 | default: '' | ||
15 | } | ||
16 | }, | ||
17 | data () { | ||
18 | return { | ||
19 | } | ||
20 | }, | ||
21 | methods: { | ||
22 | async handleResclose () { | ||
23 | try { | ||
24 | let res = await journal.sendXmlForPlat(this.msgid) | ||
25 | if (res.code == 200) { | ||
26 | this.$message({ | ||
27 | message: res.message, | ||
28 | type: 'success' | ||
29 | }) | ||
30 | this.$parent.featchData(); | ||
31 | this.$refs.resend.isHide() | ||
32 | } | ||
33 | } catch (error) { | ||
34 | this.$message({ | ||
35 | showClose: true, | ||
36 | message: '服务器出错,请稍后重试', | ||
37 | type: 'error' | ||
38 | }) | ||
39 | } | ||
40 | } | ||
41 | } | ||
42 | } | ||
43 | </script> | ||
... | \ No newline at end of file | ... | \ No newline at end of file |
src/views/reportLog/data/index.js
0 → 100644
1 | import filter from '@/utils/filter.js' | ||
2 | class data extends filter { | ||
3 | constructor() { | ||
4 | super() | ||
5 | } | ||
6 | columns () { | ||
7 | return [ | ||
8 | { | ||
9 | label: "行政区", | ||
10 | width: 120, | ||
11 | render: (h, scope) => { | ||
12 | return ( | ||
13 | <div class={{ 'warning': scope.row.status == 6, 'bad': (scope.row.status == 2 || scope.row.status == 3 || scope.row.status == 5) }}> | ||
14 | <span>{scope.row.regorgid || '暂无'}</span> | ||
15 | </div> | ||
16 | ) | ||
17 | }, | ||
18 | }, | ||
19 | { | ||
20 | label: "创建时间", | ||
21 | width: 135, | ||
22 | render: (h, scope) => { | ||
23 | return ( | ||
24 | <div class={{ 'warning': scope.row.status == 6, 'bad': (scope.row.status == 2 || scope.row.status == 3 || scope.row.status == 5) }}> | ||
25 | <span>{scope.row.cjsj}</span> | ||
26 | </div> | ||
27 | ) | ||
28 | }, | ||
29 | }, | ||
30 | { | ||
31 | label: "业务号", | ||
32 | width: 150, | ||
33 | render: (h, scope) => { | ||
34 | return ( | ||
35 | <div class={{ 'warning': scope.row.status == 6, 'bad': (scope.row.status == 2 || scope.row.status == 3 || scope.row.status == 5) }}> | ||
36 | <span>{scope.row.ywh}</span> | ||
37 | </div> | ||
38 | ) | ||
39 | }, | ||
40 | }, | ||
41 | { | ||
42 | label: "接入业务编码", | ||
43 | width: 100, | ||
44 | render: (h, scope) => { | ||
45 | return ( | ||
46 | <div class={{ 'warning': scope.row.status == 6, 'bad': (scope.row.status == 2 || scope.row.status == 3 || scope.row.status == 5) }}> | ||
47 | <span>{scope.row.rectype}</span> | ||
48 | </div> | ||
49 | ) | ||
50 | } | ||
51 | }, | ||
52 | { | ||
53 | label: "接入业务名称", | ||
54 | render: (h, scope) => { | ||
55 | return ( | ||
56 | <div class={{ 'warning': scope.row.status == 6, 'bad': (scope.row.status == 2 || scope.row.status == 3 || scope.row.status == 5) }}> | ||
57 | <span>{this.busNameStatus(scope.row.rectype)}</span> | ||
58 | </div> | ||
59 | ) | ||
60 | } | ||
61 | }, | ||
62 | { | ||
63 | label: "上报时间", | ||
64 | width: 135, | ||
65 | render: (h, scope) => { | ||
66 | return ( | ||
67 | <div class={{ 'warning': scope.row.status == 6, 'bad': (scope.row.status == 2 || scope.row.status == 3 || scope.row.status == 5) }}> | ||
68 | <span>{scope.row.sbsj}</span> | ||
69 | </div> | ||
70 | ) | ||
71 | } | ||
72 | }, | ||
73 | { | ||
74 | label: "上报状态", | ||
75 | width: 120, | ||
76 | render: (h, scope) => { | ||
77 | return ( | ||
78 | <div class={{ 'warning': scope.row.status == 6, 'bad': (scope.row.status == 2 || scope.row.status == 3 || scope.row.status == 5) }}> | ||
79 | <span>{this.reportingStatus(scope.row.status)}</span> | ||
80 | </div> | ||
81 | ) | ||
82 | } | ||
83 | }, | ||
84 | { | ||
85 | label: "响应时间", | ||
86 | width: 135, | ||
87 | render: (h, scope) => { | ||
88 | return ( | ||
89 | <div class={{ 'warning': scope.row.status == 6, 'bad': (scope.row.status == 2 || scope.row.status == 3 || scope.row.status == 5) }}> | ||
90 | <span>{scope.row.xysj}</span> | ||
91 | </div> | ||
92 | ) | ||
93 | } | ||
94 | } | ||
95 | ] | ||
96 | } | ||
97 | } | ||
98 | export default new data() |
src/views/reportLog/index.scss
0 → 100644
src/views/reportLog/index.vue
0 → 100644
1 | <template> | ||
2 | <div class="reportLog from-clues"> | ||
3 | <div class="from-clues-header"> | ||
4 | <el-form ref="form" :model="form" label-width="80px"> | ||
5 | <el-row> | ||
6 | <el-col :span="5"> | ||
7 | <el-form-item label="业务号"> | ||
8 | <el-input v-model="form.ywh" placeholder="业务号"></el-input> | ||
9 | </el-form-item> | ||
10 | </el-col> | ||
11 | <el-col :span="5"> | ||
12 | <el-form-item label="接入业务名称" label-width="120px"> | ||
13 | <el-select filterable v-model="form.rectype" ref="selectref" @visible-change="isShowSelectOptions" | ||
14 | clearable placeholder="请选择"> | ||
15 | <el-option v-for="item in $store.getters.businessInfo" :key="item.jrywbm" :label="item.jrywmc" | ||
16 | :value="item.jrywbm"> | ||
17 | </el-option> | ||
18 | </el-select> | ||
19 | </el-form-item> | ||
20 | </el-col> | ||
21 | <el-col :span="5"> | ||
22 | <el-form-item label="上报状态"> | ||
23 | <el-select v-model="form.status" ref="selectReporting" @visible-change="isShowSelectOptions" clearable | ||
24 | placeholder="上报状态"> | ||
25 | <el-option v-for="item in statusOptions" :key="item.value" :label="item.label" :value="item.value"> | ||
26 | </el-option> | ||
27 | </el-select> | ||
28 | </el-form-item> | ||
29 | </el-col> | ||
30 | |||
31 | <el-col :span="5"> | ||
32 | <el-form-item label="行政区"> | ||
33 | <el-select v-model="form.pcode" clearable placeholder="行政区"> | ||
34 | <el-option v-for="item in xzqOptions" :key="item.value" :label="item.label" :value="item.value"> | ||
35 | </el-option> | ||
36 | </el-select> | ||
37 | </el-form-item> | ||
38 | </el-col> | ||
39 | <el-col :span="4" class="btnColRight"> | ||
40 | <el-button type="primary" @click="handleSubmit">查询结果</el-button> | ||
41 | </el-col> | ||
42 | </el-row> | ||
43 | </el-form> | ||
44 | </div> | ||
45 | <div class="from-clues-content"> | ||
46 | <lb-table ref="table" :page-size="pageData.size" :current-page.sync="pageData.current" :total="pageData.total" | ||
47 | @size-change="handleSizeChange" @p-current-change="handleCurrentChange" :column="tableData.columns" | ||
48 | :data="tableData.data"> | ||
49 | </lb-table> | ||
50 | </div> | ||
51 | <!-- 相应日志 --> | ||
52 | <response-dialog ref="responseLog" :journalData="journalData" /> | ||
53 | <!-- 错误日志 --> | ||
54 | <errorLog-dialog ref="errorLog" :errorData="errorData" /> | ||
55 | <!-- 预览 --> | ||
56 | <preview-dialog :content="XMLData" ref="previewLog" /> | ||
57 | <!-- 编辑 --> | ||
58 | <edit-dialog ref="editLog" :bsmSjsb="bsmSjsb" :diaData="diaData" /> | ||
59 | <!-- 重新发报 --> | ||
60 | <resend-dialog ref="resendLog" :msgid="msgid" /> | ||
61 | <!-- 重新转换 --> | ||
62 | <retransfer-dialog ref="retransfer" /> | ||
63 | </div> | ||
64 | </template> | ||
65 | |||
66 | <script> | ||
67 | // 上报日志 | ||
68 | import data from "./data" | ||
69 | import journal from '@/api/journal.js' | ||
70 | import tableMixin from '@/mixins/tableMixin.js' | ||
71 | import dataReporting from '@/api/dataReporting' | ||
72 | import responseDialog from './components/response-dialog.vue' | ||
73 | import errorLogDialog from './components/errorLog-dialog.vue' | ||
74 | import previewDialog from './components/preview-dialog.vue' | ||
75 | import resendDialog from './components/resend-dialog.vue' | ||
76 | import retransferDialog from './components/retransfer-dialog.vue' | ||
77 | import editDialog from '@/components/dataDetails/edit-dialog.vue' | ||
78 | export default { | ||
79 | name: "reportLog", | ||
80 | mixins: [tableMixin], | ||
81 | components: { | ||
82 | responseDialog, | ||
83 | previewDialog, | ||
84 | resendDialog, | ||
85 | editDialog, | ||
86 | errorLogDialog, | ||
87 | retransferDialog | ||
88 | }, | ||
89 | data () { | ||
90 | return { | ||
91 | msgid: '', | ||
92 | // 响应日志 | ||
93 | journalData: '', | ||
94 | errorData: '', | ||
95 | XMLData: '', | ||
96 | form: { | ||
97 | ywh: '', | ||
98 | rectype: '', | ||
99 | status: '', | ||
100 | pcode: '', | ||
101 | currentPage: 1 | ||
102 | }, | ||
103 | tableData: { | ||
104 | columns: [{ | ||
105 | label: '序号', | ||
106 | type: 'index', | ||
107 | width: '50', | ||
108 | index: this.indexMethod, | ||
109 | }].concat(data.columns()).concat([ | ||
110 | { | ||
111 | width: 135, | ||
112 | label: "XML报文", | ||
113 | headerAlign: 'center', | ||
114 | align: 'left', | ||
115 | render: (h, scope) => { | ||
116 | return ( | ||
117 | <div> | ||
118 | <el-button | ||
119 | type="text" | ||
120 | size="mini" | ||
121 | style="color:#67C23A" | ||
122 | icon="el-icon-view" | ||
123 | v-show={['1', '4', '5', '6', '7', '8'].includes(scope.row.status)} | ||
124 | onClick={() => { this.handlePreview(scope.$index, scope.row) }} | ||
125 | > | ||
126 | 预览 | ||
127 | </el-button> | ||
128 | <el-button | ||
129 | type="text" | ||
130 | style="margin-bottom:5px" | ||
131 | size="mini" | ||
132 | icon="el-icon-folder" | ||
133 | onClick={() => { this.handleResponseLog(scope.row) }} | ||
134 | v-show={['5', '7'].includes(scope.row.status)} | ||
135 | > | ||
136 | 响应日志 | ||
137 | </el-button> | ||
138 | </div> | ||
139 | ); | ||
140 | }, | ||
141 | }, | ||
142 | { | ||
143 | label: "操作", | ||
144 | width: 170, | ||
145 | headerAlign: 'center', | ||
146 | align: 'right', | ||
147 | render: (h, scope) => { | ||
148 | return ( | ||
149 | <div> | ||
150 | <el-button | ||
151 | type="text" | ||
152 | size="mini" | ||
153 | icon="el-icon-edit" | ||
154 | style="margin-left: 10px" | ||
155 | onClick={() => { this.handleEdit(scope.$index, scope.row) }} | ||
156 | v-show={scope.row.status == 3} | ||
157 | > | ||
158 | 编辑 | ||
159 | </el-button> | ||
160 | <el-button | ||
161 | type="text" | ||
162 | size="mini" | ||
163 | style="color:#67C23A" | ||
164 | icon="el-icon-folder-opened" | ||
165 | onClick={() => { this.handleReissue(scope.row) }} | ||
166 | v-show={scope.row.status == 1 || scope.row.status == 5} | ||
167 | > | ||
168 | 重新上报 | ||
169 | </el-button> | ||
170 | <el-button | ||
171 | type="text" | ||
172 | icon="el-icon-folder-checked" | ||
173 | v-show={scope.row.status == 3 || scope.row.status == 9} | ||
174 | onClick={() => { this.handleInspection(scope.row) }} | ||
175 | > | ||
176 | 数据校验 | ||
177 | </el-button> | ||
178 | <el-button | ||
179 | v-show={scope.row.status == 2 || scope.row.status == 3} | ||
180 | type="text" | ||
181 | size="mini" | ||
182 | style="margin-left:0;color:#F56C6C" | ||
183 | icon="el-icon-s-order" | ||
184 | onClick={() => { this.handleErrorLog(scope.row) }} | ||
185 | > | ||
186 | 错误日志 | ||
187 | </el-button> | ||
188 | |||
189 | <el-button | ||
190 | v-show={scope.row.status == 9} | ||
191 | type="text" | ||
192 | size="mini" | ||
193 | icon="el-icon-view" | ||
194 | onClick={() => { this.handleDatapreview(scope.row) }} | ||
195 | > | ||
196 | 数据预览 | ||
197 | </el-button> | ||
198 | |||
199 | <el-button | ||
200 | v-show={scope.row.status == 2 || scope.row.status == 0} | ||
201 | type="text" | ||
202 | icon="el-icon-copy-document" | ||
203 | size="mini" | ||
204 | onClick={() => { this.handleRetransfer(scope.row) }} | ||
205 | > | ||
206 | 重新抽取 | ||
207 | </el-button> | ||
208 | </div> | ||
209 | ); | ||
210 | }, | ||
211 | }, | ||
212 | |||
213 | ]), | ||
214 | data: [] | ||
215 | }, | ||
216 | pageData: { | ||
217 | total: 0, | ||
218 | pageSize: 15, | ||
219 | current: 1, | ||
220 | }, | ||
221 | diaData: null, | ||
222 | bsmSjsb: '', | ||
223 | // 上报状态 | ||
224 | statusOptions: [ | ||
225 | { | ||
226 | value: '0', | ||
227 | label: '待抽取' | ||
228 | }, | ||
229 | { | ||
230 | value: '2', | ||
231 | label: '内部错误' | ||
232 | }, | ||
233 | { | ||
234 | value: '9', | ||
235 | label: '待校验' | ||
236 | }, | ||
237 | { | ||
238 | value: '3', | ||
239 | label: '本地校验失败' | ||
240 | }, | ||
241 | { | ||
242 | value: '1', | ||
243 | label: '待上报' | ||
244 | }, | ||
245 | { | ||
246 | value: '4', | ||
247 | label: '上报成功等待响应' | ||
248 | }, | ||
249 | { | ||
250 | value: '5', | ||
251 | label: '上报时发生错误' | ||
252 | }, | ||
253 | { | ||
254 | value: '6', | ||
255 | label: '本地上报成功,查询上报结果错误' | ||
256 | }, | ||
257 | { | ||
258 | value: '7', | ||
259 | label: '本地上报成功,上级也上报成功' | ||
260 | }, | ||
261 | { | ||
262 | value: '8', | ||
263 | label: '本地上报成功,上级上报失败' | ||
264 | } | ||
265 | ], | ||
266 | // 行政区 | ||
267 | xzqOptions: [ | ||
268 | { | ||
269 | value: '632321', | ||
270 | label: '同仁县' | ||
271 | }, | ||
272 | { | ||
273 | value: '632322', | ||
274 | label: '尖扎县' | ||
275 | }, | ||
276 | { | ||
277 | value: '632323', | ||
278 | label: '泽库县' | ||
279 | }, | ||
280 | { | ||
281 | value: '632324', | ||
282 | label: '河南县' | ||
283 | } | ||
284 | ] | ||
285 | } | ||
286 | }, | ||
287 | watch: { | ||
288 | 'tableData.data' (val) { | ||
289 | this.doLayout(); | ||
290 | } | ||
291 | }, | ||
292 | methods: { | ||
293 | doLayout () { | ||
294 | this.$nextTick(() => { | ||
295 | this.$refs.table.doLayout() | ||
296 | }) | ||
297 | }, | ||
298 | // 是否显示下拉框 | ||
299 | isShowSelectOptions (e) { | ||
300 | if (!e) this.$refs.selectref.blur() | ||
301 | if (!e) this.$refs.selectReporting.blur() | ||
302 | }, | ||
303 | async featchData () { | ||
304 | try { | ||
305 | this.form = Object.assign(this.form, this.formData) | ||
306 | let { result: { list, total, pages: pageSize, pageNum: current } | ||
307 | } = await journal.querySjsbTask(this.form) | ||
308 | if (this.$store.state.dictionaries.addDic) { | ||
309 | this.tableData.data = list | ||
310 | this.pageData = { | ||
311 | pageSize, | ||
312 | current, | ||
313 | total | ||
314 | } | ||
315 | } else { | ||
316 | this.featchData() | ||
317 | } | ||
318 | } catch (error) { | ||
319 | this.message = error | ||
320 | } | ||
321 | }, | ||
322 | async handleResponseLog (row) { | ||
323 | try { | ||
324 | let { result: res } = await journal.queryResponseLog(row.msgid) | ||
325 | if (res != null) { | ||
326 | this.$refs.responseLog.$refs.response.isShow() | ||
327 | this.journalData = res | ||
328 | } else { | ||
329 | this.$message('响应日志为空') | ||
330 | } | ||
331 | } catch (error) { | ||
332 | this.$alert(error, '提示', { | ||
333 | confirmButtonText: '确定', | ||
334 | type: 'error' | ||
335 | }) | ||
336 | } | ||
337 | }, | ||
338 | async handlePreview (index, row) { | ||
339 | try { | ||
340 | let res = await journal.queryXML(row.msgid) | ||
341 | if (res != null) { | ||
342 | this.XMLData = res.result | ||
343 | this.$refs.previewLog.$refs.preview.isShow() | ||
344 | } else { | ||
345 | this.$message('报文为空') | ||
346 | } | ||
347 | } catch (error) { | ||
348 | this.$alert(error, '提示', { | ||
349 | confirmButtonText: '确定', | ||
350 | type: 'error' | ||
351 | }) | ||
352 | } | ||
353 | }, | ||
354 | async handleEdit (index, row) { | ||
355 | try { | ||
356 | let { result: res, message } = await dataReporting.getQltFwFdcqYzByCondition(row.msgid) | ||
357 | if (res != null) { | ||
358 | this.diaData = res | ||
359 | this.bsmSjsb = row.msgid | ||
360 | this.$store.dispatch('business/setReportLogEdit') | ||
361 | this.$refs.editLog.isShow() | ||
362 | } else { | ||
363 | this.$message(message) | ||
364 | } | ||
365 | |||
366 | } catch (error) { | ||
367 | this.$alert(error, '提示', { | ||
368 | confirmButtonText: '确定', | ||
369 | type: 'error' | ||
370 | }) | ||
371 | } | ||
372 | }, | ||
373 | handleReissue (row) { | ||
374 | this.msgid = row.msgid | ||
375 | this.$refs.resendLog.$refs.resend.isShow() | ||
376 | }, | ||
377 | // 错误日志 | ||
378 | async handleErrorLog (row) { | ||
379 | try { | ||
380 | let res = await journal.queryErrorLog(row.msgid) | ||
381 | this.errorData = res.message | ||
382 | this.$refs.errorLog.$refs.error.isShow() | ||
383 | } catch (error) { | ||
384 | this.$alert(error, '提示', { | ||
385 | confirmButtonText: '确定', | ||
386 | type: 'error' | ||
387 | }) | ||
388 | } | ||
389 | }, | ||
390 | // 重新抽取 | ||
391 | handleRetransfer (row) { | ||
392 | let _this = this | ||
393 | this.$confirm('此操作将重新抽取该文件, 是否继续?', '提示', { | ||
394 | confirmButtonText: '确定', | ||
395 | cancelButtonText: '取消', | ||
396 | type: 'warning' | ||
397 | }).then(async () => { | ||
398 | this.extractLoading = true | ||
399 | try { | ||
400 | let res = await journal.extractionAndInsertData(row.msgid) | ||
401 | if (res.code == 200) { | ||
402 | _this.$message({ | ||
403 | message: res.result, | ||
404 | type: 'success' | ||
405 | }); | ||
406 | _this.featchData() | ||
407 | } | ||
408 | } catch (error) { | ||
409 | _this.$confirm(error, '提示', { | ||
410 | confirmButtonText: '确定', | ||
411 | type: 'warning' | ||
412 | }).then(() => { | ||
413 | _this.featchData() | ||
414 | }) | ||
415 | } | ||
416 | this.extractLoading = false | ||
417 | }).catch(() => { | ||
418 | this.$message({ | ||
419 | type: 'info', | ||
420 | message: '已取消' | ||
421 | }); | ||
422 | }); | ||
423 | }, | ||
424 | // 检验报文 | ||
425 | async handleInspection (row) { | ||
426 | try { | ||
427 | let res = await journal.checkSjsbXmlDatas(row.msgid) | ||
428 | if (res.code == 200) { | ||
429 | this.$message({ | ||
430 | message: '校验成功', | ||
431 | type: 'success' | ||
432 | }); | ||
433 | } | ||
434 | this.featchData() | ||
435 | } catch (error) { | ||
436 | this.$confirm(error, '提示', { | ||
437 | confirmButtonText: '确定', | ||
438 | type: 'warning' | ||
439 | }).then(() => { | ||
440 | this.featchData() | ||
441 | }).catch(() => { | ||
442 | }); | ||
443 | } | ||
444 | }, | ||
445 | // 数据预览 | ||
446 | async handleDatapreview (row) { | ||
447 | let { result: res, message } = await dataReporting.getQltFwFdcqYzByCondition(row.msgid) | ||
448 | if (res != null) { | ||
449 | this.diaData = res | ||
450 | this.bsmSjsb = row.BSM_SJSB | ||
451 | this.$store.dispatch('business/setEdit') | ||
452 | this.$refs.editLog.isShow() | ||
453 | } else { | ||
454 | this.$message(message) | ||
455 | } | ||
456 | } | ||
457 | } | ||
458 | } | ||
459 | </script> | ||
460 | <style scoped lang="scss"> | ||
461 | @import "~@/styles/public.scss"; | ||
462 | @import "./index.scss"; | ||
463 | </style> | ||
464 |
-
Please register or sign in to post a comment