|
|
@ -2,14 +2,6 @@ |
|
|
|
<template> |
|
|
|
<div class="cr-body-content"> |
|
|
|
<flexbox class="content-header"> |
|
|
|
<!-- <el-button |
|
|
|
class="filter-item" |
|
|
|
size="mini" |
|
|
|
type="info" |
|
|
|
icon="el-icon-download" |
|
|
|
@click="handleDownload()" |
|
|
|
>导出全部 |
|
|
|
</el-button> --> |
|
|
|
<JobSelectVerson |
|
|
|
:options="JobVersionList" |
|
|
|
style="width: 150px; margin-left: -10px" |
|
|
@ -56,6 +48,14 @@ |
|
|
|
@click="handleFilter" |
|
|
|
>搜索 |
|
|
|
</el-button> |
|
|
|
<el-button |
|
|
|
class="filter-item" |
|
|
|
size="mini" |
|
|
|
type="info" |
|
|
|
icon="el-icon-download" |
|
|
|
@click="handleDownload()" |
|
|
|
>全部导出 |
|
|
|
</el-button> |
|
|
|
<!--表格头组件,filter查询--> |
|
|
|
<c-r-m-table-head |
|
|
|
ref="crmTableHead" |
|
|
@ -101,27 +101,30 @@ |
|
|
|
{{ scope.column.label }} |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="OutPutQty" |
|
|
|
label="出库数量" |
|
|
|
width="100"> |
|
|
|
<el-table-column prop="OutPutQty" label="出库数量" width="100"> |
|
|
|
<template slot-scope="list"> |
|
|
|
<el-input size="small" v-model="list.row.outPutQty" @change="handleEdit(list.$index, list.row)"></el-input> |
|
|
|
<el-input |
|
|
|
size="small" |
|
|
|
v-model="list.row.outPutQty" |
|
|
|
@change="handleEdit(list.$index, list.row)" |
|
|
|
></el-input> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column |
|
|
|
prop="state" |
|
|
|
:formatter="fieldFormatter" |
|
|
|
label="状态" |
|
|
|
width="100"> |
|
|
|
width="100" |
|
|
|
> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column label="操作" align="center"> |
|
|
|
<template slot-scope="list"> |
|
|
|
<el-button |
|
|
|
type="primary" |
|
|
|
v-if="list.$index=1" |
|
|
|
v-if="(list.$index = 1)" |
|
|
|
@click="handle(list.row)" |
|
|
|
>确定</el-button> |
|
|
|
>确定</el-button |
|
|
|
> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
@ -168,9 +171,7 @@ |
|
|
|
<el-button |
|
|
|
v-loading="formLoading" |
|
|
|
type="primary" |
|
|
|
|
|
|
|
@click="handleCreateBills()" |
|
|
|
|
|
|
|
>确认</el-button |
|
|
|
> |
|
|
|
</div> |
|
|
@ -255,9 +256,9 @@ export default { |
|
|
|
version: "", |
|
|
|
guids: "", |
|
|
|
billNum: "", |
|
|
|
accountDate:"", |
|
|
|
branchId:"", |
|
|
|
outPutQty:"", |
|
|
|
accountDate: "", |
|
|
|
branchId: "", |
|
|
|
outPutQty: "", |
|
|
|
}, |
|
|
|
listDeleteQuery: { |
|
|
|
billNum: "", |
|
|
@ -273,9 +274,9 @@ export default { |
|
|
|
showExcelImport: false, |
|
|
|
tableHeight: document.documentElement.clientHeight - 230, |
|
|
|
isEdit: false, |
|
|
|
accountDatelist:{ |
|
|
|
accountDate:"" |
|
|
|
} |
|
|
|
accountDatelist: { |
|
|
|
accountDate: "", |
|
|
|
}, |
|
|
|
}; |
|
|
|
}, |
|
|
|
mounted() { |
|
|
@ -338,13 +339,60 @@ export default { |
|
|
|
}, |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
//导出全部功能 |
|
|
|
handleDownload(command) { |
|
|
|
this.listLoading = true; |
|
|
|
this.listOutPutQuery.version = this.customerInfo.version; |
|
|
|
this.listOutPutQuery.billNum = this.customerInfo.parentId; |
|
|
|
|
|
|
|
console.log( |
|
|
|
"红旗M备件出库单导出:" + JSON.stringify(this.listOutPutQuery) |
|
|
|
); |
|
|
|
this.$axios |
|
|
|
.posts( |
|
|
|
"/api/settleaccount/WmsHQMSharePartoutput/Export", |
|
|
|
this.listOutPutQuery |
|
|
|
) |
|
|
|
.then((res) => { |
|
|
|
let fileNameOfProject = res; |
|
|
|
this.$axios |
|
|
|
.BolbGets( |
|
|
|
"/api/settleaccount/getblobfile/download/" + fileNameOfProject |
|
|
|
) |
|
|
|
.then((response) => { |
|
|
|
if (fileNameOfProject.indexOf("_") != -1) { |
|
|
|
let downName = |
|
|
|
fileNameOfProject.slice( |
|
|
|
0, |
|
|
|
fileNameOfProject.lastIndexOf("_") |
|
|
|
) + |
|
|
|
fileNameOfProject.slice(fileNameOfProject.lastIndexOf(".")); |
|
|
|
downloadFile(response, downName); |
|
|
|
this.$notify({ |
|
|
|
title: "成功", |
|
|
|
message: "数据-导出成功!", |
|
|
|
type: "success", |
|
|
|
duration: 2000, |
|
|
|
}); |
|
|
|
} else { |
|
|
|
downloadFile(response, fileNameOfProject); |
|
|
|
this.$notify({ |
|
|
|
title: "成功", |
|
|
|
message: "数据-导出成功!", |
|
|
|
type: "success", |
|
|
|
duration: 2000, |
|
|
|
}); |
|
|
|
} |
|
|
|
this.listLoading = false; |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
|
handleEdit(index, row) { |
|
|
|
console.log(index, row); |
|
|
|
|
|
|
|
}, |
|
|
|
handle(row){ |
|
|
|
handle(row) { |
|
|
|
this.multipleSelection.forEach((element) => { |
|
|
|
let outPutQty=element.outPutQty; |
|
|
|
let outPutQty = element.outPutQty; |
|
|
|
}); |
|
|
|
if (row.outPutQty > row.stockQty) { |
|
|
|
this.$message({ |
|
|
@ -478,7 +526,7 @@ export default { |
|
|
|
this.getList(); |
|
|
|
return; |
|
|
|
//this.getList(); |
|
|
|
}else{ |
|
|
|
} else { |
|
|
|
if (this.accountDatelist != "") { |
|
|
|
this.listOutPutQuery.accountDate = this.accountDatelist.accountDate; |
|
|
|
} |
|
|
@ -512,7 +560,7 @@ export default { |
|
|
|
} |
|
|
|
}, |
|
|
|
//删除出库单 |
|
|
|
handleDelete(row){ |
|
|
|
handleDelete(row) { |
|
|
|
var params = []; |
|
|
|
let myalert = ""; //声明变量,其变量必须在此声明后使用 |
|
|
|
if (row) { |
|
|
@ -527,7 +575,7 @@ export default { |
|
|
|
}); |
|
|
|
myalert = "选中项"; |
|
|
|
} |
|
|
|
this.listDeleteQuery.billNum = this.listQuery.billNum ; |
|
|
|
this.listDeleteQuery.billNum = this.listQuery.billNum; |
|
|
|
console.log("单据号:" + JSON.stringify(this.listDeleteQuery)); |
|
|
|
this.$confirm("是否删除" + myalert + "?", "提示", { |
|
|
|
confirmButtonText: "确定", |
|
|
@ -536,7 +584,10 @@ export default { |
|
|
|
}) |
|
|
|
.then(() => { |
|
|
|
this.$axios |
|
|
|
.posts("/api/settleaccount/WmsHQMSharePartoutput/WmsOutPutDelete", this.listDeleteQuery) |
|
|
|
.posts( |
|
|
|
"/api/settleaccount/WmsHQMSharePartoutput/WmsOutPutDelete", |
|
|
|
this.listDeleteQuery |
|
|
|
) |
|
|
|
.then((response) => { |
|
|
|
const index = this.list.indexOf(row); |
|
|
|
this.$notify({ |
|
|
@ -579,48 +630,7 @@ export default { |
|
|
|
this.showExcelImport = false; |
|
|
|
this.getList(); |
|
|
|
}, |
|
|
|
async handleDownload() { |
|
|
|
//await this.getDownBoms(); |
|
|
|
this.listLoading = true; |
|
|
|
this.$axios |
|
|
|
.gets( |
|
|
|
"/api/settleaccount/bt-kb-not-consign/export/" + |
|
|
|
this.customerInfo.parentId |
|
|
|
) |
|
|
|
.then((res) => { |
|
|
|
let fileNameOfProject = res; |
|
|
|
this.$axios |
|
|
|
.BolbGets( |
|
|
|
"/api/settleaccount/getblobfile/download/" + fileNameOfProject |
|
|
|
) |
|
|
|
.then((response) => { |
|
|
|
if (fileNameOfProject.indexOf("_") != -1) { |
|
|
|
let downName = |
|
|
|
fileNameOfProject.slice( |
|
|
|
0, |
|
|
|
fileNameOfProject.lastIndexOf("_") |
|
|
|
) + |
|
|
|
fileNameOfProject.slice(fileNameOfProject.lastIndexOf(".")); |
|
|
|
downloadFile(response, downName); |
|
|
|
this.$notify({ |
|
|
|
title: "成功", |
|
|
|
message: "数据-导出成功!", |
|
|
|
type: "success", |
|
|
|
duration: 2000, |
|
|
|
}); |
|
|
|
} else { |
|
|
|
downloadFile(response, fileNameOfProject); |
|
|
|
this.$notify({ |
|
|
|
title: "成功", |
|
|
|
message: "数据-导出成功!", |
|
|
|
type: "success", |
|
|
|
duration: 2000, |
|
|
|
}); |
|
|
|
} |
|
|
|
this.listLoading = false; |
|
|
|
}); |
|
|
|
}); |
|
|
|
}, |
|
|
|
|
|
|
|
getList(data) { |
|
|
|
this.listLoading = true; |
|
|
|
if (data != undefined) { |
|
|
|