Browse Source

修改干线自提样式

dev-xx
qb 9 months ago
parent
commit
9b87c849a0
  1. 25
      src/views/distribution/inventory/addArteryDistrilbutionBillLadingList.vue

25
src/views/distribution/inventory/addArteryDistrilbutionBillLadingList.vue

@ -47,7 +47,7 @@
@change="val => destinationWarehouseNameChange(val, index)" @change="val => destinationWarehouseNameChange(val, index)"
:remote-method="remoteMethod" :remote-method="remoteMethod"
:loading="details.loadingObj.nodeLoading" :loading="details.loadingObj.nodeLoading"
:disabled="index === 0 || index === nodeInfoData.length - 1" :disabled="index === nodeInfoData.length - 1"
clearable clearable
> >
<el-option <el-option
@ -601,13 +601,13 @@ const active = computed(() => nodeInfoData.length);
const initData = async () => { const initData = async () => {
const res = await postloadFindLoadInitData(); const res = await postloadFindLoadInitData();
const { code, data } = res.data; const { code, data } = res.data;
nodeInfoData[0] = { // nodeInfoData[0] = {
nodeName: data.startWarehouseInfo.warehouseName, // nodeName: data.startWarehouseInfo.warehouseName,
nodeId: data.startWarehouseInfo.warehouseId, // nodeId: data.startWarehouseInfo.warehouseId,
clientId: data.startWarehouseInfo.warehouseId, // clientId: data.startWarehouseInfo.warehouseId,
clientName: data.startWarehouseInfo.warehouseName, // clientName: data.startWarehouseInfo.warehouseName,
...data.startWarehouseInfo, // ...data.startWarehouseInfo,
}; // };
nodeInfoData[nodeInfoData.length - 1] = { nodeInfoData[nodeInfoData.length - 1] = {
nodeName: data.startWarehouseInfo.warehouseName, nodeName: data.startWarehouseInfo.warehouseName,
@ -676,7 +676,12 @@ const initPage = async () => {
newInputsc('', { prop: 'aaa' }); newInputsc('', { prop: 'aaa' });
// //
data.lineList.forEach(val => { data.lineList.forEach((val, index) => {
if (index === 0) {
nodeInfoData[0] = { ...val, nodeName: val.clientName };
return;
}
nodeInfoData.splice(nodeInfoData.length - 1, 0, { nodeInfoData.splice(nodeInfoData.length - 1, 0, {
...val, ...val,
nodeName: val.clientName, nodeName: val.clientName,
@ -1168,7 +1173,7 @@ const handleSubmit = async (formEl: FormInstance | undefined) => {
if (!formEl) return; if (!formEl) return;
await formEl.validate((valid, fields) => { await formEl.validate((valid, fields) => {
if (valid) { if (valid) {
const _nodeArr = nodeInfoData.slice(1, nodeInfoData.length - 1); const _nodeArr = nodeInfoData.slice(0, nodeInfoData.length - 1);
if (_nodeArr.length === 0) return ElMessage.warning('请添加路线节点'); if (_nodeArr.length === 0) return ElMessage.warning('请添加路线节点');

Loading…
Cancel
Save