qb 5 months ago
parent
commit
a076fe447c
  1. 8
      src/api/aftersales/aftersalesWorkOrder.js
  2. 9
      src/api/basicdata/ThreePartyMallManagement.js
  3. 220
      src/option/aftersales/vueTvemp.js
  4. 72
      src/option/basicdata/ThreePartyMallManagement.js
  5. 4
      src/views/aftersales/aftersalesWorkOrder.vue
  6. 241
      src/views/aftersales/aftersalesWorkOrderAdd.vue
  7. 30
      src/views/aftersales/aftersalesWorkOrderTemp.vue
  8. 436
      src/views/basicdata/brand/ThreePartyMallManagement.vue
  9. 8
      src/views/distribution/inventory/distrilbutionBillLadingView.vue
  10. 79
      src/views/warehouse/warehousingentry/warehouseWarehouseingAddReceipt.vue

8
src/api/aftersales/aftersalesWorkOrder.js

@ -548,4 +548,12 @@ export const $_exportaftersalesOvertimeFine = (params) => {
params,
responseType: 'blob',
})
}
// 干线查询
export const $_getAdvanceAbnormalPackage = (params) => {
return request({
url: '/api/logpm-aftersales/aftersalesAbnormalPackage/getAdvanceAbnormalPackage',
method: 'get',
params
})
}

9
src/api/basicdata/ThreePartyMallManagement.js

@ -0,0 +1,9 @@
import request from '@/axios';
export const $_pageList = params => {
return request({
url: '/api/logpm-basicdata/basicdataTripartiteMall/pageList',
method: 'get',
params,
});
};

220
src/option/aftersales/vueTvemp.js

@ -41,17 +41,17 @@ export const columnList = [
sortable: true,
head: false,
},
{
prop: 'a',
label: '工单创建仓',
type: 1,
values: '',
width: '140',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
// {
// prop: 'a',
// label: '工单创建仓',
// type: 1,
// values: '',
// width: '140',
// checkarr: [],
// fixed: false,
// sortable: true,
// head: false,
// },
{
prop: 'workOrderNumber',
label: '异常工单号',
@ -163,17 +163,17 @@ export const columnList = [
sortable: true,
head: false,
},
{
prop: 'a',
label: '责任方',
type: 1,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
// {
// prop: 'a',
// label: '责任方',
// type: 1,
// values: '',
// width: '150',
// checkarr: [],
// fixed: false,
// sortable: true,
// head: false,
// },
{
prop: 'createTime',
label: '工单创建时间',
@ -185,72 +185,72 @@ export const columnList = [
sortable: true,
head: false,
},
{
prop: 'a',
label: '工单最晚处理时间',
type: 1,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'a',
label: '工单最新处理时间',
type: 1,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'a',
label: '处理结果',
type: 1,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'a',
label: '处理结果—理赔金额',
type: 1,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'a',
label: '营业部处理客服',
type: 1,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'a',
label: '总部处理客服',
type: 1,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
// {
// prop: 'a',
// label: '工单最晚处理时间',
// type: 1,
// values: '',
// width: '150',
// checkarr: [],
// fixed: false,
// sortable: true,
// head: false,
// },
// {
// prop: 'a',
// label: '工单最新处理时间',
// type: 1,
// values: '',
// width: '150',
// checkarr: [],
// fixed: false,
// sortable: true,
// head: false,
// },
// {
// prop: 'a',
// label: '处理结果',
// type: 1,
// values: '',
// width: '150',
// checkarr: [],
// fixed: false,
// sortable: true,
// head: false,
// },
// {
// prop: 'a',
// label: '处理结果—理赔金额',
// type: 1,
// values: '',
// width: '150',
// checkarr: [],
// fixed: false,
// sortable: true,
// head: false,
// },
// {
// prop: 'a',
// label: '营业部处理客服',
// type: 1,
// values: '',
// width: '150',
// checkarr: [],
// fixed: false,
// sortable: true,
// head: false,
// },
// {
// prop: 'a',
// label: '总部处理客服',
// type: 1,
// values: '',
// width: '150',
// checkarr: [],
// fixed: false,
// sortable: true,
// head: false,
// },
{
prop: 'overTime',
@ -263,28 +263,28 @@ export const columnList = [
sortable: true,
head: false,
},
{
prop: 'a',
label: '是否申诉',
type: 1,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'a',
label: '申诉状态',
type: 1,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
// {
// prop: 'a',
// label: '是否申诉',
// type: 1,
// values: '',
// width: '150',
// checkarr: [],
// fixed: false,
// sortable: true,
// head: false,
// },
// {
// prop: 'a',
// label: '申诉状态',
// type: 1,
// values: '',
// width: '150',
// checkarr: [],
// fixed: false,
// sortable: true,
// head: false,
// },
{
prop: 'processNumber',
label: '钉钉号',

72
src/option/basicdata/ThreePartyMallManagement.js

@ -0,0 +1,72 @@
export const columnList = [
{
prop: '',
label: '复选框',
type: 0,
width: 55,
fixed: true,
},
{
prop: '',
label: '序号',
type: 12,
values: '',
width: 55,
fixed: true,
},
{
prop: 'clientName',
label: '客户名称',
type: 1,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'tripartiteMall',
label: '商场名称',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'tripartiteCoding',
label: '商场编码',
type: 2,
values: '',
width: '150',
checkarr: [],
fixed: false,
sortable: true,
head: false,
},
{
prop: 'typeServiceNameS',
label: '配送类型',
type: 1,
values: '',
width: '150',
checkarr: [
],
fixed: false,
sortable: true,
head: false,
},
{
prop: '',
label: '操作',
type: 6,
values: '',
width: '80',
checkarr: [],
fixed: 'right',
sortable: false,
},
];

4
src/views/aftersales/aftersalesWorkOrder.vue

@ -1503,7 +1503,7 @@ const ButtonPermissions = computed(() => {
return {
add: false, //
batchReject: UserPermissions.value == '总部客服', //
assignment: false, //
assignment: true, //
applyArbitration: false, //
DingTalkNumber: false, //
batchFinish: false, //
@ -1520,7 +1520,7 @@ const ButtonPermissions = computed(() => {
return {
add: false, //
batchReject: false, //
assignment: false, //
assignment: true, //
applyArbitration: false, //
batchFinish: false, //
appeal: false, //

241
src/views/aftersales/aftersalesWorkOrderAdd.vue

@ -481,10 +481,9 @@
</el-form-item>
<el-form-item
label="占比(%)"
label="金额(元)"
:prop="`responsibilitiesList[${index}.responsibilityRatio]`"
:rules="ruleForm.responsibilityRatio"
@change="CompanyProportionInput"
>
<el-input-number
v-model="item.responsibilityRatio"
@ -538,11 +537,11 @@
<div></div>
</template>
</div>
<div class="el_top">
<!-- <div class="el_top">
<div class="el_Package_num">
<span>公司占比:{{ form.Proportion }}(%)</span>
</div>
</div>
</div> -->
</el-tab-pane>
</el-tabs>
@ -738,6 +737,7 @@ import {
$_getBusinessDepartmentUser,
$_getAbnormalPackage,
$_shippingInformation,
$_getAdvanceAbnormalPackage,
} from '@/api/aftersales/aftersalesWorkOrder';
import { useRouter, useRoute } from 'vue-router';
import { getDetailWarehouse, getDeptWarehouse } from '@/api/basicdata/basicdataWarehouse'; //
@ -816,20 +816,39 @@ const ruleForm = reactive({
deliverGoodsTime: [{ required: true, message: '请输入发货时间', trigger: ['blur', 'change'] }],
warehousingTime: [{ required: true, message: '请选择入库时间', trigger: ['blur', 'change'] }],
discoveryTime: [{ required: true, message: '请选择发现时间', trigger: ['blur', 'change'] }],
waybillMall: [{ required: true, message: '请输入运单商场', trigger: ['blur'] }],
waybillMall: [
{ required: true, message: '请输入运单商场', trigger: ['blur'] },
{ max: 20, message: '运单商场最多20位', trigger: 'change' },
],
typeServiceName: [{ required: false, message: '请输入合作模式', trigger: ['blur', 'change'] }],
investigationProcess: [
{ required: true, message: '请输入调查经过', trigger: ['blur', 'change'] },
{ max: 200, message: '调查经过最多200位', trigger: 'change' },
],
result: [{ required: false, message: '请输选择处理结果', trigger: ['blur'] }],
processor: [{ required: true, message: '请选择处理方', trigger: ['blur'] }],
processorEntityList: [{ required: true, message: '请选择责任方', trigger: ['blur'] }],
},
packageCode: [{ required: true, message: '请输入包条码', trigger: ['blur', 'change'] }],
waybillNumber: [{ required: true, message: '请输入运单号', trigger: ['blur', 'change'] }],
orderCode: [{ required: true, message: '请输入订单自编号', trigger: ['blur', 'change'] }],
first: [{ required: false, message: '请输入一级品', trigger: ['blur', 'change'] }],
secondary: [{ required: false, message: '请输入二级品', trigger: ['blur', 'change'] }],
packageCode: [
{ required: true, message: '请输入包条码', trigger: ['blur', 'change'] },
{ max: 64, message: '包条码最多64位', trigger: 'change' },
],
waybillNumber: [
{ required: true, message: '请输入运单号', trigger: ['blur', 'change'] },
{ max: 30, message: '运单号最多30位', trigger: 'change' },
],
orderCode: [
{ required: true, message: '请输入订单自编号', trigger: ['blur', 'change'] },
{ max: 30, message: '订单自编号最多30位', trigger: 'change' },
],
first: [
{ required: false, message: '请输入一级品', trigger: ['blur', 'change'] },
{ max: 10, message: '订单自编号最多10位', trigger: 'change' },
],
secondary: [
{ required: false, message: '请输入二级品', trigger: ['blur', 'change'] },
{ max: 10, message: '订单自编号最多10位', trigger: 'change' },
],
brandName: [{ required: false, message: '请输入品牌', trigger: ['blur', 'change'] }],
businessId: [{ required: true, message: '请选择责任方', trigger: ['blur', 'change'] }],
personResponsibleId: [{ required: true, message: '请输入责任人', trigger: ['blur', 'change'] }],
@ -932,6 +951,7 @@ const PackageListReset = async () => {
orderCode: '', //
first: '', //
secondary: '', //
thirdProduct: '', //
brandName: '', //
history: false, //
id: 1,
@ -1032,6 +1052,7 @@ const Addpackages = () => {
orderCode: '', //
first: '', //
secondary: '', //
thirdProduct: '', //
brandName: '', //
history: false, //
HistoricalPackageList: [], //
@ -1218,13 +1239,33 @@ const resetFormData = () => {
//
const ChangePackageInfo = async item => {
if (!form.value.basis.workOrderType || !form.value.basis.discoveryNode) {
const messages = [];
if (!form.value.basis.workOrderType) {
messages.push('【异常类型】');
}
if (!form.value.basis.discoveryNode) {
messages.push('【发现节点】');
}
ElMessage({
message: `请先选择${messages.join('和')}`,
type: 'warning',
plain: true,
});
item.packageCode = '';
return;
}
console.log(item, 'item');
if (!item.packageCode) {
item.waybillNumber = ''; //
item.orderCode = ''; //
item.first = ''; //
item.secondary = ''; //
item.brandName = ''; //
(item.thirdProduct = ''), //
(item.brandName = ''); //
let data = form.value.PackageList.find(res => res.packageCode); //
if (!data) {
form.value.basis.waybillMall = ''; //
@ -1236,7 +1277,8 @@ const ChangePackageInfo = async item => {
item.orderCode = ''; //
item.first = ''; //
item.secondary = ''; //
item.brandName = ''; //
(item.thirdProduct = ''), //
(item.brandName = ''); //
if (form.value.PackageList == 1) {
form.value.basis.waybillMall = ''; //
form.value.basis.typeServiceName = ''; //
@ -1264,99 +1306,109 @@ const ChangePackageInfo = async item => {
packageCode: item.packageCode, //
};
form.value.Pageloading = true; //
$_getAbnormalPackage(data)
.then(async res => {
console.log(res, '查询包条');
let packageData = {};
if (res.data.code == 200 && res.data && res.data.data.length) {
form.value.Pageloading = false; //
packageData = res.data.data[0]; //,
//
let state = await form.value.PackageList.find(res => res.orderCode || res.brandName);
if (state) {
if (
state.orderCode != packageData.orderCode ||
state.waybillNumber != packageData.waybillNumber
) {
ElMessage({
message: '请选择相同订单自编和运单号的包条码',
type: 'warning',
});
return;
}
}
let res = null;
try {
if (form.value.basis.discoveryNode == 3) {
res = await $_getAdvanceAbnormalPackage(data);
console.log(res, '干线查询包条');
} else {
res = await $_getAbnormalPackage(data);
}
} catch (e) {
console.log(e, 'error');
} finally {
form.value.Pageloading = false; //
}
console.log(res, '查询包条');
let packageData = {};
if (res.data.code == 200 && res.data && res.data.data.length) {
form.value.Pageloading = false; //
packageData = res.data.data[0]; //,
//
let state = await form.value.PackageList.find(res => res.orderCode || res.brandName);
if (state) {
if (
state.orderCode != packageData.orderCode ||
state.waybillNumber != packageData.waybillNumber
) {
ElMessage({
message: '查询成功',
type: 'success',
});
item.waybillNumber = packageData.waybillNumber || ''; //
item.orderCode = packageData.orderCode || ''; //
item.first = packageData.firsts || ''; //
item.secondary = packageData.second || ''; //
item.brandName = packageData.brandName || ''; //
form.value.basis.waybillMall = packageData.mallName || ''; //
form.value.basis.typeServiceName = packageData.typeServiceName || ''; //
// ,
const results = res.data.data.filter(item => {
return item.workOrderId && item.workOrderNumber;
message: '请选择相同订单自编和运单号的包条码',
type: 'warning',
});
//
if (results.length) {
item.history = true;
item.HistoricalPackageList = results;
} else {
item.history = false;
}
console.log(form.value.basis.discoveryNode, 'form.value.discoveryNode');
// (线线)
if (['3'].includes(form.value.basis.discoveryNode)) {
let addedTrainNumbers = []; //
res.data.data.forEach(item => {
if (item.trunklines && item.trunklines.length) {
item.trunklines.forEach(itemChid => {
if (!addedTrainNumbers.includes(itemChid.trainNumber)) {
form.value.Trainoptions.push({
trainNumber: itemChid.trainNumber, //
vehicleRoute: itemChid.vehicleRoute, // 线
});
addedTrainNumbers.push(itemChid.trainNumber);
}
return;
}
}
ElMessage({
message: '查询成功',
type: 'success',
});
item.waybillNumber = packageData.waybillNumber || ''; //
item.orderCode = packageData.orderCode || ''; //
item.first = packageData.firsts || ''; //
item.secondary = packageData.second || ''; //
item.thirdProduct = packageData.thirdProduct || ''; //
item.brandName = packageData.brandName || ''; //
form.value.basis.waybillMall = packageData.mallName || ''; //
form.value.basis.typeServiceName = packageData.typeServiceName || ''; //
// ,
const results = res.data.data.filter(item => {
return item.workOrderId && item.workOrderNumber;
});
//
if (results.length) {
item.history = true;
item.HistoricalPackageList = results;
} else {
item.history = false;
}
console.log(form.value.basis.discoveryNode, 'form.value.discoveryNode');
// (线线)
if (['3'].includes(form.value.basis.discoveryNode)) {
let addedTrainNumbers = []; //
form.value.Trainoptions = [];
res.data.data.forEach(item => {
if (item.trunklines && item.trunklines.length) {
item.trunklines.forEach(itemChid => {
if (!addedTrainNumbers.includes(itemChid.trainNumber)) {
form.value.Trainoptions.push({
trainNumber: itemChid.trainNumber, //
vehicleRoute: itemChid.vehicleRoute, // 线
});
addedTrainNumbers.push(itemChid.trainNumber);
}
});
console.log(form.value.Trainoptions, 'form.value.Trainoptions');
}
//
if (['5'].includes(form.value.basis.discoveryNode)) {
let addedTrainNumbers = []; //
res.data.data.forEach(item => {
if (item.deliver && item.deliver.length) {
item.deliver.forEach(itemChid => {
if (!addedTrainNumbers.includes(itemChid.trainNumber)) {
form.value.deliver.push({
driverName: itemChid.driverName, //
taskTime: itemChid.taskTime, //
trainNumber: itemChid.trainNumber, //
});
addedTrainNumbers.push(itemChid.trainNumber);
}
});
console.log(form.value.Trainoptions, 'form.value.Trainoptions');
}
//
if (['5'].includes(form.value.basis.discoveryNode)) {
let addedTrainNumbers = []; //
res.data.data.forEach(item => {
if (item.deliver && item.deliver.length) {
form.value.deliver = [];
item.deliver.forEach(itemChid => {
if (!addedTrainNumbers.includes(itemChid.trainNumber)) {
form.value.deliver.push({
driverName: itemChid.driverName, //
taskTime: itemChid.taskTime, //
trainNumber: itemChid.trainNumber, //
});
addedTrainNumbers.push(itemChid.trainNumber);
}
});
console.log(form.value.Trainoptions, 'form.value.Trainoptions');
}
} else {
form.value.Pageloading = false; //
ElMessage({
message: '暂无查询内容,请检查参数是否正确!',
type: 'warning',
});
}
})
.catch(error => {
console.log(error, 'error');
form.value.Pageloading = false; //
});
console.log(form.value.Trainoptions, 'form.value.Trainoptions');
}
} else {
form.value.Pageloading = false; //
ElMessage({
message: '暂无查询内容,请检查参数是否正确!或【手动录入信息】',
type: 'warning',
});
}
};
//
const Viewdetails = value => {
@ -1502,6 +1554,7 @@ const onSubmit = () => {
orderCode: item.orderCode, //
first: item.first, //
secondary: item.secondary, //
thirdProduct: item.thirdProduct, //
brandName: item.brandName, //
});
});

30
src/views/aftersales/aftersalesWorkOrderTemp.vue

@ -728,7 +728,7 @@ const ButtonPermissions = computed(() => {
Financial_accounting: false, //
Result_review: UserPermissions.value == Useridentity.Headquarters_customer_service, //
defaultassignments: false, //
export_Report: false, //
export_Report: true, //
Timed_outexport: false, //
};
case 2: //
@ -745,7 +745,7 @@ const ButtonPermissions = computed(() => {
Result_review: false, //
Financial_accounting: false, //
defaultassignments: false, //
export_Report: false, //
export_Report: true, //
Timed_outexport: false, //
};
case 3: //
@ -762,7 +762,7 @@ const ButtonPermissions = computed(() => {
Result_review: false, //
Financial_accounting: false, //
defaultassignments: false, //
export_Report: false, //
export_Report: true, //
Timed_outexport: false, //
};
case 4: //
@ -779,7 +779,7 @@ const ButtonPermissions = computed(() => {
Financial_accounting: false, //
Result_review: false, //
defaultassignments: false, //
export_Report: false, //
export_Report: true, //
Timed_outexport: false, //
};
case 5: //
@ -796,7 +796,7 @@ const ButtonPermissions = computed(() => {
Financial_accounting: false, //
Result_review: false, //
defaultassignments: false, //
export_Report: false, //
export_Report: true, //
Timed_outexport: false, //
};
case 6: //
@ -813,7 +813,7 @@ const ButtonPermissions = computed(() => {
Financial_accounting: UserPermissions.value != Useridentity.Warehouse_customer_service, //
defaultassignments: false, //
Result_review: false, //
export_Report: false, //
export_Report: true, //
Timed_outexport: false, //
};
case 7: //
@ -844,7 +844,7 @@ const ButtonPermissions = computed(() => {
ArbitrationDetermination: false, //
Financial_accounting: false, //
defaultassignments: false, //
export_Report: false, //
export_Report: true, //
Result_review: false, //
Timed_outexport: false, //
};
@ -860,6 +860,22 @@ const ButtonPermissions = computed(() => {
ArbitrationDetermination: false, //
Financial_accounting: false, //
defaultassignments: false, //
export_Report: true, //
Result_review: false, //
Timed_outexport: false, //
};
case 10: //
return {
add: false, //
batchReject: false, //
assignment: false, //
applyArbitration: false, //
batchFinish: false, //
Batchdetermination: false, //
ManagerConfirmed:false, //
ArbitrationDetermination: false, //
Financial_accounting: false, //
defaultassignments: false, //
export_Report: false, //
Result_review: false, //
Timed_outexport: false, //

436
src/views/basicdata/brand/ThreePartyMallManagement.vue

@ -0,0 +1,436 @@
<template>
<basic-container>
<!-- 首页表格 -->
<div class="avue-crud" v-loading="loadingObj.packageListLoading">
<!-- 搜索模块 -->
<div v-h5uShow="search">
<!-- 查询模块 -->
<el-form :inline="true" :model="query" class="el-fr-d">
<!-- 查询按钮 -->
<el-form-item class="el-btn">
<el-button type="primary" icon="el-icon-search" @click="searchChange"> </el-button>
<el-button icon="el-icon-delete" @click="searchReset()"> </el-button>
</el-form-item>
</el-form>
</div>
<!-- 控件模块 -->
<el-row>
<div class="avue-crud__header">
<!-- 头部左侧按钮模块 -->
<div class="avue-crud__left"></div>
<!-- 头部右侧按钮模块 -->
<div class="avue-crud__right">
<el-button icon="el-icon-refresh" @click="searchChangeS" circle></el-button>
<el-button icon="Operation" @click="showdrawer(true)" circle></el-button>
<el-button icon="Search" @click="searchHide" circle></el-button>
</div>
</div>
</el-row>
<!-- 首页表格 -->
<el-row>
<!-- 列表模块 -->
<tablecmt
class="tableNode"
:columnList="details.columnList"
:tableData="data"
:loading="loadingObj.list"
@inputTxt="inputsc"
@timeCheck="timesc"
@selectCheck="selectsc"
@selection="selectionChange"
>
<template #default="slotProps">
<template v-if="slotProps.scope.column.label === '操作'">
<div class="ElBtnClass">
<el-text @click="edit(slotProps.scope.row)">编辑</el-text>
<el-text @click="ViewDelete(slotProps.scope.row)">删除</el-text>
</div>
</template>
</template>
</tablecmt>
</el-row>
<!-- 分页模块 -->
<el-row class="el-fy">
<div class="avue-crud__pagination flex-c-sb" style="width: 100%">
<div></div>
<el-pagination
align="right"
background
@size-change="sizeChange"
@current-change="currentChange"
:current-page="page.currentPage"
:page-sizes="[30, 50, 80, 120]"
:page-size="page.pageSize"
layout="total, sizes, prev, pager, next, jumper"
:total="page.total"
>
</el-pagination>
</div>
</el-row>
</div>
<el-dialog title="编辑" v-model="malldialog" width="50%" append-to-body>
<el-form :model="form" label-width="80px" :disabled="loadingObj.list">
<el-form-item label="三方商城">
<el-input v-model.trim="form.tripartiteMall" placeholder="请输入三方商城" />
</el-form-item>
<el-form-item label="三方编码">
<el-input v-model.trim="form.tripartiteCoding" placeholder="请输入三方编码" />
</el-form-item>
<el-form-item label="品牌">
<el-select
v-model="form.brandId"
filterable
remote
:remote-method="remoteMethod"
class="m-2"
placeholder="请选择品牌"
clearable
>
<el-option
v-for="item in brandList"
:key="item.value"
:label="item.label"
:value="item.value"
/>
</el-select>
</el-form-item>
</el-form>
<!-- 表单按钮 -->
<template #footer>
<span v-if="!view" class="dialog-footer">
<el-button
type="primary"
icon="el-icon-circle-check"
:disabled="loadingObj.list"
@click="handleSubmit"
> </el-button
>
<el-button icon="el-icon-circle-close" @click="box = false"> </el-button>
</span>
</template>
</el-dialog>
</basic-container>
<!-- 列表配置显示 -->
<edittablehead
@setcolum="setnewcolum"
@closce="showdrawer"
:drawerShow="drawerShow"
:columnList="details.columnList"
v-model="details.columnList"
></edittablehead>
</template>
<script setup>
import { ref, reactive, toRefs, computed, onMounted, nextTick, watch } from 'vue';
import { columnList } from '@/option/basicdata/ThreePartyMallManagement.js';
import { $_pageList } from '@/api/basicdata/ThreePartyMallManagement';
import { getDetail, update, remove } from '@/api/basicdata/basicdataTripartiteMall';
import { getList as getBrandList } from '@/api/basicdata/basicBrand';
import { processRowPropertyName, setNodeHeight } from '@/utils/util';
import { ElMessageBox, ElMessage } from 'element-plus';
import { downloadXls, handleClearTableQuery } from '@/utils/util';
import { useStore } from 'vuex';
import { getDictionaryBiz } from '@/api/system/dict';
import dayjs from 'dayjs';
const $router = useRouter(); //
const $useStore = useStore(); //
const $route = useRoute(); //
const DeliveryType = ref([]); //
const brandList = ref([]); //
const form = ref({});
const malldialog = ref(false);
const details = reactive({
/** 是否开启搜索 */
search: false,
/** 表格搜索条件 */
query: {},
defaultTime2: [new Date(2000, 1, 1, 0, 0, 0), new Date(2000, 2, 1, 23, 59, 59)], // '12:00:00', '08:00:00'
/** 时间快捷选择设置 */
shortcuts: [
{
text: '最近一周',
value: () => {
const end = new Date();
const start = new Date();
start.setTime(start.getTime() - 3600 * 1000 * 24 * 7);
return [start, end];
},
},
{
text: '最近一个月',
value: () => {
const end = new Date();
const start = new Date();
start.setTime(start.getTime() - 3600 * 1000 * 24 * 30);
return [start, end];
},
},
{
text: '最近三个月',
value: () => {
const end = new Date();
const start = new Date();
start.setTime(start.getTime() - 3600 * 1000 * 24 * 90);
return [start, end];
},
},
],
/** 时间选择器数据 */
stockupDate: [],
/** 列表 */
columnList,
/** 列表数据 */
data: [],
/** 页面loading */
loadingObj: {
/** 列表加载loading */
list: false,
packageListLoading: false,
},
/** 列表复选框选中的数据 */
selectionList: [],
/** 是否显示设置表格 */
drawerShow: false,
/** 分页参数 */
page: {
currentPage: 1,
pageSize: 50,
total: 0,
},
/** 弹出层显示 */
popUpShow: {
/** 包件明细 */
packageOrderListlVisited: false,
/** 二维码 */
QRCodeVisible: false,
/** 修改客户信息 */
editClientInfoVisible: false,
},
/** 列表Dom节点 */
listNode: '',
form: {},
/** 全屏 */
fullscreenObj: {
/** 包明细 */
packageOrderListlVisited: false,
},
});
const {
search,
query,
shortcuts,
stockupDate,
data,
loadingObj,
selectionList,
drawerShow,
page,
trickleLoadingPage,
zeroAdditionalRecordingInfo,
popUpShow,
recorddata,
defaultTime2,
} = toRefs(details);
/** 展开列表控件 */
const showdrawer = _flag => {
details.drawerShow = _flag;
};
/** 表格表头输入框搜索 */
const inputsc = (index, row) => {
processRowPropertyName(index, row, details.query);
onLoad();
};
/** 表格表头时间选择 */
const timesc = (index, row) => {
console.log(index, row);
if (!!index) {
index = dayjs(index).format('YYYY-MM-DD');
}
details.query[row.prop] = index;
if (!index) {
delete details.query[row.prop];
}
onLoad();
};
/** 表格表头下拉框选择 */
const selectsc = (index, row) => {
processRowPropertyName(index, row, details.query);
onLoad();
};
/** 表格表头复选框选择 */
const selectionChange = list => {
console.log(list);
details.selectionList = list;
};
//
const searchChange = () => {
onLoad();
};
//
const sizeChange = val => {
details.page.pageSize = val;
onLoad();
};
/** 页码改变执行的回调 */
const currentChange = val => {
details.page.currentPage = val;
onLoad();
};
//
const searchChangeS = () => {
details.search = false; //
onLoad();
};
//
const searchReset = () => {
details.query = {};
details.page.currentPage = 1;
handleClearTableQuery(details.columnList);
onLoad();
};
//
const searchHide = () => {
console.log(details);
details.search = !details.search;
const _node = document.querySelector('.tableNode');
setNodeHeight(_node, '', true);
};
const remoteMethod = value => {
getBrandList(1, 1000, { brandName: value }).then(res => {
console.log('res ===>', res);
const {
code,
data: { records },
} = res.data;
if (code !== 200) return;
brandList.value = records.map(val => {
return {
value: val.id,
label: val.brandName,
};
});
});
};
//
function updateDictionary(targetArray, dictionaryType) {
getDictionaryBiz(dictionaryType).then(res => {
console.log(res, '字典');
res.data.data.forEach(item => {
targetArray.push({
value: item.dictKey,
label: item.dictValue,
});
});
return;
});
}
//
const Dictionaryrequest = async () => {
await updateDictionary(DeliveryType.value, 'distribution_type');
};
const Dictionaryprocessing = data => {
if (data?.length) {
data.forEach(item => {
if (['1', '2', '3', '4'].includes(item.typeService)) {
item.typeServiceNameS = DeliveryType.value.find(i => i.value == item.typeService)?.label;
}
});
}
};
//
const onLoad = async () => {
details.loadingObj.list = true;
let submitData = {
current: details.page.currentPage,
size: details.page.pageSize,
...details.query,
};
let _res = await $_pageList(submitData);
details.loadingObj.list = false;
const { code, data } = _res.data;
if (code != 200) {
return;
}
details.data = data.records;
Dictionaryprocessing(details.data);
details.page.total = data.total;
console.log(_res, 'res');
};
const onLoadPage = async () => {
details.loadingObj.list = true;
await Dictionaryrequest();
onLoad();
};
//
onLoadPage();
//
const edit = async row => {
let res = await getDetail(row.id);
malldialog.value = true;
form.value = res.data.data;
console.log(res);
};
const handleSubmit = async () => {
const submitForm = form.value;
submitForm.brandName = brandList.value.find(item => item.value == form.value.brandId)?.label;
let _res = await update(submitForm);
if (_res.data.code == 200) {
malldialog.value = false;
ElMessage.success('编辑成功');
onLoad();
}
};
//
const ViewDelete = () => {
ElMessageBox.confirm('是否确认删除数据?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning',
})
.then(async () => {
details.loadingObj.list = true;
let res = await remove(row.id);
details.loadingObj.list = false;
if (res.data.code == 200) {
ElMessage.success('删除成功');
onLoad();
}
})
.catch(() => {});
};
</script>
<style scoped lang="scss">
.ElBtnClass button {
border: none;
padding: 0;
background-color: transparent;
}
:deep(.el-card) {
height: 100%;
}
:deep(.el-card__body) {
height: 100%;
display: flex;
flex-direction: column;
}
.el-fy {
flex: 1;
display: flex;
align-items: flex-end;
}
.avue-crud {
height: 100%;
display: flex;
flex-direction: column;
}
</style>

8
src/views/distribution/inventory/distrilbutionBillLadingView.vue

@ -1948,6 +1948,14 @@ export default {
onLoad() {
//
if (!!this.$route.query.id) {
if (this.siginImgList?.length) {
this.siginImgList.forEach(item => {
if (item.imgList?.length) {
item.imgList = [];
}
});
}
this.loading = true;
let id = this.$route.query.id;
getViewDetailOwn(id).then(res => {

79
src/views/warehouse/warehousingentry/warehouseWarehouseingAddReceipt.vue

@ -258,7 +258,7 @@
</el-table>
</el-row>
<div
class="drawer-footer"
class="drawer-footer"
style="line-height: 20px; text-align: center; padding-top: 10px"
v-if="!typeView || this.$route.query.type == '3'"
>
@ -334,49 +334,50 @@
:rules="rules"
>
<!-- 表单字段 -->
<el-form-item label="SKU" prop="sku">
<el-input v-model="formDetail.sku" placeholder="请输入SKU" />
</el-form-item>
<el-form-item label="物品名称" prop="productName">
<!-- <el-input v-model="formDetail.productName" placeholder="请输入物品名称"/>-->
<el-form-item label="物品编码" prop="productCode">
<!-- <el-input v-model="formDetail.productCode" placeholder="请输入物品编码"/>-->
<el-select
v-model="formDetail.productName"
v-model="formDetail.productCode"
filterable
remote
reserve-keyword
remote-show-suffix
:remote-method="remoteMethodStuffName"
@change="getMenDianName($event, 1)"
placeholder="请输入物品名称"
:remote-method="remoteMethodStuffCode"
@change="getMenDianName($event, 2)"
placeholder="请输入物品编码"
>
<el-option
v-for="item in stuffName"
v-for="item in stuffCode"
:key="item.value"
:label="item.label"
:value="item.value"
/>
</el-select>
</el-form-item>
<el-form-item label="物品编码" prop="productCode">
<!-- <el-input v-model="formDetail.productCode" placeholder="请输入物品编码"/>-->
<el-form-item label="物品名称" prop="productName">
<!-- <el-input v-model="formDetail.productName" placeholder="请输入物品名称"/>-->
<el-select
v-model="formDetail.productCode"
v-model="formDetail.productName"
filterable
remote
reserve-keyword
remote-show-suffix
:remote-method="remoteMethodStuffCode"
@change="getMenDianName($event, 2)"
placeholder="请输入物品编码"
:remote-method="remoteMethodStuffName"
@change="getMenDianName($event, 1)"
placeholder="请输入物品名称"
>
<el-option
v-for="item in stuffCode"
v-for="item in stuffName"
:key="item.value"
:label="item.label"
:value="item.value"
/>
</el-select>
</el-form-item>
<el-form-item label="SKU" prop="sku">
<el-input v-model="formDetail.sku" placeholder="请输入SKU" disabled />
</el-form-item>
<el-form-item label="物品单位" prop="productUnit">
<!-- <el-input v-model="formDetail.productUnit" placeholder="请输入物品单位"/>-->
<el-select
@ -386,6 +387,7 @@
reserve-keyword
remote-show-suffix
placeholder="请输入物品单位"
disabled
>
<el-option
v-for="item in distributionUnit"
@ -396,10 +398,14 @@
</el-select>
</el-form-item>
<el-form-item label="包装数量" prop="packagingNumber">
<el-input v-model="formDetail.packagingNumber" placeholder="请输入包装数量" />
<el-input v-model="formDetail.packagingNumber" placeholder="请输入包装数量" disabled />
</el-form-item>
<el-form-item label="包装规格">
<el-input v-model="formDetail.packagingSpecifications" placeholder="请输入包装规格" />
<el-input
v-model="formDetail.packagingSpecifications"
placeholder="请输入包装规格"
disabled
/>
</el-form-item>
<el-form-item label="产品品牌" prop="brandId">
<!-- <el-input v-model="formDetail.actualReceipt" placeholder="请选择物资品牌"/>-->
@ -497,8 +503,7 @@ export default {
total: 40,
},
//
form: {
},
form: {},
formDetail: {},
//
selectionList: [],
@ -1004,13 +1009,13 @@ export default {
getDictionaryBiz('distribution_type').then(res => {
// console.log("...",res.data.data);
this.distributionType = [];
this.distributionType= res.data.data.map(item=>{
if(item.dictKey=='2'){
console.log(item,'item==???/');
return item
}
})
this.form.serviceType='2'
this.distributionType = res.data.data.map(item => {
if (item.dictKey == '2') {
console.log(item, 'item==???/');
return item;
}
});
this.form.serviceType = '2';
// this.distributionType
});
getDictionaryBiz('logpm_unit').then(res => {
@ -1061,7 +1066,7 @@ export default {
message: '操作成功!',
});
this.form = {};
this.form.serviceType='2'
this.form.serviceType = '2';
this.data = [];
} else {
this.$message.warning('请添加物资详情!!!');
@ -1072,7 +1077,7 @@ export default {
this.form.totalInput = null;
}
this.form.type = '1';
this.form.serviceType='2'
this.form.serviceType = '2';
this.form.list = this.data;
await update(this.form);
this.box = false;
@ -1113,7 +1118,7 @@ export default {
});
});
this.form = {};
this.form.serviceType='2'
this.form.serviceType = '2';
this.data = [];
//
this.$store.commit('DEL_TAG', this.$store.state.tags.tag);
@ -1351,10 +1356,10 @@ export default {
width: 25vw;
min-width: 20vw;
}
.drawer-footer{
position: fixed;
bottom: 10px;
left: 50%;
z-index: 999;
.drawer-footer {
position: fixed;
bottom: 10px;
left: 50%;
z-index: 999;
}
</style>

Loading…
Cancel
Save