Commit 942535dd authored by dragondean@qq.com's avatar dragondean@qq.com
parents a69dbff0 210991ee
......@@ -162,6 +162,19 @@ export const constantRoutes = [
}
]
},
{
path: '/deptTarget',
component: Layout,
hidden: true,
redirect: 'noredirect',
children: [ {
path: 'empAchievement',
component: (resolve) => require(['@/views/ecw/deptTarget/empAchievement'], resolve),
name: '员工业绩',
meta: {title: '员工业绩', activeMenu: '/deptTarget/index'}
}
]
},
{
path: '/node',
component: Layout,
......
......@@ -178,7 +178,8 @@ export default {
const { bookSeaInfo } = this.shipmentObj;
makeBillService({
orderId: row.orderId,
zgDate: bookSeaInfo.sailTime,
zgDate: '2022-09-27',
// zgDate: bookSeaInfo.sailTime,
}).then((res) => {
const { data } = res;
const { titleZh = "", contentZh = "" } = data?.ladingTemplate ?? {};
......
......@@ -11,36 +11,50 @@
<el-input v-model="queryParams.name" placeholder="请输入客户名称" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="客户等级" prop="level">
<el-select v-model="queryParams.level" placeholder="请选择客户等级" clearable size="small">
<el-select clearable v-model="queryParams.level" placeholder="请选择客户等级" clearable size="small">
<el-option v-for="dict in getDictDatas(DICT_TYPE.CUSTOMER_LEVEL)"
:key="dict.value" :label="dict.label" :value="dict.value"/>
</el-select>
</el-form-item>
<el-form-item label="联系方式">
<el-input placeholder="请输入联系方式" v-model="queryParams.defaultContactPhone"></el-input>
</el-form-item>
<el-form-item label="客户类别" prop="level">
<dict-selector :type="DICT_TYPE.CUSTOMER_TYPE" multiple v-model="queryParams.type"></dict-selector>
</el-form-item>
<el-form-item label="客户经理" prop="customerService">
<el-select clearable v-model="queryParams.customerService" placeholder="请选择客户经理" clearable size="small">
<el-option v-for="dict in customerServiceList"
:key="dict.id" :label="dict.nickname" :value="dict.id"/>
</el-select>
</el-form-item>
<el-form-item label="客户来源" prop="source">
<el-select v-model="queryParams.source" placeholder="请选择客户来源" clearable size="small">
<el-select clearable v-model="queryParams.source" placeholder="请选择客户来源" clearable size="small">
<el-option v-for="dict in getDictDatas(DICT_TYPE.CUSTOMER_SOURCE)"
:key="dict.value" :label="dict.label" :value="dict.value"/>
</el-select>
</el-form-item>
<el-form-item label="客户经理" prop="customerService">
<el-select v-model="queryParams.customerService" placeholder="请选择客户经理" clearable size="small">
<el-option v-for="dict in customerServiceList"
:key="dict.id" :label="dict.nickname" :value="dict.id"/>
<el-form-item label="国家" prop="source">
<el-select clearable v-model="form.country" placeholder="请选择国家">
<el-option v-for="dict in countryList"
:key="dict.id" :label="dict.nameZh" :value="parseInt(dict.id)" />
</el-select>
</el-form-item>
<el-form-item label="客户状态" prop="status">
<el-select v-model="queryParams.status" placeholder="请选择客户状态" clearable size="small">
<el-select clearable v-model="queryParams.status" placeholder="请选择客户状态" clearable size="small">
<el-option v-for="dict in getDictDatas(DICT_TYPE.CUSTOMER_STATUS)"
:key="dict.value" :label="dict.label" :value="dict.value"/>
</el-select>
</el-form-item>
<el-form-item label="部门" prop="department">
<el-input v-model="queryParams.department" placeholder="请输入部门" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="创建时间">
<el-date-picker v-model="dateRangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd"
<el-date-picker clearable v-model="dateRangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期" />
</el-form-item>
<el-form-item label="信用等级" prop="department">
<el-select clearable v-model="form.level" >
<el-option v-for="(item,index) in creditList" :label="item.nameZh" :key="index" :value="item.id" ></el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="handleQuery">搜索</el-button>
<el-button icon="el-icon-refresh" @click="resetQuery">重置</el-button>
......@@ -57,36 +71,44 @@
<el-button type="warning" plain icon="el-icon-download" size="mini" @click="handleExport" :loading="exportLoading"
v-hasPermi="['ecw:customer:export']">导出</el-button>
</el-col>
<el-col :span="1.5">
<el-col :span="1.5" >
<el-button :disabled="selectCustomerList.length === 0" type="warning" size="mini" @click="batchTransferShow = true;" :loading="exportLoading"
v-hasPermi="['ecw:customer:export']">批量移交</el-button>
</el-col>
</el-col>
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<!-- 列表 -->
<el-table v-loading="loading" :data="list">
<el-table ref="multipleTable" v-loading="loading" :data="list" @selection-change="handleSelectionChange">
<el-table-column
type="selection"
width="55">
</el-table-column>
<el-table-column label="客户编号" align="center" prop="number" />
<el-table-column label="客户名称" align="center" prop="name" />
<el-table-column label="客户等级" align="center" prop="level">
<el-table-column label="客户等级" align="center" prop="vipLevelNameZh">
<template slot-scope="scope">
<dict-tag :type="DICT_TYPE.CUSTOMER_LEVEL" :value="scope.row.level" />
</template>
</el-table-column>
<el-table-column label="国家" align="center" prop="country">
<template slot-scope="scope">
<dict-tag :type="DICT_TYPE.COUNTRY" :value="scope.row.country" />
</template>
</el-table-column>
<el-table-column label="客户经理" align="center" prop="customerService" :formatter="customerServiceFn">
</el-table-column>
<el-table-column label="信用等级" prop="creditLevelNameZh"></el-table-column>
<el-table-column label="客户状态" align="center" prop="status">
<template slot-scope="scope">
<dict-tag :type="DICT_TYPE.CUSTOMER_STATUS" :value="scope.row.status" />
</template>
</el-table-column>
<el-table-column label="部门" align="center" prop="department" />
<el-table-column label="主联系人" prop="defaultContactName"></el-table-column>
<el-table-column label="主联系方式" prop="defaultContactPhone"></el-table-column>
<el-table-column label="创建时间" align="center" prop="createTime" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.createTime) }}</span>
</template>
</el-table-column>
<el-table-column label="客户经理" align="center" prop="customerService" :formatter="customerServiceFn">
</el-table-column>
<el-table-column label="国家" align="center" prop="country" :formatter="countryFormatter"></el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button size="mini" type="text" icon="el-icon-edit" @click="handleUpdate(scope.row)"
......@@ -120,6 +142,7 @@
<!-- 分页组件 -->
<pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNo" :limit.sync="queryParams.pageSize"
@pagination="getList"/>
<transfer-customer :show.sync="batchTransferShow" :customer-ids.sync="selectCustomerList"></transfer-customer>
</div>
</template>
......@@ -129,13 +152,18 @@ import { createCustomer, updateCustomer, deleteCustomer, getCustomer,handOverCus
import { getDictDatas, DICT_TYPE } from '@/utils/dict';
import upload from '@/components/ImageUpload'
import {listServiceUser} from "@/api/system/user";
import {getCountryListAll} from "@/api/ecw/country";
import {getCreditPage} from "@/api/customer/credit";
import transferCustomer from "@/views/ecw/customer/transferCustomer";
export default {
name: "customerToBeAssigned",
components: {
upload
upload,
transferCustomer
},
data() {
return {
batchTransferShow:false,
getDictDatas,
DICT_TYPE,
// 遮罩层
......@@ -186,9 +214,19 @@ export default {
service:undefined,//客服
transferData:undefined,//移交数据
transferShow:false,
creditList:[],
selectCustomerList:[],
countryList:[]
};
},
created() {
getCountryListAll().then(r => {
console.log(r,'国家')
this.countryList = r.data
})
getCreditPage({page:1,rows:999}).then(r => {
this.creditList = r.data.list
})
this.getList();
listServiceUser().then(r=>{
console.log(r,'客服');
......@@ -199,6 +237,13 @@ export default {
// })
},
methods: {
countryFormatter(row, column, cellValue) {
const country = this.countryList.find((e) => e.id === cellValue)
return country?.nameZh
},
handleSelectionChange(val){
this.selectCustomerList = val.map(i => i.id);
},
/** 查询列表 */
getList() {
this.loading = true;
......@@ -370,6 +415,14 @@ export default {
return ''
}
}
},
watch:{
selectCustomerList(val){
if(val.length === 0){
this.getList()
this.$refs.multipleTable.clearSelection();
}
},
}
};
</script>
This diff is collapsed.
......@@ -40,7 +40,9 @@
<el-table v-loading="loading" :data="list">
<el-table-column label="目标名称" align="center" width="180">
<template slot-scope="scope">
<span>{{scope.row.deptName}}{{scope.row.targetPeriodName}}目标</span>
<router-link :to="{path: '/deptTarget/empAchievement',query: {row: scope.row}}" class="link-type">
<span>{{scope.row.deptName}}{{scope.row.targetPeriodName}}目标</span>
</router-link>
</template>
</el-table-column>
<el-table-column label="部门" align="center" prop="deptName"/>
......@@ -80,8 +82,8 @@
<el-button size="mini" type="text" icon="el-icon-delete" @click="handleDelete(scope.row)"
v-hasPermi="['ecw:dept-target:delete']">删除
</el-button>
<el-button size="mini" type="text" icon="el-icon-search" @click="handleView(scope.row)"
v-hasPermi="['ecw:dept-target:create']"></el-button>
<!-- <el-button size="mini" type="text" icon="el-icon-search" @click="handleView(scope.row)"-->
<!-- v-hasPermi="['ecw:dept-target:create']"></el-button>-->
</template>
</el-table-column>
</el-table>
......@@ -127,49 +129,6 @@
</div>
</el-dialog>
<!--人员目标进度-->
<el-dialog title="人员目标进度" :visible.sync="tableOpen" width="1000px" append-to-body>
<div><span><b>{{detail.deptName}}-{{getDictDataLabel(DICT_TYPE.TARGET_TYPE,detail.targetType)}}</b></span></div>
<div>
<span>运输方式:</span><span>{{getDictDataLabel(DICT_TYPE.TRANSPORT_TYPE,detail.transportType)}}</span>
<span>出货渠道:</span><span>{{ getShipChannelName(detail.shippingChannel) }}</span>
<span>部门目标:</span><span>{{detail.cubeNum}}</span>
</div>
<el-table v-loading="loading" :data="tableList">
<el-table-column label="员工名称" align="center" width="180">
<template slot-scope="scope">
<span>{{scope.row.userName}}</span>
</template>
</el-table-column>
<el-table-column label="部门" align="center">
<template>
<span>{{detail.deptName}}</span>
</template>
</el-table-column>
<el-table-column label="目标类型" align="center" prop="targetType">
<template slot-scope="scope">
<dict-tag :type="DICT_TYPE.TARGET_TYPE" :value="scope.row.targetType"/>
</template>
</el-table-column>
<el-table-column label="时间范围" align="center" prop="targetPeriodName">
<template slot-scope="scope">
<span>{{dateFormat(scope.row.startTime)}}~{{dateFormat(scope.row.endTime)}}</span>
</template>
</el-table-column>
<el-table-column label="个人目标方数" align="center" prop="personalCubeNum"/>
<el-table-column label="已完成方数" align="center" prop="personalCompleteCubeNum"/>
<el-table-column label="完成比例" align="center">
<template slot-scope="scope">
<span>{{ (scope.row.personalCompleteCubeNum/scope.row.personalCubeNum*100).toFixed(2)+'%' }}</span>
</template>
</el-table-column>
</el-table>
<!-- 分页组件 -->
<pagination v-show="tableTotal > 0" :total="tableTotal" :page.sync="tableQueryParams.pageNo"
:limit.sync="tableQueryParams.pageSize"
@pagination="getTableList"/>
</el-dialog>
</div>
</template>
......
......@@ -159,8 +159,8 @@
v-model="form.openInvoice"
placeholder="请选择是否需要开票"
>
<el-option :value="1" label="需要"></el-option>
<el-option :value="0" label="不需要"></el-option>
<el-option :value="1" label=""></el-option>
<el-option :value="0" label=""></el-option>
</el-select>
</el-form-item>
</el-descriptions-item>
......@@ -377,7 +377,8 @@
</el-card>
</el-form>
<div slot="footer" style="margin: 20px 0">
<el-button type="primary" :loading="saveBtnLoading" @click="submitForm(1)"> </el-button>
<el-button v-if="id==0" type="primary" :loading="saveBtnLoading" @click="submitForm(1)"> </el-button>
<el-button v-else type="primary" :loading="saveBtnLoading" @click="$store.dispatch('tagsView/delCurrentView')"> </el-button>
<el-button type="primary" :loading="saveBtnLoading" @click="submitForm(0)">{{ id ? '修 改' : '新 增' }}</el-button>
</div>
<el-dialog
......@@ -596,7 +597,7 @@
<dict-tag :type="DICT_TYPE.BOX_SHIPPING_PRICE_UNIT" :value="selectListRow.currencyId" />
</el-form-item>
<el-form-item label="优惠金额">
<el-input v-model="discountForm.discountTotal" style="width: 300px"></el-input>
<el-input v-model="discountForm.discountTotal" type="number" min="0" :max="selectListRow.totalAmount" @input="checkDiscount" style="width: 300px" ></el-input>
&nbsp;&nbsp;
<dict-tag :type="DICT_TYPE.BOX_SHIPPING_PRICE_UNIT" :value="selectListRow.currencyId" />
</el-form-item>
......@@ -698,6 +699,7 @@ export default {
let that = this;
if (that.$route.query.id) {
this.id = this.$route.query.id;
console.log(this.id)
getReceiptInfoByIds({ id: this.id }).then(res => {
res.data.rateValidateDate = dayjs(res.data.rateValidateDate).format('YYYY-MM-DD HH:mm:ss')
this.form = Object.assign({}, this.form, res.data)
......@@ -808,6 +810,12 @@ export default {
}
},
methods: {
checkDiscount(e){
console.log(e)
if(e>this.selectListRow.totalAmount){
this.discountForm.discountTotal = this.selectListRow.totalAmount
}
},
currencyIdChange(val, row, index) {
row.collectionCurrencyId = val
if (val == row.currencyId) row.collectionRate = 1
......@@ -819,7 +827,7 @@ export default {
if (row.currencyId == 3 && val == 1) row.collectionRate = this.NANtoUS()
if (row.currencyId == 3 && val == 2) row.collectionRate = this.NANtoRMB()
}
this.rateChange(row, index)
},
writeOffRateChange(row, index) {
......@@ -835,13 +843,13 @@ export default {
setTimeout(() => {
// 收款总计
const dollarList = this.form.receiptAccountList.filter(v => v.collectionCurrencyId == 1)
const dollar = dollarList.reduce((total, currentValue) => NP.plus(total, NP.minus(currentValue.receivableAmount, currentValue.discountTotal || 0) || 0), 0)
const dollar = dollarList.reduce((total, currentValue) => NP.plus(total, currentValue.collectionAmount), 0)
const rmbList = this.form.receiptAccountList.filter(v => v.collectionCurrencyId == 2)
const rmb = rmbList.reduce((total, currentValue) => NP.plus(total, NP.minus(currentValue.receivableAmount, currentValue.discountTotal || 0) || 0), 0)
const rmb = rmbList.reduce((total, currentValue) => NP.plus(total, currentValue.collectionAmount), 0)
const nairaList = this.form.receiptAccountList.filter(v => v.collectionCurrencyId == 3)
const naira = nairaList.reduce((total, currentValue) => NP.plus(total, NP.minus(currentValue.receivableAmount, currentValue.discountTotal || 0) || 0), 0)
const naira = nairaList.reduce((total, currentValue) => NP.plus(total, currentValue.collectionAmount), 0)
this.form.receiptAccountList[this.form.receiptAccountList.length -1].collectionAmount = [dollar, rmb, naira]
this.$set(this.form, 'receiptAccountList', [...this.form.receiptAccountList])
......@@ -857,7 +865,7 @@ export default {
discountDollar = dollarList.reduce((total, currentValue) => NP.plus(total, currentValue.discountTotal || 0), 0)
const t = copyList.find(v => v.currencyId == 1)
this.form.receiptAccountList = [
{
{
discountTotal: discountDollar,
currencyId: 1,
receivableAmount: dollar,
......@@ -877,7 +885,7 @@ export default {
const t = copyList.find(v => v.currencyId == 2)
this.form.receiptAccountList = [
...this.form.receiptAccountList,
{
{
discountTotal: discountRmb,
currencyId: 2,
receivableAmount: rmb,
......@@ -897,7 +905,7 @@ export default {
const t = copyList.find(v => v.currencyId == 3)
this.form.receiptAccountList = [
...this.form.receiptAccountList,
{
{
discountTotal: discountNaira,
currencyId: 3,
receivableAmount: naira,
......@@ -996,7 +1004,7 @@ export default {
})
},
getReceivableListByIds() {
},
cancelDiscount() {
this.discountVisible = false
......
......@@ -15,7 +15,7 @@
<el-form-item label="柜号:">
<el-input
style="max-width: 188px"
v-model="queryParams.orderNo"
v-model="queryParams.containerNo"
placeholder="请输入柜号"
clearable
@keyup.enter.native="handleQuery"
......@@ -24,7 +24,7 @@
<el-form-item label="自编号:">
<el-input
style="max-width: 188px"
v-model="queryParams.orderNo"
v-model="queryParams.payableNo"
placeholder="请输入自编号"
clearable
@keyup.enter.native="handleQuery"
......@@ -37,6 +37,7 @@
<el-select
v-model="queryParams.departureId"
placeholder="请选择始发城市"
clearable
>
<el-option
v-for="item in expoerCityList"
......@@ -50,6 +51,7 @@
<el-select
v-model="queryParams.objectiveId"
placeholder="请选择目的城市"
clearable
>
<el-option
v-for="item in importCityList"
......@@ -64,6 +66,7 @@
:type="DICT_TYPE.ECW_TRANSPORT_TYPE"
v-model="queryParams.transportId"
formatter="number"
clearable
/>
</el-form-item>
</el-row>
......
......@@ -42,6 +42,7 @@
<el-select
v-model="queryParams.departureId"
placeholder="请选择始发城市"
clearable
>
<el-option
v-for="item in expoerCityList"
......@@ -55,6 +56,7 @@
<el-select
v-model="queryParams.objectiveId"
placeholder="请选择目的城市"
clearable
>
<el-option
v-for="item in importCityList"
......@@ -69,12 +71,14 @@
:type="DICT_TYPE.ECW_TRANSPORT_TYPE"
v-model="queryParams.transportId"
formatter="number"
clearable
/>
</el-form-item>
<el-form-item label="控货:">
<dict-selector
:type="DICT_TYPE.INFRA_BOOLEAN_STRING"
v-model="queryParams.isCargoControl"
clearable
/>
</el-form-item>
</el-row>
......@@ -83,12 +87,14 @@
<dict-selector
:type="DICT_TYPE.ORDER_STATUS"
v-model="queryParams.status"
clearable
/>
</el-form-item>
<el-form-item label="报关方式:">
<dict-selector
:type="DICT_TYPE.ECW_CUSTOMS_TYPE"
v-model="queryParams.customsType"
clearable
/>
</el-form-item>
<el-form-item label="订单号:">
......@@ -133,12 +139,14 @@
<dict-selector
:type="DICT_TYPE.FEE_TYPE"
v-model="queryParams.feeType"
clearable
></dict-selector>
</el-form-item>
<el-form-item label="发货人:">
<customer-selector
v-model="queryParams.consignorNameOrPhone"
@change="consignor = $event"
clearable
/>
</el-form-item>
<!-- <el-form-item label="发货人:" >
......@@ -151,6 +159,7 @@
<customer-selector
v-model="queryParams.consigneeNameOrPhone"
@change="consignor = $event"
clearable
/>
</el-form-item>
<el-form-item label="自编号:">
......@@ -189,7 +198,7 @@
<el-table-column label="唛头" align="center" prop="marks" />
<el-table-column label="品名" align="center" prop="title">
<template slot-scope="scope">
{{ scope.row.titleZh + "(" + scope.row.titleEn + ")" }}
{{ scope.row.titleZh? (scope.row.titleZh + "(" + scope.row.titleEn + ")"):'' }}
</template>
</el-table-column>
<el-table-column label="箱数" align="center" prop="num" />
......
......@@ -11,36 +11,50 @@
<el-input v-model="queryParams.name" placeholder="请输入客户名称" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="客户等级" prop="level">
<el-select v-model="queryParams.level" placeholder="请选择客户等级" clearable size="small">
<el-select clearable v-model="queryParams.level" placeholder="请选择客户等级" clearable size="small">
<el-option v-for="dict in getDictDatas(DICT_TYPE.CUSTOMER_LEVEL)"
:key="dict.value" :label="dict.label" :value="dict.value"/>
</el-select>
</el-form-item>
<el-form-item label="联系方式">
<el-input placeholder="请输入联系方式" v-model="queryParams.defaultContactPhone"></el-input>
</el-form-item>
<el-form-item label="客户类别" prop="level">
<dict-selector :type="DICT_TYPE.CUSTOMER_TYPE" multiple v-model="queryParams.type"></dict-selector>
</el-form-item>
<el-form-item label="客户经理" prop="customerService">
<el-select clearable v-model="queryParams.customerService" placeholder="请选择客户经理" clearable size="small">
<el-option v-for="dict in customerServiceList"
:key="dict.id" :label="dict.nickname" :value="dict.id"/>
</el-select>
</el-form-item>
<el-form-item label="客户来源" prop="source">
<el-select v-model="queryParams.source" placeholder="请选择客户来源" clearable size="small">
<el-select clearable v-model="queryParams.source" placeholder="请选择客户来源" clearable size="small">
<el-option v-for="dict in getDictDatas(DICT_TYPE.CUSTOMER_SOURCE)"
:key="dict.value" :label="dict.label" :value="dict.value"/>
</el-select>
</el-form-item>
<el-form-item label="客户经理" prop="customerService">
<el-select v-model="queryParams.customerService" placeholder="请选择客户经理" clearable size="small">
<el-option v-for="dict in customerServiceList"
:key="dict.id" :label="dict.nickname" :value="dict.id"/>
<el-form-item label="国家" prop="source">
<el-select clearable v-model="form.country" placeholder="请选择国家">
<el-option v-for="dict in countryList"
:key="dict.id" :label="dict.nameZh" :value="parseInt(dict.id)" />
</el-select>
</el-form-item>
<el-form-item label="客户状态" prop="status">
<el-select v-model="queryParams.status" placeholder="请选择客户状态" clearable size="small">
<el-select clearable v-model="queryParams.status" placeholder="请选择客户状态" clearable size="small">
<el-option v-for="dict in getDictDatas(DICT_TYPE.CUSTOMER_STATUS)"
:key="dict.value" :label="dict.label" :value="dict.value"/>
</el-select>
</el-form-item>
<el-form-item label="部门" prop="department">
<el-input v-model="queryParams.department" placeholder="请输入部门" clearable @keyup.enter.native="handleQuery"/>
</el-form-item>
<el-form-item label="创建时间">
<el-date-picker v-model="dateRangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd"
<el-date-picker clearable v-model="dateRangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期" />
</el-form-item>
<el-form-item label="信用等级" prop="department">
<el-select clearable v-model="form.level" >
<el-option v-for="(item,index) in creditList" :label="item.nameZh" :key="index" :value="item.id" ></el-option>
</el-select>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="handleQuery">搜索</el-button>
<el-button icon="el-icon-refresh" @click="resetQuery">重置</el-button>
......@@ -73,29 +87,27 @@
</el-table-column>
<el-table-column label="客户编号" align="center" prop="number" />
<el-table-column label="客户名称" align="center" prop="name" />
<el-table-column label="客户等级" align="center" prop="level">
<el-table-column label="客户等级" align="center" prop="vipLevelNameZh">
<template slot-scope="scope">
<dict-tag :type="DICT_TYPE.CUSTOMER_LEVEL" :value="scope.row.level" />
</template>
</el-table-column>
<el-table-column label="国家" align="center" prop="country">
<template slot-scope="scope">
<dict-tag :type="DICT_TYPE.COUNTRY" :value="scope.row.country" />
</template>
</el-table-column>
<el-table-column label="客户经理" align="center" prop="customerService" :formatter="customerServiceFn">
</el-table-column>
<el-table-column label="信用等级" prop="creditLevelNameZh"></el-table-column>
<el-table-column label="客户状态" align="center" prop="status">
<template slot-scope="scope">
<dict-tag :type="DICT_TYPE.CUSTOMER_STATUS" :value="scope.row.status" />
</template>
</el-table-column>
<el-table-column label="部门" align="center" prop="department" />
<el-table-column label="主联系人" prop="defaultContactName"></el-table-column>
<el-table-column label="主联系方式" prop="defaultContactPhone"></el-table-column>
<el-table-column label="创建时间" align="center" prop="createTime" width="180">
<template slot-scope="scope">
<span>{{ parseTime(scope.row.createTime) }}</span>
</template>
</el-table-column>
<el-table-column label="客户经理" align="center" prop="customerService" :formatter="customerServiceFn">
</el-table-column>
<el-table-column label="国家" align="center" prop="country" :formatter="countryFormatter"></el-table-column>
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
<template slot-scope="scope">
<el-button size="mini" type="text" icon="el-icon-folder-add" @click="distribution(scope.row)">移交</el-button>
......@@ -134,6 +146,8 @@ import { createCustomer, updateCustomer, deleteCustomer,handOverCustomer,getPubl
import { getDictDatas, DICT_TYPE } from '@/utils/dict';
import upload from '@/components/ImageUpload'
import {listServiceUser} from "@/api/system/user";
import {getCountryListAll} from "@/api/ecw/country";
import {getCreditPage} from "@/api/customer/credit";
export default {
name: "customerToBeAssigned",
components: {
......@@ -193,6 +207,8 @@ export default {
transferShow:false,
multipleSelection:[],
isBatch:false,
countryList:[],
creditList:[]
};
},
created() {
......@@ -201,11 +217,21 @@ export default {
console.log(r,'客服');
this.customerServiceList = r.data;
})
getCountryListAll().then(r => {
this.countryList = r.data
})
getCreditPage({page:1,rows:999}).then(r => {
this.creditList = r.data.list
})
// getNodeList().then(r => {
// this.nodeList = r.data
// })
},
methods: {
countryFormatter(row, column, cellValue) {
const country = this.countryList.find((e) => e.id === cellValue)
return country?.nameZh
},
/** 查询列表 */
getList() {
this.loading = true;
......
......@@ -196,6 +196,7 @@ export default {
/** 查询列表 */
getList() {
this.loading = true;
this.list = []
// 处理查询参数
let params = {...this.queryParams}
// 执行查询
......@@ -203,7 +204,7 @@ export default {
this.list = response.data.list;
this.total = response.data.total;
this.loading = false;
this.reset()
// this.reset()
});
},
/** 表单重置 */
......
......@@ -8,7 +8,7 @@
<el-divider></el-divider>
<el-form inline label-width="100px">
<el-form-item label="订单号"><div class="content">
<el-input v-model.trim="params.relateOrderNo"></el-input>
<el-input v-model.trim="params.mutualOrderNo"></el-input>
</div></el-form-item>
<el-form-item><div class="content">
<el-button @click="getList">查询</el-button>
......
......@@ -5,7 +5,7 @@
<el-form inline label-width="85px" label-position="left">
<el-form-item label="订单号">
<div class="content">
<el-input v-model.trim="params.relateOrderNo"></el-input>
<el-input v-model.trim="params.mutualOrderNo"></el-input>
</div>
</el-form-item>
<el-form-item>
......
......@@ -278,6 +278,12 @@
<!--设置服务-->
<el-dialog title="设置服务" :visible.sync="serviceOpen" width="1000px" append-to-body>
<div style="font-size:large">
线路:{{this.startName}}到{{this.destName}}<span style="margin-left:20px">运输方式:{{transportName(this.lineform.transportType)}}</span>
</div>
<br/>
<el-form ref="form" :model="lineform" :rules="rules" label-width="120px">
<el-form-item label="始发港服务">
<el-checkbox-group v-model="lineform.otherService">
......@@ -501,6 +507,8 @@ export default {
form: {checkList:[],},
ladingform: {prefixCounter:null,titleZh:null,contentZh:null,account:null,acctArr:[]},
lineform: {otherService:[]},
startName:'',
destName:'',
// 表单校验
rules: {
......@@ -785,6 +793,11 @@ export default {
},
serviceClick(row) {
if(this.routeQueryParam.tradeType == 1) {
this.destName = row.titleZh;
} else {
this.startName = row.titleZh;
}
if(row.otherService) {
this.lineform.otherService = Array.isArray(row.otherService) ? row.otherService : row.otherService?.split(",") ?? [];
} else {
......@@ -792,6 +805,7 @@ export default {
}
this.serviceOpen = true;
this.lineform.lineId = row.lineId;
this.lineform.transportType = row.transportType;
},
submitLineForm() {
......@@ -835,7 +849,13 @@ export default {
this.routeQueryParam.pageNo = 1;
this.showRouteList = true;
this.routeLoadig = true;
if(tradeType == 1) {
this.startName = row.titleZh;
} else {
this.destName = row.titleZh;
}
this.getRouteList();
},
......
......@@ -270,6 +270,7 @@ export default {
const id = row.id;
getZhongPao(id).then(response => {
const form = response.data;
// console.log(form);
form.objectiveIds = form.objectiveIds && form.objectiveIds.length > 0 ? form.objectiveIds.split(',') : []
......@@ -286,6 +287,7 @@ export default {
}
let form = this.form
form.objectiveIds = form.objectiveIds?.join(',')
form.transportTypes = form.transportTypes?.join(',');
// 修改的提交
if (this.form.id != null) {
updateZhongPao(this.form).then(response => {
......@@ -297,6 +299,8 @@ export default {
return;
}
// 添加的提交
// console.log(this.form);
createZhongPao(this.form).then(response => {
this.$modal.msgSuccess("新增成功");
this.open = false;
......
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