Browse Source

修复部分bug,新增暂存单生成包条

dev-xx
qb 7 months ago
parent
commit
5f911e1113
  1. 11
      src/api/waybill/TemporaryStorageList.js
  2. 4
      src/option/distribution/TripartiteTransfer.js
  3. 20
      src/option/waybill/TemporaryStorageList.js
  4. 4
      src/styles/common.scss
  5. 26
      src/views/distribution/artery/TripartiteTransfer.vue
  6. 40
      src/views/distribution/artery/VehicleArrivalManagement.vue
  7. 40
      src/views/distribution/artery/VehicleStowage.vue
  8. 16
      src/views/distribution/deliverylist/distributionDeliveryListedt.vue
  9. 16
      src/views/waybill/ChangeOrder.vue
  10. 43
      src/views/waybill/CreateZeroOrder.vue
  11. 112
      src/views/waybill/TemporaryStorageList.vue
  12. 16
      src/views/waybill/WaybillOrderList.vue
  13. 40
      src/views/waybill/orderPackageList.vue
  14. 40
      src/views/waybill/orderPackageListDetails.vue

11
src/api/waybill/TemporaryStorageList.js

@ -94,3 +94,14 @@ export const postFindBrandList = (data = {}) => {
data,
});
};
/**
* 暂存单生成包条
*/
export const postCreateOrderPackage = (data = {}) => {
return request({
url: '/api/logpm-trunkline/openOrder/createOrderPackage',
method: 'post',
data,
});
};

4
src/option/distribution/TripartiteTransfer.js

@ -109,7 +109,7 @@ export const columnList = [
{
prop: 'isSettlementName',
label: '是否结算',
type: 2,
type: 3,
values: '',
width: '130',
checkarr: [],
@ -179,7 +179,7 @@ export const columnList = [
{
prop: 'deliveryTypeName',
label: '送货方式',
type: 2,
type: 3,
values: '',
width: '130',
checkarr: [],

20
src/option/waybill/TemporaryStorageList.js

@ -106,16 +106,16 @@ export const columnList = [
sortable: true,
isshowSummary: true,
},
{
prop: 'senderFactory',
label: '发货单位',
type: 1,
values: '',
width: '130',
checkarr: [],
fixed: false,
sortable: true,
},
// {
// prop: 'senderFactory',
// label: '发货单位',
// type: 1,
// values: '',
// width: '130',
// checkarr: [],
// fixed: false,
// sortable: true,
// },
{
prop: 'senderName',
label: '发货人',

4
src/styles/common.scss

@ -204,6 +204,10 @@ a {
margin-bottom: 10px;
}
.mb20 {
margin-bottom: 20px;
}
.flex1 {
flex: 1;
}

26
src/views/distribution/artery/TripartiteTransfer.vue

@ -385,15 +385,19 @@
<div class="fwb" :id="titleId" :class="titleClass">配载清单</div>
<div class="flex-c-c">
<!-- 全屏显示按钮 -->
<el-button type="text" v-if="!details.fullscreenObj.listOfLoadedWagonsPopUp">
<el-icon class="" @click="handleFullScrean('open', 'listOfLoadedWagonsPopUp')"
><FullScreen
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('open', 'listOfLoadedWagonsPopUp')"
v-if="!details.fullscreenObj.listOfLoadedWagonsPopUp"
>
<el-icon class=""><FullScreen /></el-icon>
</el-button>
<el-button type="text" v-else>
<el-icon class="" @click="handleFullScrean('close', 'listOfLoadedWagonsPopUp')"
><CopyDocument
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('close', 'listOfLoadedWagonsPopUp')"
v-else
>
<el-icon class=""><CopyDocument /></el-icon>
</el-button>
<!-- 弹窗关闭按钮 -->
@ -495,6 +499,7 @@ import {
debounce,
handleClearTableQuery,
getObjType,
handleSelectQuery,
} from '@/utils/util';
import { columnList, detailsColumnList } from '@/option/distribution/TripartiteTransfer';
import {
@ -906,10 +911,7 @@ const btnsc = () => {};
/** 表格表头下拉框选择 */
const selectsc = (index, row) => {
const _name = row.prop.replace('Name', '');
details.query[_name] = index;
if (!index) delete details.query[_name];
handleSelectQuery(index, row, details.query);
onLoad();
};

40
src/views/distribution/artery/VehicleArrivalManagement.vue

@ -367,15 +367,19 @@
<div class="fwb" :id="titleId" :class="titleClass">配置装车目的地</div>
<div class="flex-c-c">
<!-- 全屏显示按钮 -->
<el-button type="text" v-if="!details.fullscreenObj.truckLoadingDetailPopUp">
<el-icon class="" @click="handleFullScrean('open', 'truckLoadingDetailPopUp')"
><FullScreen
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('open', 'truckLoadingDetailPopUp')"
v-if="!details.fullscreenObj.truckLoadingDetailPopUp"
>
<el-icon class=""><FullScreen /></el-icon>
</el-button>
<el-button type="text" v-else>
<el-icon class="" @click="handleFullScrean('close', 'truckLoadingDetailPopUp')"
><CopyDocument
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('close', 'truckLoadingDetailPopUp')"
v-else
>
<el-icon class=""><CopyDocument /></el-icon>
</el-button>
<!-- 弹窗关闭按钮 -->
@ -479,15 +483,19 @@
<div class="fwb" :id="titleId" :class="titleClass">配载清单</div>
<div class="flex-c-c">
<!-- 全屏显示按钮 -->
<el-button type="text" v-if="!details.fullscreenObj.listOfLoadedWagonsPopUp">
<el-icon class="" @click="handleFullScrean('open', 'listOfLoadedWagonsPopUp')"
><FullScreen
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('open', 'listOfLoadedWagonsPopUp')"
v-if="!details.fullscreenObj.listOfLoadedWagonsPopUp"
>
<el-icon class=""><FullScreen /></el-icon>
</el-button>
<el-button type="text" v-else>
<el-icon class="" @click="handleFullScrean('close', 'listOfLoadedWagonsPopUp')"
><CopyDocument
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('close', 'listOfLoadedWagonsPopUp')"
v-else
>
<el-icon class=""><CopyDocument /></el-icon>
</el-button>
<!-- 弹窗关闭按钮 -->

40
src/views/distribution/artery/VehicleStowage.vue

@ -369,15 +369,19 @@
<div class="fwb" :id="titleId" :class="titleClass">配置装车目的地</div>
<div class="flex-c-c">
<!-- 全屏显示按钮 -->
<el-button type="text" v-if="!details.fullscreenObj.truckLoadingDetailPopUp">
<el-icon class="" @click="handleFullScrean('open', 'truckLoadingDetailPopUp')"
><FullScreen
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('open', 'truckLoadingDetailPopUp')"
v-if="!details.fullscreenObj.truckLoadingDetailPopUp"
>
<el-icon class=""><FullScreen /></el-icon>
</el-button>
<el-button type="text" v-else>
<el-icon class="" @click="handleFullScrean('close', 'truckLoadingDetailPopUp')"
><CopyDocument
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('close', 'truckLoadingDetailPopUp')"
v-else
>
<el-icon class=""><CopyDocument /></el-icon>
</el-button>
<!-- 弹窗关闭按钮 -->
@ -481,15 +485,19 @@
<div class="fwb" :id="titleId" :class="titleClass">配载清单</div>
<div class="flex-c-c">
<!-- 全屏显示按钮 -->
<el-button type="text" v-if="!details.fullscreenObj.listOfLoadedWagonsPopUp">
<el-icon class="" @click="handleFullScrean('open', 'listOfLoadedWagonsPopUp')"
><FullScreen
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('open', 'listOfLoadedWagonsPopUp')"
v-if="!details.fullscreenObj.listOfLoadedWagonsPopUp"
>
<el-icon class=""><FullScreen /></el-icon>
</el-button>
<el-button type="text" v-else>
<el-icon class="" @click="handleFullScrean('close', 'listOfLoadedWagonsPopUp')"
><CopyDocument
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('close', 'listOfLoadedWagonsPopUp')"
v-else
>
<el-icon class=""><CopyDocument /></el-icon>
</el-button>
<!-- 弹窗关闭按钮 -->

16
src/views/distribution/deliverylist/distributionDeliveryListedt.vue

@ -366,15 +366,15 @@
<div :id="titleId" :class="titleClass">{{ title }}</div>
<div class="flex-c-c">
<!-- 全屏显示按钮 -->
<el-button type="text" v-if="!wrapoption.fullscreen">
<el-icon class="" @click="handleFullScrean('open', 'el-dialog-view')"
><FullScreen
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('open', 'el-dialog-view')"
v-if="!wrapoption.fullscreen"
>
<el-icon class=""><FullScreen /></el-icon>
</el-button>
<el-button type="text" v-else>
<el-icon class="" @click="handleFullScrean('close', 'el-dialog-view')"
><CopyDocument
/></el-icon>
<el-button type="text" @click="handleFullScrean('close', 'el-dialog-view')" v-else>
<el-icon class=""><CopyDocument /></el-icon>
</el-button>
<!-- 弹窗关闭按钮 -->

16
src/views/waybill/ChangeOrder.vue

@ -133,15 +133,15 @@
<div :id="titleId" :class="titleClass">查看改单</div>
<div class="flex-c-c">
<!-- 全屏显示按钮 -->
<el-button type="text" v-if="!details.fullscreenObj.view">
<el-icon class="" @click="handleFullScrean('open', 'el-dialog-view')"
><FullScreen
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('open', 'el-dialog-view')"
v-if="!details.fullscreenObj.view"
>
<el-icon class=""><FullScreen /></el-icon>
</el-button>
<el-button type="text" v-else>
<el-icon class="" @click="handleFullScrean('close', 'el-dialog-view')"
><CopyDocument
/></el-icon>
<el-button type="text" @click="handleFullScrean('close', 'el-dialog-view')" v-else>
<el-icon class=""><CopyDocument /></el-icon>
</el-button>
<!-- 弹窗关闭按钮 -->

43
src/views/waybill/CreateZeroOrder.vue

@ -515,6 +515,7 @@
:input="() => debounce(handleFindGoods(item.goodsName, item, 1), 1000)"
:focus="handleCloseSelcet"
v-model="item.goodsName"
:class="!item.goodsId ? 'is-error' : ''"
placeholder="货物名称"
>
<div v-loading="item.loading">
@ -1863,33 +1864,33 @@ const onLoad = async () => {
/** 新增 */
const handleAdd = () => {
const _flag = details.goodsList.every(val => {
//
const _arr = [];
for (let i = 0; i < details.goodsList.length; i++) {
const val = details.goodsList[i];
if (_arr.includes(val.goodsName)) return ElMessage.warning('存在重复品类名,请移除其中一项');
else _arr.push(val.goodsName);
if (val.goodsName === '' || !val.num) {
ElMessage({
return ElMessage({
message: '请填写完整件数和名称',
type: 'warning',
});
return false;
}
if (val.chargeType === 2 && val.volume === 0) {
ElMessage({
return ElMessage({
message: '请填写方数',
type: 'warning',
});
return false;
}
if (val.chargeType === 3 && val.weight === 0) {
ElMessage({
return ElMessage({
message: '请填写重量',
type: 'warning',
});
return false;
}
return true;
});
if (!_flag) return;
}
details.goodsList.push({
/** 货物名称 */
@ -2471,17 +2472,15 @@ const handleSubmit = async (formEl: FormInstance | undefined) => {
try {
details.loadingObj.submitLoadingBtn = true;
//
const _flag = details.goodsList.every(val => {
if (!val.goodsName || !isNumber(val.num) || val.num === 0) return false;
return true;
});
let _arr = [];
if (!_flag) {
return ElMessage({
type: 'warning',
message: '请填写正确的货物名称和件数',
});
for (let i = 0; i < details.goodsList.length; i++) {
const val = details.goodsList[i];
//
if (!val.goodsName || !isNumber(val.num) || val.num === 0)
return ElMessage.warning('请填写正确的货物名称和件数');
if (_arr.includes(val.goodsName)) return ElMessage.warning('存在重复的货物名称,请移除');
}
if (!(details.query.totalFreight > 0)) return ElMessage.warning('请输入大于零的运费');

112
src/views/waybill/TemporaryStorageList.vue

@ -157,6 +157,13 @@
>
包明细
</el-text>
<el-text
v-if="slotProps.scope.row.totalNum === 0"
@click="handleCreatePackage(slotProps.scope)"
>
生成包条
</el-text>
</template>
</template>
</tablecmt>
@ -201,15 +208,15 @@
<div class="fwb" :id="titleId" :class="titleClass">开标签</div>
<div class="flex-c-c">
<!-- 全屏显示按钮 -->
<el-button type="text" v-if="!details.fullscreenObj.addTagVisited">
<el-icon class="" @click="handleFullScrean('open', 'addTagVisited')"
><FullScreen
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('open', 'addTagVisited')"
v-if="!details.fullscreenObj.addTagVisited"
>
<el-icon class=""><FullScreen /></el-icon>
</el-button>
<el-button type="text" v-else>
<el-icon class="" @click="handleFullScrean('close', 'addTagVisited')"
><CopyDocument
/></el-icon>
<el-button type="text" @click="handleFullScrean('close', 'addTagVisited')" v-else>
<el-icon class=""><CopyDocument /></el-icon>
</el-button>
<!-- 弹窗关闭按钮 -->
@ -478,6 +485,39 @@
</template>
</div>
</el-dialog>
<!-- 暂存单生成包条 -->
<el-dialog
:modal-append-to-body="false"
:append-to-body="false"
class="el-dialog-createPackge"
title="生成包条"
width="780px"
v-model="details.popUpShow.createPackge"
>
<div class="title mb20">订单号{{ details.form.orderCode }}</div>
<el-form-item label="生成数量:" style="margin-right: 0">
<el-input-number
class="inputNum"
v-model="details.form.enterNum"
style="width: 100%"
:controls="false"
:min="1"
:precision="0"
:value-on-clear="0"
/>
</el-form-item>
<div style="text-align: right">
<el-button icon="CircleClose" @click="details.popUpShow.createPackge = false">
</el-button>
<el-button type="primary" icon="Position" @click="handleSubmitCreatePackage">
</el-button>
</div>
</el-dialog>
</div>
</basic-container>
@ -512,6 +552,7 @@ import {
postOpenOrderDeletedAdvance,
postFindBrandList,
postOpenLabel,
postCreateOrderPackage,
} from '@/api/waybill/TemporaryStorageList';
import { getLazyTreeAll } from '@/api/base/region';
import { showOrderPackgeCode } from '@/api/distribution/distributionStockArticle';
@ -623,6 +664,8 @@ const details = reactive<any>({
UploadBatch: false,
/** 新增标签 */
addTagVisited: false,
/** 生成包条 */
createPackge: false,
},
/** 列表Dom节点 */
listNode: '',
@ -1414,6 +1457,35 @@ const handleDownLoadFile = () => {
downloadFileBase64(url, name);
};
/** 开启生成包条的弹窗 */
const handleCreatePackage = ({ row }) => {
details.form = { ...row, enterNum: 1 };
details.popUpShow.createPackge = true;
};
/** 生成包条 */
const handleSubmitCreatePackage = async () => {
try {
if (!details.form.enterNum) return ElMessage.warning('请输入大于零的数量');
details.popUpShow.createPackge = false;
details.loadingObj.pageLoading = true;
const res = await postCreateOrderPackage({
advanceId: details.form.id,
enterNum: details.form.enterNum,
});
const { code, data } = res.data;
if (code !== 200) return;
onLoad();
} catch (error) {
console.log('error :>> ', error);
} finally {
details.loadingObj.pageLoading = false;
}
};
onActivated(() => {
console.log('activated');
console.log('this.$store :>> ', $store);
@ -1571,4 +1643,28 @@ onActivated(() => {
:deep(.el-overlay-dialog) {
position: absolute;
}
//
.el-dialog-createPackge {
.title {
display: flex;
align-items: center;
font-weight: bold;
&::before {
content: '';
display: block;
height: 1rem;
width: 4px;
background: var(--el-color-primary);
margin-right: 5px;
}
}
}
.inputNum {
:deep(.el-input__inner) {
text-align: left !important;
}
}
</style>

16
src/views/waybill/WaybillOrderList.vue

@ -186,15 +186,15 @@
<div :id="titleId" :class="titleClass">上传回单</div>
<div class="flex-c-c">
<!-- 全屏显示按钮 -->
<el-button type="text" v-if="!details.fullscreenObj.view">
<el-icon class="" @click="handleFullScrean('open', 'el-dialog-view')"
><FullScreen
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('open', 'el-dialog-view')"
v-if="!details.fullscreenObj.view"
>
<el-icon class=""><FullScreen /></el-icon>
</el-button>
<el-button type="text" v-else>
<el-icon class="" @click="handleFullScrean('close', 'el-dialog-view')"
><CopyDocument
/></el-icon>
<el-button type="text" @click="handleFullScrean('close', 'el-dialog-view')" v-else>
<el-icon class=""><CopyDocument /></el-icon>
</el-button>
<!-- 弹窗关闭按钮 -->

40
src/views/waybill/orderPackageList.vue

@ -191,15 +191,19 @@
<h4 :id="titleId" :class="titleClass">包内产品</h4>
<div class="flex-c-c">
<!-- 全屏显示按钮 -->
<el-button type="text" v-if="!details.fullscreenObj.packageDetailColumnListVisited">
<el-icon class="" @click="handleFullScrean('open', 'packageDetailColumnListVisited')"
><FullScreen
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('open', 'packageDetailColumnListVisited')"
v-if="!details.fullscreenObj.packageDetailColumnListVisited"
>
<el-icon class=""><FullScreen /></el-icon>
</el-button>
<el-button type="text" v-else>
<el-icon class="" @click="handleFullScrean('close', 'packageDetailColumnListVisited')"
><CopyDocument
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('close', 'packageDetailColumnListVisited')"
v-else
>
<el-icon class=""><CopyDocument /></el-icon>
</el-button>
<!-- 弹窗关闭按钮 -->
@ -253,15 +257,19 @@
<h4 :id="titleId" :class="titleClass">流转节点</h4>
<div class="flex-c-c">
<!-- 全屏显示按钮 -->
<el-button type="text" v-if="!details.fullscreenObj.flowNodeColumnListVisited">
<el-icon class="" @click="handleFullScrean('open', 'flowNodeColumnListVisited')"
><FullScreen
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('open', 'flowNodeColumnListVisited')"
v-if="!details.fullscreenObj.flowNodeColumnListVisited"
>
<el-icon class=""><FullScreen /></el-icon>
</el-button>
<el-button type="text" v-else>
<el-icon class="" @click="handleFullScrean('close', 'flowNodeColumnListVisited')"
><CopyDocument
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('close', 'flowNodeColumnListVisited')"
v-else
>
<el-icon class=""><CopyDocument /></el-icon>
</el-button>
<!-- 弹窗关闭按钮 -->

40
src/views/waybill/orderPackageListDetails.vue

@ -174,15 +174,19 @@
<h4 :id="titleId" :class="titleClass">包内产品</h4>
<div class="flex-c-c">
<!-- 全屏显示按钮 -->
<el-button type="text" v-if="!details.fullscreenObj.packageDetailColumnListVisited">
<el-icon class="" @click="handleFullScrean('open', 'packageDetailColumnListVisited')"
><FullScreen
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('open', 'packageDetailColumnListVisited')"
v-if="!details.fullscreenObj.packageDetailColumnListVisited"
>
<el-icon class=""><FullScreen /></el-icon>
</el-button>
<el-button type="text" v-else>
<el-icon class="" @click="handleFullScrean('close', 'packageDetailColumnListVisited')"
><CopyDocument
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('close', 'packageDetailColumnListVisited')"
v-else
>
<el-icon class=""><CopyDocument /></el-icon>
</el-button>
<!-- 弹窗关闭按钮 -->
@ -236,15 +240,19 @@
<h4 :id="titleId" :class="titleClass">流转节点</h4>
<div class="flex-c-c">
<!-- 全屏显示按钮 -->
<el-button type="text" v-if="!details.fullscreenObj.flowNodeColumnListVisited">
<el-icon class="" @click="handleFullScrean('open', 'flowNodeColumnListVisited')"
><FullScreen
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('open', 'flowNodeColumnListVisited')"
v-if="!details.fullscreenObj.flowNodeColumnListVisited"
>
<el-icon class=""><FullScreen /></el-icon>
</el-button>
<el-button type="text" v-else>
<el-icon class="" @click="handleFullScrean('close', 'flowNodeColumnListVisited')"
><CopyDocument
/></el-icon>
<el-button
type="text"
@click="handleFullScrean('close', 'flowNodeColumnListVisited')"
v-else
>
<el-icon class=""><CopyDocument /></el-icon>
</el-button>
<!-- 弹窗关闭按钮 -->

Loading…
Cancel
Save