From a296223898d61a9838bbd35ed75c87575e308a36 Mon Sep 17 00:00:00 2001
From: huangxiaoqiang <huangxiaoqiang@hnkhzn.com>
Date: 星期五, 07 十一月 2025 17:19:38 +0800
Subject: [PATCH] 1
---
项目代码/WMS/WIDESEA_WMSClient/src/extension/widesea_wms/stock/Dt_BillGroupStock.jsx | 252 +++++++++++++++++++++++++++++++-------------------
1 files changed, 157 insertions(+), 95 deletions(-)
diff --git "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WIDESEA_WMSClient/src/extension/widesea_wms/stock/Dt_BillGroupStock.jsx" "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WIDESEA_WMSClient/src/extension/widesea_wms/stock/Dt_BillGroupStock.jsx"
index 18e66bc..6a2415c 100644
--- "a/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WIDESEA_WMSClient/src/extension/widesea_wms/stock/Dt_BillGroupStock.jsx"
+++ "b/\351\241\271\347\233\256\344\273\243\347\240\201/WMS/WIDESEA_WMSClient/src/extension/widesea_wms/stock/Dt_BillGroupStock.jsx"
@@ -9,12 +9,12 @@
// import gridHeader from "./demo_Product/Dt_BillGroupStockDetail.vue";
// import gridHeader from './extend/printView.vue'
-// import gridBody from './extend/OtherOutBound.vue'
+import gridBody from './extend/Remark.vue'
let extension = {
components: {
//鏌ヨ鐣岄潰鎵╁睍缁勪欢
gridHeader: '',
- gridBody: '',
+ gridBody: gridBody,
gridFooter: '',
//鏂板缓銆佺紪杈戝脊鍑烘鎵╁睍缁勪欢
modelHeader: '',
@@ -26,28 +26,28 @@
methods: {
//涓嬮潰杩欎簺鏂规硶鍙互淇濈暀涔熷彲浠ュ垹闄�
onInit() {
- this.detailOptions.buttons.unshift({
- name: '鍏朵粬鍑哄簱', //鎸夐挳鍚嶇О
- icon: 'el-icon-document', //鎸夐挳鍥炬爣vue2鐗堟湰瑙乮view鏂囨。icon锛寁ue3鐗堟湰瑙乪lement ui鏂囨。icon(娉ㄦ剰涓嶆槸element puls鏂囨。)
- type: 'primary',
- onClick: function () {
- this.$confirm('鏄惁鍏朵粬鍑哄簱', "璀﹀憡浣犳鍦ㄤ娇鐢ㄥ叾浠栧嚭搴�", {
- confirmButtonText: '纭畾',
- cancelButtonText: '鍙栨秷',
- type: 'warning',
- center: true
- }).then(() => {
- this.http.post(`/api/Task/OtherOutBoundTaskAsync`, row, "姝e湪瀹屾垚浠诲姟").then((res) => {
- //绀轰緥锛氳皟鐢ㄥ悗鍙版帴鍙�
- if (res.status) {
- this.$Message.success('浠诲姟瀹屾垚')
- } else {
- this.$Message.error(res.message) //閿欒鎻愮ず
- }
- })
- })
- }
- });
+ // this.detailOptions.buttons.unshift({
+ // name: '鍏朵粬鍑哄簱', //鎸夐挳鍚嶇О
+ // icon: 'el-icon-document', //鎸夐挳鍥炬爣vue2鐗堟湰瑙乮view鏂囨。icon锛寁ue3鐗堟湰瑙乪lement ui鏂囨。icon(娉ㄦ剰涓嶆槸element puls鏂囨。)
+ // type: 'primary',
+ // onClick: function () {
+ // this.$confirm('鏄惁鍏朵粬鍑哄簱', "璀﹀憡浣犳鍦ㄤ娇鐢ㄥ叾浠栧嚭搴�", {
+ // confirmButtonText: '纭畾',
+ // cancelButtonText: '鍙栨秷',
+ // type: 'warning',
+ // center: true
+ // }).then(() => {
+ // this.http.post(`/api/Task/OtherOutBoundTaskAsync`, row, "姝e湪瀹屾垚浠诲姟").then((res) => {
+ // //绀轰緥锛氳皟鐢ㄥ悗鍙版帴鍙�
+ // if (res.status) {
+ // this.$Message.success('浠诲姟瀹屾垚')
+ // } else {
+ // this.$Message.error(res.message) //閿欒鎻愮ず
+ // }
+ // })
+ // })
+ // }
+ // });
this.boxButtons.push({
name: '鍏朵粬鍑哄簱', //鎸夐挳鍚嶇О
icon: 'el-icon-document', //鎸夐挳鍥炬爣:缁勪欢绀轰緥->鍥炬爣
@@ -55,19 +55,27 @@
type: 'primary',
plain: true,
onClick: function () {
- this.$confirm('鏄惁鍏朵粬鍑哄簱', "璀﹀憡浣犳鍦ㄤ娇鐢ㄥ叾浠栧嚭搴�", {
+ this.$confirm('鏄惁鍏朵粬鍑哄簱', '璀﹀憡', {
confirmButtonText: '纭畾',
cancelButtonText: '鍙栨秷',
type: 'warning',
center: true
}).then(() => {
- this.http.post(`/api/Task/OtherOutBoundTaskAsync`, this.$refs.detail.rowData, "姝e湪瀹屾垚浠诲姟").then((res) => {
- if (res.status) {
- this.$Message.success(res.message)
- } else {
- this.$Message.error(res.message) //閿欒鎻愮ず
- }
- })
+ this.http
+ .post(
+ `/api/Task/OtherOutBoundTaskAsync`,
+ this.$refs.detail.rowData,
+ '姝e湪鐢熸垚鍑哄簱浠诲姟'
+ )
+ .then((res) => {
+ if (res.status) {
+ this.$Message.success(res.message)
+ this.boxModel = false
+ this.refresh()
+ } else {
+ this.$Message.error(res.message) //閿欒鎻愮ず
+ }
+ })
})
}
})
@@ -78,19 +86,27 @@
type: 'danger',
plain: true,
onClick: function () {
- this.$confirm('鏄惁璋冩嫧鍑哄簱', "璀﹀憡浣犳鍦ㄤ娇鐢ㄨ皟鎷ㄥ嚭搴�", {
+ this.$confirm('鏄惁璋冩嫧鍑哄簱', '璀﹀憡', {
confirmButtonText: '纭畾',
cancelButtonText: '鍙栨秷',
type: 'warning',
center: true
}).then(() => {
- this.http.post(`/api/Task/OtherOutBoundTaskAsync`, this.$refs.detail.rowData, "姝e湪瀹屾垚浠诲姟").then((res) => {
- if (res.status) {
- this.$Message.success(res.message)
- } else {
- this.$Message.error(res.message) //閿欒鎻愮ず
- }
- })
+ this.http
+ .post(
+ `/api/Task/HandAllocateOutBoundTaskAsync`,
+ this.$refs.detail.rowData,
+ '姝e湪鐢熸垚鍑哄簱浠诲姟'
+ )
+ .then((res) => {
+ if (res.status) {
+ this.$Message.success(res.message)
+ this.boxModel = false
+ this.refresh()
+ } else {
+ this.$Message.error(res.message) //閿欒鎻愮ず
+ }
+ })
})
}
})
@@ -116,30 +132,78 @@
// })
// }
// });
+ // this.columns.push({
+ // field: '鎿嶄綔',
+ // title: '鎿嶄綔',
+ // width: 90,
+ // fixed: 'right',
+ // align: 'center',
+ // type:'jsx',
+ // formatter: (row) => {
+ // //return '<i style="cursor: pointer;color: #2d8cf0;"class="el-icon-view">鐩樼偣鍑哄簱</i>'
+ // return [{
+ // name:"btn1",
+ // type:"primary"
+ // },{
+ // name:"btn1",
+ // type:"success"
+ // }]
+ // },
+ // click: (row,formatter) => {
+ // console.log(formatter);
+ // this.http
+ // .post(`/api/Task/OutBoundTaskAsync?palletCode=${row.palletCode}`, {}, '姝e湪鐢熸垚浠诲姟')
+ // .then((res) => {
+ // //绀轰緥锛氳皟鐢ㄥ悗鍙版帴鍙�
+ // if (res.status) {
+ // this.$Message.success(row.palletCode + '鍑哄簱鎴愬姛')
+ // this.refresh()
+ // } else {
+ // this.$Message.error(res.message) //閿欒鎻愮ず
+ // this.refresh()
+ // }
+ // })
+ // }
+ // })
this.columns.push({
- field: '鎿嶄綔',
title: '鎿嶄綔',
- width: 90,
- fixed: 'right',
- align: 'center',
- formatter: (row) => {
+ field: '鎿嶄綔',
+ width: 250,
+ align: 'center', // 'center',
+ render: (h, { row, column, index }) => {
return (
- '<i style="cursor: pointer;color: #2d8cf0;"class="el-icon-view">鐩樼偣鍑哄簱</i>'
- );
- },
- click: (row) => {
- this.http.post(`/api/Task/OutBoundTaskAsync?palletCode=${row.palletCode}`, {}, "姝e湪鐢熸垚浠诲姟").then((res) => {
- //绀轰緥锛氳皟鐢ㄥ悗鍙版帴鍙�
- if (res.status) {
- this.$Message.success(row.palletCode + "鍑哄簱鎴愬姛");
- this.refresh();
- } else {
- this.$Message.error(res.message) //閿欒鎻愮ず
- this.refresh();
- }
- })
+ <div>
+ <el-button onClick={($e) => { }} type="primary">
+ 鍏朵粬鍑哄簱
+ </el-button>
+
+ <el-button onClick={($e) => {
+
+ }} type="success" >
+ 璋冩嫧鍑哄簱
+ </el-button>
+
+ <el-button onClick={($e) => {
+ // this.http
+ // .post(`/api/Task/OutBoundTaskAsync?palletCode=${row.palletCode}`, {}, '姝e湪鐢熸垚浠诲姟')
+ // .then((res) => {
+ // //绀轰緥锛氳皟鐢ㄥ悗鍙版帴鍙�
+ // if (res.status) {
+ // this.$Message.success(row.palletCode + '鍑哄簱鎴愬姛')
+ // this.refresh()
+ // } else {
+ // this.$Message.error(res.message) //閿欒鎻愮ず
+ // this.refresh()
+ // }
+ // })
+ this.$refs.gridBody.open(row.palletCode);
+ }} type="warning">
+ 鐩樼偣鍑哄簱
+ </el-button>
+ </div>
+ )
}
- });
+ })
// this.columns.push({
// title: "鎿嶄綔",
// field: "鎿嶄綔",
@@ -159,7 +223,7 @@
// style="height:26px; padding: 10px !important;"
// >
// 鎵撳嵃
- // </el-button>
+ // </el-button>
// </div>
// );
// },
@@ -167,55 +231,53 @@
//绀轰緥锛氳缃慨鏀规柊寤恒�佺紪杈戝脊鍑烘瀛楁鏍囩鐨勯暱搴�
this.boxOptions.labelWidth = 150
-
+ this.buttons.forEach((btn) => {
+ if (btn.name == '缂栬緫') {
+ btn.hidden = true
+ }
+ })
this.columns.forEach((column) => {
-
if (column.field == 'floor') {
-
const floorMap = {
'1F': '涓�妤�',
- '2F': '浜屾ゼ',
- };
+ '2F': '浜屾ゼ'
+ }
column.formatter = (row) => {
return floorMap[row?.locationInfo?.floor] || ''
}
}
if (column.field == 'areaId') {
-
const floorMap = {
- '1': '涓�妤煎爢鍨涙満鍖哄煙',
- '2': '涓�妤糀GV鍑哄簱缂撳瓨鍖�',
- '3': '涓�妤糀GV绔嬪簱缂撳瓨鍖�',
- '4': '涓�妤糀GV鍏ュ簱缂撳瓨鍖�',
- '5': '浜屾ゼB4-G4缂撳瓨鍖�',
- '6': '浜屾ゼB5-G5缂撳瓨鍖�',
- };
+ 1: '涓�妤煎爢鍨涙満鍖哄煙',
+ 2: '涓�妤糀GV鍑哄簱缂撳瓨鍖�',
+ 3: '涓�妤糀GV绔嬪簱缂撳瓨鍖�',
+ 4: '涓�妤糀GV鍏ュ簱缂撳瓨鍖�',
+ 5: '浜屾ゼB4-G4缂撳瓨鍖�',
+ 6: '浜屾ゼB5-G5缂撳瓨鍖�'
+ }
column.formatter = (row) => {
return floorMap[row?.locationInfo?.areaId] || ''
}
}
if (column.field == 'locationStatus') {
const statusMap = {
- '0': '绌洪棽',
- '1': '閿佸畾',
- '2': '鏈夎揣',
- '3': '鏈夎揣绂佺敤',
- '4': '鏃犺揣绂佺敤'
- };
+ 0: '绌洪棽',
+ 1: '閿佸畾',
+ 2: '鏈夎揣',
+ 3: '鏈夎揣绂佺敤',
+ 4: '鏃犺揣绂佺敤'
+ }
column.formatter = (row) => {
- return statusMap[row?.locationInfo?.locationStatus] || '';
+ return statusMap[row?.locationInfo?.locationStatus] || ''
}
}
-
})
},
onInited() {
//妗嗘灦鍒濆鍖栭厤缃悗
//濡傛灉瑕侀厤缃槑缁嗚〃,鍦ㄦ鏂规硶鎿嶄綔
- this.detailOptions.columns.forEach(column => {
-
- });
+ this.detailOptions.columns.forEach((column) => {})
},
searchBefore(param) {
//鐣岄潰鏌ヨ鍓�,鍙互缁檖aram.wheres娣诲姞鏌ヨ鍙傛暟
@@ -238,38 +300,38 @@
//this.$refs.table.$refs.table.toggleRowSelection(row) //鍗曞嚮琛屾椂閫変腑褰撳墠琛�;
},
modelOpenAfter(row) {
- const isAdd = this.currentAction == 'Add';//鍒ゆ柇鏄惁涓烘柊寤烘搷浣�
+ const isAdd = this.currentAction == 'Add' //鍒ゆ柇鏄惁涓烘柊寤烘搷浣�
//闅愯棌鏄庣粏琛ㄦ寜閽�
this.detailOptions.buttons.forEach((btn) => {
if (btn.name == '娣诲姞琛�') {
- btn.hidden = true;
+ btn.hidden = true
//鎴栬�呰缃彧璇�
//btn.readonly=true;
}
- });
- const isDel = this.currentAction == 'Add';//鍒ゆ柇鏄惁涓烘柊寤烘搷浣�
+ })
+ const isDel = this.currentAction == 'Add' //鍒ゆ柇鏄惁涓烘柊寤烘搷浣�
//闅愯棌鏄庣粏琛ㄦ寜閽�
this.detailOptions.buttons.forEach((btn) => {
if (btn.name == '鍒犻櫎琛�') {
- btn.hidden = true;
+ btn.hidden = true
//鎴栬�呰缃彧璇�
//btn.readonly=true;
}
- });
+ })
this.detailOptions.buttons.forEach((btn) => {
if (btn.name == '瀵煎叆') {
- btn.hidden = true;
+ btn.hidden = true
//鎴栬�呰缃彧璇�
//btn.readonly=true;
}
- });
+ })
this.detailOptions.buttons.forEach((btn) => {
if (btn.name == '瀵煎嚭') {
- btn.hidden = true;
+ btn.hidden = true
//鎴栬�呰缃彧璇�
//btn.readonly=true;
}
- });
+ })
//鐐瑰嚮缂栬緫銆佹柊寤烘寜閽脊鍑烘鍚庯紝鍙互鍦ㄦ澶勫啓閫昏緫锛屽锛屼粠鍚庡彴鑾峰彇鏁版嵁
//(1)鍒ゆ柇鏄紪杈戣繕鏄柊寤烘搷浣滐細 this.currentAction=='Add';
//(2)缁欏脊鍑烘璁剧疆榛樿鍊�
--
Gitblit v1.9.3