|
@@ -27,7 +27,7 @@
|
|
|
的文件
|
|
|
</div>
|
|
|
<!-- 文件列表 -->
|
|
|
- <transition-group class="upload-file-list el-upload-list el-upload-list--text" name="el-fade-in-linear" tag="ul">
|
|
|
+ <transition-group ref="uploadFileList" class="upload-file-list el-upload-list el-upload-list--text" name="el-fade-in-linear" tag="ul">
|
|
|
<li :key="file.uid" class="el-upload-list__item ele-upload-list__item-content" v-for="(file, index) in fileList">
|
|
|
<el-link :href="`${baseUrl}${file.url}`" :underline="false" target="_blank">
|
|
|
<span class="el-icon-document"> {{ getFileName(file.name) }} </span>
|
|
@@ -216,7 +216,7 @@ function listToString(list, separator) {
|
|
|
onMounted(() => {
|
|
|
if (props.drag) {
|
|
|
nextTick(() => {
|
|
|
- const element = document.querySelector('.upload-file-list')
|
|
|
+ const element = proxy.$refs.uploadFileList?.$el || proxy.$refs.uploadFileList
|
|
|
Sortable.create(element, {
|
|
|
ghostClass: 'file-upload-darg',
|
|
|
onEnd: (evt) => {
|