n20-common-lib 2.9.13 → 2.9.14
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/nstc-g6/components/NstcCharts/NstcCharts.vue +16 -8
- package/package.json +8 -5
- package/src/assets/css/approve-card.scss +1 -1
- package/src/assets/css/date-quarter.scss +8 -0
- package/src/assets/css/expandable-pane.scss +7 -0
- package/src/assets/css/file-upload-table.scss +2 -3
- package/src/assets/css/font-icon.scss +3 -1
- package/src/assets/css/message.scss +6 -6
- package/src/assets/css/normalize.scss +4 -1
- package/src/assets/css/table.scss +16 -11
- package/src/assets/iconFont/SIMSUN.ttf +0 -0
- package/src/assets/iconFont/font.css +4 -0
- package/src/components/AIButton/index.vue +101 -0
- package/src/components/AdvancedFilter/formItemRender.vue +7 -4
- package/src/components/AdvancedFilter/index.vue +6 -7
- package/src/components/Anchor/index.vue +1 -0
- package/src/components/ApprovalButtons/index.vue +404 -82
- package/src/components/ApprovalButtons/indexApp.vue +1102 -0
- package/src/components/ApprovalButtons/selectSpr.vue +128 -0
- package/src/components/ApprovalButtons/setCarboncopyProp.vue +1 -1
- package/src/components/ApprovalButtons/setRejectToProp.vue +45 -5
- package/src/components/ApprovalButtons/showAppOpi.vue +265 -8
- package/src/components/ApprovalButtons/showOtherAttrNew.vue +161 -0
- package/src/components/ApprovalCard/index.vue +190 -44
- package/src/components/ApprovalCard/indexApp.vue +592 -0
- package/src/components/ApprovalRecord/approvalImgPro/child.vue +1 -1
- package/src/components/ApprovalRecord/approvalImgPro/index.vue +42 -5
- package/src/components/ApprovalRecord/index.vue +23 -6
- package/src/components/ApprovalRecord/indexApp.vue +79 -0
- package/src/components/AttachmentPass/index.vue +286 -0
- package/src/components/Button/button-group.vue +3 -1
- package/src/components/CascaderArea/index.vue +5 -6
- package/src/components/DatePicker/por.vue +31 -1
- package/src/components/DateSelect/quarterDatePicker.vue +23 -1
- package/src/components/Descriptions/index.vue +7 -3
- package/src/components/Dialog/index.vue +4 -0
- package/src/components/Diff/index.vue +4 -2
- package/src/components/DynamicField/DynamicField.vue +29 -6
- package/src/components/DynamicField/DynamicFieldMixin.js +13 -5
- package/src/components/DynamicField/DynamicFieldOptions.vue +135 -62
- package/src/components/DynamicField/DynamicTable.vue +11 -1
- package/src/components/DynamicField/contentPop.vue +110 -0
- package/src/components/DynamicField/tableList.vue +5 -1
- package/src/components/DynamicField/tableView.vue +143 -0
- package/src/components/ECharts/index.vue +15 -9
- package/src/components/Expandable/main.vue +17 -2
- package/src/components/FileImport/index.vue +4 -5
- package/src/components/FileUploadTable/FileUploadTableV3.vue +937 -0
- package/src/components/FileUploadTable/aiCheckDialog.vue +139 -0
- package/src/components/FileUploadTable/index.vue +251 -33
- package/src/components/FileUploadTable/jytg.svg +6 -0
- package/src/components/FileUploadTable/wsc.svg +3 -0
- package/src/components/FileUploadTable/ysc.svg +3 -0
- package/src/components/HandlingAdvice/index.vue +191 -0
- package/src/components/InputAccount/index.vue +105 -0
- package/src/components/InputNumber/index.vue +16 -4
- package/src/components/InputNumber/numberRange.vue +14 -0
- package/src/components/InputSearch/index.vue +8 -0
- package/src/components/Layout/HeaderWrap/changePwd.vue +50 -23
- package/src/components/Layout/HeaderWrap/index.vue +2 -2
- package/src/components/Layout/HeaderWrap/indexN.vue +296 -119
- package/src/components/Layout/SubContent/index.vue +45 -14
- package/src/components/Layout/indexN.vue +26 -5
- package/src/components/LoginTemporary/form.vue +126 -34
- package/src/components/LoginTemporary/index.vue +14 -3
- package/src/components/LoginTemporary/indexN.vue +35 -13
- package/src/components/Preview/index.vue +199 -0
- package/src/components/SelectDatePickerPro/customDatePicker.vue +7 -0
- package/src/components/SelectDatePickerPro/halfYearPicker.vue +165 -0
- package/src/components/SelectDatePickerPro/index.vue +44 -4
- package/src/components/SelectDatePickerPro/quarterDatePicker.vue +32 -10
- package/src/components/SelectTree/index.vue +10 -4
- package/src/components/SelectTree/pro.vue +3 -0
- package/src/components/ShowColumn/index copy 2.vue +545 -0
- package/src/components/ShowColumn/index copy.vue +566 -0
- package/src/components/ShowColumn/index.vue +11 -7
- package/src/components/Statis/statisItem.vue +8 -7
- package/src/components/Table/filters.js +13 -0
- package/src/components/Table/index.vue +4 -4
- package/src/components/TablePro/filterContent.vue +18 -8
- package/src/components/TablePro/index.js +41 -1
- package/src/components/TablePro/index.vue +117 -6
- package/src/components/TableProOperateColumn/OperateBtns.vue +11 -53
- package/src/components/TableProOperateColumn/OperateBtns_copy.vue +141 -0
- package/src/components/TableProOperateColumn/childrenOperateBtn.vue +108 -0
- package/src/components/TableProOperateColumn/index.vue +3 -6
- package/src/components/TableSetSize/index.vue +1 -1
- package/src/components/Tree/index.vue +21 -5
- package/src/components/Upload/index.vue +25 -10
- package/src/components/Upload/uploadMsg.vue +30 -25
- package/src/components/operatingStatus/index.vue +3 -4
- package/src/directives/VTitle/index.js +15 -5
- package/src/directives/watermark/index.js +140 -56
- package/src/i18n.json +146 -18
- package/src/index.js +31 -3
- package/src/plugins/Sign/CaMap.js +47 -8
- package/src/plugins/Sign/Itrus/index.js +1 -1
- package/src/plugins/Sign/Itrus/sign_3720.js +2 -1
- package/src/plugins/Sign/NetSM3/index.js +20 -11
- package/src/plugins/Sign/NetV3/index.js +163 -22
- package/src/plugins/Sign/SkfSign/index.js +55 -52
- package/src/plugins/Sign/bjca/index.js +229 -9
- package/src/plugins/Sign/hnca/index.js +5064 -0
- package/src/plugins/Sign/index.js +155 -103
- package/src/plugins/Sign/kySign/base64.js +160 -0
- package/src/plugins/Sign/kySign/hex.js +92 -0
- package/src/plugins/Sign/kySign/index.js +186 -0
- package/src/plugins/Sign/kySign/skf.js +937 -0
- package/src/plugins/Sign/kySign/test.html +463 -0
- package/src/plugins/Sign/sdca/index.js +73 -0
- package/src/plugins/Sign/sign.js +72 -52
- package/src/plugins/Sign/signV3/InfosecNetSignCNGAgent.min.js +1 -0
- package/src/plugins/Sign/signV3/sign.js +187 -0
- package/src/plugins/Sign/sign_back.js +172 -0
- package/src/utils/accountFormat.js +7 -0
- package/src/utils/asyncGetRelaNos.js +79 -46
- package/src/utils/axios.js +3 -5
- package/src/utils/i18n/index.js +1 -1
- package/src/utils/importGlobal.js +23 -12
- package/style/fonts/SIMSUN.5e0c362c.ttf +0 -0
- package/style/index.css +2 -2
- package/theme/blue.css +2 -2
- package/theme/cctcRed.css +2 -2
- package/theme/fonts/SIMSUN.5e0c362c.ttf +0 -0
- package/theme/green.css +2 -2
- package/theme/lightBlue.css +2 -2
- package/theme/orange.css +2 -2
- package/theme/purple.css +2 -2
- package/theme/red.css +2 -2
- package/theme/yellow.css +2 -2
|
@@ -0,0 +1,139 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<Dialog
|
|
3
|
+
v-drag
|
|
4
|
+
class="aiCheckDialog"
|
|
5
|
+
:title="'AI校验' | $lc"
|
|
6
|
+
:visible.sync="visibleP"
|
|
7
|
+
width="60%"
|
|
8
|
+
:close-on-click-modal="false"
|
|
9
|
+
@close="closeSee"
|
|
10
|
+
>
|
|
11
|
+
<Table :data="tableData" :columns="checkColumns" height="400px" :show-setsize="true" :cell-default="true">
|
|
12
|
+
<el-table-column slot="checkStatus" slot-scope="{ column }" v-bind="column">
|
|
13
|
+
<template slot-scope="{ row }">
|
|
14
|
+
<el-tag v-if="row.checkStatus === '0'" effect="dark" type="warning" size="mini">不通过</el-tag>
|
|
15
|
+
<el-tag v-if="row.checkStatus === '1'" effect="dark" type="success" size="mini">通过</el-tag>
|
|
16
|
+
</template>
|
|
17
|
+
</el-table-column>
|
|
18
|
+
<el-table-column slot="remark" slot-scope="{ column }" v-bind="column">
|
|
19
|
+
<template slot-scope="{ row }">
|
|
20
|
+
<el-input
|
|
21
|
+
v-model="row.remark"
|
|
22
|
+
placeholder="请输入"
|
|
23
|
+
size="normal"
|
|
24
|
+
clearable
|
|
25
|
+
:disabled="readonly || row.status === '1'"
|
|
26
|
+
/>
|
|
27
|
+
</template>
|
|
28
|
+
</el-table-column>
|
|
29
|
+
</Table>
|
|
30
|
+
<div slot="footer" class="page-button-shadow flex-box flex-c flex-v">
|
|
31
|
+
<el-button v-if="!readonly" type="primary" @click="save">确定</el-button>
|
|
32
|
+
<el-button plain @click="cancel">取消</el-button>
|
|
33
|
+
</div>
|
|
34
|
+
</Dialog>
|
|
35
|
+
</template>
|
|
36
|
+
|
|
37
|
+
<script>
|
|
38
|
+
import Dialog from '../Dialog/index.vue'
|
|
39
|
+
import Table from '../Table/index.vue'
|
|
40
|
+
|
|
41
|
+
export default {
|
|
42
|
+
name: 'AiCheckDialog',
|
|
43
|
+
components: { Dialog, Table },
|
|
44
|
+
props: {
|
|
45
|
+
apiPrefix: {
|
|
46
|
+
type: String,
|
|
47
|
+
default: undefined
|
|
48
|
+
},
|
|
49
|
+
readonly: {
|
|
50
|
+
type: Boolean,
|
|
51
|
+
default: false
|
|
52
|
+
}
|
|
53
|
+
},
|
|
54
|
+
data() {
|
|
55
|
+
return {
|
|
56
|
+
visibleP: false,
|
|
57
|
+
checkColumns: [
|
|
58
|
+
{
|
|
59
|
+
type: 'index',
|
|
60
|
+
label: '序号',
|
|
61
|
+
width: '56',
|
|
62
|
+
align: 'center',
|
|
63
|
+
static: 'pre'
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
label: '提示词',
|
|
67
|
+
prop: 'prompt',
|
|
68
|
+
align: 'center',
|
|
69
|
+
minWidth: '120',
|
|
70
|
+
checked: true, // 默认选择的,不能在设置"显示列"中取消的列
|
|
71
|
+
'show-overflow-tooltip': true
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
label: 'AI识别结果',
|
|
75
|
+
prop: 'aiResult',
|
|
76
|
+
align: 'center',
|
|
77
|
+
minWidth: '120',
|
|
78
|
+
checked: true, // 默认选择的,不能在设置"显示列"中取消的列
|
|
79
|
+
'show-overflow-tooltip': true
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
label: '校验结果',
|
|
83
|
+
prop: 'checkStatus',
|
|
84
|
+
slotName: 'checkStatus',
|
|
85
|
+
align: 'center',
|
|
86
|
+
minWidth: '120',
|
|
87
|
+
checked: true, // 默认选择的,不能在设置"显示列"中取消的列
|
|
88
|
+
'show-overflow-tooltip': true
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
label: '说明',
|
|
92
|
+
prop: 'remark',
|
|
93
|
+
slotName: 'remark',
|
|
94
|
+
align: 'center',
|
|
95
|
+
minWidth: '120',
|
|
96
|
+
checked: true, // 默认选择的,不能在设置"显示列"中取消的列
|
|
97
|
+
'show-overflow-tooltip': false
|
|
98
|
+
}
|
|
99
|
+
],
|
|
100
|
+
tableData: [],
|
|
101
|
+
beid: ''
|
|
102
|
+
}
|
|
103
|
+
},
|
|
104
|
+
computed: {},
|
|
105
|
+
watch: {},
|
|
106
|
+
created() {},
|
|
107
|
+
mounted() {},
|
|
108
|
+
methods: {
|
|
109
|
+
cancel() {
|
|
110
|
+
this.visibleP = false
|
|
111
|
+
this.tableData = []
|
|
112
|
+
this.$emit('cancel', this.beid)
|
|
113
|
+
},
|
|
114
|
+
setView(list, beid) {
|
|
115
|
+
this.visibleP = true
|
|
116
|
+
this.tableData = list
|
|
117
|
+
this.beid = beid
|
|
118
|
+
},
|
|
119
|
+
async save() {
|
|
120
|
+
const list = this.tableData.map((item) => {
|
|
121
|
+
item.beid = this.beid
|
|
122
|
+
item.status = '1'
|
|
123
|
+
return item
|
|
124
|
+
})
|
|
125
|
+
const { code } = await this.$axios.post(
|
|
126
|
+
this.apiPrefix ? `${this.apiPrefix}/neams/ai/saveAiBussResult` : `/neams/ai/saveAiBussResult`,
|
|
127
|
+
list
|
|
128
|
+
)
|
|
129
|
+
if (code === 200) {
|
|
130
|
+
this.$message.success('保存成功')
|
|
131
|
+
this.visibleP = false
|
|
132
|
+
}
|
|
133
|
+
},
|
|
134
|
+
closeSee() {
|
|
135
|
+
this.tableData = []
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
</script>
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
<div class="flex-box flex-v flex-lr m-b-s">
|
|
4
4
|
<div>
|
|
5
5
|
<slot name="title"></slot>
|
|
6
|
+
<span v-if="fileText" v-html="fileText"></span>
|
|
6
7
|
</div>
|
|
7
8
|
<div>
|
|
8
9
|
<slot v-if="!readonly" name="add-btn">
|
|
@@ -23,6 +24,7 @@
|
|
|
23
24
|
</div>
|
|
24
25
|
</div>
|
|
25
26
|
<el-table
|
|
27
|
+
:key="tableKey"
|
|
26
28
|
:data="tableData"
|
|
27
29
|
:row-key="keys.rowKey"
|
|
28
30
|
:height="height"
|
|
@@ -48,22 +50,24 @@
|
|
|
48
50
|
<slot slot="header" slot-scope="scope" name="type-header" :column="scope.column">{{ '附件类型' | $lc }}</slot>
|
|
49
51
|
<slot slot-scope="{ row }" name="type" :row="row">
|
|
50
52
|
<span v-if="readonly">{{ row[keys.type] | typeFiter(typeOptions) }}</span>
|
|
51
|
-
<
|
|
52
|
-
v-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
53
|
+
<div v-else class="flex-box flex-v">
|
|
54
|
+
<span v-if="requiredTypes.includes(row[keys.type])" style="color: red" class="m-r-s">*</span>
|
|
55
|
+
<el-select
|
|
56
|
+
v-model="row[keys.type]"
|
|
57
|
+
:disabled="row._typeDisabled"
|
|
58
|
+
:placeholder="'请选择' | $lc"
|
|
59
|
+
style="width: calc(100% - 16px)"
|
|
60
|
+
@change="$emit('typeChange', row[keys.type])"
|
|
61
|
+
>
|
|
62
|
+
<el-option
|
|
63
|
+
v-for="item in typeOptions"
|
|
64
|
+
:key="item.type"
|
|
65
|
+
:disabled="item.disabled"
|
|
66
|
+
:value="item.type"
|
|
67
|
+
:label="item.label"
|
|
68
|
+
/>
|
|
69
|
+
</el-select>
|
|
70
|
+
</div>
|
|
67
71
|
</slot>
|
|
68
72
|
</el-table-column>
|
|
69
73
|
<el-table-column :label="'附件名称' | $lc" :prop="keys.name">
|
|
@@ -72,6 +76,7 @@
|
|
|
72
76
|
<span v-if="readonly">{{ row[keys.name] ? row[keys.name].replace(/\.[A-z0-9]+$/, '') : '' }}</span>
|
|
73
77
|
<el-input
|
|
74
78
|
v-else
|
|
79
|
+
v-title
|
|
75
80
|
:value="row[keys.name] ? row[keys.name].replace(/\.[A-z0-9]+$/, '') : ''"
|
|
76
81
|
disabled
|
|
77
82
|
:placeholder="'请输入' | $lc"
|
|
@@ -118,7 +123,37 @@
|
|
|
118
123
|
</slot>
|
|
119
124
|
</el-table-column>
|
|
120
125
|
<slot name="slotCol"></slot>
|
|
121
|
-
<el-table-column :label="'
|
|
126
|
+
<el-table-column v-if="AICheck" :label="'AI校验' | $lc" width="170" align="left">
|
|
127
|
+
<template slot-scope="{ row }">
|
|
128
|
+
<span
|
|
129
|
+
v-if="AIOptions.hasViewBtn && readonly"
|
|
130
|
+
class="m-r-s"
|
|
131
|
+
style="color: var(--color-success); cursor: pointer"
|
|
132
|
+
@click="getAiCheckData(row)"
|
|
133
|
+
>
|
|
134
|
+
{{ '查看' | $lc }}</span
|
|
135
|
+
>
|
|
136
|
+
<span
|
|
137
|
+
v-if="row.aiCheckStatus === '0' || row.aiCheckStatus === 0"
|
|
138
|
+
class="m-r-s"
|
|
139
|
+
style="color: var(--color-danger); cursor: pointer"
|
|
140
|
+
@click="getAiCheckData(row)"
|
|
141
|
+
>
|
|
142
|
+
{{ '校验异常' | $lc }}</span
|
|
143
|
+
>
|
|
144
|
+
<span
|
|
145
|
+
v-if="row.aiCheckStatus === '1' || row.aiCheckStatus === 1"
|
|
146
|
+
class="m-r-s"
|
|
147
|
+
style="color: var(--color-success)"
|
|
148
|
+
>
|
|
149
|
+
{{ '校验通过' | $lc }}</span
|
|
150
|
+
>
|
|
151
|
+
<el-button v-if="!readonly && row[keys.url]" type="text" size="small" @click="AiCheck(row)">{{
|
|
152
|
+
'校验' | $lc
|
|
153
|
+
}}</el-button>
|
|
154
|
+
</template>
|
|
155
|
+
</el-table-column>
|
|
156
|
+
<el-table-column v-if="!hideTime" :label="'上传时间' | $lc" :prop="keys.time" sortable width="170" align="left">
|
|
122
157
|
<slot slot="header" slot-scope="scope" name="time-header" :column="scope.column">{{ '上传时间' | $lc }}</slot>
|
|
123
158
|
<slot slot-scope="{ row }" name="time" :row="row">{{ row[keys.time] }}</slot>
|
|
124
159
|
</el-table-column>
|
|
@@ -164,12 +199,14 @@
|
|
|
164
199
|
<el-table-column :label="'操作' | $lc" align="center" width="90" fixed="right">
|
|
165
200
|
<slot slot="header" slot-scope="scope" name="handle-header" :column="scope.column">{{ '操作' | $lc }}</slot>
|
|
166
201
|
<slot slot-scope="{ row }" name="handle" :row="row">
|
|
202
|
+
<el-button type="text" icon="el-icon-view" :disabled="!row[keys.url]" @click="seeFile(row)" />
|
|
167
203
|
<el-button
|
|
204
|
+
v-if="getOfficeStatus && openAI"
|
|
205
|
+
v-title="'ai识别'"
|
|
168
206
|
type="text"
|
|
169
|
-
icon="
|
|
170
|
-
v-if="getOfficeStatus"
|
|
207
|
+
icon="n20-icon-query"
|
|
171
208
|
:disabled="!row[keys.url]"
|
|
172
|
-
@click="
|
|
209
|
+
@click="AiFn(row)"
|
|
173
210
|
/>
|
|
174
211
|
<el-button
|
|
175
212
|
v-if="readonly"
|
|
@@ -228,7 +265,7 @@
|
|
|
228
265
|
:close-on-click-modal="false"
|
|
229
266
|
:destroy-on-open="true"
|
|
230
267
|
>
|
|
231
|
-
<el-select class="m-b-s"
|
|
268
|
+
<el-select v-model="bathType" class="m-b-s" clearable @change="handleBathChange">
|
|
232
269
|
<el-option
|
|
233
270
|
v-for="item in typeOptions"
|
|
234
271
|
:key="item.type"
|
|
@@ -269,13 +306,17 @@
|
|
|
269
306
|
<el-button plain @click="visibleBatch = false">{{ '取消' | $lc }}</el-button>
|
|
270
307
|
</div>
|
|
271
308
|
</Dialog>
|
|
309
|
+
<aiCheckDialog ref="aiCheckDialog" :api-prefix="apiPrefix" :readonly="readonly" @cancel="aiCheckCancel" />
|
|
272
310
|
</div>
|
|
273
311
|
</template>
|
|
274
312
|
|
|
275
313
|
<script>
|
|
314
|
+
import aiCheckDialog from './aiCheckDialog.vue'
|
|
315
|
+
import getJsonc from '../../assets/getJsonc.js'
|
|
276
316
|
import _axios from 'axios'
|
|
277
317
|
import dayjs from 'dayjs'
|
|
278
|
-
import
|
|
318
|
+
import XEUtils from 'xe-utils'
|
|
319
|
+
|
|
279
320
|
import 'viewerjs/dist/viewer.css'
|
|
280
321
|
import auth from '../../utils/auth'
|
|
281
322
|
import axios from '../../utils/axios'
|
|
@@ -305,13 +346,14 @@ const typeOptionsDefault = [
|
|
|
305
346
|
export default {
|
|
306
347
|
name: 'FileUploadTable',
|
|
307
348
|
components: {
|
|
349
|
+
aiCheckDialog,
|
|
308
350
|
Upload,
|
|
309
351
|
Dialog,
|
|
310
352
|
ViewerImg
|
|
311
353
|
},
|
|
312
354
|
filters: {
|
|
313
355
|
typeFiter(type, typeOptions) {
|
|
314
|
-
return typeOptions.find((c) => c.type === type)?.label ||
|
|
356
|
+
return typeOptions.find((c) => c.type === type)?.label || type
|
|
315
357
|
},
|
|
316
358
|
acceptFilter(type, typeOptions, fileAccept) {
|
|
317
359
|
return typeOptions.find((c) => c.type === type)?.accept || fileAccept
|
|
@@ -325,12 +367,28 @@ export default {
|
|
|
325
367
|
} else if (row[urlK]) {
|
|
326
368
|
let urlArr = row[urlK].split('/')
|
|
327
369
|
let _n = urlArr[urlArr.length - 1]
|
|
328
|
-
|
|
370
|
+
try {
|
|
371
|
+
return _n ? decodeURI(_n) : undefined
|
|
372
|
+
} catch (e) {
|
|
373
|
+
return _n // 如果解码失败,返回原始文件名
|
|
374
|
+
}
|
|
329
375
|
}
|
|
330
376
|
return undefined
|
|
331
377
|
}
|
|
332
378
|
},
|
|
333
379
|
props: {
|
|
380
|
+
AICheck: {
|
|
381
|
+
type: Boolean,
|
|
382
|
+
default: false
|
|
383
|
+
},
|
|
384
|
+
AIOptions: {
|
|
385
|
+
type: Object,
|
|
386
|
+
default: () => ({})
|
|
387
|
+
},
|
|
388
|
+
openAI: {
|
|
389
|
+
type: Boolean,
|
|
390
|
+
default: false
|
|
391
|
+
},
|
|
334
392
|
readonly: {
|
|
335
393
|
type: Boolean,
|
|
336
394
|
default: false
|
|
@@ -390,6 +448,10 @@ export default {
|
|
|
390
448
|
hideUser: {
|
|
391
449
|
type: Boolean,
|
|
392
450
|
default: false
|
|
451
|
+
},
|
|
452
|
+
hideTime: {
|
|
453
|
+
type: Boolean,
|
|
454
|
+
default: false
|
|
393
455
|
}
|
|
394
456
|
},
|
|
395
457
|
data() {
|
|
@@ -416,6 +478,12 @@ export default {
|
|
|
416
478
|
}
|
|
417
479
|
|
|
418
480
|
return {
|
|
481
|
+
tableKey: 0,
|
|
482
|
+
// 是否仅平铺必选附件
|
|
483
|
+
fileRequired: true,
|
|
484
|
+
// 必传附件
|
|
485
|
+
requiredTypes: [],
|
|
486
|
+
fileText: '',
|
|
419
487
|
bathType: '',
|
|
420
488
|
indexK: '$index',
|
|
421
489
|
imgType: /\.(jpg|png|gif|svg)$/i,
|
|
@@ -454,7 +522,138 @@ export default {
|
|
|
454
522
|
return this.dataPorp.multiple ?? true
|
|
455
523
|
}
|
|
456
524
|
},
|
|
525
|
+
watch: {
|
|
526
|
+
dataPorp: {
|
|
527
|
+
handler() {
|
|
528
|
+
this.requiredTypes = this.dataPorp.typeOptions
|
|
529
|
+
.filter((item) => {
|
|
530
|
+
return item.required === 1
|
|
531
|
+
})
|
|
532
|
+
.map((item) => {
|
|
533
|
+
return item.attno
|
|
534
|
+
})
|
|
535
|
+
if (this.dataPorp.typeOptions.length === 0) {
|
|
536
|
+
return false
|
|
537
|
+
}
|
|
538
|
+
this.setTableData()
|
|
539
|
+
},
|
|
540
|
+
immediate: true,
|
|
541
|
+
deep: true
|
|
542
|
+
}
|
|
543
|
+
},
|
|
544
|
+
mounted() {
|
|
545
|
+
this.getConfiguration()
|
|
546
|
+
},
|
|
457
547
|
methods: {
|
|
548
|
+
// ai校验取消
|
|
549
|
+
aiCheckCancel(beid) {
|
|
550
|
+
this.tableData.forEach((item) => {
|
|
551
|
+
if (item.beid === beid) {
|
|
552
|
+
item.aiCheckStatus = ''
|
|
553
|
+
}
|
|
554
|
+
this.tableKey++
|
|
555
|
+
})
|
|
556
|
+
},
|
|
557
|
+
// ai校验结果
|
|
558
|
+
async getAiCheckData(row) {
|
|
559
|
+
const { data, code } = await this.$axios.get(
|
|
560
|
+
this.apiPrefix ? `${this.apiPrefix}/neams/ai/getAiBussResult` : `/neams/ai/getAiBussResult`,
|
|
561
|
+
{
|
|
562
|
+
beid: row.beid,
|
|
563
|
+
status: '1'
|
|
564
|
+
}
|
|
565
|
+
)
|
|
566
|
+
if (code === 200) {
|
|
567
|
+
this.$refs.aiCheckDialog.setView(data, row.beid)
|
|
568
|
+
}
|
|
569
|
+
},
|
|
570
|
+
// ai校验
|
|
571
|
+
async AiCheck(row) {
|
|
572
|
+
// isOptionAiCheck为true,业务组件自己调ai校验
|
|
573
|
+
if (this.AIOptions.isOptionAiCheck) {
|
|
574
|
+
this.$emit('AiCheckFn', row, (result) => {
|
|
575
|
+
row.aiCheckStatus = result.aiCheckStatus
|
|
576
|
+
this.tableKey++
|
|
577
|
+
this.$refs.aiCheckDialog.setView(result.list, row.beid)
|
|
578
|
+
})
|
|
579
|
+
} else {
|
|
580
|
+
if (!this.AIOptions.bussType) {
|
|
581
|
+
this.$message.error('请先配置bussType')
|
|
582
|
+
return false
|
|
583
|
+
}
|
|
584
|
+
let { data, code } = await this.$axios.post(
|
|
585
|
+
this.apiPrefix ? `${this.apiPrefix}/neams/eamsbaserecord/aiAttaFile` : `/neams/eamsbaserecord/aiAttaFile`,
|
|
586
|
+
{
|
|
587
|
+
...this.AIOptions,
|
|
588
|
+
beid: row.beid,
|
|
589
|
+
bussType: this.AIOptions.bussType,
|
|
590
|
+
extendPrompt: ''
|
|
591
|
+
}
|
|
592
|
+
)
|
|
593
|
+
if (code === 200) {
|
|
594
|
+
this.$emit('AiCheckFn', data, (result) => {
|
|
595
|
+
row.aiCheckStatus = result.aiCheckStatus
|
|
596
|
+
this.tableKey++
|
|
597
|
+
this.$refs.aiCheckDialog.setView(result.list, row.beid)
|
|
598
|
+
})
|
|
599
|
+
}
|
|
600
|
+
}
|
|
601
|
+
},
|
|
602
|
+
// ai识别
|
|
603
|
+
async AiFn(row) {
|
|
604
|
+
if (!this.AIOptions.bussType) {
|
|
605
|
+
this.$message.error('请先配置bussType')
|
|
606
|
+
return false
|
|
607
|
+
}
|
|
608
|
+
const { data, code } = await this.$axios.post(
|
|
609
|
+
this.apiPrefix ? `${this.apiPrefix}/neams/eamsbaserecord/aiAttaFile` : `/neams/eamsbaserecord/aiAttaFile`,
|
|
610
|
+
{
|
|
611
|
+
beid: row.beid,
|
|
612
|
+
bussType: this.AIOptions.bussType,
|
|
613
|
+
extendPrompt: ''
|
|
614
|
+
}
|
|
615
|
+
)
|
|
616
|
+
if (code === 200) {
|
|
617
|
+
this.$emit('aiFn', data)
|
|
618
|
+
}
|
|
619
|
+
},
|
|
620
|
+
// 平铺附件
|
|
621
|
+
setTableData() {
|
|
622
|
+
if (this.tableData.length === 0 && !this.readonly) {
|
|
623
|
+
this.dataPorp.typeOptions
|
|
624
|
+
.filter((item) => {
|
|
625
|
+
if (this.fileRequired) {
|
|
626
|
+
return item.required === 1
|
|
627
|
+
} else {
|
|
628
|
+
return item.required === 1 || item.required === 0
|
|
629
|
+
}
|
|
630
|
+
})
|
|
631
|
+
.forEach((item) => {
|
|
632
|
+
let obj
|
|
633
|
+
obj = {
|
|
634
|
+
id: 'n' + Math.random(),
|
|
635
|
+
name: ''
|
|
636
|
+
}
|
|
637
|
+
obj[this.keys.type] = item.attno
|
|
638
|
+
obj[this.keys.time] = ''
|
|
639
|
+
obj[this.keys.user] = JSON.parse(sessionStorage.getItem('userInfo')).uname
|
|
640
|
+
|
|
641
|
+
console.log(obj)
|
|
642
|
+
this.tableData.push(obj)
|
|
643
|
+
})
|
|
644
|
+
}
|
|
645
|
+
},
|
|
646
|
+
getConfiguration() {
|
|
647
|
+
getJsonc('portal/server-config.jsonc', null, true)
|
|
648
|
+
.then(({ loginConf, fileRequired }) => {
|
|
649
|
+
this.fileText = loginConf?.sLogan?.fileText
|
|
650
|
+
this.fileRequired = fileRequired ?? true
|
|
651
|
+
})
|
|
652
|
+
.catch(() => {
|
|
653
|
+
this.fileText = ''
|
|
654
|
+
this.fileRequired = true
|
|
655
|
+
})
|
|
656
|
+
},
|
|
458
657
|
async getOfficeStatus() {
|
|
459
658
|
const { data } = await this.$axios.get(
|
|
460
659
|
this.apiPrefix
|
|
@@ -516,7 +715,7 @@ export default {
|
|
|
516
715
|
$uploadwrap.submit()
|
|
517
716
|
},
|
|
518
717
|
batchSuccess(response, file, fileList) {
|
|
519
|
-
let row = {}
|
|
718
|
+
let row = { ...this.dataPorp.keys }
|
|
520
719
|
this.tableData.splice(0, 0, row)
|
|
521
720
|
this.$nextTick(() => {
|
|
522
721
|
this.onSuccessFn(response, file, fileList, row)
|
|
@@ -559,7 +758,10 @@ export default {
|
|
|
559
758
|
showClose: true
|
|
560
759
|
})
|
|
561
760
|
}
|
|
562
|
-
this.$emit(
|
|
761
|
+
this.$emit(
|
|
762
|
+
'down-rows',
|
|
763
|
+
this.selectionList.filter((item) => item[this.keys.url] || item._name)
|
|
764
|
+
)
|
|
563
765
|
},
|
|
564
766
|
deleteRows() {
|
|
565
767
|
if (!this.selectionList.length) {
|
|
@@ -681,6 +883,7 @@ export default {
|
|
|
681
883
|
let Pro = axios.post(opt.action + '?r=' + Math.random(), FD, {
|
|
682
884
|
headers: Object.assign(auth.setHeaders(this.headers), { 'Content-Type': 'multipart/form-data' }),
|
|
683
885
|
loading: false,
|
|
886
|
+
timeout: 900000,
|
|
684
887
|
onUploadProgress: (arg) => {
|
|
685
888
|
if (opt.onProgress) {
|
|
686
889
|
arg.percent = arg.progress * 100
|
|
@@ -703,38 +906,53 @@ export default {
|
|
|
703
906
|
if (bu) return bu(file, row)
|
|
704
907
|
},
|
|
705
908
|
onProgressFn({ percent }, row) {
|
|
909
|
+
this.$set(row, '_typeDisabled', true)
|
|
706
910
|
this.$set(row, '_percent', percent <= 99 ? Math.round(percent) : 99)
|
|
707
911
|
},
|
|
708
912
|
onSuccessFn(response, file, fileList, row) {
|
|
709
913
|
this.$set(row, '_typeDisabled', true)
|
|
710
914
|
this.$set(row, '_name', file.name)
|
|
711
|
-
|
|
915
|
+
|
|
916
|
+
this.$set(row, [this.keys.rowKey], response.data)
|
|
712
917
|
this.$set(row, [this.keys.type], row[this.keys.type] || this.bathType)
|
|
713
918
|
row[this.keys.time] = dayjs().format('YYYY-MM-DD HH:mm:ss')
|
|
714
|
-
|
|
919
|
+
if (response.code >= 900 || response.code === -1) {
|
|
920
|
+
this.$set(row, '_percent', 99)
|
|
921
|
+
this.$set(row, '_status', 'error')
|
|
922
|
+
} else {
|
|
923
|
+
this.$set(row, '_percent', 100)
|
|
924
|
+
this.$set(row, '_status', 'success')
|
|
925
|
+
}
|
|
715
926
|
row[this.keys.url] = response.data
|
|
716
|
-
// if (!row[this.keys.name]) { row[this.keys.name] = file.name }
|
|
717
927
|
row[this.keys.name] = file.name
|
|
718
|
-
this.$set(row, '_status', 'success')
|
|
719
928
|
|
|
720
929
|
this.$emit('on-success', file, row)
|
|
721
930
|
},
|
|
722
931
|
MultipleSUccessFn(response, file, fileList, row) {
|
|
723
932
|
if (fileList.length > 1) {
|
|
724
|
-
let deepRow =
|
|
933
|
+
let deepRow = XEUtils.clone(row, true)
|
|
725
934
|
this.$nextTick(() => {
|
|
726
935
|
if (this.tableData.length && !this.tableData[0][this.keys.url]) {
|
|
727
936
|
this.tableData.shift()
|
|
728
937
|
}
|
|
729
938
|
})
|
|
939
|
+
let _percent = 0
|
|
940
|
+
let _status = undefined
|
|
941
|
+
if (response.code >= 900 || response.code === -1) {
|
|
942
|
+
_percent = 99
|
|
943
|
+
_status = 'error'
|
|
944
|
+
} else {
|
|
945
|
+
_percent = 99
|
|
946
|
+
_status = 'success'
|
|
947
|
+
}
|
|
730
948
|
setTimeout(() => {
|
|
731
949
|
this.tableData.splice(0, 0, {
|
|
732
950
|
_name: file.name,
|
|
733
|
-
_percent
|
|
951
|
+
_percent,
|
|
734
952
|
[this.keys.time]: dayjs().format('YYYY-MM-DD HH:mm:ss'),
|
|
735
953
|
[this.keys.url]: response.data,
|
|
736
954
|
[this.keys.name]: file.name,
|
|
737
|
-
_status
|
|
955
|
+
_status,
|
|
738
956
|
_typeDisabled: true,
|
|
739
957
|
[this.keys.user]: deepRow[this.keys.user],
|
|
740
958
|
[this.keys.type]: deepRow[this.keys.type]
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" class="design-iconfont">
|
|
2
|
+
<path d="M8.24182 3.58716L11.2487 8.99438V6.31665H13.3151V12.9797L11.3785 13.4827L7.3219 6.18677L4.3512 11.3323H8.37366V13.3997H2.56018L1.66565 11.8499L6.44397 3.57349L8.24182 3.58716Z" fill="#007AFF"/>
|
|
3
|
+
<path d="M12.2593 1.66284L12.7877 3.21041L14.3353 3.73888L12.7877 4.26736L12.2593 5.81492L11.7308 4.26736L10.1832 3.73888L11.7308 3.21041L12.2593 1.66284Z" fill="#007AFF"/>
|
|
4
|
+
<path d="M2.32765 3.57349L2.68419 4.61759L3.72829 4.97413L2.68419 5.33068L2.32765 6.37478L1.9711 5.33068L0.927002 4.97413L1.9711 4.61759L2.32765 3.57349Z" fill="#007AFF"/>
|
|
5
|
+
<path d="M9.83558 13.011L10.0044 13.5053L10.4987 13.6741L10.0044 13.8429L9.83558 14.3372L9.66679 13.8429L9.17249 13.6741L9.66679 13.5053L9.83558 13.011Z" fill="#007AFF"/>
|
|
6
|
+
</svg>
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" class="design-iconfont">
|
|
2
|
+
<path fill-rule="evenodd" clip-rule="evenodd" d="M1.33334 7.99998C1.33334 4.31808 4.31811 1.33331 8.00001 1.33331C11.6819 1.33331 14.6667 4.31808 14.6667 7.99998C14.6667 11.6819 11.6819 14.6666 8.00001 14.6666C4.31811 14.6666 1.33334 11.6819 1.33334 7.99998ZM7.33335 10.6095L11.6381 6.30473L10.6953 5.36192L7.33335 8.72385L5.47142 6.86192L4.52862 7.80473L7.33335 10.6095Z" fill="#CCC"/>
|
|
3
|
+
</svg>
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
<svg fill="none" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16" class="design-iconfont">
|
|
2
|
+
<path fill-rule="evenodd" clip-rule="evenodd" d="M1.33334 8.00004C1.33334 4.31814 4.31811 1.33337 8.00001 1.33337C11.6819 1.33337 14.6667 4.31814 14.6667 8.00004C14.6667 11.6819 11.6819 14.6667 8.00001 14.6667C4.31811 14.6667 1.33334 11.6819 1.33334 8.00004ZM7.33335 10.6095L11.6381 6.30479L10.6953 5.36198L7.33335 8.72391L5.47142 6.86198L4.52862 7.80479L7.33335 10.6095Z" fill="#48D2A0"/>
|
|
3
|
+
</svg>
|