|
@ -36,16 +36,7 @@ |
|
|
</el-form> |
|
|
</el-form> |
|
|
|
|
|
|
|
|
<el-row :gutter="10" class="mb8"> |
|
|
<el-row :gutter="10" class="mb8"> |
|
|
<!-- <el-col :span="1.5"> |
|
|
|
|
|
<el-button |
|
|
|
|
|
type="primary" |
|
|
|
|
|
icon="el-icon-plus" |
|
|
|
|
|
size="mini" |
|
|
|
|
|
@click="handleAdd" |
|
|
|
|
|
v-hasPermi="['build:sourceFunds:add']" |
|
|
|
|
|
>新增</el-button |
|
|
|
|
|
> |
|
|
|
|
|
</el-col>--> |
|
|
|
|
|
<el-col :span="1.5"> |
|
|
<el-col :span="1.5"> |
|
|
<el-button |
|
|
<el-button |
|
|
type="success" |
|
|
type="success" |
|
@ -90,7 +81,7 @@ |
|
|
<template slot-scope="props"> |
|
|
<template slot-scope="props"> |
|
|
<el-table |
|
|
<el-table |
|
|
@selection-change="handleSelectionChange" |
|
|
@selection-change="handleSelectionChange" |
|
|
:data="props.row.details" v-loading="!props.row.loadDetails" |
|
|
:data="props.row.details" |
|
|
stripe border |
|
|
stripe border |
|
|
> |
|
|
> |
|
|
<el-table-column type="selection" width="55" align="center" fixed/> |
|
|
<el-table-column type="selection" width="55" align="center" fixed/> |
|
@ -108,7 +99,27 @@ |
|
|
<el-table-column label="本期实付金额" min-width="120" align="center" prop="paidinAmount"/> |
|
|
<el-table-column label="本期实付金额" min-width="120" align="center" prop="paidinAmount"/> |
|
|
<el-table-column label="本期暂扣款" min-width="120" align="center" prop="temporaryWithholding"/> |
|
|
<el-table-column label="本期暂扣款" min-width="120" align="center" prop="temporaryWithholding"/> |
|
|
<el-table-column label="合同支付票据" min-width="120" align="center" prop="paymentBill"/> |
|
|
<el-table-column label="合同支付票据" min-width="120" align="center" prop="paymentBill"/> |
|
|
<el-table-column label="操作" min-width="120" align="center"/> |
|
|
<el-table-column label="操作" min-width="120" align="center"> |
|
|
|
|
|
<template slot-scope="scope"> |
|
|
|
|
|
<el-button |
|
|
|
|
|
size="mini" |
|
|
|
|
|
type="text" |
|
|
|
|
|
icon="el-icon-edit" |
|
|
|
|
|
@click="handleUpdate(scope.row)" |
|
|
|
|
|
v-hasPermi="['build:sourceFunds:edit']" |
|
|
|
|
|
>修改 |
|
|
|
|
|
</el-button> |
|
|
|
|
|
<el-button |
|
|
|
|
|
size="mini" |
|
|
|
|
|
type="text" |
|
|
|
|
|
icon="el-icon-delete" |
|
|
|
|
|
@click="handleDelete(scope.row)" |
|
|
|
|
|
v-hasPermi="['build:sourceFunds:remove']" |
|
|
|
|
|
>删除 |
|
|
|
|
|
</el-button |
|
|
|
|
|
> |
|
|
|
|
|
</template> |
|
|
|
|
|
</el-table-column> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</el-table> |
|
|
</el-table> |
|
@ -182,12 +193,12 @@ |
|
|
<el-button |
|
|
<el-button |
|
|
size="mini" |
|
|
size="mini" |
|
|
type="text" |
|
|
type="text" |
|
|
icon="el-icon-edit" |
|
|
icon="el-icon-plus" |
|
|
@click="handleUpdate(scope.row)" |
|
|
@click="handleAdd(scope.row)" |
|
|
v-hasPermi="['build:sourceFunds:edit']" |
|
|
v-hasPermi="['build:sourceFunds:edit']" |
|
|
>修改 |
|
|
>资金支付 |
|
|
</el-button> |
|
|
</el-button> |
|
|
<el-button |
|
|
<!-- <el-button |
|
|
size="mini" |
|
|
size="mini" |
|
|
type="text" |
|
|
type="text" |
|
|
icon="el-icon-delete" |
|
|
icon="el-icon-delete" |
|
@ -195,7 +206,7 @@ |
|
|
v-hasPermi="['build:sourceFunds:remove']" |
|
|
v-hasPermi="['build:sourceFunds:remove']" |
|
|
>删除 |
|
|
>删除 |
|
|
</el-button |
|
|
</el-button |
|
|
> |
|
|
>--> |
|
|
</template> |
|
|
</template> |
|
|
</el-table-column> |
|
|
</el-table-column> |
|
|
</el-table> |
|
|
</el-table> |
|
@ -220,51 +231,109 @@ |
|
|
<el-row :gutter="15"> |
|
|
<el-row :gutter="15"> |
|
|
<el-form ref="form" :model="form" :rules="rules" label-width="110px"> |
|
|
<el-form ref="form" :model="form" :rules="rules" label-width="110px"> |
|
|
<el-col :span="12"> |
|
|
<el-col :span="12"> |
|
|
<el-form-item label="下达日期" prop="releaseTime"> |
|
|
<el-form-item label="支付条款" prop="paymentTerms"> |
|
|
|
|
|
<el-input v-model="form.paymentTerms" placeholder="支付条款"/> |
|
|
|
|
|
</el-form-item> |
|
|
|
|
|
</el-col> |
|
|
|
|
|
|
|
|
|
|
|
<el-col :span="12"> |
|
|
|
|
|
<el-form-item label="支付期数" prop="paymentPeriods"> |
|
|
|
|
|
<el-input v-model="form.paymentPeriods" placeholder="支付期数"/> |
|
|
|
|
|
</el-form-item> |
|
|
|
|
|
</el-col> |
|
|
|
|
|
|
|
|
|
|
|
<el-col :span="12"> |
|
|
|
|
|
|
|
|
|
|
|
<el-form-item label="起始年月" prop="startingYear"> |
|
|
|
|
|
<el-date-picker |
|
|
|
|
|
v-model="timeScope" |
|
|
|
|
|
type="daterange" |
|
|
|
|
|
range-separator="至" |
|
|
|
|
|
start-placeholder="开始日期" |
|
|
|
|
|
end-placeholder="结束日期"> |
|
|
|
|
|
</el-date-picker> |
|
|
|
|
|
</el-form-item> |
|
|
|
|
|
</el-col> |
|
|
|
|
|
|
|
|
|
|
|
<el-col :span="12"> |
|
|
|
|
|
<el-form-item label="支付日期" prop="paymentTime"> |
|
|
<el-date-picker |
|
|
<el-date-picker |
|
|
clearable |
|
|
clearable |
|
|
size="small" |
|
|
size="small" |
|
|
style="width: 100%" |
|
|
style="width: 100%" |
|
|
v-model="form.releaseTime" |
|
|
v-model="form.paymentTime" |
|
|
type="date" |
|
|
type="date" |
|
|
value-format="yyyy-MM-dd" |
|
|
value-format="yyyy-MM-dd" |
|
|
placeholder="请输入下达日期" |
|
|
placeholder="请输入支付日期" |
|
|
> |
|
|
> |
|
|
</el-date-picker> |
|
|
</el-date-picker> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-col> |
|
|
</el-col> |
|
|
|
|
|
|
|
|
<el-col :span="12"> |
|
|
<el-col :span="12"> |
|
|
<el-form-item label="中央资金(万元)" prop="centralArrangedFunds"> |
|
|
<el-form-item label="本期应付金额" prop="payableAmount"> |
|
|
<el-input v-model="form.centralArrangedFunds" placeholder="请输入中央资金(万元)"/> |
|
|
<el-input v-model="form.payableAmount" placeholder="请输入本期应付金额"/> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-col> |
|
|
</el-col> |
|
|
<el-col :span="12"> |
|
|
<el-col :span="12"> |
|
|
<el-form-item label="省级资金(万元)" prop="provincialFunding"> |
|
|
<el-form-item label="本期实付金额" prop="paidinAmount"> |
|
|
<el-input |
|
|
<el-input |
|
|
v-model="form.provincialFunding" |
|
|
v-model="form.paidinAmount" |
|
|
placeholder="请输入省级资金(万元)" |
|
|
placeholder="请输入本期实付金额" |
|
|
/> |
|
|
/> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-col> |
|
|
</el-col> |
|
|
<el-col :span="12"> |
|
|
<el-col :span="12"> |
|
|
<el-form-item label="地市级资金(万元)" prop="cityLevelFunds"> |
|
|
<el-form-item label="本期暂扣款" prop="temporaryWithholding"> |
|
|
<el-input |
|
|
<el-input |
|
|
v-model="form.cityLevelFunds" |
|
|
v-model="form.temporaryWithholding" |
|
|
placeholder="请输入地市级资金(万元)" |
|
|
placeholder="请输入地市级资金(万元)" |
|
|
/> |
|
|
/> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-col> |
|
|
</el-col> |
|
|
<el-col :span="12"> |
|
|
<el-col :span="12"> |
|
|
<el-form-item label="县级资金(万元)" prop="countyLevelFunds"> |
|
|
<el-form-item label="项目法人审核人" prop="auditor"> |
|
|
<el-input v-model="form.countyLevelFunds" placeholder="请输入县级资金(万元)"/> |
|
|
<el-input v-model="form.auditor" placeholder="请输入县级资金(万元)"/> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-col> |
|
|
</el-col> |
|
|
<el-col :span="12"> |
|
|
<el-col :span="12"> |
|
|
<el-form-item label="乡镇及群众自筹和其他投资(万元)" prop="townshipInvestments"> |
|
|
<el-form-item label="项目法人经办人" prop="agent"> |
|
|
<el-input v-model="form.townshipInvestments" placeholder="请输入乡镇及群众自筹和其他投资(万元)"/> |
|
|
<el-input v-model="form.agent" placeholder="请输入乡镇及群众自筹和其他投资(万元)"/> |
|
|
|
|
|
</el-form-item> |
|
|
|
|
|
</el-col> |
|
|
|
|
|
<el-col :span="12"> |
|
|
|
|
|
<el-form-item |
|
|
|
|
|
label="合同支付票据" |
|
|
|
|
|
prop="paymentBill" |
|
|
|
|
|
> |
|
|
|
|
|
<!-- <el-input |
|
|
|
|
|
v-model="form.projectAttachment" |
|
|
|
|
|
placeholder="请输入规划附件" |
|
|
|
|
|
/> --> |
|
|
|
|
|
<el-upload |
|
|
|
|
|
class="upload-demo" |
|
|
|
|
|
action="thinking/common/upload" |
|
|
|
|
|
:headers="headers" |
|
|
|
|
|
:on-preview="handleProjectPreview" |
|
|
|
|
|
:on-remove="handleProjectRemove" |
|
|
|
|
|
:before-remove="beforeProjectRemove" |
|
|
|
|
|
multiple |
|
|
|
|
|
:on-exceed="handleProjectExceed" |
|
|
|
|
|
:on-success="submitProjectUpload" |
|
|
|
|
|
:file-list="projectFileList" |
|
|
|
|
|
> |
|
|
|
|
|
<el-button size="small" type="primary" plain> |
|
|
|
|
|
<i class="el-icon-upload el-icon--right"></i> |
|
|
|
|
|
点击上传 |
|
|
|
|
|
</el-button> |
|
|
|
|
|
<div slot="tip" class="el-upload__tip"> |
|
|
|
|
|
支持jpg/png/pdf/word/excel文件等,不超过100M |
|
|
|
|
|
</div> |
|
|
|
|
|
</el-upload> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
|
</el-col> |
|
|
</el-col> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
</el-form> |
|
|
</el-form> |
|
|
</el-row> |
|
|
</el-row> |
|
|
<div slot="footer" class="dialog-footer"> |
|
|
<div slot="footer" class="dialog-footer"> |
|
@ -284,6 +353,7 @@ import { |
|
|
updateFunds, |
|
|
updateFunds, |
|
|
exportFunds, |
|
|
exportFunds, |
|
|
getRecord, |
|
|
getRecord, |
|
|
|
|
|
getContractId, |
|
|
} from "@/api/build/funds"; |
|
|
} from "@/api/build/funds"; |
|
|
|
|
|
|
|
|
import { |
|
|
import { |
|
@ -296,11 +366,23 @@ import { |
|
|
listInfoByCode, |
|
|
listInfoByCode, |
|
|
} from "@/api/build/contractInfo"; |
|
|
} from "@/api/build/contractInfo"; |
|
|
|
|
|
|
|
|
|
|
|
import { getFileStream } from "@/api/system/upload"; |
|
|
|
|
|
import { getToken } from "@/utils/auth"; |
|
|
|
|
|
|
|
|
export default { |
|
|
export default { |
|
|
name: "sourceFunds", |
|
|
name: "sourceFunds", |
|
|
props: ["formData"], |
|
|
props: ["formData"], |
|
|
data() { |
|
|
data() { |
|
|
return { |
|
|
return { |
|
|
|
|
|
|
|
|
|
|
|
timeScope:[], |
|
|
|
|
|
contractNumber:"", |
|
|
|
|
|
// 规划附件 |
|
|
|
|
|
projectFileList: [], |
|
|
|
|
|
// 请求头 |
|
|
|
|
|
headers: { |
|
|
|
|
|
jianwei: "jwtech " + getToken(), |
|
|
|
|
|
}, |
|
|
expands: [], |
|
|
expands: [], |
|
|
getRowKeys(row) { |
|
|
getRowKeys(row) { |
|
|
return row.id; |
|
|
return row.id; |
|
@ -386,28 +468,40 @@ export default { |
|
|
}, |
|
|
}, |
|
|
// 表单重置 |
|
|
// 表单重置 |
|
|
reset() { |
|
|
reset() { |
|
|
|
|
|
this.timeScope=[] |
|
|
this.form = { |
|
|
this.form = { |
|
|
releaseTime: null, |
|
|
paymentTerms: null, |
|
|
centralArrangedFunds: null, |
|
|
paymentPeriods: null, |
|
|
provincialFunding: null, |
|
|
startingYear: null, |
|
|
cityLevelFunds: null, |
|
|
paymentTime: null, |
|
|
countyLevelFunds: null, |
|
|
payableAmount: null, |
|
|
townshipInvestments: null, |
|
|
paidinAmount: null, |
|
|
|
|
|
temporaryWithholding:null, |
|
|
|
|
|
auditor:null, |
|
|
|
|
|
agent:null, |
|
|
|
|
|
paymentBill:null, |
|
|
|
|
|
|
|
|
}; |
|
|
}; |
|
|
this.resetForm("form"); |
|
|
this.resetForm("form"); |
|
|
}, |
|
|
}, |
|
|
// 查询表单重置 |
|
|
// 查询表单重置 |
|
|
resetQueryForm() { |
|
|
resetQueryForm() { |
|
|
|
|
|
this.timeScope=[] |
|
|
this.queryParams = { |
|
|
this.queryParams = { |
|
|
pageNum: 1, |
|
|
pageNum: 1, |
|
|
pageSize: 10, |
|
|
pageSize: 10, |
|
|
data: { |
|
|
data: { |
|
|
releaseTime: null, |
|
|
|
|
|
centralArrangedFunds: null, |
|
|
paymentTerms: null, |
|
|
provincialFunding: null, |
|
|
paymentPeriods: null, |
|
|
cityLevelFunds: null, |
|
|
startingYear: null, |
|
|
countyLevelFunds: null, |
|
|
paymentTime: null, |
|
|
townshipInvestments: null, |
|
|
payableAmount: null, |
|
|
|
|
|
paidinAmount: null, |
|
|
|
|
|
temporaryWithholding:null, |
|
|
|
|
|
auditor:null, |
|
|
|
|
|
agent:null, |
|
|
|
|
|
paymentBill:null, |
|
|
}, |
|
|
}, |
|
|
// 排序方式 |
|
|
// 排序方式 |
|
|
params: { |
|
|
params: { |
|
@ -427,6 +521,7 @@ export default { |
|
|
// 关闭弹窗 |
|
|
// 关闭弹窗 |
|
|
close() { |
|
|
close() { |
|
|
this.reset(); |
|
|
this.reset(); |
|
|
|
|
|
|
|
|
}, |
|
|
}, |
|
|
/** 重置按钮操作 */ |
|
|
/** 重置按钮操作 */ |
|
|
resetQuery() { |
|
|
resetQuery() { |
|
@ -440,19 +535,24 @@ export default { |
|
|
this.multiple = !selection.length; |
|
|
this.multiple = !selection.length; |
|
|
}, |
|
|
}, |
|
|
/** 新增按钮操作 */ |
|
|
/** 新增按钮操作 */ |
|
|
handleAdd() { |
|
|
handleAdd(row) { |
|
|
this.reset(); |
|
|
this.reset(); |
|
|
this.open = true; |
|
|
this.open = true; |
|
|
this.title = "添加下达资金"; |
|
|
this.title = "资金支付"; |
|
|
|
|
|
this.contractNumber = row.contractNumber; |
|
|
}, |
|
|
}, |
|
|
/** 修改按钮操作 */ |
|
|
/** 修改按钮操作 */ |
|
|
handleUpdate(row) { |
|
|
handleUpdate(row) { |
|
|
this.reset(); |
|
|
this.reset(); |
|
|
const id = row.id || this.ids; |
|
|
const id = row.id || this.ids; |
|
|
getFunds(id).then((response) => { |
|
|
getFunds(id).then((response) => { |
|
|
|
|
|
|
|
|
|
|
|
this.timeScope.push(response.data.startYear) |
|
|
|
|
|
this.timeScope.push(response.data.endYear) |
|
|
|
|
|
|
|
|
this.form = response.data; |
|
|
this.form = response.data; |
|
|
this.open = true; |
|
|
this.open = true; |
|
|
this.title = "修改下达资金"; |
|
|
this.title = "修改资金支付"; |
|
|
}); |
|
|
}); |
|
|
}, |
|
|
}, |
|
|
/** 提交按钮 */ |
|
|
/** 提交按钮 */ |
|
@ -464,12 +564,15 @@ export default { |
|
|
if (response.code === 200) { |
|
|
if (response.code === 200) { |
|
|
this.msgSuccess("修改成功"); |
|
|
this.msgSuccess("修改成功"); |
|
|
this.open = false; |
|
|
this.open = false; |
|
|
this.getList(); |
|
|
|
|
|
} |
|
|
} |
|
|
}); |
|
|
}); |
|
|
} else { |
|
|
} else { |
|
|
|
|
|
this.form.startYear = this.timeScope[0]; |
|
|
|
|
|
this.form.endYear = this.timeScope[1]; |
|
|
this.form.proNo = this.$route.query.proNo; |
|
|
this.form.proNo = this.$route.query.proNo; |
|
|
this.form.proCode = this.$route.query.proCode; |
|
|
this.form.proCode = this.$route.query.proCode; |
|
|
|
|
|
this.form.contractNumber = this.contractNumber; |
|
|
addFunds(this.form).then((response) => { |
|
|
addFunds(this.form).then((response) => { |
|
|
if (response.code === 200) { |
|
|
if (response.code === 200) { |
|
|
this.msgSuccess("新增成功"); |
|
|
this.msgSuccess("新增成功"); |
|
@ -503,53 +606,16 @@ export default { |
|
|
this.$message.warning("请选择要删除的数据!!"); |
|
|
this.$message.warning("请选择要删除的数据!!"); |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
/*expandChange(row,expandedRows){ |
|
|
|
|
|
this.childListLoading = true; |
|
|
|
|
|
let query = {parkOrderId: row.parkOrderId} |
|
|
|
|
|
getRecord(row.id).then((response) => { |
|
|
|
|
|
this.infoList=response.data |
|
|
|
|
|
this.infoList.push({}); //触发vue更新视图 |
|
|
|
|
|
this.infoList.pop(); //把最后添加的空对象删除掉 |
|
|
|
|
|
this.childListLoading = false; |
|
|
|
|
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
},*/ |
|
|
|
|
|
/*expandChange(row, expandedRows) { |
|
|
|
|
|
if (expandedRows.length) { |
|
|
|
|
|
this.expands = [] |
|
|
|
|
|
if (row) { |
|
|
|
|
|
this.expands.push(row.id) |
|
|
|
|
|
} |
|
|
|
|
|
} else { |
|
|
|
|
|
this.expands = [] |
|
|
|
|
|
} |
|
|
|
|
|
getRecord(row.id).then((response) => { |
|
|
|
|
|
if (response.data.size === 0) { |
|
|
|
|
|
this.contractsList.forEach((item, index) => { |
|
|
|
|
|
this.contractsList[index].children = {}; |
|
|
|
|
|
}) |
|
|
|
|
|
}else { |
|
|
|
|
|
this.contractsList.forEach((item, index) => { |
|
|
|
|
|
if (row.contractNumber === response.data[0].contractNumber) { |
|
|
|
|
|
this.contractsList[index].children = response.data; |
|
|
|
|
|
} |
|
|
|
|
|
}); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}*/ |
|
|
|
|
|
expandChange(row) { |
|
|
expandChange(row) { |
|
|
if(!row.loadDetails){ |
|
|
if(!row.loadDetails){ |
|
|
|
|
|
|
|
|
let temp = []; |
|
|
|
|
|
//根据loadDetails判定是否已经加载了数据 |
|
|
//根据loadDetails判定是否已经加载了数据 |
|
|
setTimeout(() =>{ |
|
|
|
|
|
getRecord(row.id).then((res)=>{ |
|
|
getRecord(row.id).then((res)=>{ |
|
|
row.details = res.data; |
|
|
row.details = res.data; |
|
|
}) |
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
setTimeout(() =>{ |
|
|
row.loadDetails= true //加载成功之后更新标识 |
|
|
row.loadDetails= true //加载成功之后更新标识 |
|
|
this.$message({ |
|
|
this.$message({ |
|
|
showClose: true, |
|
|
showClose: true, |
|
@ -557,7 +623,64 @@ export default { |
|
|
}) |
|
|
}) |
|
|
},1000) |
|
|
},1000) |
|
|
} |
|
|
} |
|
|
} |
|
|
}, |
|
|
|
|
|
// 表格中下载 |
|
|
|
|
|
downloadProjectFile(scope, index) { |
|
|
|
|
|
// console.log(scope); |
|
|
|
|
|
let file = JSON.parse(scope.row.projectProposalAttachment)[index]; |
|
|
|
|
|
this.handleProjectPreview(file); |
|
|
|
|
|
}, |
|
|
|
|
|
// 查看信息中, 下载 |
|
|
|
|
|
downloadProjectFile2(info, index) { |
|
|
|
|
|
console.log(info); |
|
|
|
|
|
this.handleProjectPreview(info); |
|
|
|
|
|
}, |
|
|
|
|
|
// 点击预览下载文件 |
|
|
|
|
|
handleProjectPreview(file) { |
|
|
|
|
|
// console.log(file); |
|
|
|
|
|
getFileStream({ fileName: file.fileName }).then((res) => { |
|
|
|
|
|
const blob = new Blob([res], { |
|
|
|
|
|
// type类型后端返回来的数据中会有,根据自己实际进行修改 |
|
|
|
|
|
// 表格下载为 application/xlsx,压缩包为 application/zip等, |
|
|
|
|
|
type: "application/xlsx", |
|
|
|
|
|
}); //excel,pdf等 |
|
|
|
|
|
const href = URL.createObjectURL(blob); //创建新的URL表示指定的blob对象 |
|
|
|
|
|
const a = document.createElement("a"); //创建a标签 |
|
|
|
|
|
a.style.display = "none"; |
|
|
|
|
|
a.href = href; // 指定下载链接 |
|
|
|
|
|
a.download = file.name; //指定下载文件名 |
|
|
|
|
|
a.click(); //触发下载 |
|
|
|
|
|
URL.revokeObjectURL(a.href); //释放URL对象 |
|
|
|
|
|
}); |
|
|
|
|
|
}, |
|
|
|
|
|
handleProjectRemove(file, fileList) { |
|
|
|
|
|
// console.log(file, fileList); |
|
|
|
|
|
let index = this.projectFileList.findIndex( |
|
|
|
|
|
(item) => item.uid === file.uid |
|
|
|
|
|
); |
|
|
|
|
|
// 删除文件 |
|
|
|
|
|
this.projectFileList.splice(index, 1); |
|
|
|
|
|
}, |
|
|
|
|
|
beforeProjectRemove(file, fileList) { |
|
|
|
|
|
return this.$confirm(`确定移除 ${file.name}?`); |
|
|
|
|
|
}, |
|
|
|
|
|
handleProjectExceed(files, fileList) { |
|
|
|
|
|
this.$message.warning( |
|
|
|
|
|
`当前限制选择 3 个文件,本次选择了 ${files.length} 个文件,共选择了 ${ |
|
|
|
|
|
files.length + fileList.length |
|
|
|
|
|
} 个文件` |
|
|
|
|
|
); |
|
|
|
|
|
}, |
|
|
|
|
|
submitProjectUpload(_, fileList) { |
|
|
|
|
|
console.log("fileList", fileList); |
|
|
|
|
|
this.projectFileList.push({ |
|
|
|
|
|
name: fileList.name, |
|
|
|
|
|
fileName: fileList.response.fileName, |
|
|
|
|
|
url: fileList.response.url, |
|
|
|
|
|
uid: fileList.uid, |
|
|
|
|
|
}); |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
}, |
|
|
}, |
|
|
}; |
|
|
}; |
|
|
</script> |
|
|
</script> |
|
|