Browse Source

修复部分bug

dev-xx
qb 6 months ago
parent
commit
f17192ceeb
  1. 2
      src/api/basic/basicMaterial.js
  2. 58
      src/api/warehouse/warehouseWaybill.js
  3. 10
      src/views/distribution/deliverylist/distributionDeliveryListedt.vue
  4. 253
      src/views/distribution/inventory/CreateOrder.vue
  5. 42
      src/views/warehouse/warehouseWaybill.vue

2
src/api/basic/basicMaterial.js

@ -1,6 +1,6 @@
import request from '@/axios';
export const getList = params => {
export const getList = (current, size, params) => {
return request({
url: '/api/logpm-basic/material/list',
method: 'get',

58
src/api/warehouse/warehouseWaybill.js

@ -8,9 +8,9 @@ export const getList = (current, size, params) => {
...params,
current,
size,
}
})
}
},
});
};
/**
* 导出
@ -22,53 +22,55 @@ export const getWarehouseWaybillExport = row => {
url: '/logpm-warehouse/warehouseWaybill/export-exportWarehouseWaybill',
method: 'get',
params: {
...row
...row,
},
responseType: 'blob',
})
});
};
export const getDetail = (id) => {
/**
* 获取运单详情
* @param {*} params
* @returns
*/
export const getDetail = params => {
return request({
url: '/logpm-warehouse/warehouseWaybill/detail',
method: 'get',
params: {
id
}
})
}
params,
});
};
export const remove = (ids) => {
export const remove = ids => {
return request({
url: '/logpm-warehouse/warehouseWaybill/remove',
method: 'post',
params: {
ids,
}
})
}
},
});
};
export const add = (row) => {
export const add = row => {
return request({
url: '/logpm-warehouse/warehouseWaybill/submit',
method: 'post',
data: row
})
}
data: row,
});
};
export const update = (row) => {
export const update = row => {
return request({
url: '/logpm-warehouse/warehouseWaybill/submit',
method: 'post',
data: row
})
}
data: row,
});
};
export const splitOrder = (row) => {
export const splitOrder = row => {
return request({
url: '/logpm-warehouse/warehouseWaybill/splitOrder',
method: 'post',
data: row
})
}
data: row,
});
};

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

@ -639,9 +639,9 @@
<el-form-item label="文员备注">
<el-input v-model="TcForm.clerkSignRemarks" placeholder="暂无备注" />
</el-form-item>
<el-form-item label="司机备注">
<el-input v-model="TcForm.driverRemarks" placeholder="暂无备注" disabled/>
<el-input v-model="TcForm.driverRemarks" placeholder="暂无备注" disabled />
</el-form-item>
</el-form>
<div class="imgName">
@ -5560,4 +5560,10 @@ export default {
display: flex;
justify-content: space-between;
}
.my-header {
:deep(.el-icon) {
font-size: 20px;
}
}
</style>

253
src/views/distribution/inventory/CreateOrder.vue

@ -566,31 +566,38 @@
prop="goodsName"
class="el-times"
>
<el-input v-model="item.goodsName" placeholder="货物名称" disabled />
<!-- <SelectBox
ref="goodsNameRef"
className="goodsName"
:input="() => debounce(handleFindGoods(item.goodsName, item, 1), 1000)"
:focus="handleCloseSelcet"
v-model="item.goodsName"
placeholder="货物名称"
>
<div v-loading="item.loading">
<template v-if="item.goodsListOptions.length > 0">
<div
:class="{ goodsNameRow: true, active: val.goodsId === item.goodsId }"
v-for="val in item.goodsListOptions"
:key="val.goodsId"
@click="handleChooseGoods(item, val)"
>
{{ val.goodsName }}
<!-- 有数据 -->
<template v-if="details.submitType === 'haveData'">
<el-input v-model="item.goodsName" placeholder="货物名称" disabled />
</template>
<!-- 无数据 -->
<template v-else>
<SelectBox
ref="goodsNameRef"
className="goodsName"
:input="() => debounce(handleFindGoods(item.goodsName, item, 1), 1000)"
:focus="handleCloseSelcet"
v-model="item.goodsName"
placeholder="货物名称"
>
<div v-loading="item.loading">
<template v-if="item.goodsListOptions.length > 0">
<div
:class="{ goodsNameRow: true, active: val.goodsId === item.goodsId }"
v-for="val in item.goodsListOptions"
:key="val.goodsId"
@click="handleChooseGoods(item, val)"
>
{{ val.goodsName }}
</div>
</template>
<template v-else>
<div class="goodsNameRow" @click="handleCloseSelcet">暂无数据</div>
</template>
</div>
</template>
<template v-else>
<div class="goodsNameRow" @click="handleCloseSelcet">暂无数据</div>
</template>
</div>
</SelectBox> -->
</SelectBox>
</template>
</el-form-item>
<el-form-item label="件数:" label-width="fit-content" prop="num" class="el-times">
@ -674,7 +681,14 @@
<div>
<span class="mr20"> 合计 </span>
<el-button type="primary" icon="Edit" @click="handleShow"> 配置包条品类 </el-button>
<el-button
v-if="details.submitType === 'haveData'"
type="primary"
icon="Edit"
@click="handleShow"
>
配置包条品类
</el-button>
</div>
<!-- 货物名称 -->
<div>{{ details.goodsList.length }}</div>
@ -1689,176 +1703,6 @@ const details = reactive<any>({
vehicleTypeArr: [],
/** 到站地区数组 */
regionOptione: [],
/** 支付字典 */
payOption: [
{
label: '现金',
value: 1,
},
{
label: '银行卡',
value: 2,
},
{
label: '微信',
value: 3,
},
{
label: '支付宝',
value: 4,
},
{
label: '支票',
value: 5,
},
{
label: '账本',
value: 6,
},
],
/** 开单付款字典 */
paymentOption: [
{
label: '现付',
value: 1,
},
{
label: '到付',
value: 2,
},
{
label: '月结',
value: 3,
},
{
label: '回付',
value: 4,
},
{
label: '内部结算',
value: 5,
},
{
label: '多笔付',
value: 6,
},
],
/** 紧急度 */
emergencyOption: [
{
label: '正常',
value: 1,
},
{
label: '急',
value: 2,
},
{
label: '特急',
value: 3,
},
{
label: '加急',
value: 4,
},
],
/** 送货方式字典 */
shippingOption: [
{
label: '自提',
value: 1,
},
{
label: '送货',
value: 2,
},
{
label: '送货上门',
value: 3,
},
{
label: '送货上门(有电梯)',
value: 4,
},
{
label: '送货上门(无电梯)',
value: 5,
},
{
label: '送货卸货',
value: 6,
},
{
label: '送货安装',
value: 7,
},
],
/** 开单回单方式 */
receiptOption: [
{
label: '签回单',
value: 1,
},
{
label: '打收条',
value: 2,
},
{
label: '签信封',
value: 3,
},
{
label: '签回单盖章',
value: 4,
},
{
label: '1份回单',
value: 5,
},
{
label: '2份回单',
value: 6,
},
{
label: '3份回单',
value: 7,
},
{
label: '4份回单',
value: 8,
},
{
label: '5份回单',
value: 9,
},
],
/** 运输方式 */
transportationOption: [
{
label: '公路快运',
value: 1,
},
{
label: '海运',
value: 2,
},
{
label: '卡车航班',
value: 3,
},
{
label: '空运',
value: 4,
},
{
label: '普通汽班',
value: 5,
},
{
label: '快递',
value: 6,
},
],
/** 收货方 -- 收货单位 */
consigneeOptions: [],
/** 收货方 -- 收货人 */
@ -2036,24 +1880,11 @@ const details = reactive<any>({
submitData: {},
/** tab标签有无数据 */
orderStatus: 'haveData',
priceArr: [
/** 单价 */
{ name: '运费', key: 'price' },
/** 送货费 */
{ name: '配送费', key: 'deliveryFee' },
// { name: '', key: 'pickupFee' },
/** 仓库管理费 */
{ name: '仓库管理费', key: 'warehouseManagementFee' },
/** 仓储费 */
{ name: '仓库存储费', key: 'storageFee' },
/** 装卸费 */
// { name: '', key: 'storageFee' },
],
/** 提交类型 */
submitType: 'haveData' as 'haveData' | 'notHaveData',
/** 修改原因 */
causeForm: {},
/** 修改列表 */
/** 修改列表 -- 表头 */
changeColumnList: [
{
prop: 'itemName',
@ -2348,6 +2179,8 @@ const onLoad = async (idsArr = []) => {
}),
//
postFindAdvanceDetailListByAdvanceIds({ advanceIds: ids }).then(async res => {
if (details.submitType === 'notHaveData') return;
const { code, data } = res.data;
if (code !== 200) return;
details.package.data = data || [];
@ -2524,6 +2357,8 @@ const onEditLoad = async () => {
}),
//
postFindAdvanceDetailListByWaybillId({ waybillId: details.pageInfo.id }).then(async res => {
if (details.submitType === 'notHaveData') return;
const { code, data } = res.data;
if (code !== 200) return;
details.package.data = data || [];

42
src/views/warehouse/warehouseWaybill.vue

@ -413,7 +413,7 @@ import {
} from '@/api/warehouse/warehouseWaybill';
import option from '@/option/warehouse/warehouseWaybill';
import { mapGetters } from 'vuex';
import { downloadXls, handleClearTableQuery, isNumber } from '@/utils/util';
import { downloadXls, getObjType, handleClearTableQuery, isNumber } from '@/utils/util';
export default {
data() {
@ -986,20 +986,38 @@ export default {
this.form = {};
this.box = true;
},
handleEdit(row) {
this.title = '编辑';
this.box = true;
getDetail(row.row.id).then(res => {
async handleEdit({ row }) {
try {
this.loadingObj.pageLoading = true;
this.title = '编辑';
const res = await getDetail({ waybillNo: row.waybillNo });
const { code, data } = res.data;
if (code !== 200 || getObjType(data) !== 'object') return;
this.box = true;
this.form = res.data.data;
});
} catch (error) {
console.log('error :>> ', error);
} finally {
this.loadingObj.pageLoading = false;
}
},
handleView(row) {
this.title = '查看';
this.view = true;
this.box = true;
getDetail(row.row.id).then(res => {
async handleView({ row }) {
try {
this.loadingObj.pageLoading = true;
this.title = '查看';
const res = await getDetail({ waybillNo: row.waybillNo });
const { code, data } = res.data;
if (code !== 200 || getObjType(data) !== 'object') return;
this.box = true;
this.form = res.data.data;
});
} catch (error) {
console.log('error :>> ', error);
} finally {
this.loadingObj.pageLoading = false;
}
},
handleDelete() {
if (this.selectionList.length === 0) {

Loading…
Cancel
Save