Commit 0d8c20bb authored by 黄奎's avatar 黄奎

页面修改

parent 44ca2cbd
...@@ -220,6 +220,7 @@ export const admin={ //行政 ...@@ -220,6 +220,7 @@ export const admin={ //行政
mane:'名前', mane:'名前',
admin_group:'グループ名', admin_group:'グループ名',
admin_company:'会社名', admin_company:'会社名',
CompanyTitle:"確認物の台頭",
admin_department:'部署名', admin_department:'部署名',
admin_departmentLevel:'部署ランク', admin_departmentLevel:'部署ランク',
admin_parentdepartment:'上司', admin_parentdepartment:'上司',
......
...@@ -220,7 +220,7 @@ export const admin={ //行政 ...@@ -220,7 +220,7 @@ export const admin={ //行政
mane:'名称', mane:'名称',
admin_group:'集团名称', admin_group:'集团名称',
admin_company:'公司名称', admin_company:'公司名称',
CompanyTitle:"", CompanyTitle:"确认件抬头",
admin_department:'部门名称', admin_department:'部门名称',
admin_departmentLevel:'部门层级', admin_departmentLevel:'部门层级',
admin_parentdepartment:'上级部门', admin_parentdepartment:'上级部门',
......
...@@ -52,8 +52,8 @@ ...@@ -52,8 +52,8 @@
background: #fff; background: #fff;
padding-top: 20px; padding-top: 20px;
box-sizing: border-box; box-sizing: border-box;
overflow: hidden!important; overflow: hidden !important;
} }
.page_MyCustomer ._mc_list>ul>li { .page_MyCustomer ._mc_list>ul>li {
...@@ -319,49 +319,79 @@ ...@@ -319,49 +319,79 @@
.page_MyCustomer .upload-demo { .page_MyCustomer .upload-demo {
text-align: center; text-align: center;
} }
.MycustomerTable th,.MycustomerTable td{
.MycustomerTable th,
.MycustomerTable td {
text-align: left; text-align: left;
padding-left:25px padding-left: 25px
}
.MyCustomerDetailbottomLayer {
overflow: auto;
position: absolute;
height: 200px;
z-index: 50;
bottom: 0;
left: 0;
border-top: 1px solid #d1d1d1;
background-color: #FFFFFF;
padding: 20px 20px 0;
width: 100%;
}
.MyCustomerDetailbottomLayer>p {
border-left: 3px solid #E95252;
text-indent: 15px;
height: 14px;
font-size: 14px;
margin-bottom: 20px;
line-height: 14px;
color: #000;
}
.MyCustomerDetailbottomLayer .el-form-item__label {
font-size: 12px !important;
}
.MyCustomerDetailbottomLayer .avatar-uploader .el-upload {
border: 1px dashed #d9d9d9;
border-radius: 6px;
cursor: pointer;
position: relative;
overflow: hidden;
}
.MyCustomerDetailbottomLayer .avatar-uploader .el-upload:hover {
border-color: #409EFF;
} }
.MyCustomerDetailbottomLayer{overflow: auto; position:absolute;height:200px;
z-index:50;bottom:0;left: 0;border-top:1px solid #d1d1d1;background-color:#FFFFFF;padding: 20px 20px 0;width: 100%;} .MyCustomerDetailbottomLayer .avatar-uploader-icon {
.MyCustomerDetailbottomLayer>p{border-left: 3px solid #E95252; text-indent: 15px; height: 14px; font-size: 14px; margin-bottom:20px; line-height: 14px; color: #000;} font-size: 28px;
.MyCustomerDetailbottomLayer .el-form-item__label{font-size: 12px!important;} color: #8c939d;
width: 148px;
.MyCustomerDetailbottomLayer .avatar-uploader .el-upload { height: 148px;
border: 1px dashed #d9d9d9; line-height: 148px;
border-radius: 6px; text-align: center;
cursor: pointer; }
position: relative;
overflow: hidden; .MyCustomerDetailbottomLayer .avatar {
} width: 148px;
.MyCustomerDetailbottomLayer .avatar-uploader .el-upload:hover { height: 148px;
border-color: #409EFF; display: block;
} }
.MyCustomerDetailbottomLayer .avatar-uploader-icon {
font-size: 28px; .yichangde {
color: #8c939d; display: inline-block;
width: 148px; border-radius: 50%;
height: 148px; color: red;
line-height: 148px; border: 1px solid red;
text-align: center; font-size: 12px;
} width: 18px;
.MyCustomerDetailbottomLayer .avatar { height: 18px;
width: 148px; text-align: center;
height: 148px; cursor: pointer;
display: block; }
}
.yichangde{
display: inline-block;
border-radius: 50%;
color: red;
border: 1px solid red;
font-size: 12px;
width: 18px;
height: 18px;
text-align: center;
cursor:pointer;
}
</style> </style>
<template> <template>
<div class="page_MyCustomer MyCustomerDiv"> <div class="page_MyCustomer MyCustomerDiv">
...@@ -375,7 +405,8 @@ ...@@ -375,7 +405,8 @@
</li> </li>
<li> <li>
<button class="hollowFixedBtn" @click="getList()">{{$t('pub.searchBtn')}}</button> <button class="hollowFixedBtn" @click="getList()">{{$t('pub.searchBtn')}}</button>
<button class="normalBtn" @click="addShow=true;isOldPerson=false,addLayer1=false">{{$t('salesModule.addCustomer')}}</button> <button class="normalBtn"
@click="addShow=true;isOldPerson=false,addLayer1=false">{{$t('salesModule.addCustomer')}}</button>
<button class="normalBtn" @click="outerVisible=true">导入</button> <button class="normalBtn" @click="outerVisible=true">导入</button>
<button class="normalBtn" @click="getDownList">模板下载</button> <button class="normalBtn" @click="getDownList">模板下载</button>
</li> </li>
...@@ -399,80 +430,88 @@ ...@@ -399,80 +430,88 @@
</li> </li>
</div> </div>
<div class="_mc_list _scrollbar" :class="addShow==true?'_edHeight':''"> <div class="_mc_list _scrollbar" :class="addShow==true?'_edHeight':''">
<table class="MycustomerTable singeRowTable" border="0" cellspacing="0" cellpadding="0" v-loading="loading"> <table class="MycustomerTable singeRowTable" border="0" cellspacing="0" cellpadding="0" v-loading="loading">
<tr> <tr>
<th>姓名</th> <th>姓名</th>
<th>联系电话</th> <th>联系电话</th>
<th>门店名称</th> <th>门店名称</th>
<th>近期约访</th> <th>近期约访</th>
<th>最近拜访</th> <th>最近拜访</th>
<th>累计拜访</th> <th>累计拜访</th>
<th>幸福存折</th> <th>幸福存折</th>
<th>累计交易额</th> <th>累计交易额</th>
<th>询价与需求</th> <th>询价与需求</th>
<th>所属联盟</th> <th>所属联盟</th>
<th>优惠券</th> <th>优惠券</th>
<th>操作</th> <th>操作</th>
</tr>
</tr> <tr v-for="(item,i) in dataList" :key="i">
<tr v-for="(item,i) in dataList" :key="i"> <td>
<td> <span>{{item.contact}}</span>
<span>{{item.contact}}</span> <el-popover width="280" popper-class="pd20" trigger="click">
<el-popover width="280" popper-class="pd20" trigger="click"> <table width="100%" border="0" cellspacing="0" cellpadding="0">
<table width="100%" border="0" cellspacing="0" cellpadding="0"> <tr class="_color_666">
<tr class="_color_666"> <th>异常名称</th>
<th>异常名称</th> <th>创建人</th>
<th>创建人</th> <th>创建时间</th>
<th>创建时间</th> </tr>
</tr> <tr v-for="(unionItem,x) in CustomerException">
<tr v-for="(unionItem,x) in CustomerException"> <td>{{unionItem.ExceptionName}}</td>
<td>{{unionItem.ExceptionName}}</td> <td>{{unionItem.CreateByName}}</td>
<td>{{unionItem.CreateByName}}</td> <td>{{unionItem.CreateTimestr}}</td>
<td>{{unionItem.CreateTimestr}}</td> </tr>
</tr> </table>
</table> <span v-show="item.exceptionCount > 0" slot="reference" class="yichangde"
<span v-show="item.exceptionCount > 0" slot="reference" class="yichangde" @click="yichangde(item)"></span> @click="yichangde(item)"></span>
</el-popover> </el-popover>
</td> </td>
<td>{{item.contactNumber}}</td> <td>{{item.contactNumber}}</td>
<td>{{item.customerName}}</td> <td>{{item.customerName}}</td>
<td> <td>
<p v-if="item.customerVisitList.length>0"> <p v-if="item.customerVisitList.length>0">
{{item.customerVisitList[0].visitDateTime}} {{item.customerVisitList[0].visitDateTime}}
</p> </p>
<p v-else>{{$t('salesModule.noYuefang')}}</p> <p v-else>{{$t('salesModule.noYuefang')}}</p>
</td> </td>
<td> <td>
<div @click="goUrl(type,item.customerId,1)"> <div @click="goUrl(type,item.customerId,1)">
<p v-if="item.customerVisitList[1]"> <p v-if="item.customerVisitList[1]">
<span style="cursor: pointer;text-decoration: underline;">{{item.customerVisitList[1].visitDateTime}}</span></p> <span
style="cursor: pointer;text-decoration: underline;">{{item.customerVisitList[1].visitDateTime}}</span>
</p>
<p v-else> <p v-else>
<span style="cursor: pointer;text-decoration: underline;">{{$t('pub.noMsg')}}</span></p> <span style="cursor: pointer;text-decoration: underline;">{{$t('pub.noMsg')}}</span></p>
</div> </div>
</td> </td>
<td><span @click="goUrl(type,item.customerId,2)" style="cursor: pointer;text-decoration: underline;">{{item.visiteCount}}</span></td> <td><span @click="goUrl(type,item.customerId,2)"
<td>{{item.cL_Balance}}</td> style="cursor: pointer;text-decoration: underline;">{{item.visiteCount}}</span></td>
<td><span @click="goUrl(type,item.customerId,3)" style="cursor: pointer;text-decoration: underline;">{{item.tradeTotal}}</span></td> <td>{{item.cL_Balance}}</td>
<td>{{item.inquireCount}}</td> <td><span @click="goUrl(type,item.customerId,3)"
<td>{{item.allianceName}}</td> style="cursor: pointer;text-decoration: underline;">{{item.tradeTotal}}</span></td>
<td><span style="cursor: pointer;text-decoration: underline;" @click.stop="goUrC('CouponsList',item.customerAccountId)">{{item.couponNum}}</span></td> <td>{{item.inquireCount}}</td>
<td> <td>{{item.allianceName}}</td>
<el-tooltip class="item" effect="dark" content="编辑" placement="top-start"> <td><span style="cursor: pointer;text-decoration: underline;"
<el-button @click.stop="EditMsg(item)" style="padding:4px" type="primary" icon="iconfont icon-bianji" circle></el-button> @click.stop="goUrC('CouponsList',item.customerAccountId)">{{item.couponNum}}</span></td>
<td>
<el-tooltip class="item" effect="dark" content="编辑" placement="top-start">
<el-button @click.stop="EditMsg(item)" style="padding:4px" type="primary" icon="iconfont icon-bianji"
circle></el-button>
</el-tooltip> </el-tooltip>
<el-tooltip class="item" effect="dark" content="账户管理" placement="top-start"> <el-tooltip class="item" effect="dark" content="账户管理" placement="top-start">
<el-button style="padding:4px" @click.stop="goUrlT('empBankAccount',item.customerId)" type="danger" icon="iconfont icon-guanliyuan" circle></el-button> <el-button style="padding:4px" @click.stop="goUrlT('empBankAccount',item.customerId)" type="danger"
icon="iconfont icon-guanliyuan" circle></el-button>
</el-tooltip> </el-tooltip>
<el-tooltip class="item" effect="dark" content="交易详情" placement="top-start"> <el-tooltip class="item" effect="dark" content="交易详情" placement="top-start">
<el-button style="padding:4px" @click.stop="goUrC('CustomerAnalysis',item.customerId)" type="success" icon="iconfont icon-icon-test6" circle></el-button> <el-button style="padding:4px" @click.stop="goUrC('CustomerAnalysis',item.customerId)" type="success"
icon="iconfont icon-icon-test6" circle></el-button>
</el-tooltip> </el-tooltip>
</td> </td>
</tr> </tr>
<tr v-if="dataList.length==0"> <tr v-if="dataList.length==0">
<td colspan="12" style="text-align:center">暂无数据</td> <td colspan="12" style="text-align:center">暂无数据</td>
</tr> </tr>
</table> </table>
<el-pagination background @current-change="handleCurrentChange" :current-page.sync="currentPage" <el-pagination background @current-change="handleCurrentChange" :current-page.sync="currentPage"
layout="total,prev, pager, next, jumper" :page-size="this.msg.pageSize" :total="total"> layout="total,prev, pager, next, jumper" :page-size="this.msg.pageSize" :total="total">
</el-pagination> </el-pagination>
...@@ -623,127 +662,104 @@ ...@@ -623,127 +662,104 @@
</el-upload> </el-upload>
</el-dialog> </el-dialog>
<div class="MyCustomerDetailbottomLayer ownScrollbarStyle" style="height:500px;" v-show="addLayer1"> <div class="MyCustomerDetailbottomLayer ownScrollbarStyle" style="height:500px;" v-show="addLayer1">
<p>修改客户信息</p> <p>修改客户信息</p>
<p class="fz12 color333 fbold" style="border: none; padding-left: 3px;">可直接保存</p> <p class="fz12 color333 fbold" style="border: none; padding-left: 3px;">可直接保存</p>
<el-form label-width="80px"> <el-form label-width="80px">
<el-row :gutter="20"> <el-row :gutter="20">
<el-col :span="6"> <el-col :span="6">
<el-form-item label="门店名称:"> <el-form-item label="门店名称:">
<el-input class='w200' v-model='updateMsg.CustomerName'></el-input> <el-input class='w200' v-model='updateMsg.CustomerName'></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="6"> <el-col :span="6">
<el-form-item label="联系人姓名"> <el-form-item label="联系人姓名">
<el-input class='w200' v-model='updateMsg.Contact'></el-input> <el-input class='w200' v-model='updateMsg.Contact'></el-input>
</el-form-item> </el-form-item>
</el-col> </el-col>
<el-col :span="6" v-if="updateMsg.customerExceptionList.length > 0"> <el-col :span="6" v-if="updateMsg.customerExceptionList.length > 0">
<el-form-item label="解决异常"> <el-form-item label="解决异常">
<el-select class='w200' filterable multiple <el-select class='w200' filterable multiple clearable collapse-tags
clearable v-model='updateMsg.CustomerExceptionIds'>
collapse-tags v-model='updateMsg.CustomerExceptionIds'> <el-option v-for='item in updateMsg.customerExceptionList' :label='item.exceptionName'
<el-option v-for='item in updateMsg.customerExceptionList' :value='item.exceptionId' :key='item.exceptionId'>
:label='item.exceptionName' </el-option>
:value='item.exceptionId' </el-select>
:key='item.exceptionId'> </el-form-item>
</el-option> </el-col>
</el-select> <el-col :span="12">
</el-form-item> </el-col>
</el-col> </el-row>
<el-col :span="12"> <el-row :gutter="20" style='margin-top:13px;'>
</el-col> <el-col :span="24">
</el-row> <p class="fz12 color333 fbold" style="border: none; margin-bottom: 15px; padding-left: 20px;">需审核信息<span
<el-row :gutter="20" style='margin-top:13px;'> class="colorE95252 fz12 fwnormal">
<el-col :span="24"> (编辑门店地址后,客户将重新进入审核流程)
<p class="fz12 color333 fbold" style="border: none; margin-bottom: 15px; padding-left: 20px;">需审核信息<span class="colorE95252 fz12 fwnormal"> </span>
(编辑门店地址后,客户将重新进入审核流程) </p>
</span> </el-col>
</p> </el-row>
</el-col> <el-row :gutter="20">
</el-row> <el-col :span="12">
<el-row :gutter="20"> <el-form-item label="区域:">
<el-col :span="12"> <el-select class='w200' filterable v-model='updateMsg.Province' @change='getCityNew'>
<el-form-item label="区域:"> <el-option v-for='item in provinceList' :label='item.Name' :value='item.ID' :key='item.ID'>
<el-select class='w200' filterable v-model='updateMsg.Province' @change='getCityNew'> </el-option>
<el-option v-for='item in provinceList' </el-select>
:label='item.Name' <el-select class='w200' filterable v-model='updateMsg.City' @change='getRegionNew'>
:value='item.ID' <el-option v-for='item in cityList' :label='item.Name' :value='item.ID' :key='item.ID'>
:key='item.ID'> </el-option>
</el-option> </el-select>
</el-select> <el-select class='w200' filterable v-model='updateMsg.District'>
<el-select class='w200' filterable v-model='updateMsg.City' @change='getRegionNew'> <el-option v-for='item in regionList' :label='item.Name' :value='item.ID' :key='item.ID'>
<el-option v-for='item in cityList' </el-option>
:label='item.Name' </el-select>
:value='item.ID' </el-form-item>
:key='item.ID'> </el-col>
</el-option> <el-col :span="6">
</el-select> <el-form-item label="详细地址:">
<el-select class='w200' filterable v-model='updateMsg.District'> <el-input v-model='updateMsg.Address'></el-input>
<el-option v-for='item in regionList' </el-form-item>
:label='item.Name' </el-col>
:value='item.ID' <el-col :span="6">
:key='item.ID'> </el-col>
</el-option> </el-row>
</el-select> <el-row :gutter="20">
</el-form-item> <el-col :span="6">
</el-col> <el-form-item label="名片照片:">
<el-col :span="6"> <el-upload class="avatar-uploader" action="" :http-request="uploadImgNew"
<el-form-item label="详细地址:"> accept="image/jpeg,image/gif,image/png,image/bmp" :show-file-list="false">
<el-input v-model='updateMsg.Address' ></el-input> <img v-if="BusinessCardPhotosNew" :src="BusinessCardPhotosNew" class="avatar">
</el-form-item> <i v-else class="el-icon-plus avatar-uploader-icon"></i>
</el-col> </el-upload>
<el-col :span="6"> </el-form-item>
</el-col> </el-col>
</el-row> <el-col :span="6">
<el-row :gutter="20"> <el-form-item label="门牌照片:">
<el-col :span="6"> <el-upload class="avatar-uploader" action="" :http-request="uploadImg1New"
<el-form-item label="名片照片:"> accept="image/jpeg,image/gif,image/png,image/bmp" :show-file-list="false">
<el-upload class="avatar-uploader" <img v-if="HousePhotosNew" :src="HousePhotosNew" class="avatar">
action="" <i v-else class="el-icon-plus avatar-uploader-icon"></i>
:http-request="uploadImgNew" </el-upload>
accept="image/jpeg,image/gif,image/png,image/bmp" </el-form-item>
:show-file-list="false" </el-col>
> <el-col :span="6">
<img v-if="BusinessCardPhotosNew" :src="BusinessCardPhotosNew" class="avatar"> <el-form-item label="营业执照:">
<i v-else class="el-icon-plus avatar-uploader-icon"></i> <el-upload class="avatar-uploader" action="" :http-request="uploadImg2New"
</el-upload> accept="image/jpeg,image/gif,image/png,image/bmp" :show-file-list="false">
</el-form-item> <img v-if="ImagesNew" :src="ImagesNew" class="avatar">
</el-col> <i v-else class="el-icon-plus avatar-uploader-icon"></i>
<el-col :span="6"> </el-upload>
<el-form-item label="门牌照片:"> </el-form-item>
<el-upload class="avatar-uploader" </el-col>
action="" </el-row>
:http-request="uploadImg1New" <el-row :gutter="20">
accept="image/jpeg,image/gif,image/png,image/bmp" <el-col :span="24">
:show-file-list="false" <input type="button" class="normalBtn" value="保存" @click="saveUpdate()" />
> <input type="button" class="hollowFixedBtn" value="取消" @click="addLayer1=false" />
<img v-if="HousePhotosNew" :src="HousePhotosNew" class="avatar"> </el-col>
<i v-else class="el-icon-plus avatar-uploader-icon"></i> </el-row>
</el-upload> </el-form>
</el-form-item> </div>
</el-col>
<el-col :span="6">
<el-form-item label="营业执照:">
<el-upload class="avatar-uploader"
action=""
:http-request="uploadImg2New"
accept="image/jpeg,image/gif,image/png,image/bmp"
:show-file-list="false"
>
<img v-if="ImagesNew" :src="ImagesNew" class="avatar">
<i v-else class="el-icon-plus avatar-uploader-icon"></i>
</el-upload>
</el-form-item>
</el-col>
</el-row>
<el-row :gutter="20">
<el-col :span="24">
<input type="button" class="normalBtn" value="保存" @click="saveUpdate()"/>
<input type="button" class="hollowFixedBtn" value="取消" @click="addLayer1=false"/>
</el-col>
</el-row>
</el-form>
</div>
</div> </div>
</template> </template>
...@@ -751,7 +767,7 @@ ...@@ -751,7 +767,7 @@
export default { export default {
data() { data() {
return { return {
addLayer1:false, addLayer1: false,
allowAdd: true, allowAdd: true,
defaultImg: 'this.src="' + require("../../assets/img/litheader.png") + '"', defaultImg: 'this.src="' + require("../../assets/img/litheader.png") + '"',
BusinessCardPhotos: '', BusinessCardPhotos: '',
...@@ -812,11 +828,10 @@ ...@@ -812,11 +828,10 @@
trigger: "blur" trigger: "blur"
}], }],
contactNumber: [{ contactNumber: [{
required: true, required: true,
message: this.$t('rule.EnterPNum'), message: this.$t('rule.EnterPNum'),
trigger: "blur" trigger: "blur"
} }],
],
brandIds: [{ brandIds: [{
required: true, required: true,
message: this.$t('rule.ChoiceBrand'), message: this.$t('rule.ChoiceBrand'),
...@@ -870,185 +885,186 @@ ...@@ -870,185 +885,186 @@
zw: [], //职务 zw: [], //职务
khly: [], //客户来源 khly: [], //客户来源
outerVisible: false, outerVisible: false,
updateMsg:{ updateMsg: {
CustomerName:'', CustomerName: '',
CustomerId:0, CustomerId: 0,
Address:'', Address: '',
Country:2, Country: 2,
Province:0, Province: 0,
Contact:'', Contact: '',
City:0, City: 0,
District:0, District: 0,
HousePhotos:[], HousePhotos: [],
BusinessCardPhotos:[], BusinessCardPhotos: [],
Images:[], Images: [],
customerExceptionList: [], customerExceptionList: [],
CustomerExceptionIds: [], CustomerExceptionIds: [],
}, },
cityList:[], cityList: [],
regionList:[], regionList: [],
id:'', id: '',
ImagesNew:'', ImagesNew: '',
BusinessCardPhotosNew:'', BusinessCardPhotosNew: '',
HousePhotosNew:'', HousePhotosNew: '',
CustomerException: [], CustomerException: [],
JYExceptionList: [], JYExceptionList: [],
} }
}, },
methods: { methods: {
yichangde(obj){ yichangde(obj) {
this.apipost("app_get_GetCustomerException", {customerId: obj.customerId},res => { this.apipost("app_get_GetCustomerException", {
customerId: obj.customerId
}, res => {
if (res.data.resultCode == 1) { if (res.data.resultCode == 1) {
this.CustomerException = res.data.data this.CustomerException = res.data.data
} }
}) })
}, },
EditMsg(item){ EditMsg(item) {
this.addLayer1=true; this.addLayer1 = true;
this.id=item.customerId; this.id = item.customerId;
this.getMyCustomerInfo(); this.getMyCustomerInfo();
}, },
saveUpdate(){ saveUpdate() {
if(this.updateMsg.District=='') if (this.updateMsg.District == '') {
{ this.updateMsg.District = 0
this.updateMsg.District=0 }
} if (this.BusinessCardPhotos) {
if(this.BusinessCardPhotos) this.updateMsg.BusinessCardPhotos = []
{ this.updateMsg.BusinessCardPhotos=[] this.updateMsg.BusinessCardPhotos.push(this.BusinessCardPhotos)
this.updateMsg.BusinessCardPhotos.push(this.BusinessCardPhotos) }
} if (this.HousePhotos) {
if(this.HousePhotos) this.updateMsg.HousePhotos = []
{ this.updateMsg.HousePhotos=[] this.updateMsg.HousePhotos.push(this.HousePhotos)
this.updateMsg.HousePhotos.push(this.HousePhotos) }
} if (this.Images) {
if(this.Images) this.updateMsg.Images = []
{ this.updateMsg.Images=[] this.updateMsg.Images.push(this.Images)
this.updateMsg.Images.push(this.Images) }
} let sheng = ''
let sheng='' let shi = ''
let shi='' let qu = ''
let qu='' if (this.updateMsg.District == '') {
if(this.updateMsg.District=='') this.updateMsg.District = 0
{ }
this.updateMsg.District=0 if (this.updateMsg.City == '') {
} this.updateMsg.City = 0
if(this.updateMsg.City=='') }
{ this.provinceList.forEach(item => {
this.updateMsg.City=0 if (this.updateMsg.Province == item.ID) {
} sheng = item.Name
this.provinceList.forEach(item=>{ }
if(this.updateMsg.Province==item.ID) })
{ this.cityList.forEach(item => {
sheng=item.Name if (this.updateMsg.City == item.ID) {
} shi = item.Name
}) }
this.cityList.forEach(item=>{ })
if(this.updateMsg.City==item.ID) this.regionList.forEach(item => {
{ if (this.updateMsg.District == item.ID) {
shi=item.Name qu = item.Name
} }
}) })
this.regionList.forEach(item=>{ let AreaName = sheng + shi + qu
if(this.updateMsg.District==item.ID) this.updateMsg.Address = AreaName + ',' + this.updateMsg.Address
{ this.apipost('app_customer_UpdateCustomerAddress', this.updateMsg, res => {
qu=item.Name if (res.data.resultCode == 1) {
} this.addLayer1 = false;
}) this.$message.success(res.data.message)
let AreaName=sheng+shi+qu this.getList()
this.updateMsg.Address=AreaName+','+this.updateMsg.Address this.addLayer1 = false
this.apipost('app_customer_UpdateCustomerAddress',this.updateMsg,res=>{ } else {
if(res.data.resultCode==1){ this.$message.error(res.data.message)
this.addLayer1=false; }
this.$message.success(res.data.message) }, err => {})
this.getList()
this.addLayer1=false
}else{
this.$message.error(res.data.message)
}
},err=>{})
}, },
uploadImgNew(file) { uploadImgNew(file) {
//上传 //上传
let newArr = []; let newArr = [];
newArr.push(file.file); newArr.push(file.file);
let path = "/Upload/Temporary/"; let path = "/Upload/Temporary/";
this.UploadSelfFileT(path, newArr, x => { this.UploadSelfFileT(path, newArr, x => {
this.BusinessCardPhotosNew= this.domainManager().ViittoFileUrl + x.data.FilePath this.BusinessCardPhotosNew = this.domainManager().ViittoFileUrl + x.data.FilePath
}); });
}, },
uploadImg1New(file) { uploadImg1New(file) {
//上传 //上传
let newArr = []; let newArr = [];
newArr.push(file.file); newArr.push(file.file);
let path = "/Upload/Temporary/"; let path = "/Upload/Temporary/";
this.UploadSelfFileT(path, newArr, x => { this.UploadSelfFileT(path, newArr, x => {
this.HousePhotosNew= this.domainManager().ViittoFileUrl + x.data.FilePath this.HousePhotosNew = this.domainManager().ViittoFileUrl + x.data.FilePath
}); });
}, },
uploadImg2New(file) { uploadImg2New(file) {
//上传 //上传
let newArr = []; let newArr = [];
newArr.push(file.file); newArr.push(file.file);
let path = "/Upload/Temporary/"; let path = "/Upload/Temporary/";
this.UploadSelfFileT(path, newArr, x => { this.UploadSelfFileT(path, newArr, x => {
this.ImagesNew= this.domainManager().ViittoFileUrl + x.data.FilePath this.ImagesNew = this.domainManager().ViittoFileUrl + x.data.FilePath
}); });
}, },
getMyCustomerInfo(){ getMyCustomerInfo() {
this.apipost('app_GetMyCustomerInfo',{customerId:this.id},res=>{ this.apipost('app_GetMyCustomerInfo', {
if(res.data.resultCode==1){ customerId: this.id
let x=res.data.data; }, res => {
// this.customerInfo=res.data.data if (res.data.resultCode == 1) {
// if(this.customerInfo.address.indexOf(',')!=-1){ let x = res.data.data;
// this.customerInfo.address=this.customerInfo.address.split(',')[1] // this.customerInfo=res.data.data
// }else{ // if(this.customerInfo.address.indexOf(',')!=-1){
// this.customerInfo.address=this.customerInfo.address // this.customerInfo.address=this.customerInfo.address.split(',')[1]
// } // }else{
// this.contact=res.data.data.contact // this.customerInfo.address=this.customerInfo.address
this.updateMsg.CustomerName=x.customerName // }
this.updateMsg.Contact=x.contactName // this.contact=res.data.data.contact
this.updateMsg.CustomerId=x.customerId this.updateMsg.CustomerName = x.customerName
this.updateMsg.Address=x.address.split(',')[1] this.updateMsg.Contact = x.contactName
this.updateMsg.Province=x.province this.updateMsg.CustomerId = x.customerId
this.getCityNew() this.updateMsg.Address = x.address.split(',')[1]
this.updateMsg.City=x.city this.updateMsg.Province = x.province
this.getRegionNew() this.getCityNew()
this.updateMsg.customerExceptionList=x.customerExceptionList this.updateMsg.City = x.city
this.getRegionNew()
this.updateMsg.customerExceptionList = x.customerExceptionList
this.updateMsg.CustomerExceptionIds = [] this.updateMsg.CustomerExceptionIds = []
this.updateMsg.District=x.district this.updateMsg.District = x.district
if(x.businessCardPhotos&&x.businessCardPhotos.length>0) if (x.businessCardPhotos && x.businessCardPhotos.length > 0) {
{ this.BusinessCardPhotos = x.businessCardPhotos[0]
this.BusinessCardPhotos=x.businessCardPhotos[0] }
} if (x.images && x.images.length > 0) {
if(x.images&&x.images.length>0) this.Images = x.images[0]
{ }
this.Images=x.images[0] if (x.housePhotos && x.housePhotos.length > 0) {
} this.HousePhotos = x.housePhotos[0]
if(x.housePhotos&&x.housePhotos.length>0) }
{ } else {}
this.HousePhotos=x.housePhotos[0] }, err => {})
} },
}else{} getCityNew() {
},err=>{}) this.apipost('app_customer_GetChildList', {
}, Id: this.updateMsg.Province,
getCityNew(){ "level": 2
this.apipost('app_customer_GetChildList',{Id:this.updateMsg.Province,"level":2},res=>{ }, res => {
if(res.data.resultCode==1){ if (res.data.resultCode == 1) {
this.cityList=res.data.data; this.cityList = res.data.data;
// this.regionList=[] // this.regionList=[]
// this.updateMsg.City='' // this.updateMsg.City=''
// this.updateMsg.District='' // this.updateMsg.District=''
} }
},err=>{}) }, err => {})
}, },
getRegionNew(){ getRegionNew() {
this.apipost('app_customer_GetChildList',{Id:this.updateMsg.City,"level":3},res=>{ this.apipost('app_customer_GetChildList', {
if(res.data.resultCode==1){ Id: this.updateMsg.City,
this.regionList=res.data.data "level": 3
// this.updateMsg.District='' }, res => {
} if (res.data.resultCode == 1) {
},err=>{}) this.regionList = res.data.data
}, // this.updateMsg.District=''
}
}, err => {})
},
//导入 //导入
getImportFileUrl() { getImportFileUrl() {
let url = let url =
...@@ -1075,8 +1091,8 @@ ...@@ -1075,8 +1091,8 @@
if (res.data.resultCode == 1) { if (res.data.resultCode == 1) {
this.downList = this.downList =
this.domainManager().LocalTemplateFileDownLoadUrl + this.domainManager().LocalTemplateFileDownLoadUrl +
res.data.data.FileUrl; res.data.data.FileUrl;
window.open(this.downList); window.open(this.downList);
} else { } else {
this.Error(res.data.message); this.Error(res.data.message);
} }
...@@ -1251,24 +1267,24 @@ ...@@ -1251,24 +1267,24 @@
} }
}, err => {}) }, err => {})
}, },
goUrl(type, id,num) { goUrl(type, id, num) {
this.$router.push({ this.$router.push({
name: 'MyCustomerDetail', name: 'MyCustomerDetail',
query: { query: {
"id": id, "id": id,
"num":num "num": num
} }
}) })
}, },
goUrC(path, customerId) { goUrC(path, customerId) {
this.$router.push({ this.$router.push({
name: path, name: path,
query: { query: {
"customerId": customerId, "customerId": customerId,
blank: 'y' blank: 'y'
} }
}) })
}, },
goUrlT(path, id) { goUrlT(path, id) {
this.$router.push({ this.$router.push({
......
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