Browse Source

Merge branch 'dev' of http://47.108.105.48:3000/java_project/logpm_page into dev

fix_bug_pro20231227
13208366016 1 year ago
parent
commit
6bae9b5e02
  1. 8
      src/store/getters.js
  2. 139
      src/views/distribution/checkInventoryTask/createTask.vue
  3. 26
      src/views/distribution/inventory/delivery/distributionStockArticleMarket.vue
  4. 17
      src/views/distribution/inventory/distrilbutionBillLading.vue

8
src/store/getters.js

@ -19,7 +19,13 @@ const getters = {
.filter(ele => {
return (ele.meta || {}).keepAlive;
})
.map(ele => ele.fullPath);
.map(ele => {
console.log('ele :>> ', ele);
const path = ele.path;
const reg = new RegExp(path, 'g');
console.log('reg', reg);
return ele.fullPath;
});
},
tagWel: state => state.tags.tagWel,
token: state => state.user.token,

139
src/views/distribution/checkInventoryTask/createTask.vue

@ -64,19 +64,12 @@
@click="handleViewCheck(slotProps.scope.row)"
> </el-text
>
<el-text
type="primary"
text
icon="el-icon-view"
@click="handleEditCheck(slotProps.scope.row)"
> </el-text
>
<el-text
type="primary"
text
icon="el-icon-view"
@click="handleDeleteCheck(slotProps.scope.row)"
> </el-text
> </el-text
>
</template>
</tablecmt>
@ -144,33 +137,15 @@
/>
</div>
</el-form-item>
<!-- 盘点订单状态 -->
<template v-if="isEdit">
<el-form-item label="盘点订单状态">
<el-select v-model="form.dictKey" placeholder="请选择订单状态" clearable>
<template v-if="this.typeData.length !== 0">
<el-option
v-for="item in this.typeData"
:label="item.dictValue"
:value="item.dictKey"
/>
</template>
</el-select>
</el-form-item>
</template>
</el-form>
<!-- 表单按钮 -->
<template #footer>
<span v-if="!view" class="dialog-footer">
<span class="dialog-footer">
<el-button
type="primary"
v-if="isEdit"
icon="el-icon-circle-check"
@click="handleEditSubmit"
> </el-button
>
<el-button type="primary" v-else icon="el-icon-circle-check" @click="handleSubmit"
@click="handleSubmit"
:loading="buttonLoadingList.createTaskButton"
> </el-button
>
<el-button icon="el-icon-circle-close" @click="box = false"> </el-button>
@ -337,10 +312,6 @@ export default {
search: true,
//
loading: true,
//
view: false,
//
isEdit: false,
//
query: {},
//
@ -360,6 +331,12 @@ export default {
//
typeData: [],
//
buttonLoadingList: {
//
createTaskButton: false,
},
};
},
mounted() {
@ -650,6 +627,9 @@ export default {
//
async handleSubmit() {
try {
this.buttonLoadingList.createTaskButton = true;
//
if (!this.form.time || this.form.time.length === 0) {
return this.$message({
@ -662,13 +642,19 @@ export default {
formData.list = [];
//
console.log('this.form.selectList :>> ', this.form.selectList);
//
const _clientList = this.form.clientList || [];
//
if (this.form.selectList.length !== 0) {
this.form.selectList.forEach(val => {
if (this.form.clientList.includes(val.id))
if (_clientList.includes(val.id))
formData.list.push({
refId: val.id,
refName: val.clientName,
});
});
}
//
formData.startTime = this.form.time[0].toLocaleString();
//
@ -687,53 +673,11 @@ export default {
this.onLoad();
//
this.box = false;
},
//
async handleEditSubmit() {
console.log('this.form :>> ', this.form);
//
if (!this.form.time || this.form.time.length === 0) {
return this.$message({
type: 'error',
message: '请选择盘点时间',
});
} catch (error) {
console.log('error :>> ', error);
} finally {
this.buttonLoadingList.createTaskButton = false;
}
const formData = {};
formData.list = [];
//
this.form.selectList.forEach(val => {
if (this.form.clientList.includes(val.id))
formData.list.push({
refId: val.id,
refName: val.clientName,
});
});
//
formData.startTime = this.form.time[0].toLocaleString();
//
formData.endTime = this.form.time[1].toLocaleString();
console.log('formData :>> ', formData);
formData.questStatus = this.form.dictKey;
formData.id = this.form.id;
const res = await postEditTaskQuestUpdate(formData);
const { code, msg } = res.data;
console.log('msg :>> ', msg);
console.log('res :>> ', res);
if (code === 200)
this.$message({
message: msg,
type: 'success',
});
//
this.onLoad();
//
this.box = false;
},
/**
@ -776,41 +720,6 @@ export default {
});
},
/**
* 编辑单个任务
*/
async handleEditCheck(row) {
this.title = '编辑盘点任务';
this.isEdit = true; //
this.box = true; //
console.log('row :>> ', row);
this.form.brandName = row.brandName;
this.form.time = [row.startTime, row.endTime];
this.form.clientList = row.list.map(val => val.refId);
this.form.dictKey = row.questStatus;
this.form.selectList = [];
this.form.id = row.id;
console.log('this.form :>> ', this.form);
//
const res = await getDictList();
const { code, data } = res.data;
if (code === 200 && !!data) {
console.log('data :>> ', data);
this.form.selectList = data.map(item => {
return {
//
clientName: item.clientName,
// id
id: item.id,
//
brandName: item.brandName,
};
});
}
},
beforeClose(done) {
done();
this.form = {};

26
src/views/distribution/inventory/delivery/distributionStockArticleMarket.vue

@ -81,7 +81,7 @@
>转预约单</el-button
>
<el-button type="primary" icon="el-icon-edit" @click="handleStockList" v-if="handler"
>批量加配转库存品</el-button
>批量转库存品</el-button
>
<el-button
type="danger"
@ -117,7 +117,9 @@
v-if="!handler"
>通知提货</el-button
>
<el-button type="danger" icon="el-icon-plus" @click="handleExport" plain> </el-button>
<el-button type="danger" icon="el-icon-plus" @click="handleExport" plain
> </el-button
>
</div>
<!-- 头部右侧按钮模块 -->
<div class="avue-crud__right">
@ -392,7 +394,8 @@ import {
add,
update,
remove,
addStock, stockArticExport
addStock,
stockArticExport,
} from '@/api/distribution/distributionStockArticle';
import { getListOwn } from '@/api/distribution/distributionParcelList';
import { addCallDelivery } from '@/api/distribution/distrilbutionCallDelivery';
@ -1007,17 +1010,15 @@ export default {
methods: {
//
handleExport() {
let row = { };
if(!!this.ids){
let row = {};
if (!!this.ids) {
row.ids = this.ids;
}
row.typeService ="2";
stockArticExport(row).then( res =>{
row.typeService = '2';
stockArticExport(row).then(res => {
console.log(res.data);
downloadXls(res.data, '市配订单数据.xlsx');
});
},
showdrawer(value) {
this.drawerShow = value;
@ -1173,8 +1174,8 @@ export default {
}
if (item.isZero === '1') {
this.$message.warning(item.orderCode + ' - 为零担订单,暂无法转为库存品')
return false
this.$message.warning(item.orderCode + ' - 为零担订单,暂无法转为库存品');
return false;
}
ids.push(item.id);
@ -1494,9 +1495,6 @@ export default {
type: 'error',
message: '功能还在开发中',
});
this.title = '新增';
this.form = {};
this.box = true;
},
handleEdit(row) {
this.title = '编辑';

17
src/views/distribution/inventory/distrilbutionBillLading.vue

@ -2494,6 +2494,7 @@ export default {
},
async handleSubmit() {
const zeroOrderList = this.dataList.filter(val => val.isZero === '1');
if (this.$route.query.type !== '2') {
//
const wrongZeroOrder = zeroOrderList.find(val => !val.ParcelLisList);
console.log('zeroOrderList :>> ', zeroOrderList);
@ -2504,7 +2505,6 @@ export default {
message: `订单自编号为${wrongZeroOrder.orderCode}的物料数量未编辑`,
});
}
if (this.$route.query.type !== '2') {
if (zeroOrderList) {
//
const isSubmit = zeroOrderList.every(item => {
@ -2663,7 +2663,9 @@ export default {
up.parcelLisList = [];
up.zeroType = '2';
zeroOrderList.forEach(val => {
if (val.ParcelLisList) {
up.parcelLisList = [...up.parcelLisList, ...val.ParcelLisList];
}
// val.ParcelLisList.forEach(item => {
// up.parcelLisList.push(item);
// });
@ -2704,12 +2706,12 @@ export default {
up.unBillPackageEntityList = _unBillPackageEntityList;
update(up).then(() => {
// this.$message({
// type: 'success',
// message: '!',
// });
// this.$store.commit('DEL_TAG_CURRENT');
// this.$router.push(this.tagWel);
this.$message({
type: 'success',
message: '操作成功!',
});
this.$store.commit('DEL_TAG_CURRENT');
this.$router.push(this.tagWel);
});
return;
}
@ -3012,7 +3014,6 @@ export default {
}
return zeroOrder;
});
console.log('this.zeroOrderFormList :>> ', this.zeroOrderFormList);
}
//
this.dialogFormZeroOrderVisible = true;

Loading…
Cancel
Save