Commit 683f79dd authored by yujinyao's avatar yujinyao

客户详情 报价标签加查询条件

parent 7e0c1c55
...@@ -88,7 +88,7 @@ ...@@ -88,7 +88,7 @@
range-separator="-" range-separator="-"
:start-placeholder="$t('开始日期')" :end-placeholder="$t('结束日期')" /> :start-placeholder="$t('开始日期')" :end-placeholder="$t('结束日期')" />
</el-form-item> </el-form-item>
<el-form-item :label="$t('目的国')" prop="destCountryId"> <el-form-item :label="$t('目的国')">
<el-select <el-select
v-model="destCountryId" v-model="destCountryId"
:label="destCountryId" :label="destCountryId"
...@@ -104,7 +104,7 @@ ...@@ -104,7 +104,7 @@
</el-option> </el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item :label="$t('目的地')" prop="destCityId"> <el-form-item :label="$t('目的地')">
<el-select v-model="destCityId" clearable @change="handleQuery"> <el-select v-model="destCityId" clearable @change="handleQuery">
<el-option <el-option
v-for="item in AddressCity" v-for="item in AddressCity"
...@@ -114,7 +114,7 @@ ...@@ -114,7 +114,7 @@
></el-option> ></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item :label="$t('目的仓')" prop="destWarehouseId"> <el-form-item :label="$t('目的仓')">
<el-select v-model="destWarehouseId" clearable @change="handleQuery"> <el-select v-model="destWarehouseId" clearable @change="handleQuery">
<el-option <el-option
v-for="item in AddressTown" v-for="item in AddressTown"
...@@ -207,6 +207,53 @@ ...@@ -207,6 +207,53 @@
</el-card> </el-card>
</el-tab-pane> </el-tab-pane>
<el-tab-pane name="quote" :label="$t('报价')"> <el-tab-pane name="quote" :label="$t('报价')">
<el-card class="box-card">
<div slot="header" class="clearfix">
<el-form :inline="true" size="small">
<el-form-item :label="$t('目的国')">
<el-select
v-model="destCountryId"
:label="destCountryId"
clearable
@change="handleQuery"
>
<el-option
v-for="item in countryList"
:key="item.id"
:label="$l(item, 'title')"
:value="item.id"
>
</el-option>
</el-select>
</el-form-item>
<el-form-item :label="$t('目的地')">
<el-select v-model="destCityId" clearable @change="handleQuery">
<el-option
v-for="item in AddressCity"
:key="item.shi"
:label="item.shiName"
:value="item.shi"
></el-option>
</el-select>
</el-form-item>
<el-form-item :label="$t('目的仓')">
<el-select v-model="destWarehouseId" clearable @change="handleQuery">
<el-option
v-for="item in AddressTown"
:key="item.id"
:label="item.titleZh"
:value="item.id"
></el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button type="primary" @click="getorderList">{{$t('搜索')}}</el-button>
<el-button type="primary" @click="()=>{
queryParams = { rows:10,page:1}; getInfoListOfferPage();rucangtime = [];
}">{{$t('重置')}}</el-button>
</el-form-item>
</el-form>
</div>
<el-table <el-table
:data="infoListOfferList" :data="infoListOfferList"
style="width: 100%" style="width: 100%"
...@@ -249,9 +296,18 @@ ...@@ -249,9 +296,18 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="objectiveName" :label="$t('始发仓')"
:label="$t('目的地')" >
<template v-slot="{row}">
{{getWarehouse(row.startWarehouseId)}}
</template>
</el-table-column>
<el-table-column
:label="$t('运输方式/目的地')"
> >
<template slot-scope="{row}">
<dict-tag :type="DICT_TYPE.ECW_TRANSPORT_TYPE" :value="row.transportType" /> / {{row.objectiveName}}
</template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
:label="$t('销售阶段')" :label="$t('销售阶段')"
...@@ -295,6 +351,7 @@ ...@@ -295,6 +351,7 @@
</el-table-column> </el-table-column>
</el-table> </el-table>
<pagination @pagination="getInfoListOfferPage" :page.sync="infoListOfferFrom.pageNo" :limit.sync="infoListOfferFrom.pageSize" :total="infoListOfferTotal" ></pagination> <pagination @pagination="getInfoListOfferPage" :page.sync="infoListOfferFrom.pageNo" :limit.sync="infoListOfferFrom.pageSize" :total="infoListOfferTotal" ></pagination>
</el-card>
</el-tab-pane> </el-tab-pane>
<el-tab-pane name="follow" :label="$t('跟进')"> <el-tab-pane name="follow" :label="$t('跟进')">
<customer-follow v-if="activeName === 'follow'" customerQuery ref="customerFollow" :id="id" :customer-id="id"></customer-follow> <customer-follow v-if="activeName === 'follow'" customerQuery ref="customerFollow" :id="id" :customer-id="id"></customer-follow>
...@@ -615,10 +672,10 @@ ...@@ -615,10 +672,10 @@
<el-input type="textarea" v-model="creditFrom.remark"> </el-input> <el-input type="textarea" v-model="creditFrom.remark"> </el-input>
</el-form-item> </el-form-item>
</el-form> </el-form>
<span slot="footer" class="dialog-footer"> <div slot="footer" class="dialog-footer">
<el-button @click="submit">{{$t('提交')}}</el-button> <el-button @click="submit">{{$t('提交')}}</el-button>
<el-button @click="dialogVisible = false" >{{$t('取消')}}</el-button> <el-button @click="dialogVisible = false" >{{$t('取消')}}</el-button>
</span> </div>
</el-dialog> </el-dialog>
</div> </div>
</template> </template>
...@@ -655,6 +712,7 @@ import customerLog from "@/views/ecw/customer/customerLog.vue"; ...@@ -655,6 +712,7 @@ import customerLog from "@/views/ecw/customer/customerLog.vue";
import {checkPermi} from "@/utils/permission"; import {checkPermi} from "@/utils/permission";
import ImageDisplay from "@/views/ecw/order/components/imageDisplay.vue"; import ImageDisplay from "@/views/ecw/order/components/imageDisplay.vue";
import { getListTree } from "@/api/ecw/region"; import { getListTree } from "@/api/ecw/region";
import { getWarehouseList } from "@/api/ecw/warehouse";
export default { export default {
name: 'query', name: 'query',
components: { components: {
...@@ -708,14 +766,23 @@ export default { ...@@ -708,14 +766,23 @@ export default {
this.getData(); this.getData();
//获取城市列表 //获取城市列表
this.getCountryList(); this.getCountryList();
this.getWarehouseList()
}, },
watch:{ watch:{
activeName(val){ activeName(val){
switch (val) { switch (val) {
case 'order': case 'order':
this.destCountryId = ''
this.destCityId = ''
this.destWarehouseId = ''
this.queryParams = { rows:10, page:1}
this.getorderList()//订单 this.getorderList()//订单
break break
case 'quote': case 'quote':
this.destCountryId = ''
this.destCityId = ''
this.destWarehouseId = ''
this.queryParams = { rows:10, page:1}
this.getInfoListOfferPage()//报价 this.getInfoListOfferPage()//报价
break break
case 'bill': case 'bill':
...@@ -768,16 +835,16 @@ export default { ...@@ -768,16 +835,16 @@ export default {
}); });
} else if ( } else if (
this.destCountryId != "" && this.destCountryId != "" &&
this.objectiveId == "" && this.destCityId == "" &&
this.destWarehouseId == "" this.destWarehouseId == ""
) { ) {
getRegionList(2, this.destCountryId) /*getRegionList(2, this.destCountryId)
.then(({ data }) => { .then(({ data }) => {
this.AddressCity = data; this.AddressCity = data;
}) })
.catch((error) => { .catch((error) => {
console.log(error); console.log(error);
}); });*/
getRegionList(5, 5) getRegionList(5, 5)
.then(({ data }) => { .then(({ data }) => {
this.AddressTown = data; this.AddressTown = data;
...@@ -800,13 +867,13 @@ export default { ...@@ -800,13 +867,13 @@ export default {
this.destWarehouseId == "" this.destWarehouseId == ""
) { ) {
//获取当前城市值id,获取该城市下区域 //获取当前城市值id,获取该城市下区域
getRegionList(3, this.destCityId) /*getRegionList(3, this.destCityId)
.then(({ data }) => { .then(({ data }) => {
this.AddressTown = data; this.AddressTown = data;
}) })
.catch((error) => { .catch((error) => {
console.log(error); console.log(error);
}); });*/
} else if ( } else if (
this.destCountryId == "" && this.destCountryId == "" &&
this.destCityId == "" && this.destCityId == "" &&
...@@ -1007,10 +1074,11 @@ export default { ...@@ -1007,10 +1074,11 @@ export default {
AddressCity: [], //目的城市 AddressCity: [], //目的城市
AddressProvince: [], //省份 AddressProvince: [], //省份
AddressTown: [], //目的仓 AddressTown: [], //目的仓
destCountryId: [], destCountryId: null,
objectiveId: [], // objectiveId: null,
destCityId: null, destCityId: null,
destWarehouseId: "", destWarehouseId: null,
warehouseList: [],
} }
}, },
computed: { computed: {
...@@ -1181,7 +1249,7 @@ export default { ...@@ -1181,7 +1249,7 @@ export default {
}, },
findBycityCode() { findBycityCode() {
//获取当前城市值id,获取该城市下区域 //获取当前城市值id,获取该城市下区域
getRegionList(3, this.objectiveId) getRegionList(3, this.destCityId)
.then(({ data }) => { .then(({ data }) => {
this.AddressTown = data; this.AddressTown = data;
}) })
...@@ -1224,14 +1292,32 @@ export default { ...@@ -1224,14 +1292,32 @@ export default {
/** 搜索按钮操作 */ /** 搜索按钮操作 */
handleQuery() { handleQuery() {
this.queryParams.pageNo = 1; this.queryParams.pageNo = 1;
//目的城市
this.queryParams.destCityId = this.destCityId;
//目的国 //目的国
this.queryParams.destCountryId = this.destCountryId; this.queryParams.destCountryId = this.destCountryId;
//目的城市
this.queryParams.objectiveId = this.destCityId;
//目的仓 //目的仓
this.queryParams.destWarehouseId = this.destWarehouseId; this.queryParams.destWarehouseId = this.destWarehouseId;
if (this.activeName == 'order') {
this.getorderList() this.getorderList()
} else if (this.activeName == 'quote') {
this.getInfoListOfferPage()
}
},
getWarehouseList() {
getWarehouseList().then((res) => {
this.warehouseList = res.data;
})
},
getWarehouse(id) {
let warehouseName = ''
for(const item of this.warehouseList) {
if(item.id == id){
warehouseName = this.$i18n.locale=='zh_CN'?item.titleZh:item.titleEn
break
}
}
return warehouseName
}, },
}, },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment