|
@@ -340,12 +340,25 @@ const config = computed(() => {
|
|
|
{
|
|
|
attrs: {
|
|
|
label: "操作",
|
|
|
- width: 180,
|
|
|
+ width: 200,
|
|
|
align: "center",
|
|
|
fixed: "right",
|
|
|
},
|
|
|
renderHTML(row) {
|
|
|
return [
|
|
|
+ !props.selectStatus && row.status == 40
|
|
|
+ ? {
|
|
|
+ attrs: {
|
|
|
+ label: "导出",
|
|
|
+ type: "primary",
|
|
|
+ text: true,
|
|
|
+ },
|
|
|
+ el: "button",
|
|
|
+ click() {
|
|
|
+ deriveExcel(row);
|
|
|
+ },
|
|
|
+ }
|
|
|
+ : {},
|
|
|
props.selectStatus
|
|
|
? {
|
|
|
attrs: {
|
|
@@ -715,6 +728,19 @@ const clickCancel = (status) => {
|
|
|
getList();
|
|
|
}
|
|
|
};
|
|
|
+const deriveExcel = (row) => {
|
|
|
+ ElMessageBox.confirm("你是否确认此操作", "提示", {
|
|
|
+ confirmButtonText: "确定",
|
|
|
+ cancelButtonText: "取消",
|
|
|
+ type: "warning",
|
|
|
+ })
|
|
|
+ .then(() => {
|
|
|
+ proxy.postFile("/orderInfo/orderExportExcel", { id: row.id }).then((res) => {
|
|
|
+ proxy.downloadFile(res, row.code + ".xlsx");
|
|
|
+ });
|
|
|
+ })
|
|
|
+ .catch(() => {});
|
|
|
+};
|
|
|
</script>
|
|
|
|
|
|
<style lang="scss" scoped>
|