vue-wiring-diagram 1.0.9 → 1.0.11
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
|
@@ -79,9 +79,9 @@ const imageUrl = ref('')
|
|
|
79
79
|
* @param file
|
|
80
80
|
*/
|
|
81
81
|
const changeImage = (file) => {
|
|
82
|
-
if (file.raw.type
|
|
83
|
-
ElMessage.error('
|
|
84
|
-
return
|
|
82
|
+
if (file.raw.type.indexOf('image') === -1) {
|
|
83
|
+
ElMessage.error('请上传图片格式的文件')
|
|
84
|
+
return
|
|
85
85
|
}
|
|
86
86
|
const formData = new FormData();
|
|
87
87
|
formData.append('file', file.raw);
|
|
@@ -48,11 +48,11 @@
|
|
|
48
48
|
</el-table-column>
|
|
49
49
|
</el-table>
|
|
50
50
|
<el-dialog v-model="groupDialog.show" :title="groupDialog.title" width="300" :close-on-click-modal="false" :close-on-press-escape="false"
|
|
51
|
-
|
|
51
|
+
>
|
|
52
52
|
<group-form v-if="groupDialog.show" :payload="groupDialog.payload" @close="closeDialog"/>
|
|
53
53
|
</el-dialog>
|
|
54
54
|
<el-dialog v-model="imageDialog.show" :title="imageDialog.title" width="300" :close-on-click-modal="false" :close-on-press-escape="false"
|
|
55
|
-
|
|
55
|
+
>
|
|
56
56
|
<image-form v-if="imageDialog.show" :payload="imageDialog.payload" @close="closeDialog"/>
|
|
57
57
|
</el-dialog>
|
|
58
58
|
</div>
|
|
@@ -62,7 +62,7 @@
|
|
|
62
62
|
import {onMounted, reactive} from "vue";
|
|
63
63
|
import groupForm from "./group-form.vue";
|
|
64
64
|
import imageForm from "./image-form.vue";
|
|
65
|
-
import {get, del
|
|
65
|
+
import {get, del} from "../../http.js";
|
|
66
66
|
import {ElMessage, ElMessageBox} from "element-plus";
|
|
67
67
|
|
|
68
68
|
// 数据集
|
|
@@ -115,19 +115,13 @@ const editGroup = (row) => {
|
|
|
115
115
|
* @param id
|
|
116
116
|
*/
|
|
117
117
|
const deleteGroup = (id) => {
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
ElMessage.success('删除成功')
|
|
126
|
-
loadImageRecord()
|
|
127
|
-
} else {
|
|
128
|
-
ElMessage.error(res.msg || '删除失败')
|
|
129
|
-
}
|
|
130
|
-
})
|
|
118
|
+
del('/cny/custom/removeGroup/' + id).then(res => {
|
|
119
|
+
if (res.code === 200) {
|
|
120
|
+
ElMessage.success('删除成功')
|
|
121
|
+
loadImageRecord()
|
|
122
|
+
} else {
|
|
123
|
+
ElMessage.error(res.msg || '删除失败')
|
|
124
|
+
}
|
|
131
125
|
})
|
|
132
126
|
}
|
|
133
127
|
|
|
@@ -172,19 +166,13 @@ const editPicture = (row) => {
|
|
|
172
166
|
* @param id
|
|
173
167
|
*/
|
|
174
168
|
const deletePicture = (id) => {
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
ElMessage.success('删除成功')
|
|
183
|
-
loadImageRecord()
|
|
184
|
-
} else {
|
|
185
|
-
ElMessage.error(res.msg || '删除失败')
|
|
186
|
-
}
|
|
187
|
-
})
|
|
169
|
+
del('/cny/custom/removePicture/' + id).then(res => {
|
|
170
|
+
if (res.code === 200) {
|
|
171
|
+
ElMessage.success('删除成功')
|
|
172
|
+
loadImageRecord()
|
|
173
|
+
} else {
|
|
174
|
+
ElMessage.error(res.msg || '删除失败')
|
|
175
|
+
}
|
|
188
176
|
})
|
|
189
177
|
}
|
|
190
178
|
|