|
|
@ -2,7 +2,7 @@ |
|
|
|
<div :class="kind ? 'orderPage' : 'orderPageS'"> |
|
|
|
<div :class="kind ? 'orderPage' : 'orderPageS'"> |
|
|
|
<el-tabs |
|
|
|
<el-tabs |
|
|
|
v-loading="editLoading" |
|
|
|
v-loading="editLoading" |
|
|
|
element-loading-text="编辑内容加载中..." |
|
|
|
element-loading-text="正在加载中..." |
|
|
|
type="border-card" |
|
|
|
type="border-card" |
|
|
|
class="order-table" |
|
|
|
class="order-table" |
|
|
|
@tab-click="tabClick" |
|
|
|
@tab-click="tabClick" |
|
|
@ -820,6 +820,7 @@ import { |
|
|
|
getZeroOrderDetail, |
|
|
|
getZeroOrderDetail, |
|
|
|
} from '@/api/distribution/distributionStockArticle'; //API |
|
|
|
} from '@/api/distribution/distributionStockArticle'; //API |
|
|
|
import { getVehicleList } from '@/api/basicdata/basicdataVehicle'; //车辆信息 |
|
|
|
import { getVehicleList } from '@/api/basicdata/basicdataVehicle'; //车辆信息 |
|
|
|
|
|
|
|
import { useStore } from 'vuex'; |
|
|
|
import { getDriverList } from '@/api/basicdata/basicdataDriverArtery'; //司机信息 |
|
|
|
import { getDriverList } from '@/api/basicdata/basicdataDriverArtery'; //司机信息 |
|
|
|
import { ElMessage, type UploadProps } from 'element-plus'; |
|
|
|
import { ElMessage, type UploadProps } from 'element-plus'; |
|
|
|
import { |
|
|
|
import { |
|
|
@ -840,6 +841,10 @@ import type { FormProps } from 'element-plus'; |
|
|
|
import { updateEntryNum, entryNum } from '@/api/distribution/distributionParcelNumber'; |
|
|
|
import { updateEntryNum, entryNum } from '@/api/distribution/distributionParcelNumber'; |
|
|
|
const route = useRoute(); |
|
|
|
const route = useRoute(); |
|
|
|
const router = useRouter(); |
|
|
|
const router = useRouter(); |
|
|
|
|
|
|
|
// 获取vuex仓库 |
|
|
|
|
|
|
|
const $store = useStore(); |
|
|
|
|
|
|
|
console.log($store,'仓库'); |
|
|
|
|
|
|
|
|
|
|
|
// 选项卡 |
|
|
|
// 选项卡 |
|
|
|
const numTab = ref([ |
|
|
|
const numTab = ref([ |
|
|
|
{ |
|
|
|
{ |
|
|
@ -1933,25 +1938,7 @@ const soclear = () => { |
|
|
|
SearchFu(); |
|
|
|
SearchFu(); |
|
|
|
}; |
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
// function scrollToElementWithPartialId(partialId) { |
|
|
|
|
|
|
|
// // 首先清空之前所有元素的颜色样式 |
|
|
|
|
|
|
|
// document.querySelectorAll('[id]').forEach(function(el) { |
|
|
|
|
|
|
|
// el.style.backgroundColor = ''; // 移除背景颜色 |
|
|
|
|
|
|
|
// el.style.color = ''; // 移除文字颜色 |
|
|
|
|
|
|
|
// }); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// // 现在开始搜索含有 partialId 的元素 |
|
|
|
|
|
|
|
// const allElements = document.querySelectorAll(`[id*="${partialId}"]`); |
|
|
|
|
|
|
|
// if (allElements.length > 0) { |
|
|
|
|
|
|
|
// // 获取第一个匹配的元素 |
|
|
|
|
|
|
|
// const targetElement = allElements[0]; |
|
|
|
|
|
|
|
// // 添加背景颜色和文字颜色 |
|
|
|
|
|
|
|
// targetElement.style.backgroundColor = '#ff0000'; // 设置背景颜色为红色 |
|
|
|
|
|
|
|
// targetElement.style.color = '#fff'; // 设置文字颜色为白色 |
|
|
|
|
|
|
|
// // 将匹配元素滚动到视野区域 |
|
|
|
|
|
|
|
// targetElement.scrollIntoView(); |
|
|
|
|
|
|
|
// } |
|
|
|
|
|
|
|
// } |
|
|
|
|
|
|
|
function scrollToElementWithinTableRow(partialIdString) { |
|
|
|
function scrollToElementWithinTableRow(partialIdString) { |
|
|
|
// 首先清空之前所有元素的颜色样式 |
|
|
|
// 首先清空之前所有元素的颜色样式 |
|
|
|
const tableRows = document.querySelectorAll('tr'); |
|
|
|
const tableRows = document.querySelectorAll('tr'); |
|
|
@ -2704,6 +2691,8 @@ const moveUpVehictle = row => { |
|
|
|
|
|
|
|
|
|
|
|
// 最后提交订单 |
|
|
|
// 最后提交订单 |
|
|
|
const SubmitCommercial = () => { |
|
|
|
const SubmitCommercial = () => { |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// kind为假就说明目前是在外协页面 |
|
|
|
// kind为假就说明目前是在外协页面 |
|
|
|
console.log(kind.value); |
|
|
|
console.log(kind.value); |
|
|
|
if (kind.value) { |
|
|
|
if (kind.value) { |
|
|
@ -2715,6 +2704,7 @@ const SubmitCommercial = () => { |
|
|
|
if (!state.value) { |
|
|
|
if (!state.value) { |
|
|
|
return; |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// 如果订单下面没有选择包件就默认给每个订单包件下面添加packageListInfo字段为空数组 |
|
|
|
// 如果订单下面没有选择包件就默认给每个订单包件下面添加packageListInfo字段为空数组 |
|
|
|
dataInfo.value.forEach(item => { |
|
|
|
dataInfo.value.forEach(item => { |
|
|
|
if (!item.packageListInfo) { |
|
|
|
if (!item.packageListInfo) { |
|
|
@ -2724,6 +2714,7 @@ const SubmitCommercial = () => { |
|
|
|
DataSubmit.value.stockArticle = dataInfo.value; //订单列表 |
|
|
|
DataSubmit.value.stockArticle = dataInfo.value; //订单列表 |
|
|
|
// 提交 |
|
|
|
// 提交 |
|
|
|
// 编辑修改 |
|
|
|
// 编辑修改 |
|
|
|
|
|
|
|
editLoading.value = true;//开启提交加载 |
|
|
|
if (RouteId.value) { |
|
|
|
if (RouteId.value) { |
|
|
|
if (!kind.value) { |
|
|
|
if (!kind.value) { |
|
|
|
delete DataSubmit.value.allocationInfo; //如果为外协删掉此参数 |
|
|
|
delete DataSubmit.value.allocationInfo; //如果为外协删掉此参数 |
|
|
@ -2733,15 +2724,21 @@ const SubmitCommercial = () => { |
|
|
|
DataSubmitRenamed.stockupInfo = DataSubmit.value.stockup; //把原来的参数赋值给新对象名字,这里用于修改对象名字 |
|
|
|
DataSubmitRenamed.stockupInfo = DataSubmit.value.stockup; //把原来的参数赋值给新对象名字,这里用于修改对象名字 |
|
|
|
DataSubmitRenamed.id = RouteId.value; //修改提交的时候带上参数ID |
|
|
|
DataSubmitRenamed.id = RouteId.value; //修改提交的时候带上参数ID |
|
|
|
updateDeliveryList(DataSubmitRenamed).then(res => { |
|
|
|
updateDeliveryList(DataSubmitRenamed).then(res => { |
|
|
|
|
|
|
|
editLoading.value = false;//关闭提交加载 |
|
|
|
console.log(res, '修改之后提交的返回值'); |
|
|
|
console.log(res, '修改之后提交的返回值'); |
|
|
|
router.push('/distribution/deliverylist/distributionDeliveryListdis'); |
|
|
|
$store.commit('DEL_TAG_CURRENT'); //关闭当前页面 |
|
|
|
|
|
|
|
router.push('/distribution/inventory/distrilbutionBillLadingList'); |
|
|
|
|
|
|
|
|
|
|
|
}); |
|
|
|
}); |
|
|
|
} else { |
|
|
|
} else { |
|
|
|
// 新增信息 |
|
|
|
// 新增信息 |
|
|
|
deliveryBusinessTask(DataSubmit.value).then(res => { |
|
|
|
deliveryBusinessTask(DataSubmit.value).then(res => { |
|
|
|
console.log(res, '新增之后的返回值'); |
|
|
|
console.log(res, '新增之后的返回值'); |
|
|
|
// 提交之后进行跳转 |
|
|
|
// 提交之后进行跳转 |
|
|
|
router.push('/distribution/deliverylist/distributionDeliveryListdis'); |
|
|
|
editLoading.value = false;//关闭提交加载 |
|
|
|
|
|
|
|
$store.commit('DEL_TAG_CURRENT'); //关闭当前页面 |
|
|
|
|
|
|
|
router.push('/distribution/inventory/distrilbutionBillLadingList'); |
|
|
|
|
|
|
|
|
|
|
|
}); |
|
|
|
}); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|