doway-coms 1.2.6 → 1.2.7
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
CHANGED
|
@@ -24,19 +24,35 @@
|
|
|
24
24
|
`${internalServiceUrl}/GetAttachFile/${internalRow.attach.id}?accessToken=${$store.getters.token}`
|
|
25
25
|
"
|
|
26
26
|
/>
|
|
27
|
-
<i
|
|
27
|
+
<!-- <i
|
|
28
28
|
class="el-icon-error attach-delete"
|
|
29
29
|
v-if="edit === true"
|
|
30
30
|
@click="removeAttach(internalRow.attach)"
|
|
31
|
-
></i>
|
|
32
|
-
<
|
|
31
|
+
></i> -->
|
|
32
|
+
<a-icon
|
|
33
|
+
class="attach-delete"
|
|
34
|
+
type="close-circle"
|
|
35
|
+
@click="removeAttach(internalRow.attach)"
|
|
36
|
+
v-if="edit === true"
|
|
37
|
+
/>
|
|
38
|
+
<a-icon
|
|
39
|
+
class="attach-download"
|
|
40
|
+
type="vertical-align-bottom"
|
|
41
|
+
@click="downloadAttach(internalRow.attach)"
|
|
42
|
+
/>
|
|
43
|
+
<!-- <i
|
|
33
44
|
class="el-icon-download attach-download"
|
|
34
45
|
@click="downloadAttach(internalRow.attach)"
|
|
35
|
-
></i>
|
|
36
|
-
<i
|
|
46
|
+
></i> -->
|
|
47
|
+
<!-- <i
|
|
37
48
|
class="el-icon-view attach-view"
|
|
38
49
|
@click="viewAttach(internalRow.attach)"
|
|
39
|
-
></i>
|
|
50
|
+
></i> -->
|
|
51
|
+
<a-icon
|
|
52
|
+
class="attach-view"
|
|
53
|
+
type="zoom-in"
|
|
54
|
+
@click="viewAttach(internalRow.attach)"
|
|
55
|
+
/>
|
|
40
56
|
<VxeCheckbox
|
|
41
57
|
class="attach-circle"
|
|
42
58
|
v-model="internalRow.isDefault"
|
|
@@ -89,7 +105,7 @@
|
|
|
89
105
|
:action="uploadData.picAction"
|
|
90
106
|
:data="uploadData"
|
|
91
107
|
v-if="edit === true"
|
|
92
|
-
|
|
108
|
+
@change="handleAvatarSuccess"
|
|
93
109
|
:show-file-list="false"
|
|
94
110
|
:before-upload="beforeAvatarUpload"
|
|
95
111
|
>
|
|
@@ -342,32 +358,35 @@ export default {
|
|
|
342
358
|
.catch(() => {})
|
|
343
359
|
},
|
|
344
360
|
attachFileClick(attachFile) {},
|
|
345
|
-
handleAvatarSuccess(
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
let tempField
|
|
352
|
-
for (let i = 0; i < this.cols.length; i++) {
|
|
353
|
-
// 赋值关联字段数据
|
|
354
|
-
let tempValue = addRow
|
|
355
|
-
tempField = this.cols[i].field
|
|
356
|
-
if (this.cols[i].isAuto) {
|
|
357
|
-
tempValue[tempField] = this.$store.getters.newId() + ''
|
|
358
|
-
continue
|
|
361
|
+
handleAvatarSuccess(info) {
|
|
362
|
+
if (info.file.status == 'done') {
|
|
363
|
+
let addRow = {
|
|
364
|
+
attachId: info.file.response.content.id,
|
|
365
|
+
sysRowState: sysRowState.add,
|
|
366
|
+
attach: info.file.response.content
|
|
359
367
|
}
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
368
|
+
this.internalRows.push(addRow)
|
|
369
|
+
this.$emit('add', this.dataName, info.file.response.content)
|
|
370
|
+
let tempField
|
|
371
|
+
for (let i = 0; i < this.cols.length; i++) {
|
|
372
|
+
// 赋值关联字段数据
|
|
373
|
+
let tempValue = addRow
|
|
374
|
+
tempField = this.cols[i].field
|
|
375
|
+
if (this.cols[i].isAuto) {
|
|
376
|
+
tempValue[tempField] = this.$store.getters.newId() + ''
|
|
377
|
+
continue
|
|
378
|
+
}
|
|
379
|
+
if (
|
|
380
|
+
this.cols[i].controlType === 'text' &&
|
|
381
|
+
this.cols[i].linkValueField !== null &&
|
|
382
|
+
this.cols[i].linkValueField !== '' &&
|
|
383
|
+
this.cols[i].linkValueField !== undefined
|
|
384
|
+
) {
|
|
385
|
+
tempValue[tempField] = this.formRow[this.cols[i].linkValueField]
|
|
386
|
+
}
|
|
367
387
|
}
|
|
368
388
|
}
|
|
369
|
-
|
|
370
|
-
// this.$emit('add', this.dataName, res.data)
|
|
389
|
+
|
|
371
390
|
},
|
|
372
391
|
beforeAvatarUpload(file) {
|
|
373
392
|
// const isPic = file.type === 'image/jpeg' || file.type === 'image/png'
|