Browse Source

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

dev-warehouse
zhangsiyu 2 years ago
parent
commit
1ed41df2ba
  1. 21
      src/api/distribution/distributionDeliveryList.js
  2. 60
      src/views/basicdata/driverArtery/basicdataDriverArtery.vue
  3. 6
      src/views/basicdata/warehouse/warehouse/basicdataWarehouse.vue
  4. 2
      src/views/distribution/deliverylist/distributionDeliveryList2.vue
  5. 4
      src/views/distribution/deliverylist/distributionDeliveryList3.vue
  6. 274
      src/views/distribution/deliverylist/distributionDeliveryListedt.vue
  7. 97
      src/views/distribution/reservation/reservation.vue
  8. 83
      src/views/distribution/reservation/reservationFrom.vue

21
src/api/distribution/distributionDeliveryList.js

@ -22,6 +22,17 @@ export const getPage = (current, size, params) => {
}
})
}
export const getstatistics = (current, size, params) => {
return request({
url: '/api/logpm-distribution/deliveryList/statistics',
method: 'get',
params: {
...params,
current,
size,
}
})
}
export const getDetail = (id) => {
return request({
@ -33,6 +44,16 @@ export const getDetail = (id) => {
})
}
export const getWrapdetail = (id) => {
return request({
url: '/api/logpm-distribution/deliveryList/wrapdetail',
method: 'get',
params: {
id
}
})
}
export const remove = (ids) => {
return request({
url: '/api/logpm-distribution/deliveryList/remove',

60
src/views/basicdata/driverArtery/basicdataDriverArtery.vue

@ -38,6 +38,7 @@
<script>
import {getList, getDetail, add, update, remove,getPage} from "@/api/basicdata/basicdataDriverArtery";
import { getList as getUserList,getUser} from '@/api/system/user'
import {getVehicle } from "@/api/basicdata/basicdataVehicle";
import option from "@/option/basicdata/basicdataDriverArtery";
import {mapGetters} from "vuex";
@ -47,6 +48,7 @@
import {dateNow} from "@/utils/date";
import NProgress from 'nprogress';
import 'nprogress/nprogress.css';
import { getDetail as getDetailDelineNode } from '@/api/basic/basicDelineNode';
export default {
data() {
return {
@ -154,6 +156,34 @@
viewDisplay: false,
hide: true,
},
{
label: "用户",
prop: "userId",
type: "select",
labelWidth:'150',
dicData: [],
width:"100px",
align:'center',
span:11,
hide: true,
filterable: true,
rules: [
{
required: true,
message: '请选择用户',
trigger: 'blur',
},
],
change: (val) => {
if (!!val.value && val.value !== -1){
getUser(val.value).then(res => {
this.form.name =res.data.data.name
this.form.phone =res.data.data.phone
})
}
},
},
{
label: "姓名",
prop: "name",
@ -546,8 +576,7 @@
hide: true,
},
]
}
,
},
data: []
};
},
@ -697,7 +726,6 @@
},
onLoad(page, params = {}) {
this.loading = true;
const {
name,
phone,
@ -720,9 +748,12 @@
this.data = data.records;
this.loading = false;
// console.log("this.option.column>>>>>>>",this.option.column);
this.option.column[15].dicData =[]
this.option.column[16].dicData =[]
this.option.column[9].dicData =[]
//
this.getVehiclede();
//
this.getpeople();
// getVehicle().then(res => {
// console.log("res.data.data>>>>>>>",res.data.data)
// res.data.data.map(v=>{
@ -752,7 +783,26 @@
label: v.vehicleNub,
value: v.id,
}
this.option.column[15].dicData.push(value)
this.option.column[16].dicData.push(value)
})
});
},
//
getpeople(){
getUserList(
1,
100000,
null,
''
).then(res => {
const data = res.data.data;
data.records.map(v=>{
let value =
{
label: v.name,
value: v.id,
}
this.option.column[9].dicData.push(value)
})
});
}

6
src/views/basicdata/warehouse/warehouse/basicdataWarehouse.vue

@ -167,13 +167,7 @@
row.code = code[2];
}
}
//
if (!!this.form.administrativeAreas){
row.administrativeAreas = this.form.administrativeAreas.join(";")
}
console.log(">>>row",row);
update(row).then(() => {
this.onLoad(this.page);

2
src/views/distribution/deliverylist/distributionDeliveryList2.vue

@ -62,7 +62,7 @@
<!-- 操作栏模块 -->
<el-table-column prop="menu" label="操作" :width="220" align="center">
<template #="{row}">
<el-button type="primary" text icon="el-icon-view" @click="handleView(row)">查看</el-button>
<!-- <el-button type="primary" text icon="el-icon-view" @click="handleView(row)">查看</el-button>-->
<el-button type="primary" text icon="el-icon-view" @click="handleViewBlank(row)">查看</el-button>
<el-button type="primary" text icon="el-icon-view" @click="handleViewBlank(row)">查看地图</el-button>
<!-- <el-button type="primary" text icon="el-icon-edit" @click="handleEdit(row)">编辑</el-button>-->

4
src/views/distribution/deliverylist/distributionDeliveryList3.vue

@ -62,11 +62,9 @@
<!-- 操作栏模块 -->
<el-table-column prop="menu" label="操作" :width="220" align="center">
<template #="{row}">
<el-button type="primary" text icon="el-icon-view" @click="handleView(row)">查看</el-button>
<!-- <el-button type="primary" text icon="el-icon-view" @click="handleView(row)">查看</el-button>-->
<el-button type="primary" text icon="el-icon-view" @click="handleViewBlank(row)">查看</el-button>
<el-button type="primary" text icon="el-icon-view" @click="handleViewBlank(row)">查看地图</el-button>
<!-- <el-button type="primary" text icon="el-icon-edit" @click="handleEdit(row)">编辑</el-button>-->
<!-- <el-button type="primary" text icon="el-icon-delete" @click="rowDel(row)">删除</el-button>-->
</template>
</el-table-column>
</el-table>

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

@ -32,15 +32,15 @@
</el-col>
</el-row>
<el-divider>订单列表</el-divider>
<el-row>
<div class="avue-crud__header">
<!-- 头部左侧按钮模块 -->
<div class="avue-crud__left">
<el-button type="primary" icon="el-icon-plus" @click="handleAdd"> </el-button>
<el-button type="danger" icon="el-icon-delete" @click="handleDelete" plain> </el-button>
</div>
</div>
</el-row>
<!-- <el-row>-->
<!-- <div class="avue-crud__header">-->
<!-- &lt;!&ndash; 头部左侧按钮模块 &ndash;&gt;-->
<!-- <div class="avue-crud__left">-->
<!-- <el-button type="primary" icon="el-icon-plus" @click="handleAdd"> </el-button>-->
<!-- <el-button type="danger" icon="el-icon-delete" @click="handleDelete" plain> </el-button>-->
<!-- </div>-->
<!-- </div>-->
<!-- </el-row>-->
<el-row>
<!-- 列表模块 -->
<el-table ref="table" v-loading="loading"
@ -49,10 +49,7 @@
:height="height"
style="width: 100%"
:border="option.border">
<el-table-column type="selection" v-if="option.selection" width="55" align="center"></el-table-column>
<el-table-column type="expand" v-if="option.expand" align="center"></el-table-column>
<el-table-column v-if="option.index" label="序号" type="index" width="80" align="center">
</el-table-column>
<template v-for="(item,index) in option.column">
<!-- table字段 -->
<el-table-column v-if="item.hide!==true"
@ -67,8 +64,6 @@
<el-table-column prop="menu" label="操作" :width="220" align="center">
<template #="{row}">
<el-button type="primary" text icon="el-icon-view" @click="handleView(row)">查看</el-button>
<el-button type="primary" text icon="el-icon-edit" @click="handleEdit(row)" v-if="!this.edt">编辑</el-button>
<el-button type="primary" text icon="el-icon-delete" @click="rowDel(row)" v-if="!this.edt">删除</el-button>
</template>
</el-table-column>
</el-table>
@ -76,16 +71,16 @@
<el-row>
<div class="avue-crud__pagination" style="width:100%">
<!-- 分页模块 -->
<el-pagination align="right"
background
@size-change="sizeChange"
@current-change="currentChange"
:current-page="page.currentPage"
:page-sizes="[10, 20, 30, 40, 50, 100]"
:page-size="page.pageSize"
layout="total, sizes, prev, pager, next, jumper"
:total="page.total">
</el-pagination>
<!-- <el-pagination align="right"-->
<!-- background-->
<!-- @size-change="sizeChange"-->
<!-- @current-change="currentChange"-->
<!-- :current-page="page.currentPage"-->
<!-- :page-sizes="[10, 20, 30, 40, 50, 100]"-->
<!-- :page-size="page.pageSize"-->
<!-- layout="total, sizes, prev, pager, next, jumper"-->
<!-- :total="page.total">-->
<!-- </el-pagination>-->
</div>
</el-row>
<!-- 表单模块 -->
@ -94,104 +89,24 @@
width="50%"
:before-close="beforeClose"
append-to-body>
<el-form :disabled="view" :size="option.size" :rules="validatorRules" ref="form" :model="form"
label-width="80px">
<!-- 表单字段 -->
<!-- <el-form-item label="关联pdaid" prop="masterId">-->
<!-- <el-input v-model="form.masterId" placeholder="请输入关联pdaid"/>-->
<!-- </el-form-item>-->
<el-row>
<el-col :span="11">
<el-form-item label="反馈日期" prop="feedbackTime" label-width="80px">
<el-date-picker v-model="form.feedbackTime" placeholder="请输入反馈日期" type="date" value-format="YYYY-MM-DD"
style="position: absolute;right: 0px;width: 100%"></el-date-picker>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="营业部" prop="businessDepartment" label-width="120px">
<el-input v-model="form.businessDepartment" placeholder="请输入营业部"
style="position: absolute;right: 0px;width: 100%" />
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="11">
<el-form-item label="维修公司" prop="maintenanceCompany" label-width="80px">
<el-input v-model="form.maintenanceCompany" placeholder="请输入维修公司"
style="position: absolute;right: 0px;width: 100%" />
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="采买经销商" prop="dealer" label-width="120px">
<el-input v-model="form.dealer" placeholder="请输入采买经销商"
style="position: absolute;right: 0px;width: 100%" />
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="11">
<el-form-item label="问题描述" prop="problemDescription" label-width="80px">
<el-input v-model="form.problemDescription" placeholder="请输入问题描述"
style="position: absolute;right: 0px;width: 100%" />
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="是否保修期" prop="isLiability" label-width="120px">
<el-select v-model="form.isLiability" clearable placeholder="是否保修期"
style="position: absolute;right: 0px;width: 100%">
<el-option
v-for="item in isLiabilityData"
:key="item.dictKey"
:label="item.dictValue"
:value="item.dictKey">
</el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="11">
<el-form-item label="寄回日期" prop="returnDate" label-width="80px">
<el-date-picker v-model="form.returnDate" placeholder="请输入寄回日期" type="date" value-format="YYYY-MM-DD"
style="position: absolute;right: 0px;width: 100%"></el-date-picker>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="寄检修快递单号" prop="repairTrackingNub" label-width="120px">
<el-input v-model="form.repairTrackingNub" placeholder="请输入寄检修快递单号"
style="position: absolute;right: 0px;width: 100%" />
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="11">
<el-form-item label="寄回单号" prop="returnOrderNub" label-width="80px">
<el-input v-model="form.returnOrderNub" placeholder="请输入维修寄回单号"
style="position: absolute;right: 0px;width: 100%" />
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="维修费(元)" prop="maintenanceCosts" label-width="120px">
<el-input v-model="form.maintenanceCosts" placeholder="请输入维修费用;单位(元)" style="width: 100%" />
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="23">
<el-form-item label="备注" prop="notes">
<el-input v-model="form.notes" placeholder="请输入备注" style="width: 100%" />
</el-form-item>
</el-col>
</el-row>
</el-form>
<el-table ref="table" v-loading="loading"
@selection-change="selectionChange"
:data="wrapdata"
:height="height"
style="width: 100%"
:border="option.border">
<el-table-column type="expand" v-if="option.expand" align="center"></el-table-column>
<template v-for="(item,index) in wrapoption.column">
<!-- table字段 -->
<el-table-column v-if="item.hide!==true"
:prop="item.prop"
:label="item.label"
align="center"
:width="item.width"
:key="index">
</el-table-column>
</template>
</el-table>
<!-- 表单按钮 -->
<template #footer>
<span v-if="!view" class="dialog-footer">
@ -205,7 +120,7 @@
</template>
<script>
import { getList, getDetail, add, update, remove,getPage,getstatistics } from "@/api/distribution/distributionDeliveryList";
import { getList, getDetail, add, update, remove,getPage,getstatistics,getWrapdetail } from "@/api/distribution/distributionDeliveryList";
import option from '@/option/basic/basicPdarecords';
import { mapGetters } from 'vuex';
import { getDictionaryBiz } from '@/api/system/dict';
@ -269,7 +184,7 @@ export default {
},
{
label: "收货电话",
prop: "businessDepartment",
prop: "deliveryPhone",
search: true,
width:"100px"
},
@ -281,25 +196,19 @@ export default {
},
{
label: "订单自编号",
prop: "stockArticleId",
prop: "orderIds",
search: true,
width:"100px"
},
{
label: "收货地址",
prop: "businessDepartment",
label: "配送件数",
prop: "packageNub",
search: true,
width:"100px"
},
{
label: "装车件数",
prop: "businessDepartment",
search: true,
width:"100px"
},
{
label: "配送件数",
prop: "businessDepartment",
prop: "loadedNub",
search: true,
width:"100px"
},
@ -311,48 +220,51 @@ export default {
},
]
},
propertyoption: {
height:'auto',
calcHeight: 30,
tip: false,
searchShow: true,
editBtn:false,
emptyBtn:false,//
submitBtn: false, //
searchMenuSpan: 6,
disabled: false,
border: true,
//
wrapoption: {
expand: false,
index: true,
viewBtn: false,
border: true,
selection: true,
dialogClickModal: false,
column: [
{
label: "配送类型:",
prop: "kind",
type: "input",
labelWidth:'150',
width:"120px",
align:'center',
dicUrl: '/api/blade-system/dict-biz/dictionary?code=distribution_deliverylist_kind',
props: {
label: 'dictValue',
value: 'dictKey',
},
label: "包条码",
prop: "packetBarCode",
search: true,
width:"100px"
},
{
label: "一级品类",
prop: "firsts",
search: true,
width:"100px"
},
{
label: "二级品类",
prop: "second",
search: true,
width:"100px"
},
{
label: "三级品类",
prop: "thirdProduct",
search: true,
width:"100px"
},
{
label: "配送车辆:",
prop: "vehicle",
type: "input",
labelWidth:'150',
width:"120px",
align:'center',
label: "物料名称",
prop: "material",
search: true,
width:"100px"
},
]
},
//
data: [],
//
wrapdata:[],
};
},
watch: {
@ -393,23 +305,7 @@ export default {
methods: {
//
rowUpdate() {
this.$refs.myForm.validate(valid => {
if (valid) {
let row = this.dataForm
updatevalue(row).then(() => {
this.$message({
type: "success",
message: "操作成功!"
});
let str = {
val: true
}
this.$emit("returnpda", str);
}, error => {
console.log(error);
});
}
});
},
queryDictionary() {
getDictionaryBiz('yes_no').then(res => {
@ -422,10 +318,7 @@ export default {
},
//
handleViewpda() {
let str = {
val: this.propertyformdata.activeTab
}
this.$emit("returnproperty", str);
},
init() {
this.height = this.setPx(document.body.clientHeight - 340);
@ -492,11 +385,13 @@ export default {
});
},
handleView(row) {
console.log("查看>>>>>>>>>>",row);
this.title = '查看';
this.view = true;
this.box = true;
getDetail(row.id).then(res => {
this.form = res.data.data;
getWrapdetail(row.id).then(res => {
console.log("查看>>>>>>>",res.data.data);
// this.wrapdata = res.data.data;
});
},
handleDelete() {
@ -564,7 +459,8 @@ export default {
let id = this.$route.query.id;
getDetail(id).then(res => {
console.log("res.data>>>>>>>>>>>>",res.data.data);
this.deliverydata = res.data.data
const data = res.data.data
this.deliverydata = data
this.data = res.data.data.reservationList
});
this.loading = false;

97
src/views/distribution/reservation/reservation.vue

@ -82,103 +82,6 @@
</el-pagination>
</div>
</el-row>
<!-- 表单模块 -->
<el-dialog :title="title"
v-model="box"
width="50%"
:before-close="beforeClose"
append-to-body>
<el-form :disabled="view" ref="form" :model="form" label-width="80px">
<!-- 表单字段 -->
<el-form-item label="订单自编号" v-if="isUpdate" prop="orderId">
<el-input v-model="form.orderId" placeholder="请输入订单自编号;订单自编号,关联订单表"/>
</el-form-item>
<el-form-item label="收货人" prop="consignee">
<el-input v-model="form.consignee" placeholder="请输入收货人"/>
</el-form-item>
<el-form-item label="收件人电话" prop="deliveryPhone">
<el-input v-model="form.deliveryPhone" placeholder="请输入收件人电话"/>
</el-form-item>
<el-form-item label="收件地址" prop="deliveryAddress">
<el-input v-model="form.deliveryAddress" placeholder="请输入收件地址"/>
</el-form-item>
<el-form-item label="预约时间:" prop="reservationDate">
<el-date-picker
v-model="form.reservationDate"
type="date"
clearable
placeholder="选择日期时间">
</el-date-picker>
</el-form-item>
<el-form-item label="预约时间:" prop="periodOfTime">
<el-radio v-model="form.periodOfTime" :label="'1'" :value="'1'">上午</el-radio>
<el-radio v-model="form.periodOfTime" :label="'2'" :value="'2'">下午</el-radio>
<el-radio v-model="form.periodOfTime" :label="'3'" :value="'3'">全天</el-radio>
</el-form-item>
<el-form-item label="配送类型:" prop="serveType">
<el-radio v-model="form.deliveryType" :label="'1'" :value="'1'">市配</el-radio>
<el-radio v-model="form.deliveryType" :label="'2'" :value="'2'">商配</el-radio>
</el-form-item>
<el-form-item label="配送方式" prop="deliveryType">
<el-radio-group v-model="form.deliveryWay">
<el-radio v-model="form.deliveryWay" :label="'1'" :value="'1'">送货</el-radio>
<el-radio v-model="form.deliveryWay" :label="'2'" :value="'2'">送货上楼</el-radio>
<el-radio v-model="form.deliveryWay" :label="'3'" :value="'3'">送装一体</el-radio>
<el-radio v-model="form.deliveryWay" :label="'4'" :value="'4'"></el-radio>
</el-radio-group>
</el-form-item>
<el-form-item label="到付运费" v-if="isUpdate" :disAbled="true" prop="collectFee">
<el-input v-model="form.collectFee" placeholder="请输入到付运费"/>
</el-form-item>
<el-form-item label="服务类型" prop="serveType">
<el-checkbox-group v-model="form.serveType">
<el-checkbox v-for="item in this.addvalueServeTypeData" :label="item.dictKey"
:value="item.dictKey">{{item.dictValue}}
</el-checkbox>
</el-checkbox-group>
</el-form-item>
<el-form-item label="代付运费" v-if="isUpdate" prop="replaceFee">
<el-input v-model="form.replaceFee" placeholder="请输入代付运费"/>
</el-form-item>
<el-form-item label="其他费用" prop="otherFee">
<el-input v-model="form.otherFee" placeholder="请输入其他费用"/>
</el-form-item>
<el-form-item label="预约信息状态" v-if="isUpdate" prop="resvervationStatus">
<el-input v-model="form.resvervationStatus" placeholder="请输入预约信息状态;预约列表信息状态;1-待确认、2-已确认"/>
</el-form-item>
<el-form-item label="订单来源" v-if="isUpdate" prop="orderSource">
<el-input v-model="form.orderSource" placeholder="请输入订单来源"/>
</el-form-item>
<el-form-item label="备货状态" v-if="isUpdate" prop="stockupStatus">
<el-input v-model="form.stockupStatus" placeholder="请输入备货状态;备货状态;1-未备货、2-待备货、3-已备货"/>
</el-form-item>
<el-form-item label="备货区编号" v-if="isUpdate" prop="goodsShelfId">
<el-input v-model="form.goodsShelfId" placeholder="请输入备货区编号"/>
</el-form-item>
<!-- <el-form-item label="预留1" prop="reserve1">-->
<!-- <el-input v-model="form.reserve1" placeholder="请输入预留1"/>-->
<!-- </el-form-item>-->
<!-- <el-form-item label="预留2" prop="reserve2">-->
<!-- <el-input v-model="form.reserve2" placeholder="请输入预留2"/>-->
<!-- </el-form-item>-->
<!-- <el-form-item label="预留3" prop="reserve3">-->
<!-- <el-input v-model="form.reserve3" placeholder="请输入预留3"/>-->
<!-- </el-form-item>-->
<!-- <el-form-item label="预留4" prop="reserve4">-->
<!-- <el-input v-model="form.reserve4" placeholder="请输入预留4"/>-->
<!-- </el-form-item>-->
<!-- <el-form-item label="预留5" prop="reserve5">-->
<!-- <el-input v-model="form.reserve5" placeholder="请输入预留5"/>-->
<!-- </el-form-item>-->
</el-form>
<!-- 表单按钮 -->
<template #footer>
<span v-if="!view" class="dialog-footer">
<el-button type="primary" icon="el-icon-circle-check" @click="handleSubmit"> </el-button>
<el-button icon="el-icon-circle-close" @click="box = false"> </el-button>
</span>
</template>
</el-dialog>
</div>
</basic-container>
</template>

83
src/views/distribution/reservation/reservationFrom.vue

@ -32,10 +32,13 @@
</el-col>
<el-col :span="10">
<el-form-item label="时&emsp;&emsp;段:" prop="deliveryAddress" label-width="100px">
<el-radio-group v-model="form.periodOfTime">
<el-radio v-for="item in this.periodOfTimeData" :label="item.dictValue"
:value="item.dictKey"></el-radio>
<el-radio-group v-model="form.periodOfTime" v-for="item in this.periodOfTimeData">
<el-radio
:label="item.dictKey"
:value="item.dictKey">{{item.dictValue}}&emsp;</el-radio>
</el-radio-group>
<!-- :label="item.dictValue"-->
</el-form-item>
</el-col>
@ -50,9 +53,10 @@
<el-col :span="10">
<el-form-item label="配送类型:" prop="serveType" label-width="100px">
<el-radio-group v-model="form.deliveryType">
<el-radio v-for="item in this.deliveryTypeData" :label="item.dictValue"
:value="item.dictKey"></el-radio>
<el-radio-group v-model="form.deliveryType" v-for="item in this.deliveryTypeData">
<el-radio
:label="item.dictKey"
:value="item.dictKey">{{item.dictValue}}&emsp;</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
@ -66,15 +70,15 @@
type="textarea"
:rows="2"
placeholder="请输入内容"
v-model="form.textarea">
v-model="form.remarks">
</el-input>
</el-form-item>
</el-col>
<el-col :span="10">
<el-form-item label="配送方式:" prop="serveType" label-width="100px">
<el-radio-group v-model="form.deliveryWay">
<el-radio v-for="item in this.deliveryWayData" :label="item.dictValue"
:value="item.dictKey"></el-radio>
<el-radio-group v-model="form.deliveryWay" v-for="item in this.deliveryWayData" >
<el-radio :label="item.dictKey"
:value="item.dictKey">{{item.dictValue}}&emsp;</el-radio>
</el-radio-group>
</el-form-item>
</el-col>
@ -92,9 +96,9 @@
<el-col :span="10">
<el-form-item label="服务类型:" prop="serveType" label-width="100px">
<!-- <el-input v-model="form.serveType" clearable placeholder="请选择服务类型"/>-->
<el-checkbox-group v-model="serveType">
<el-checkbox v-for="item in this.addvalueServeTypeData" :label="item.dictValue"
:value="item.dictKey"></el-checkbox>
<el-checkbox-group v-model="serveType" v-for="item in this.addvalueServeTypeData">
<el-checkbox :label="item.dictKey"
:value="item.dictKey">{{item.dictValue}}&emsp;</el-checkbox>
</el-checkbox-group>
</el-form-item>
</el-col>
@ -644,7 +648,7 @@
let inventoryList = [];
let stockArticleList = [];
this.orderData.forEach(item => {
if (item.number > item.handQuantity || !item.number) {
if (item.reservationNum > item.handQuantity || !item.reservationNum) {
this.$message({
type: 'warning',
message: '请输入' + item.orderSelfNumbering + '正确数量!'
@ -652,23 +656,21 @@
return;
}
orderIds.push(item.id);
item.reservationNum = item.number;
item.reservationNum = item.reservationNum;
stockArticleList.push(item);
});
this.inventoryData.forEach(item => {
if (!item.number || item.number > item.quantityStock) {
if (!item.reservationNum || item.reservationNum > item.quantityStock) {
this.$message({
type: 'warning',
message: '请输入' + item.orderSelfNumbering + '正确数量!'
});
return;
}
item.reservationNum = item.number;
item.reservationNum = item.reservationNum;
inventoryIds.push(item.id);
inventoryList.push(item);
});
console.log('>>>>>>>>>>>', this.inventoryData);
console.log('>>>>>>>>>>>', this.orderData);
orderIds.join(',');
inventoryIds.join(',');
this.form.stockArticleIds = orderIds.toString();
@ -690,20 +692,19 @@
this.form.periodOfTime = item.dictKey;
}
});
let a = [];
this.addvalueServeTypeData.forEach(item => {
this.serveType.forEach(type => {
if (type === item.dictValue) {
a.push(item.dictKey);
// this.form.serveType=item.dictKey;
}
});
});
this.form.serveType = a.toString();
// let a = [];
// this.addvalueServeTypeData.forEach(item => {
// this.form.serveType.forEach(type => {
// if (type === item.dictValue) {
// a.push(item.dictKey);
// // this.form.serveType=item.dictKey;
// }
// });
// });
this.form.serveType = this.serveType.join(",")
console.log('^^^^^^^^^^', this.form);
add(this.form).then(() => {
this.box = false;
this.onLoad(this.page);
this.$router.go(-1);
this.$message({
type: 'success',
@ -792,7 +793,6 @@
return;
}
if (this.orderData.length > 0) {
this.selectionList.some(i => {
console.log('asdgfasdv', i);
let a = this.orderData.filter((ele) => ele.customerName != i.customerName || ele.customerTelephone != i.customerTelephone || ele.customerAddress != i.customerAddress).length >= 1;
@ -869,16 +869,23 @@
}
if (this.reservationId) {
getReservationInfo(this.reservationId).then(res => {
this.form = res.data.data;
this.orderData = res.data.data.stockArticleList;
this.inventoryData = res.data.data.inventoryList;
console.log(res.data.data);
const reservation = res.data.data;
this.orderData = reservation.stockArticleList;
this.inventoryData = reservation.inventoryList;
this.form.deliveryType = reservation.deliveryType;
this.form.periodOfTime = reservation.periodOfTime;
this.form.periodOfTime = reservation.periodOfTime;
if (reservation.serveType){
this.serveType = Array.from(reservation.serveType)
}
this.form = reservation;
console.log("<<<<<<<<<<<<<<",res.data.data);
});
}
getInventoryList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
const data = res.data.data;
this.page.total = data.total;
this.inventoryInfo = data.records;
const inventoryList = res.data.data;
this.page.total = inventoryList.total;
this.inventoryInfo = inventoryList.records;
this.loading = false;
this.selectionClear();
});

Loading…
Cancel
Save