|
@ -99,7 +99,7 @@ |
|
|
type="danger" |
|
|
type="danger" |
|
|
icon="el-icon-delete" |
|
|
icon="el-icon-delete" |
|
|
size="mini" |
|
|
size="mini" |
|
|
@click="handleDelete()" |
|
|
@click="print()" |
|
|
>作废(支持批量)</el-button |
|
|
>作废(支持批量)</el-button |
|
|
> |
|
|
> |
|
|
</el-form-item> |
|
|
</el-form-item> |
|
@ -195,6 +195,57 @@ |
|
|
/> |
|
|
/> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
|
|
|
<div> |
|
|
|
|
|
<el-dialog |
|
|
|
|
|
title="作废信息" |
|
|
|
|
|
append-to-body="true" |
|
|
|
|
|
:visible.sync="dialogTableVisible" |
|
|
|
|
|
> |
|
|
|
|
|
<el-table :data="zflist"> |
|
|
|
|
|
<el-table-column |
|
|
|
|
|
property="billNum" |
|
|
|
|
|
label="装箱单号" |
|
|
|
|
|
width="100" |
|
|
|
|
|
></el-table-column> |
|
|
|
|
|
<el-table-column |
|
|
|
|
|
property="billSerialNum" |
|
|
|
|
|
label="单据顺号" |
|
|
|
|
|
width="100" |
|
|
|
|
|
></el-table-column> |
|
|
|
|
|
<el-table-column |
|
|
|
|
|
property="billLocation" |
|
|
|
|
|
label="左或右" |
|
|
|
|
|
width="100" |
|
|
|
|
|
></el-table-column> |
|
|
|
|
|
<el-table-column |
|
|
|
|
|
property="providerCode" |
|
|
|
|
|
label="供应商厂家代码" |
|
|
|
|
|
width="100" |
|
|
|
|
|
></el-table-column> |
|
|
|
|
|
<el-table-column |
|
|
|
|
|
property="partType" |
|
|
|
|
|
label="零件类型" |
|
|
|
|
|
width="100" |
|
|
|
|
|
></el-table-column> |
|
|
|
|
|
<el-table-column |
|
|
|
|
|
property="capacity" |
|
|
|
|
|
label="器具容量" |
|
|
|
|
|
width="100" |
|
|
|
|
|
></el-table-column> |
|
|
|
|
|
<el-table-column |
|
|
|
|
|
property="printDate" |
|
|
|
|
|
label="打印日期" |
|
|
|
|
|
width="100" |
|
|
|
|
|
></el-table-column> |
|
|
|
|
|
</el-table> |
|
|
|
|
|
<div slot="footer" class="dialog-footer"> |
|
|
|
|
|
<el-button type="text" @click="dialogTableVisible = false" |
|
|
|
|
|
>取消</el-button |
|
|
|
|
|
> |
|
|
|
|
|
<el-button type="primary" @click="handleDelete">确 认</el-button> |
|
|
|
|
|
</div> |
|
|
|
|
|
</el-dialog> |
|
|
|
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</template> |
|
|
</template> |
|
|
|
|
|
|
|
@ -243,6 +294,7 @@ export default { |
|
|
}; |
|
|
}; |
|
|
return { |
|
|
return { |
|
|
crmType: "M100Online-MB", |
|
|
crmType: "M100Online-MB", |
|
|
|
|
|
dialogTableVisible: false, |
|
|
getRowKeys: (row) => { |
|
|
getRowKeys: (row) => { |
|
|
return row.id; //这里看这一行中需要根据哪个属性值是id |
|
|
return row.id; //这里看这一行中需要根据哪个属性值是id |
|
|
}, |
|
|
}, |
|
@ -507,19 +559,13 @@ export default { |
|
|
) |
|
|
) |
|
|
.then((response) => { |
|
|
.then((response) => { |
|
|
response.items.forEach((item) => { |
|
|
response.items.forEach((item) => { |
|
|
if(item.printType == 0) |
|
|
if (item.printType == 0) { |
|
|
{ |
|
|
|
|
|
item.printType = "正常打印"; |
|
|
item.printType = "正常打印"; |
|
|
} |
|
|
} else if (item.printType == 1) { |
|
|
else if(item.printType == 1) |
|
|
|
|
|
{ |
|
|
|
|
|
item.printType = "重打"; |
|
|
item.printType = "重打"; |
|
|
} |
|
|
} else { |
|
|
else |
|
|
|
|
|
{ |
|
|
|
|
|
item.printType = "补打"; |
|
|
item.printType = "补打"; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
}); |
|
|
}); |
|
|
this.list = response.items; |
|
|
this.list = response.items; |
|
|
this.totalCount = response.totalCount; |
|
|
this.totalCount = response.totalCount; |
|
@ -581,25 +627,21 @@ export default { |
|
|
.catch(() => {}); |
|
|
.catch(() => {}); |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
//作废操作,支持批量操作-门板 |
|
|
print(row) { |
|
|
handleDelete(row) { |
|
|
|
|
|
//批量删除 |
|
|
|
|
|
var params = []; |
|
|
var params = []; |
|
|
let myalert = ""; //声明变量,其变量必须在此声明后使用 |
|
|
|
|
|
let myalertcount = []; |
|
|
|
|
|
if (row) { |
|
|
if (row) { |
|
|
//单行 |
|
|
//单行 |
|
|
params.push(row.id); |
|
|
params.push(row.id); |
|
|
myalert = row.name; |
|
|
|
|
|
} else { |
|
|
} else { |
|
|
//多选 |
|
|
//多选 |
|
|
this.multipleSelection.forEach((element) => { |
|
|
this.multipleSelection.forEach((element) => { |
|
|
let id = element.id; |
|
|
let id = element.id; |
|
|
params.push(id); |
|
|
params.push(id); |
|
|
}); |
|
|
}); |
|
|
myalert = "选中项"; |
|
|
|
|
|
} |
|
|
} |
|
|
console.log("作废查询参数:" + JSON.stringify(params)); |
|
|
this.zuofei = params; |
|
|
|
|
|
|
|
|
|
|
|
this.dialogTableVisible = true; |
|
|
this.$axios |
|
|
this.$axios |
|
|
.posts("/api/newjit/MenBanPackingList/get-all-del-List", params) |
|
|
.posts("/api/newjit/MenBanPackingList/get-all-del-List", params) |
|
|
.then((response) => { |
|
|
.then((response) => { |
|
@ -613,46 +655,111 @@ export default { |
|
|
return; |
|
|
return; |
|
|
} else { |
|
|
} else { |
|
|
this.fileQuery.dataname = JSON.stringify(response); |
|
|
this.fileQuery.dataname = JSON.stringify(response); |
|
|
response.forEach((itemsss) => { |
|
|
this.zflist = response; |
|
|
myalertcount.push(itemsss.billNum); |
|
|
|
|
|
}); |
|
|
|
|
|
console.log( |
|
|
console.log( |
|
|
"门板-调用Handlers/Handler1.ashx?report=menban传的值:" + |
|
|
"门板-调用Handlers/Handler1.ashx?report=menban传的值:" + |
|
|
JSON.stringify(this.fileQuery.dataname) |
|
|
JSON.stringify(this.fileQuery.dataname) |
|
|
); |
|
|
); |
|
|
this.$confirm( |
|
|
|
|
|
"是否作废选中的" + response.length + "条记录?", |
|
|
|
|
|
"提示", |
|
|
|
|
|
{ |
|
|
|
|
|
confirmButtonText: "确定", |
|
|
|
|
|
cancelButtonText: "取消", |
|
|
|
|
|
type: "warning", |
|
|
|
|
|
} |
|
|
} |
|
|
) |
|
|
}) |
|
|
.then(() => { |
|
|
.catch(() => {}); |
|
|
|
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
//作废详情页确认按钮 |
|
|
|
|
|
handleDelete() { |
|
|
|
|
|
//debugger; |
|
|
|
|
|
let params = this.zuofei; |
|
|
|
|
|
|
|
|
this.$axios |
|
|
this.$axios |
|
|
.posts("/api/newjit/MenBanPackingList/scrap", params) |
|
|
.posts("/api/newjit/MenBanPackingList/scrap", params) |
|
|
.then((response) => { |
|
|
.then((response) => { |
|
|
const index = this.list.indexOf(row); |
|
|
console.log( |
|
|
|
|
|
"门板-调用Handlers/Handler1.ashx?report=menban传的值:" + |
|
|
|
|
|
JSON.stringify(response) |
|
|
|
|
|
); |
|
|
this.$notify({ |
|
|
this.$notify({ |
|
|
title: "成功", |
|
|
title: "成功", |
|
|
message: "作废成功", |
|
|
message: "作废成功", |
|
|
type: "success", |
|
|
type: "success", |
|
|
duration: 2000, |
|
|
duration: 2000, |
|
|
}); |
|
|
}); |
|
|
this.getList(); |
|
|
|
|
|
}); |
|
|
}); |
|
|
}) |
|
|
this.dialogTableVisible = false; |
|
|
.catch(() => { |
|
|
this.getList(); |
|
|
this.$message({ |
|
|
|
|
|
type: "info", |
|
|
|
|
|
message: "已取消操作", |
|
|
|
|
|
}); |
|
|
|
|
|
}); |
|
|
|
|
|
} |
|
|
|
|
|
}) |
|
|
|
|
|
.catch(() => {}); |
|
|
|
|
|
}, |
|
|
}, |
|
|
|
|
|
|
|
|
|
|
|
//作废操作,支持批量操作-门板 |
|
|
|
|
|
// handleDelete(row) { |
|
|
|
|
|
// //批量删除 |
|
|
|
|
|
// var params = []; |
|
|
|
|
|
// let myalert = ""; //声明变量,其变量必须在此声明后使用 |
|
|
|
|
|
// let myalertcount = []; |
|
|
|
|
|
// if (row) { |
|
|
|
|
|
// //单行 |
|
|
|
|
|
// params.push(row.id); |
|
|
|
|
|
// myalert = row.name; |
|
|
|
|
|
// } else { |
|
|
|
|
|
// //多选 |
|
|
|
|
|
// this.multipleSelection.forEach((element) => { |
|
|
|
|
|
// let id = element.id; |
|
|
|
|
|
// params.push(id); |
|
|
|
|
|
// }); |
|
|
|
|
|
// myalert = "选中项"; |
|
|
|
|
|
// } |
|
|
|
|
|
// console.log("作废查询参数:" + JSON.stringify(params)); |
|
|
|
|
|
// this.$axios |
|
|
|
|
|
// .posts("/api/newjit/MenBanPackingList/get-all-del-List", params) |
|
|
|
|
|
// .then((response) => { |
|
|
|
|
|
// //alert(response.status); |
|
|
|
|
|
// const index = this.list.indexOf(row); |
|
|
|
|
|
// if (response.status === false) { |
|
|
|
|
|
// this.$message({ |
|
|
|
|
|
// message: response.message, |
|
|
|
|
|
// type: "error", |
|
|
|
|
|
// }); |
|
|
|
|
|
// return; |
|
|
|
|
|
// } else { |
|
|
|
|
|
// this.fileQuery.dataname = JSON.stringify(response); |
|
|
|
|
|
// response.forEach((itemsss) => { |
|
|
|
|
|
// myalertcount.push(itemsss.billNum); |
|
|
|
|
|
// }); |
|
|
|
|
|
// console.log( |
|
|
|
|
|
// "门板-调用Handlers/Handler1.ashx?report=menban传的值:" + |
|
|
|
|
|
// JSON.stringify(this.fileQuery.dataname) |
|
|
|
|
|
// ); |
|
|
|
|
|
// this.$confirm( |
|
|
|
|
|
// "是否作废选中的" + response.length + "条记录?", |
|
|
|
|
|
// "提示", |
|
|
|
|
|
// { |
|
|
|
|
|
// confirmButtonText: "确定", |
|
|
|
|
|
// cancelButtonText: "取消", |
|
|
|
|
|
// type: "warning", |
|
|
|
|
|
// } |
|
|
|
|
|
// ) |
|
|
|
|
|
// .then(() => { |
|
|
|
|
|
// this.$axios |
|
|
|
|
|
// .posts("/api/newjit/MenBanPackingList/scrap", params) |
|
|
|
|
|
// .then((response) => { |
|
|
|
|
|
// const index = this.list.indexOf(row); |
|
|
|
|
|
// this.$notify({ |
|
|
|
|
|
// title: "成功", |
|
|
|
|
|
// message: "作废成功", |
|
|
|
|
|
// type: "success", |
|
|
|
|
|
// duration: 2000, |
|
|
|
|
|
// }); |
|
|
|
|
|
// this.getList(); |
|
|
|
|
|
// }); |
|
|
|
|
|
// }) |
|
|
|
|
|
// .catch(() => { |
|
|
|
|
|
// this.$message({ |
|
|
|
|
|
// type: "info", |
|
|
|
|
|
// message: "已取消操作", |
|
|
|
|
|
// }); |
|
|
|
|
|
// }); |
|
|
|
|
|
// } |
|
|
|
|
|
// }) |
|
|
|
|
|
// .catch(() => {}); |
|
|
|
|
|
// }, |
|
|
fetchData(id) { |
|
|
fetchData(id) { |
|
|
//循环动态 |
|
|
//循环动态 |
|
|
this.$axios |
|
|
this.$axios |
|
|