+
+
+
+
新增标签指定
@@ -705,27 +732,42 @@
-
+
+
+
-
-
+
+
+
-
-
+
+
-
-
-
-
-
-
+
+
+
+
+
+
上移
下移
@@ -734,8 +776,36 @@
- 保存
- 关闭
+ 保存
+ 关闭
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 关闭
@@ -822,7 +892,9 @@ import {
searchMaterialListDetail, // rqrq - 导入预留标签清单API
deleteNotifySOS, // rqrq - 导入删除申请订单API
getNoOrderMaterialAllocList,
- saveNoOrderMaterialAllocList
+ saveNoOrderMaterialAllocList,
+ getNoOrderAvailableInStockLabelList,
+ getNoOrderMaterialAllocListByNotifyNo
} from '@/api/haianWarehouse/noOrderIssueNotify.js'
import {
getSiteAndBuByUserName,
@@ -1546,24 +1618,6 @@ export default {
fixed: false,
columnWidth: 80,
},
- {
- userId: this.$store.state.user.name,
- functionId: 444002,
- serialNumber: '555001Table1NeedDate',
- tableId: '555001Table1',
- tableName: '领料申请派工单子表',
- columnProp: 'needDate',
- headerAlign: 'center',
- align: 'left',
- columnLabel: '要求发料时间',
- columnHidden: false,
- columnImage: false,
- columnSortable: false,
- sortLv: 0,
- status: true,
- fixed: false,
- columnWidth: 80,
- },
{
userId: this.$store.state.user.name,
functionId: 444002,
@@ -1638,6 +1692,9 @@ export default {
},
],
columnDetailList2:[],
+ // rqrq - 指定物料清单页签数据
+ allocDetailList: [],
+ allocDetailLoading: false,
// rqrq - 预留标签清单数据和列定义
dataList7: [],
columnList6: [
@@ -1831,8 +1888,15 @@ export default {
partNo: '',
partDesc: '',
subSite: '',
+ qtyToIssue: 0,
allocList: []
},
+ // 海安无单在库可用标签选择弹窗状态 - rqrq
+ noOrderLabelPickDialogVisible: false,
+ noOrderLabelPickLoading: false,
+ noOrderLabelPickList: [],
+ noOrderLabelPickIndex: -1,
+ noOrderLabelPickMode: 'LABEL',
availableMaterialList: [], // 左侧可选物料列表
selectedMaterialList: [], // 右侧已选物料列表
availableMaterialSelections: [], // 左侧选中的行
@@ -2214,12 +2278,46 @@ export default {
if (this.activeTable === 'inboundDetail') {
// 刷新非工单申请明细数据 - rqrq
this.getNotifyNoOrderDetailByType()
+ } else if (this.activeTable === 'allocDetail') {
+ // 查询当前申请单指定物料清单 - rqrq
+ this.searchNoOrderMaterialAllocListByNotifyNo()
} else if (this.activeTable === 'labelDetail') {
// 查询预留标签清单 - rqrq
this.searchMaterialListDetail()
}
},
+ /**
+ * 查询当前申请单指定物料清单:按site+notifyNo拉取全部指定行,不含备注 - rqrq
+ */
+ searchNoOrderMaterialAllocListByNotifyNo() {
+ if (!this.currentRow || !this.currentRow.notifyNo) {
+ this.allocDetailList = []
+ return
+ }
+ this.allocDetailLoading = true
+ getNoOrderMaterialAllocListByNotifyNo({
+ site: this.currentRow.site || this.$store.state.user.site,
+ notifyNo: this.currentRow.notifyNo,
+ page: 1,
+ limit: 20
+ }).then(({ data }) => {
+ if (data && data.code === 0) {
+ this.allocDetailList = data.rows || []
+ } else {
+ this.allocDetailList = []
+ if (data && data.msg) {
+ this.$alert(data.msg, '提示', { confirmButtonText: '确定' })
+ }
+ }
+ }).catch((error) => {
+ this.allocDetailList = []
+ this.$message.error(error.message || '查询指定物料清单失败')
+ }).finally(() => {
+ this.allocDetailLoading = false
+ })
+ },
+
// rqrq - 查询预留标签清单
searchMaterialListDetail() {
if (!this.currentRow || !this.currentRow.notifyNo) {
@@ -2667,6 +2765,7 @@ export default {
partNo: row.partNo || row.componentPartNo || '',
partDesc: row.partDesc || row.componentPartDesc || '',
subSite: row.subSite || (this.clickrow && this.clickrow.subSite) || this.$store.state.user.site,
+ qtyToIssue: row.qtyToIssue == null || row.qtyToIssue === '' ? 0 : row.qtyToIssue,
allocList: []
}
this.noOrderAllocDialogVisible = true
@@ -2705,6 +2804,77 @@ export default {
this.refreshNoOrderAllocRowNo()
},
+ /**
+ * 打开在库可用标签清单:按当前指定行的subsite+物料号查询未预留且托盘可调用标签 - rqrq
+ * @param index 当前指定策略行下标
+ * @param pickMode LABEL回填标签号;BATCH回填批次号
+ */
+ openNoOrderAvailableLabelDialog (index, pickMode) {
+ if (!this.noOrderAllocForm.subSite) {
+ this.$alert('缺少子站点,无法查询在库标签', '提示', { confirmButtonText: '确定' })
+ return
+ }
+ if (!this.noOrderAllocForm.partNo) {
+ this.$alert('缺少物料号,无法查询在库标签', '提示', { confirmButtonText: '确定' })
+ return
+ }
+ this.noOrderLabelPickIndex = index
+ this.noOrderLabelPickMode = pickMode
+ this.noOrderLabelPickList = []
+ this.noOrderLabelPickDialogVisible = true
+ this.noOrderLabelPickLoading = true
+ // 调用独立查询接口:site来自登录store,subSite+partNo定位可用标签;失败保留空表 - rqrq
+ getNoOrderAvailableInStockLabelList({
+ site: this.$store.state.user.site,
+ subSite: this.noOrderAllocForm.subSite,
+ partNo: this.noOrderAllocForm.partNo,
+ page: 1,
+ limit: 20
+ }).then(({ data }) => {
+ if (data && data.code === 0) {
+ this.noOrderLabelPickList = data.rows || []
+ } else {
+ this.noOrderLabelPickList = []
+ this.$alert((data && data.msg) || '查询在库可用标签失败', '提示', { confirmButtonText: '确定' })
+ }
+ }).catch((error) => {
+ this.noOrderLabelPickList = []
+ this.$message.error(error.message || '查询在库可用标签失败')
+ }).finally(() => {
+ this.noOrderLabelPickLoading = false
+ })
+ },
+
+ /**
+ * 双击在库标签:标签指定回填标签号并锁定数量;批次指定回填批次号且数量默认可改 - rqrq
+ */
+ handleNoOrderAvailableLabelDblClick (row) {
+ const target = this.noOrderAllocForm.allocList[this.noOrderLabelPickIndex]
+ if (!target) {
+ this.$message.warning('未找到待回填的指定行')
+ return
+ }
+ const labelQty = row.qty == null || row.qty === '' ? 0 : row.qty
+ if (this.noOrderLabelPickMode === 'LABEL') {
+ if (!row.serialNo) {
+ this.$alert('所选行缺少标签号,无法指定', '提示', { confirmButtonText: '确定' })
+ return
+ }
+ target.serialNo = row.serialNo
+ target.batchNo = ''
+ target.allocQty = labelQty
+ } else {
+ if (!row.batchNo) {
+ this.$alert('所选标签缺少批次号,无法指定批次', '提示', { confirmButtonText: '确定' })
+ return
+ }
+ target.serialNo = ''
+ target.batchNo = row.batchNo
+ target.allocQty = labelQty
+ }
+ this.noOrderLabelPickDialogVisible = false
+ },
+
/**
* 删除指定策略行,删除后重排序号 - rqrq
*/
@@ -3242,7 +3412,7 @@ export default {
previewInventory () {
this.$message.warning('海安无单申请WCS推送功能暂不启用')
},
-
+
/**
* @Description 获取区域显示文本 - rqrq
* @param areaId 区域ID
@@ -3256,7 +3426,7 @@ export default {
}
return areaId
},
-
+
/**
* @Description 目的地下拉框值改变时自动保存 - rqrq
* @param newValue 新的目的地值
@@ -3266,15 +3436,15 @@ export default {
if (newValue === this.originalProductionArea) {
return
}
-
+
this.destinationUpdating = true
-
+
const updateData = {
site: this.currentNotifyRow.site,
notifyNo: this.currentNotifyRow.notifyNo,
productionArea: newValue
}
-
+
updateProductionArea(updateData).then(({data}) => {
this.destinationUpdating = false
if (data && data.code === 0) {