1、文件上传功能重构

2、实现签到删除
3、实现签到表格处弹性布局
4、库存删除问题修正
This commit is contained in:
2024-12-16 08:02:05 +08:00
parent ba0d565424
commit de37820973
28 changed files with 1292 additions and 91 deletions

View File

@@ -574,7 +574,9 @@
<el-descriptions-item label="附件" :span="3" :labelStyle="lableBg">
<!--附件-->
<template v-if="form.accessory">
<ImageOss :name="form.accessory"/>
<el-tooltip class="item" effect="dark" content="点击下载" placement="bottom">
<el-link type="primary" @click="downloadFile(form.accessory)">{{form.accessory.match('[^/]+(?!.*/)')[0]}}</el-link>
</el-tooltip>
</template>
<template v-else>
<span style="color: #999999">暂无附件</span>
@@ -1217,6 +1219,11 @@ export default {
this.loading = false;
});
},
/** 下载文件 */
downloadFile(filePath){
this.$download.resource(filePath)
},
// 多选框选中数据
/* handleSelectionChange(selection) {

View File

@@ -454,7 +454,9 @@
<el-descriptions-item label="附件" :span="4" :labelStyle="lableBg">
<!--附件-->
<template v-if="form.accessory">
<ImageOss :name="form.accessory"/>
<el-tooltip class="item" effect="dark" content="点击下载" placement="bottom">
<el-link type="primary" @click="downloadFile(form.accessory)">{{form.accessory.match('[^/]+(?!.*/)')[0]}}</el-link>
</el-tooltip>
</template>
<template v-else>
<span style="color: #999999">暂无附件</span>
@@ -1335,6 +1337,11 @@ export default {
this.download('oa/finance/export', {
...this.queryParams
}, `finance_${new Date().getTime()}.xlsx`)
},
/** 下载文件 */
downloadFile(filePath){
this.$download.resource(filePath)
}
}
};

View File

@@ -422,7 +422,9 @@
<!--附件-->
<template v-if="form.accessory">
<ImageOss :name="form.accessory"/>
<el-tooltip class="item" effect="dark" content="点击下载" placement="bottom">
<el-link type="primary" @click="downloadFile(form.accessory)">{{form.accessory.match('[^/]+(?!.*/)')[0]}}</el-link>
</el-tooltip>
</template>
<template v-else>
<span style="color: #999999">暂无附件</span>
@@ -876,6 +878,11 @@ export default {
this.loading = false;
});
},
/** 下载文件 */
downloadFile(filePath){
this.$download.resource(filePath)
},
//tabs标签
handleClick(tab, event) {
// console.log(tab, event);

View File

@@ -235,7 +235,9 @@
</template>
<!--附件-->
<template v-if="form.accessory">
<ImageOss :name="form.accessory"/>
<el-tooltip class="item" effect="dark" content="点击下载" placement="bottom">
<el-link type="primary" @click="downloadFile(form.accessory)">{{form.accessory.match('[^/]+(?!.*/)')[0]}}</el-link>
</el-tooltip>
</template>
<template v-else>
<span style="color: #999999">暂无附件</span>
@@ -519,6 +521,11 @@ export default {
this.title = "修改合同管理";
});
},
/** 下载文件 */
downloadFile(filePath){
this.$download.resource(filePath)
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {

View File

@@ -225,7 +225,9 @@
</template>
<!--附件-->
<template v-if="form.accessory">
<ImageOss :name="form.accessory"/>
<el-tooltip class="item" effect="dark" content="点击下载" placement="bottom">
<el-link type="primary" @click="downloadFile(form.accessory)">{{form.accessory.match('[^/]+(?!.*/)')[0]}}</el-link>
</el-tooltip>
</template>
<template v-else>
<span style="color: #999999">暂无附件</span>
@@ -585,7 +587,9 @@
</template>
<!--附件-->
<template v-if="form.accessory">
<ImageOss :name="form.accessory"/>
<el-tooltip class="item" effect="dark" content="点击下载" placement="bottom">
<el-link type="primary" @click="downloadFile(form.accessory)">{{form.accessory.match('[^/]+(?!.*/)')[0]}}</el-link>
</el-tooltip>
</template>
<template v-else>
<span style="color: #999999">暂无附件</span>
@@ -742,6 +746,7 @@ export default {
//点击添加按钮状态
addBottomStatus: false,
openForm: false,
downLoadUrl :process.env.VUE_APP_BASE_API+'/common/download' ,
// 表单参数
form: {},
// 按钮loading
@@ -1069,6 +1074,12 @@ export default {
} else {
callback()
}
},
/** 下载文件 */
downloadFile(filePath){
this.$download.resource(filePath)
}
}
}

View File

@@ -313,7 +313,9 @@
</template>
<!--附件-->
<template v-if="form.accessory">
<ImageOss :name="form.accessory"/>
<el-tooltip class="item" effect="dark" content="点击下载" placement="bottom">
<el-link type="primary" @click="downloadFile(form.accessory)">{{form.accessory.match('[^/]+(?!.*/)')[0]}}</el-link>
</el-tooltip>
</template>
<template v-else>
<span style="color: #999999">暂无附件</span>
@@ -634,7 +636,9 @@
</template>
<!--附件-->
<template v-if="item.accessory">
<ImageOss :name="item.accessory"/>
<el-tooltip class="item" effect="dark" content="点击下载" placement="bottom">
<el-link type="primary" @click="downloadFile(form.accessory)">{{form.accessory.match('[^/]+(?!.*/)')[0]}}</el-link>
</el-tooltip>
</template>
<template v-else>
<span style="color: #999999">暂无附件</span>
@@ -887,7 +891,9 @@
</template>
<!--附件-->
<template v-if="contractForm.accessory">
<ImageOss :name="contractForm.accessory"/>
<el-tooltip class="item" effect="dark" content="点击下载" placement="bottom">
<el-link type="primary" @click="downloadFile(form.accessory)">{{form.accessory.match('[^/]+(?!.*/)')[0]}}</el-link>
</el-tooltip>
</template>
<template v-else>
<span style="color: #999999">暂无附件</span>
@@ -1165,7 +1171,9 @@
</template>
<!--附件-->
<template v-if="contractForm.accessory">
<ImageOss :name="contractForm.accessory"/>
<el-tooltip class="item" effect="dark" content="点击下载" placement="bottom">
<el-link type="primary" @click="downloadFile(form.accessory)">{{form.accessory.match('[^/]+(?!.*/)')[0]}}</el-link>
</el-tooltip>
</template>
<template v-else>
<span style="color: #999999">暂无附件</span>
@@ -1520,6 +1528,11 @@ export default {
this.queryParams.pageNum = 1;
this.getList();
},
/** 下载文件 */
downloadFile(filePath){
this.$download.resource(filePath)
},
/** 重置按钮操作 */
resetQuery() {
this.searchTime = [];

View File

@@ -156,7 +156,9 @@
<el-descriptions-item label="附件" span="4" :labelStyle="lableBg">
<!--附件-->
<template v-if="formQuery.accessory">
<ImageOss :name="formQuery.accessory"/>
<el-tooltip class="item" effect="dark" content="点击下载" placement="bottom">
<el-link type="primary" @click="downloadFile(form.accessory)">{{form.accessory.match('[^/]+(?!.*/)')[0]}}</el-link>
</el-tooltip>
</template>
<template v-else>
<span style="color: #999999">暂无附件</span>
@@ -341,6 +343,11 @@ export default {
this.resetForm("queryForm");
this.handleQuery();
},
/** 下载文件 */
downloadFile(filePath){
this.$download.resource(filePath)
},
// 多选框选中数据
handleSelectionChange(selection) {
this.ids = selection.map(item => item.purposeId)

View File

@@ -146,7 +146,9 @@
</template>
<!--附件-->
<template v-if="lookRemind.accessory">
<ImageOss :name="lookRemind.accessory"/>
<el-tooltip class="item" effect="dark" content="点击下载" placement="bottom">
<el-link type="primary" @click="downloadFile(form.accessory)">{{form.accessory.match('[^/]+(?!.*/)')[0]}}</el-link>
</el-tooltip>
</template>
<template v-else>
<span style="color: #999999">暂无附件</span>
@@ -186,7 +188,9 @@
</template>
<!--附件-->
<template v-if="form.accessory">
<ImageOss :name="form.accessory"/>
<el-tooltip class="item" effect="dark" content="点击下载" placement="bottom">
<el-link type="primary" @click="downloadFile(form.accessory)">{{form.accessory.match('[^/]+(?!.*/)')[0]}}</el-link>
</el-tooltip>
</template>
<template v-else>
<span style="color: #999999">暂无附件</span>
@@ -470,7 +474,11 @@ export default {
this.openTask = false;
this.reset();
},
/** 下载文件 */
downloadFile(filePath){
this.$download.resource(filePath)
},
}
}

View File

@@ -151,7 +151,9 @@
<el-descriptions-item label="附件" :labelStyle="lableBg" span="4">
<!--附件-->
<template v-if="formLook.accessory">
<ImageOss :name="formLook.accessory"/>
<el-tooltip class="item" effect="dark" content="点击下载" placement="bottom">
<el-link type="primary" @click="downloadFile(form.accessory)">{{form.accessory.match('[^/]+(?!.*/)')[0]}}</el-link>
</el-tooltip>
</template>
<template v-else>
<span style="color: #999999">暂无附件</span>
@@ -415,6 +417,11 @@ export default {
this.download('oa/remind/export', {
...this.queryParams
}, `remind_${new Date().getTime()}.xlsx`)
},
/** 下载文件 */
downloadFile(filePath){
this.$download.resource(filePath)
}
}
};