fl-web-component 0.1.0
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/README.md +24 -0
- package/dist/demo.html +10 -0
- package/dist/fl-web-component.common.js +316 -0
- package/dist/fl-web-component.common.js.map +1 -0
- package/dist/fl-web-component.css +1 -0
- package/dist/fl-web-component.umd.js +326 -0
- package/dist/fl-web-component.umd.js.map +1 -0
- package/dist/fl-web-component.umd.min.js +2 -0
- package/dist/fl-web-component.umd.min.js.map +1 -0
- package/package.json +47 -0
- package/packages/components/button/index.vue +22 -0
- package/packages/components/model/api/index.js +429 -0
- package/packages/components/model/api/mock/detecttree.js +58 -0
- package/packages/components/model/api/mock/getmodel-line.js +79336 -0
- package/packages/components/model/api/mock/init.js +1 -0
- package/packages/components/model/api/mock/pbstree.js +835 -0
- package/packages/components/model/api/mock/topology.json +3238 -0
- package/packages/components/model/components/TextOverTooltip/index.vue +84 -0
- package/packages/components/model/components/annotation-toolbar.vue +425 -0
- package/packages/components/model/components/check-proofing-model.vue +42 -0
- package/packages/components/model/components/clipping-type.vue +51 -0
- package/packages/components/model/components/com-dialogWrapper/Readme.md +53 -0
- package/packages/components/model/components/com-dialogWrapper/index.vue +117 -0
- package/packages/components/model/components/detect-panel.vue +327 -0
- package/packages/components/model/components/detect-tree.vue +460 -0
- package/packages/components/model/components/firstPer-panel.vue +111 -0
- package/packages/components/model/components/header-button.vue +546 -0
- package/packages/components/model/components/imageViewer/index.vue +127 -0
- package/packages/components/model/components/import-model.vue +127 -0
- package/packages/components/model/components/location-panel.vue +95 -0
- package/packages/components/model/components/measure-type.vue +59 -0
- package/packages/components/model/components/pbs-tree.vue +502 -0
- package/packages/components/model/components/proof-config.vue +80 -0
- package/packages/components/model/components/proof-for-pc.vue +123 -0
- package/packages/components/model/components/proof-history.vue +318 -0
- package/packages/components/model/components/proof-panel-detail.vue +567 -0
- package/packages/components/model/components/proof-panel.vue +770 -0
- package/packages/components/model/components/proof-project-user.vue +482 -0
- package/packages/components/model/components/proof-publish.vue +130 -0
- package/packages/components/model/components/proof-role.vue +535 -0
- package/packages/components/model/components/props-panel.vue +249 -0
- package/packages/components/model/index.vue +3413 -0
- package/packages/components/model/readme.md +31 -0
- package/packages/components/model/utils/annotation-tool.js +340 -0
- package/packages/components/model/utils/cursor.js +18 -0
- package/packages/components/model/utils/detect-v1.js +341 -0
- package/packages/components/model/utils/index.js +48 -0
- package/packages/components/model/utils/threejs/measure-angle.js +258 -0
- package/packages/components/model/utils/threejs/measure-area.js +269 -0
- package/packages/components/model/utils/threejs/measure-distance.js +207 -0
- package/packages/components/model/utils/threejs/measure-volume.js +94 -0
- package/packages/index.js +24 -0
|
@@ -0,0 +1,770 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<div :class="[isClient ? '': 'box-card']">
|
|
3
|
+
<div :class="[isClient ? 'box-card box-card_pc': '']" style="height: calc(100vh - 134px)">
|
|
4
|
+
<div class="box-title">
|
|
5
|
+
<span class="box-title-desc">校审</span>
|
|
6
|
+
<i v-if="!isClient" class="el-icon-close box-title-close" style="cursor: pointer" @click="$emit('rightOperation', 'proof')" />
|
|
7
|
+
</div>
|
|
8
|
+
|
|
9
|
+
<div v-show="!readOnlyMode" v-if="!isClient" v-loading="loading" class="box-add">
|
|
10
|
+
<el-button type="primary" style="margin-top: 8px; width: 100%"
|
|
11
|
+
@click="clickAdd"
|
|
12
|
+
v-hasPermi="[
|
|
13
|
+
`project:opinion:add:proj:${defaultParams.projectId}`,
|
|
14
|
+
]"
|
|
15
|
+
>添加校审意见</el-button>
|
|
16
|
+
<!-- :image="require('@/assets/images/no_drawer.png')" -->
|
|
17
|
+
</div>
|
|
18
|
+
|
|
19
|
+
<div class="box-filter">
|
|
20
|
+
<el-form @submit.native.prevent :model="filterModel" ref="queryForm" :inline="true" label-width="68px"
|
|
21
|
+
class="box-filter-form">
|
|
22
|
+
<template v-if="isClient">
|
|
23
|
+
<el-row class="row-bg" :gutter="10">
|
|
24
|
+
<el-col :span="6">
|
|
25
|
+
<el-form-item width="100%">
|
|
26
|
+
<el-select clearable v-model="filterModel.postId" placeholder="选择专业">
|
|
27
|
+
<el-option v-for="item in postList" :key="item.postId" :label="item.postName" :value="item.postId"
|
|
28
|
+
:disabled="item.disabled">
|
|
29
|
+
</el-option>
|
|
30
|
+
</el-select>
|
|
31
|
+
</el-form-item>
|
|
32
|
+
</el-col>
|
|
33
|
+
<el-col :span="6">
|
|
34
|
+
<el-form-item>
|
|
35
|
+
<el-select clearable v-model="filterModel.status" placeholder="选择状态">
|
|
36
|
+
<el-option v-for="item in filterStatusOpt" :key="item.value" :label="item.label" :value="item.value">
|
|
37
|
+
</el-option>
|
|
38
|
+
</el-select>
|
|
39
|
+
</el-form-item>
|
|
40
|
+
</el-col>
|
|
41
|
+
<el-col :span="8">
|
|
42
|
+
<el-form-item label="" prop="description" :style="{ width: `100%` }">
|
|
43
|
+
<el-input v-model="filterModel.description" placeholder="问题描述" clearable size="small"
|
|
44
|
+
@keyup.enter.native="handleQuery" />
|
|
45
|
+
</el-form-item>
|
|
46
|
+
</el-col>
|
|
47
|
+
<!-- :offset="2" -->
|
|
48
|
+
<el-col :span="4" >
|
|
49
|
+
<el-form-item>
|
|
50
|
+
<el-button type="primary" size="small" @click="handleQuery">搜索</el-button>
|
|
51
|
+
<!-- <el-button icon="el-icon-refresh" size="small" @click="resetQuery"
|
|
52
|
+
>重置</el-button
|
|
53
|
+
> -->
|
|
54
|
+
</el-form-item>
|
|
55
|
+
</el-col>
|
|
56
|
+
</el-row>
|
|
57
|
+
</template>
|
|
58
|
+
<template v-else>
|
|
59
|
+
<el-row type="flex" class="row-bg" align="middle" justify="space-between" :gutter="24">
|
|
60
|
+
<el-col :span="12">
|
|
61
|
+
<el-form-item>
|
|
62
|
+
<el-select clearable v-model="filterModel.postId" placeholder="选择专业">
|
|
63
|
+
<el-option v-for="item in postList" :key="item.postId" :label="item.postName" :value="item.postId"
|
|
64
|
+
:disabled="item.disabled">
|
|
65
|
+
</el-option>
|
|
66
|
+
</el-select>
|
|
67
|
+
</el-form-item>
|
|
68
|
+
</el-col>
|
|
69
|
+
<el-col :span="12">
|
|
70
|
+
<el-form-item>
|
|
71
|
+
<el-select clearable v-model="filterModel.status" placeholder="选择状态">
|
|
72
|
+
<el-option v-for="item in filterStatusOpt" :key="item.value" :label="item.label" :value="item.value">
|
|
73
|
+
</el-option>
|
|
74
|
+
</el-select>
|
|
75
|
+
</el-form-item>
|
|
76
|
+
</el-col>
|
|
77
|
+
</el-row>
|
|
78
|
+
<el-row type="flex" class="row-bg last-form-item" align="middle" justify="space-between" :gutter="24">
|
|
79
|
+
<el-col :span="18">
|
|
80
|
+
<el-form-item label="" prop="description" :style="{ width: `100%` }">
|
|
81
|
+
<el-input v-model="filterModel.description" placeholder="问题描述" clearable size="small"
|
|
82
|
+
@keyup.enter.native="handleQuery" />
|
|
83
|
+
</el-form-item>
|
|
84
|
+
</el-col>
|
|
85
|
+
<!-- :offset="2" -->
|
|
86
|
+
<el-col :span="6" >
|
|
87
|
+
<el-form-item>
|
|
88
|
+
<el-button type="primary" size="small" @click="handleQuery">搜索</el-button>
|
|
89
|
+
<!-- <el-button icon="el-icon-refresh" size="small" @click="resetQuery"
|
|
90
|
+
>重置</el-button
|
|
91
|
+
> -->
|
|
92
|
+
</el-form-item>
|
|
93
|
+
</el-col>
|
|
94
|
+
</el-row>
|
|
95
|
+
</template>
|
|
96
|
+
</el-form>
|
|
97
|
+
</div>
|
|
98
|
+
|
|
99
|
+
<div class="box-content">
|
|
100
|
+
<el-scrollbar>
|
|
101
|
+
|
|
102
|
+
<!-- v-infinite-scroll="load" -->
|
|
103
|
+
<!-- style="overflow-y: auto;height: calc(100vh - 250px)" -->
|
|
104
|
+
<div v-if="dataList.length" :class="[isClient ? 'data-item-container': '']">
|
|
105
|
+
<div v-for="(item, index) in dataList" :key="index" class="data-item" @click="selectRow(item)">
|
|
106
|
+
<el-card class="box-card-item" :class="item.id == selectedRow.id ? 'selected-row': ''" >
|
|
107
|
+
<div slot="header" class="clearfix">
|
|
108
|
+
<el-descriptions title="" :column="2">
|
|
109
|
+
<el-descriptions-item label="视点编号">{{ item.id }}</el-descriptions-item>
|
|
110
|
+
<el-descriptions-item label="" labelClassName="item-label" contentClassName="item-content">
|
|
111
|
+
<el-tag class="tag-reply" type="success" size="small" v-if="item.status === `1`">已回复</el-tag>
|
|
112
|
+
</el-descriptions-item>
|
|
113
|
+
<el-descriptions-item :contentClassName="isClient ? 'item-desc-pc': 'item-desc'" label="问题描述">{{ item.description }}</el-descriptions-item>
|
|
114
|
+
</el-descriptions>
|
|
115
|
+
</div>
|
|
116
|
+
<div :class="['footer', readOnlyMode ? 'readonly-mode' : '']">
|
|
117
|
+
<el-button
|
|
118
|
+
v-show="!readOnlyMode"
|
|
119
|
+
v-if="!isClient"
|
|
120
|
+
type="text"
|
|
121
|
+
@click="clickDelete(item)"
|
|
122
|
+
v-hasPermi="[
|
|
123
|
+
`project:opinion:remove:proj:${defaultParams.projectId}`,
|
|
124
|
+
]"
|
|
125
|
+
><span>删除</span><i
|
|
126
|
+
class="el-icon-delete pmc-fs-14 pmc-fc-BDC6CA" /></el-button>
|
|
127
|
+
<el-button type="text" @click="handleDetail(item)"><span>详情</span><i
|
|
128
|
+
class="el-icon-arrow-right pmc-fs-14 pmc-fc-BDC6CA" /></el-button>
|
|
129
|
+
</div>
|
|
130
|
+
</el-card>
|
|
131
|
+
</div>
|
|
132
|
+
</div>
|
|
133
|
+
<el-empty v-if="dataList.length === 0 && !loading" :image-size="150" description="暂无校审意见" />
|
|
134
|
+
</el-scrollbar>
|
|
135
|
+
</div>
|
|
136
|
+
</div>
|
|
137
|
+
<!-- @clickEdit="handleEdit" -->
|
|
138
|
+
<!-- v-if="annotationDetailDialog" -->
|
|
139
|
+
<proof-panel-detail
|
|
140
|
+
ref="proofPanelDetail"
|
|
141
|
+
:key="dataId"
|
|
142
|
+
:dialog-visible="annotationDetailDialog"
|
|
143
|
+
:data-id="dataId"
|
|
144
|
+
:postList="postList"
|
|
145
|
+
:userList="userList"
|
|
146
|
+
:detailProps="detailData"
|
|
147
|
+
:isClient="isClient"
|
|
148
|
+
:readOnlyMode="readOnlyMode"
|
|
149
|
+
:updatingOpinion="updatingOpinion"
|
|
150
|
+
:defaultParams="defaultParams"
|
|
151
|
+
@close="closeAnnotationDetailDialog"
|
|
152
|
+
@clickSaveBtn="saveForm"
|
|
153
|
+
@clickEditPic="handleEditPic"
|
|
154
|
+
/>
|
|
155
|
+
</div>
|
|
156
|
+
</template>
|
|
157
|
+
|
|
158
|
+
<script>
|
|
159
|
+
import ProofPanelDetail from './proof-panel-detail.vue'
|
|
160
|
+
import * as modelApi from "../api/index";
|
|
161
|
+
|
|
162
|
+
let timer = null;
|
|
163
|
+
|
|
164
|
+
const NEED_UPDATE_ENUM = {
|
|
165
|
+
false: 0,
|
|
166
|
+
true: 1,
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
export default {
|
|
170
|
+
name: "proofPanel",
|
|
171
|
+
components: { ProofPanelDetail },
|
|
172
|
+
props: {
|
|
173
|
+
// 文件id
|
|
174
|
+
fileId: {
|
|
175
|
+
type: Number,
|
|
176
|
+
default: 0
|
|
177
|
+
},
|
|
178
|
+
defaultParams: {
|
|
179
|
+
type: Object,
|
|
180
|
+
default() {
|
|
181
|
+
return {};
|
|
182
|
+
},
|
|
183
|
+
},
|
|
184
|
+
proofData: {
|
|
185
|
+
type: Object,
|
|
186
|
+
default() {
|
|
187
|
+
return {};
|
|
188
|
+
},
|
|
189
|
+
},
|
|
190
|
+
readOnlyMode:{
|
|
191
|
+
type: Boolean,
|
|
192
|
+
default: false,
|
|
193
|
+
}
|
|
194
|
+
},
|
|
195
|
+
data() {
|
|
196
|
+
return {
|
|
197
|
+
// 查询参数
|
|
198
|
+
queryParams: {
|
|
199
|
+
origFileId: this.fileId, // 批注前 原始的文件id
|
|
200
|
+
pageNum: 1,
|
|
201
|
+
pageSize: 3
|
|
202
|
+
},
|
|
203
|
+
dataList: [],
|
|
204
|
+
userList: [],
|
|
205
|
+
filterModel: {},
|
|
206
|
+
filterStatusOpt: [
|
|
207
|
+
{
|
|
208
|
+
value: "0",
|
|
209
|
+
label: "未处理",
|
|
210
|
+
},
|
|
211
|
+
{
|
|
212
|
+
value: "1",
|
|
213
|
+
label: "已处理",
|
|
214
|
+
},
|
|
215
|
+
{
|
|
216
|
+
value: "2",
|
|
217
|
+
label: "待确认",
|
|
218
|
+
}
|
|
219
|
+
],
|
|
220
|
+
postList: [],
|
|
221
|
+
loading: false,
|
|
222
|
+
annotationDetailDialog: false, // 查询详情弹窗
|
|
223
|
+
dataId: '', // 主键 id
|
|
224
|
+
screenHeight: document.documentElement.clientHeight, // 屏幕高度
|
|
225
|
+
selectedRow: {},
|
|
226
|
+
detailData: {},
|
|
227
|
+
updatingOpinion: false,
|
|
228
|
+
}
|
|
229
|
+
},
|
|
230
|
+
computed: {
|
|
231
|
+
isClient() {
|
|
232
|
+
return this.defaultParams.client == 'true'
|
|
233
|
+
},
|
|
234
|
+
},
|
|
235
|
+
watch:{
|
|
236
|
+
// 列表详情
|
|
237
|
+
selectedRow(row) {
|
|
238
|
+
console.log('selectedRow')
|
|
239
|
+
this.detailData = Object.assign({}, row);
|
|
240
|
+
},
|
|
241
|
+
// 编辑新建详情
|
|
242
|
+
proofData:{
|
|
243
|
+
handler(data){
|
|
244
|
+
this.detailData = Object.assign({}, data);
|
|
245
|
+
console.log(this.detailData)
|
|
246
|
+
},
|
|
247
|
+
deep: true,
|
|
248
|
+
}
|
|
249
|
+
},
|
|
250
|
+
created() {
|
|
251
|
+
},
|
|
252
|
+
mounted() {
|
|
253
|
+
// web端正常初始化,pc端不初始化
|
|
254
|
+
if(!this.isClient){
|
|
255
|
+
this.init()
|
|
256
|
+
}
|
|
257
|
+
},
|
|
258
|
+
methods: {
|
|
259
|
+
init(){
|
|
260
|
+
this.getProofOpinionList(this.defaultParams);
|
|
261
|
+
this.getPostList();
|
|
262
|
+
this.getProofProjectUserList({
|
|
263
|
+
projectId: this.defaultParams.projectId,
|
|
264
|
+
});
|
|
265
|
+
},
|
|
266
|
+
getProofOpinionList(params) {
|
|
267
|
+
modelApi
|
|
268
|
+
.getProofOpinionList(params)
|
|
269
|
+
.then((res) => {
|
|
270
|
+
// if (this.lodash.isEmpty(res)) {
|
|
271
|
+
// this.$message({ type: "warning", message: "暂无数据" });
|
|
272
|
+
// return;
|
|
273
|
+
// }
|
|
274
|
+
// res.rows.forEach(item => {
|
|
275
|
+
// item.stageId = this.defaultParams.stageId;
|
|
276
|
+
// item.projectId = this.defaultParams.projectId
|
|
277
|
+
// }); // TODO dev delete
|
|
278
|
+
console.log(res.rows)
|
|
279
|
+
this.$set(this, "dataList", res.rows ? res.rows : []);
|
|
280
|
+
})
|
|
281
|
+
.catch((err) => { })
|
|
282
|
+
.finally(() => {
|
|
283
|
+
this.currentRow = null;
|
|
284
|
+
this.detailStatus = "view";
|
|
285
|
+
});
|
|
286
|
+
},
|
|
287
|
+
getPostList() {
|
|
288
|
+
modelApi.getPostList().then((res) => {
|
|
289
|
+
if (res.code != 200) {
|
|
290
|
+
this.$message({ type: "warning", message: "暂无属性数据" });
|
|
291
|
+
return;
|
|
292
|
+
} else {
|
|
293
|
+
this.postList = res.rows;
|
|
294
|
+
}
|
|
295
|
+
});
|
|
296
|
+
},
|
|
297
|
+
load() {
|
|
298
|
+
if (this.dataList.length >= this.total) return false
|
|
299
|
+
this.queryParams.pageNum += 1
|
|
300
|
+
this.getList()
|
|
301
|
+
},
|
|
302
|
+
// 预览
|
|
303
|
+
handlePerview(id, callback) {
|
|
304
|
+
perview({ id }).then((res) => {
|
|
305
|
+
let reader = new FileReader()
|
|
306
|
+
reader.readAsDataURL(res) // 转换为base64
|
|
307
|
+
reader.onload = function () {
|
|
308
|
+
callback(reader.result)
|
|
309
|
+
}
|
|
310
|
+
})
|
|
311
|
+
},
|
|
312
|
+
handleDetail(row) {
|
|
313
|
+
const params = {
|
|
314
|
+
id: row.id,
|
|
315
|
+
projectId: this.defaultParams.projectId,
|
|
316
|
+
}
|
|
317
|
+
modelApi.getProofOpinionById(params).then((res) => {
|
|
318
|
+
if(res.code == 200){
|
|
319
|
+
this.selectedRow = res.data
|
|
320
|
+
}else{
|
|
321
|
+
this.selectedRow = row
|
|
322
|
+
}
|
|
323
|
+
}).catch((err) => {
|
|
324
|
+
console.log(err)
|
|
325
|
+
this.selectedRow = row
|
|
326
|
+
}).finally(() => {
|
|
327
|
+
this.annotationDetailDialog = true
|
|
328
|
+
})
|
|
329
|
+
},
|
|
330
|
+
// 取消按钮
|
|
331
|
+
cancel() {
|
|
332
|
+
this.open = false
|
|
333
|
+
this.reset()
|
|
334
|
+
},
|
|
335
|
+
// 关闭
|
|
336
|
+
closeAnnotationDetailDialog(refresh) {
|
|
337
|
+
refresh && this.getProofOpinionList(this.defaultParams);
|
|
338
|
+
this.annotationDetailDialog = false
|
|
339
|
+
},
|
|
340
|
+
openAnnotationDetailDialog(){
|
|
341
|
+
this.annotationDetailDialog = true
|
|
342
|
+
},
|
|
343
|
+
clickDelete(item) {
|
|
344
|
+
this.$confirm('此操作将删除, 是否继续?', '提示', {
|
|
345
|
+
confirmButtonText: '确定',
|
|
346
|
+
cancelButtonText: '取消',
|
|
347
|
+
type: 'warning'
|
|
348
|
+
}).then(() => {
|
|
349
|
+
const { id } = item;
|
|
350
|
+
modelApi
|
|
351
|
+
.deleteProofOpinion({
|
|
352
|
+
ids: id,
|
|
353
|
+
projectId: this.defaultParams.projectId,
|
|
354
|
+
// stageId: this.defaultParams.stageId,
|
|
355
|
+
})
|
|
356
|
+
.then((res) => {
|
|
357
|
+
if (res.code != 200) {
|
|
358
|
+
this.$message({
|
|
359
|
+
type: "error",
|
|
360
|
+
message: res.msg,
|
|
361
|
+
});
|
|
362
|
+
} else {
|
|
363
|
+
// this.disabledForm(true);
|
|
364
|
+
|
|
365
|
+
this.currentRow = null;
|
|
366
|
+
this.detailModel = {};
|
|
367
|
+
this.$emit("deleteRow", true);
|
|
368
|
+
this.getProofOpinionList(this.defaultParams);
|
|
369
|
+
this.$message({
|
|
370
|
+
type: "success",
|
|
371
|
+
message: res.msg,
|
|
372
|
+
});
|
|
373
|
+
}
|
|
374
|
+
})
|
|
375
|
+
.catch((res) => {
|
|
376
|
+
this.$message({
|
|
377
|
+
type: "error",
|
|
378
|
+
message: res.msg,
|
|
379
|
+
});
|
|
380
|
+
});
|
|
381
|
+
}).catch(() => {
|
|
382
|
+
});
|
|
383
|
+
},
|
|
384
|
+
handleQuery() {
|
|
385
|
+
const params = {
|
|
386
|
+
...this.filterModel,
|
|
387
|
+
...this.defaultParams,
|
|
388
|
+
};
|
|
389
|
+
this.getProofOpinionList(params);
|
|
390
|
+
},
|
|
391
|
+
clickAdd() {
|
|
392
|
+
this.detailStatus = "add";
|
|
393
|
+
this.selectedRow = {}; // 清空已选数据
|
|
394
|
+
// this.$refs.tableRef.setCurrentRow(); // 清空表格列表选择项
|
|
395
|
+
this.detailModel = {}; // 清空表单
|
|
396
|
+
this.detailData = {}
|
|
397
|
+
// this.disabledForm(false); // 表单可编辑
|
|
398
|
+
this.$emit("clickAddBtn", {
|
|
399
|
+
detailStatus: this.detailStatus,
|
|
400
|
+
});
|
|
401
|
+
},
|
|
402
|
+
handleProofSavelBtn(data){
|
|
403
|
+
this.$emit('clickSaveBtn', data)
|
|
404
|
+
},
|
|
405
|
+
// saveForm(data, success, fail){
|
|
406
|
+
// this.annotationDetailDialog = true;
|
|
407
|
+
|
|
408
|
+
// this.$nextTick(() => {
|
|
409
|
+
// console.log(this.$refs.proofPanelDetail)
|
|
410
|
+
// this.$refs.proofPanelDetail.saveForm(data, success, fail)
|
|
411
|
+
// this.annotationDetailDialog = false;
|
|
412
|
+
// })
|
|
413
|
+
// },
|
|
414
|
+
saveForm(data, success, fail) {
|
|
415
|
+
console.log(data);
|
|
416
|
+
this.annotationDetailDialog = true;
|
|
417
|
+
|
|
418
|
+
// this.$nextTick(() => {
|
|
419
|
+
// console.log(this.$refs.proofPanelDetail)
|
|
420
|
+
// this.$refs.proofPanelDetail.saveForm(data, success, fail)
|
|
421
|
+
// })
|
|
422
|
+
|
|
423
|
+
// 去除临时截图数据
|
|
424
|
+
if(data.previewScreenshotData){
|
|
425
|
+
delete data.previewScreenshotData;
|
|
426
|
+
}
|
|
427
|
+
|
|
428
|
+
// 上传截图判断
|
|
429
|
+
if(!data.problemPrintscreenId){
|
|
430
|
+
this.$message({
|
|
431
|
+
type: "warning",
|
|
432
|
+
message: '视点截图上传中,请稍后...',
|
|
433
|
+
});
|
|
434
|
+
return
|
|
435
|
+
}
|
|
436
|
+
|
|
437
|
+
this.updatingOpinion = true;
|
|
438
|
+
|
|
439
|
+
if (data.id) {
|
|
440
|
+
// if(this.defaultParams.toProjectId){
|
|
441
|
+
// data.projectId = '';
|
|
442
|
+
// data.toProjectId = this.defaultParams.toProjectId
|
|
443
|
+
// }
|
|
444
|
+
modelApi
|
|
445
|
+
.putProofOpinion(data)
|
|
446
|
+
.then((res) => {
|
|
447
|
+
if (res.code != 200) {
|
|
448
|
+
this.$message({
|
|
449
|
+
type: "error",
|
|
450
|
+
message: res.msg,
|
|
451
|
+
});
|
|
452
|
+
} else {
|
|
453
|
+
// this.disabledForm(true);
|
|
454
|
+
|
|
455
|
+
// this.detailModel = {}; // 清空表单
|
|
456
|
+
|
|
457
|
+
this.getProofOpinionList(this.defaultParams);
|
|
458
|
+
|
|
459
|
+
this.$message({
|
|
460
|
+
type: "success",
|
|
461
|
+
message: res.msg,
|
|
462
|
+
});
|
|
463
|
+
}
|
|
464
|
+
success && success();
|
|
465
|
+
})
|
|
466
|
+
.catch((res) => {
|
|
467
|
+
this.$message({
|
|
468
|
+
type: "error",
|
|
469
|
+
message: res.msg,
|
|
470
|
+
});
|
|
471
|
+
fail && fail();
|
|
472
|
+
})
|
|
473
|
+
.finally(() => {
|
|
474
|
+
this.annotationDetailDialog = false;
|
|
475
|
+
this.updatingOpinion = false
|
|
476
|
+
// this.detailStatus = "view";
|
|
477
|
+
});
|
|
478
|
+
} else {
|
|
479
|
+
// if(this.defaultParams.projectId){
|
|
480
|
+
// data.projectId = this.defaultParams.projectId;
|
|
481
|
+
// data.toProjectId = '';
|
|
482
|
+
// }
|
|
483
|
+
data.status = '0'; // 未处理
|
|
484
|
+
|
|
485
|
+
modelApi
|
|
486
|
+
.addProofOpinion(data)
|
|
487
|
+
.then((res) => {
|
|
488
|
+
if (res.code != 200) {
|
|
489
|
+
this.$message({
|
|
490
|
+
type: "error",
|
|
491
|
+
message: res.msg,
|
|
492
|
+
});
|
|
493
|
+
} else {
|
|
494
|
+
// this.disabledForm(true);
|
|
495
|
+
this.getProofOpinionList(this.defaultParams);
|
|
496
|
+
|
|
497
|
+
this.$message({
|
|
498
|
+
type: "success",
|
|
499
|
+
message: res.msg,
|
|
500
|
+
});
|
|
501
|
+
}
|
|
502
|
+
success && success();
|
|
503
|
+
})
|
|
504
|
+
.catch((res) => {
|
|
505
|
+
this.$message({
|
|
506
|
+
type: "error",
|
|
507
|
+
message: res.msg,
|
|
508
|
+
});
|
|
509
|
+
fail && fail();
|
|
510
|
+
})
|
|
511
|
+
.finally(() => {
|
|
512
|
+
this.annotationDetailDialog = false;
|
|
513
|
+
this.updatingOpinion = false
|
|
514
|
+
});
|
|
515
|
+
}
|
|
516
|
+
},
|
|
517
|
+
handleEditPic(detailData){
|
|
518
|
+
this.annotationDetailDialog = false
|
|
519
|
+
this.$emit('clickEditBtn', detailData)
|
|
520
|
+
},
|
|
521
|
+
selectRow(row){
|
|
522
|
+
this.selectedRow = row;
|
|
523
|
+
this.$emit('selectRow', this.selectedRow)
|
|
524
|
+
},
|
|
525
|
+
clickEditPic(data) {
|
|
526
|
+
this.detailStatus = "edit";
|
|
527
|
+
// backupDetailModel = Object.assign({}, this.detailModel);
|
|
528
|
+
|
|
529
|
+
this.$emit("clickEditBtn", {
|
|
530
|
+
detailStatus: this.detailStatus,
|
|
531
|
+
});
|
|
532
|
+
},
|
|
533
|
+
getProofProjectUserList(params){
|
|
534
|
+
modelApi.getProofProjectUserList(params).then((res) => {
|
|
535
|
+
if (res.code == 200) {
|
|
536
|
+
let data = res.rows;
|
|
537
|
+
this.userList = data && data.map((item) => {
|
|
538
|
+
return {
|
|
539
|
+
userName: item.userName,
|
|
540
|
+
userId: item.userId
|
|
541
|
+
}
|
|
542
|
+
})
|
|
543
|
+
}
|
|
544
|
+
});
|
|
545
|
+
},
|
|
546
|
+
IfUpdateModel(params) {
|
|
547
|
+
timer = setInterval(() => {
|
|
548
|
+
modelApi.IfUpdateModel(params).then((res) => {
|
|
549
|
+
if (res.code == 200) {
|
|
550
|
+
const data = res.data;
|
|
551
|
+
if (NEED_UPDATE_ENUM.false !== data) {
|
|
552
|
+
this.$confirm('检测到模型更新,是否刷新页面进行更新?', '提示', {
|
|
553
|
+
confirmButtonText: '确定',
|
|
554
|
+
cancelButtonText: '取消',
|
|
555
|
+
type: 'warning'
|
|
556
|
+
}).then(() => {
|
|
557
|
+
window.location.reload();
|
|
558
|
+
})
|
|
559
|
+
clearInterval(timer);
|
|
560
|
+
}
|
|
561
|
+
}
|
|
562
|
+
});
|
|
563
|
+
}, 30000)
|
|
564
|
+
},
|
|
565
|
+
clearUpdateModelInterval(){
|
|
566
|
+
clearInterval(timer);
|
|
567
|
+
}
|
|
568
|
+
}
|
|
569
|
+
}
|
|
570
|
+
</script>
|
|
571
|
+
|
|
572
|
+
<style scoped lang="scss">
|
|
573
|
+
.box-card {
|
|
574
|
+
padding-top: 0;
|
|
575
|
+
padding-bottom: 0;
|
|
576
|
+
background: #fff;
|
|
577
|
+
width: 400px;
|
|
578
|
+
|
|
579
|
+
.tree-header {
|
|
580
|
+
height: 52px;
|
|
581
|
+
line-height: 52px;
|
|
582
|
+
border-bottom: 1px solid #dfdfdf;
|
|
583
|
+
// margin-bottom: 15px;
|
|
584
|
+
}
|
|
585
|
+
|
|
586
|
+
.data-item {
|
|
587
|
+
// height: 248px;
|
|
588
|
+
background: #ffffff;
|
|
589
|
+
border-radius: 8px;
|
|
590
|
+
border: 1px solid #e6e6e6;
|
|
591
|
+
margin-top: 14px;
|
|
592
|
+
|
|
593
|
+
.info {
|
|
594
|
+
padding: 0 12px;
|
|
595
|
+
height: 36px;
|
|
596
|
+
}
|
|
597
|
+
|
|
598
|
+
.selected-row {
|
|
599
|
+
border: 1px solid #008DE9;
|
|
600
|
+
}
|
|
601
|
+
}
|
|
602
|
+
|
|
603
|
+
|
|
604
|
+
.footer {
|
|
605
|
+
height: 36px;
|
|
606
|
+
line-height: 36px;
|
|
607
|
+
padding: 0 12px;
|
|
608
|
+
border-top: 1px solid #e6e6e6;
|
|
609
|
+
display: flex;
|
|
610
|
+
justify-content: space-between;
|
|
611
|
+
align-items: center;
|
|
612
|
+
cursor: pointer;
|
|
613
|
+
|
|
614
|
+
span {
|
|
615
|
+
font-size: 14
|
|
616
|
+
}
|
|
617
|
+
}
|
|
618
|
+
|
|
619
|
+
.box-content,
|
|
620
|
+
.box-filter,
|
|
621
|
+
.box-add {
|
|
622
|
+
padding: 5px 10px;
|
|
623
|
+
}
|
|
624
|
+
|
|
625
|
+
.box-content {
|
|
626
|
+
height: 540px;
|
|
627
|
+
}
|
|
628
|
+
|
|
629
|
+
.data-item {
|
|
630
|
+
margin: 10px 0;
|
|
631
|
+
|
|
632
|
+
&:first-child {
|
|
633
|
+
margin-top: 0;
|
|
634
|
+
}
|
|
635
|
+
|
|
636
|
+
&:last-child {
|
|
637
|
+
margin-bottom: 0;
|
|
638
|
+
}
|
|
639
|
+
}
|
|
640
|
+
|
|
641
|
+
&.box-card_pc {
|
|
642
|
+
.data-item {
|
|
643
|
+
margin: 10px 0;
|
|
644
|
+
}
|
|
645
|
+
}
|
|
646
|
+
|
|
647
|
+
::v-deep .box-card-item {
|
|
648
|
+
.item-label {
|
|
649
|
+
display: none;
|
|
650
|
+
}
|
|
651
|
+
|
|
652
|
+
.item-content {
|
|
653
|
+
flex-direction: row-reverse;
|
|
654
|
+
}
|
|
655
|
+
|
|
656
|
+
.item-desc {
|
|
657
|
+
display: -webkit-box;
|
|
658
|
+
display: -moz-box;
|
|
659
|
+
/* 旧版Firefox */
|
|
660
|
+
display: box;
|
|
661
|
+
-webkit-box-orient: vertical;
|
|
662
|
+
-moz-box-orient: vertical;
|
|
663
|
+
box-orient: vertical;
|
|
664
|
+
-webkit-line-clamp: 2;
|
|
665
|
+
line-clamp: 2;
|
|
666
|
+
/* 标准属性 */
|
|
667
|
+
overflow: hidden;
|
|
668
|
+
text-overflow: ellipsis;
|
|
669
|
+
}
|
|
670
|
+
|
|
671
|
+
.item-desc-pc {
|
|
672
|
+
display: inline-block;
|
|
673
|
+
max-width: 100%;
|
|
674
|
+
white-space: nowrap;
|
|
675
|
+
overflow: hidden;
|
|
676
|
+
text-overflow: ellipsis;
|
|
677
|
+
}
|
|
678
|
+
}
|
|
679
|
+
|
|
680
|
+
.box-filter-form {
|
|
681
|
+
display: flex;
|
|
682
|
+
flex-direction: column;
|
|
683
|
+
|
|
684
|
+
::v-deep .el-form-item {
|
|
685
|
+
width: 100%;
|
|
686
|
+
|
|
687
|
+
.el-form-item__content {
|
|
688
|
+
width: 100%;
|
|
689
|
+
box-sizing: border-box;
|
|
690
|
+
// padding-right: 20px;
|
|
691
|
+
}
|
|
692
|
+
}
|
|
693
|
+
}
|
|
694
|
+
|
|
695
|
+
.box-title {
|
|
696
|
+
display: flex;
|
|
697
|
+
justify-content: space-between;
|
|
698
|
+
align-items: center;
|
|
699
|
+
height: 52px;
|
|
700
|
+
line-height: 52px;
|
|
701
|
+
padding-left: 8px;
|
|
702
|
+
padding-right: 8px;
|
|
703
|
+
border-bottom: 1px solid #dfdfdf;
|
|
704
|
+
|
|
705
|
+
.box-title-desc {
|
|
706
|
+
font-size: 14px;
|
|
707
|
+
font-weight: bold;
|
|
708
|
+
}
|
|
709
|
+
|
|
710
|
+
.box-title-close {
|
|
711
|
+
font-size: 24px;
|
|
712
|
+
}
|
|
713
|
+
}
|
|
714
|
+
|
|
715
|
+
::v-deep .el-scrollbar__thumb {
|
|
716
|
+
background-color: #e0e0e0;
|
|
717
|
+
}
|
|
718
|
+
|
|
719
|
+
}
|
|
720
|
+
|
|
721
|
+
::v-deep .box-card_pc {
|
|
722
|
+
width: 100%;
|
|
723
|
+
|
|
724
|
+
.data-item-container {
|
|
725
|
+
display: grid;
|
|
726
|
+
grid-template-columns: repeat(2, 49%);
|
|
727
|
+
column-gap: 20px;
|
|
728
|
+
}
|
|
729
|
+
|
|
730
|
+
.el-card__header {
|
|
731
|
+
padding: 10px;
|
|
732
|
+
}
|
|
733
|
+
|
|
734
|
+
.el-card__body {
|
|
735
|
+
padding: 0;
|
|
736
|
+
}
|
|
737
|
+
|
|
738
|
+
.footer {
|
|
739
|
+
flex-direction: row-reverse;
|
|
740
|
+
}
|
|
741
|
+
|
|
742
|
+
.box-filter {
|
|
743
|
+
.el-select {
|
|
744
|
+
width: 100%;
|
|
745
|
+
}
|
|
746
|
+
}
|
|
747
|
+
}
|
|
748
|
+
|
|
749
|
+
.readonly-mode.footer {
|
|
750
|
+
flex-direction: row-reverse;
|
|
751
|
+
}
|
|
752
|
+
|
|
753
|
+
::v-deep.el-scrollbar {
|
|
754
|
+
height: 580px;
|
|
755
|
+
|
|
756
|
+
.el-scrollbar__wrap {
|
|
757
|
+
margin-bottom: 0px !important;
|
|
758
|
+
margin-right: 0px !important;
|
|
759
|
+
}
|
|
760
|
+
}
|
|
761
|
+
|
|
762
|
+
.tag-reply {
|
|
763
|
+
height: 20px;
|
|
764
|
+
line-height: 20px;
|
|
765
|
+
}
|
|
766
|
+
|
|
767
|
+
::v-deep .last-form-item {
|
|
768
|
+
margin-bottom: -25px;
|
|
769
|
+
}
|
|
770
|
+
</style>
|