
64 changed files with 3168 additions and 1046 deletions
@ -0,0 +1,636 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<div v-show="viewState == 1"> |
||||
|
<div class="tab-header webtop"> |
||||
|
<div>{{ viewTitle }}</div> |
||||
|
<div> |
||||
|
<el-button type="primary" size="small" :disabled="submitdisabled" @click="saveOrUpdate()">保存</el-button> |
||||
|
<el-button type="info" size="small" @click="handleReturn()">关闭</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div class="listconadd"> |
||||
|
<el-form ref="form_obj" :model="formobj" :rules="rules" class="formaddcopy02"> |
||||
|
<el-row style="border-top: 1px solid #e0e3eb"> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty"><span class="icon">*</span>客户名称</div> |
||||
|
<el-form-item prop="name"><el-input class="addinputInfo addinputw" v-model="formobj.name" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">客户类型</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.customerType }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty"><span class="icon">*</span>联系电话</div> |
||||
|
<el-form-item prop="mobile"><el-input class="addinputInfo" style="width: 30%" v-model="formobj.mobile" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">微信号</div> |
||||
|
<el-form-item><el-input class="addinputInfo" style="width: 30%" v-model="formobj.weixin" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">客户地址</div> |
||||
|
<el-form-item> |
||||
|
<div class="addinputInfo" style="display: flex;flex-direction: row;justify-content: flex-start;align-items: center"> |
||||
|
<el-select v-model="formobj.province" filterable clearable placeholder="请选择省" style="width:160px" @change="provinceChange"> |
||||
|
<el-option v-for="item in province_list" :key="item.sid" :label="item.name" :value="item.name"/> |
||||
|
</el-select> |
||||
|
<el-select v-model="formobj.city" filterable placeholder="请选择市" style="width:160px" @change="cityChange"> |
||||
|
<el-option v-for="item in city_list" :key="item.sid" :label="item.name" :value="item.name"/> |
||||
|
</el-select> |
||||
|
<el-select v-model="formobj.county" filterable placeholder="请选择县" style="width:160px" @change="countyChange"> |
||||
|
<el-option v-for="item in county_list" :key="item.sid" :label="item.name" :value="item.name"/> |
||||
|
</el-select> |
||||
|
<el-input style="width: 30%" v-model="formobj.address" clearable placeholder=""/> |
||||
|
</div> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">客户级别</div> |
||||
|
<el-form-item> |
||||
|
<el-select v-model="formobj.levelKey" class="addinputInfo" clearable filterable placeholder="" @change="levelChange"> |
||||
|
<el-option v-for="item in level_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictKey"/> |
||||
|
</el-select> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">是否开启提醒</div> |
||||
|
<el-form-item> |
||||
|
<el-radio-group class="addinputInfo" v-model="formobj.isOnRemind" @change="isOnRemindChange"> |
||||
|
<el-radio label="是">是</el-radio> |
||||
|
<el-radio label="否">否</el-radio> |
||||
|
</el-radio-group> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row v-show="formobj.isOnRemind == '是'"> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">提醒日期</div> |
||||
|
<el-form-item><el-date-picker class="addinputInfo" v-model="formobj.remind_day" type="date" value-format="yyyy-MM-dd" format="yyyy-MM-dd" placeholder="选择日期" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">提醒备注</div> |
||||
|
<el-form-item><el-input class="addinputInfo addinputw" v-model="formobj.remind_remark" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<div class="title">更多信息</div> |
||||
|
<el-row v-if="formobj.customerType == '个人'"> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">客户生日</div> |
||||
|
<el-form-item><el-date-picker class="addinputInfo" v-model="formobj.birthday" type="date" value-format="yyyy-MM-dd" format="yyyy-MM-dd" placeholder="选择日期" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">性别</div> |
||||
|
<el-form-item> |
||||
|
<el-radio-group class="addinputInfo" v-model="formobj.sex" @change="sexChange"> |
||||
|
<el-radio v-for="item in sex_list" :key="item.dictKey" :label="item.dictValue">{{ item.dictValue }}</el-radio> |
||||
|
</el-radio-group> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">证件类型</div> |
||||
|
<el-form-item><span class="addinputInfo">{{ formobj.certificateType }}</span></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">证件号码</div> |
||||
|
<el-form-item><el-input class="addinputInfo addinputw" v-model="formobj.idnumber" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">证件有效期</div> |
||||
|
<el-form-item><el-date-picker class="addinputInfo" v-model="formobj.endDate" type="date" value-format="yyyy-MM-dd" format="yyyy-MM-dd" placeholder="选择日期" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">电子邮箱</div> |
||||
|
<el-form-item><el-input class="addinputInfo addinputw" style="width: 30%" v-model="formobj.e_mail" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">紧急联系人</div> |
||||
|
<el-form-item><el-input class="addinputInfo addinputw" style="width: 30%" v-model="formobj.emergencyContact" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">紧急联系电话</div> |
||||
|
<el-form-item><el-input class="addinputInfo addinputw" style="width: 30%" v-model="formobj.emergencyMobile" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">客户来源</div> |
||||
|
<el-form-item> |
||||
|
<el-select v-model="formobj.sourceKey" class="addinputInfo" clearable filterable placeholder="" @change="sourceChange"> |
||||
|
<el-option v-for="item in source_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictKey"/> |
||||
|
</el-select> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">客户分类</div> |
||||
|
<el-form-item> |
||||
|
<el-select v-model="formobj.customerClassKey" class="addinputInfo" clearable filterable placeholder="" @change="customerClassChange"> |
||||
|
<el-option v-for="item in customerClass_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictKey"/> |
||||
|
</el-select> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">备注</div> |
||||
|
<el-form-item><el-input class="addinputInfo addinputw" v-model="formobj.remarks" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<div class="title">车辆信息</div> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty"><span class="icon">*</span>车牌号</div> |
||||
|
<el-form-item prop="vehMark"><el-input class="addinputInfo" style="width: 40%" v-model="formobj.vehMark" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty"><span class="icon">*</span>车架号</div> |
||||
|
<el-form-item prop="vinNo"><el-input class="addinputInfo" style="width: 40%" v-model="formobj.vinNo" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">发动机号</div> |
||||
|
<el-form-item><el-input class="addinputInfo" style="width: 40%" v-model="formobj.engineNo" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">车型</div> |
||||
|
<el-form-item><el-input class="addinputInfo" style="width: 40%" v-model="formobj.vehModel" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">购车日期</div> |
||||
|
<el-form-item> <el-date-picker class="addinputInfo" value-format="yyyy-MM-dd" v-model="formobj.buyDate" clearable type="date" placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">行驶里程(Km)</div> |
||||
|
<el-form-item><el-input class="addinputInfo" style="width: 40%" @keyup.native="formobj.mileage = getNumber(formobj.mileage, 2)" v-model="formobj.mileage" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">上次保养里程(Km)</div> |
||||
|
<el-form-item><el-input class="addinputInfo" style="width: 40%" @keyup.native="formobj.lastMileage = getNumber(formobj.lastMileage, 2)" v-model="formobj.lastMileage" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">下次保养日期</div> |
||||
|
<el-form-item> <el-date-picker class="addinputInfo" value-format="yyyy-MM-dd" v-model="formobj.nextMaintainDate" clearable type="date" placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">商业险到期日期</div> |
||||
|
<el-form-item> <el-date-picker class="addinputInfo" value-format="yyyy-MM-dd" v-model="formobj.commercialInsuranceEndDate" clearable type="date" placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">交强险到期日期</div> |
||||
|
<el-form-item> <el-date-picker class="addinputInfo" value-format="yyyy-MM-dd" v-model="formobj.compulsoryInsuranceEndDate" clearable type="date" placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">备注</div> |
||||
|
<el-form-item><el-input class="addinputInfo addinputw" v-model="formobj.carRemarks" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<div class="title">保养到期明细</div> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">行驶里程(Km)</div> |
||||
|
<el-form-item><el-input class="addinputInfo" style="width: 40%" @keyup.native="formobj.currentMileage = getNumber(formobj.currentMileage, 2)" v-model="formobj.currentMileage" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">每月公里</div> |
||||
|
<el-form-item><el-input class="addinputInfo" style="width: 40%" @keyup.native="formobj.monthKm = getNumber(formobj.monthKm, 2)" v-model="formobj.monthKm" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">滤芯到期公里</div> |
||||
|
<el-form-item><el-input class="addinputInfo" style="width: 40%" @keyup.native="formobj.filter_km = getNumber(formobj.filter_km, 2)" v-model="formobj.filter_km" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">滤芯到期日期</div> |
||||
|
<el-form-item> <el-date-picker class="addinputInfo" value-format="yyyy-MM-dd" v-model="formobj.filter_date" clearable type="date" placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">机油到期公里</div> |
||||
|
<el-form-item><el-input class="addinputInfo" style="width: 40%" @keyup.native="formobj.engineoil_km = getNumber(formobj.engineoil_km, 2)" v-model="formobj.engineoil_km" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">机油到期日期</div> |
||||
|
<el-form-item> <el-date-picker class="addinputInfo" value-format="yyyy-MM-dd" v-model="formobj.engineoil_date" clearable type="date" placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">齿轮油到期公里</div> |
||||
|
<el-form-item><el-input class="addinputInfo" style="width: 40%" @keyup.native="formobj.gearoil_km = getNumber(formobj.gearoil_km, 2)" v-model="formobj.gearoil_km" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">齿轮油到期日期</div> |
||||
|
<el-form-item> <el-date-picker class="addinputInfo" value-format="yyyy-MM-dd" v-model="formobj.gearoil_date" clearable type="date" placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">宝轮到期公里</div> |
||||
|
<el-form-item><el-input class="addinputInfo" style="width: 40%" @keyup.native="formobj.treasurewheel_km = getNumber(formobj.treasurewheel_km, 2)" v-model="formobj.treasurewheel_km" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">宝轮到期日期</div> |
||||
|
<el-form-item> <el-date-picker class="addinputInfo" value-format="yyyy-MM-dd" v-model="formobj.treasurewheel_date" clearable type="date" placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">风扇皮带到期公里</div> |
||||
|
<el-form-item><el-input class="addinputInfo" style="width: 40%" @keyup.native="formobj.fanbelt_km = getNumber(formobj.fanbelt_km, 2)" v-model="formobj.fanbelt_km" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">风扇皮带到期日期</div> |
||||
|
<el-form-item> <el-date-picker class="addinputInfo" value-format="yyyy-MM-dd" v-model="formobj.fanbelt_date" clearable type="date" placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">刹车片到期公里</div> |
||||
|
<el-form-item><el-input class="addinputInfo" style="width: 40%" @keyup.native="formobj.brakepads_km = getNumber(formobj.brakepads_km, 2)" v-model="formobj.brakepads_km" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="12"> |
||||
|
<div class="span-sty">刹车片到期日期</div> |
||||
|
<el-form-item> <el-date-picker class="addinputInfo" value-format="yyyy-MM-dd" v-model="formobj.brakepads_date" clearable type="date" placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
<el-row> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">备注</div> |
||||
|
<el-form-item><el-input class="addinputInfo addinputw" v-model="formobj.byRemarks" clearable placeholder="" /></el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
</el-form> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import req from '@/api/client/customermanagement' |
||||
|
import { getProvince, getCity, getCounty, typeValues } from '@/api/Common/dictcommons' |
||||
|
|
||||
|
export default { |
||||
|
name: 'CustomerManagementAdd', |
||||
|
data() { |
||||
|
return { |
||||
|
viewTitle: '', |
||||
|
viewState: 1, |
||||
|
submitdisabled: false, |
||||
|
province_list: [], |
||||
|
city_list: [], |
||||
|
county_list: [], |
||||
|
level_list: [], |
||||
|
sex_list: [], |
||||
|
source_list: [], |
||||
|
customerClass_list: [], |
||||
|
formobj: { |
||||
|
name: '', |
||||
|
customerType: '', |
||||
|
customerTypeKey: '', |
||||
|
visitWay: '', |
||||
|
visitWayKey: '', |
||||
|
mobile: '', |
||||
|
weixin: '', |
||||
|
province: '', |
||||
|
city: '', |
||||
|
county: '', |
||||
|
address: '', |
||||
|
level: '', |
||||
|
levelKey: '', |
||||
|
isOnRemind: '', |
||||
|
isOnRemindKey: '', |
||||
|
remind_day: '', |
||||
|
remind_remark: '', |
||||
|
birthday: '', |
||||
|
sex: '', |
||||
|
sexKey: '', |
||||
|
certificateType: '', |
||||
|
certificateTypeKey: '', |
||||
|
idnumber: '', |
||||
|
endDate: '', |
||||
|
e_mail: '', |
||||
|
emergencyContact: '', |
||||
|
emergencyMobile: '', |
||||
|
source: '', |
||||
|
sourceKey: '', |
||||
|
customerClass: '', |
||||
|
customerClassKey: '', |
||||
|
remarks: '', |
||||
|
userSid: '', |
||||
|
orgPath: '', |
||||
|
useOrgSid: '', |
||||
|
sid: '', |
||||
|
customerOrgName: '', |
||||
|
customerOrgSid: '', |
||||
|
customerVehSid: '', |
||||
|
customerSid: '', |
||||
|
vehMark: '', |
||||
|
vinNo: '', |
||||
|
engineNo: '', |
||||
|
vehModelSid: '', |
||||
|
vehModel: '', |
||||
|
mileage: '', |
||||
|
lastMileage: '', |
||||
|
nextMaintainDate: '', |
||||
|
buyDate: '', |
||||
|
commercialInsuranceEndDate: '', |
||||
|
compulsoryInsuranceEndDate: '', |
||||
|
currentMileage: '', |
||||
|
monthKm: '', |
||||
|
filter_km: '', |
||||
|
filter_date: '', |
||||
|
engineoil_km: '', |
||||
|
engineoil_date: '', |
||||
|
gearoil_km: '', |
||||
|
gearoil_date: '', |
||||
|
treasurewheel_km: '', |
||||
|
treasurewheel_date: '', |
||||
|
fanbelt_km: '', |
||||
|
fanbelt_date: '', |
||||
|
brakepads_km: '', |
||||
|
brakepads_date: '', |
||||
|
carRemarks: '', |
||||
|
byRemarks: '' |
||||
|
}, |
||||
|
rules: { |
||||
|
name: [{ required: true, message: '客户名称不能为空', trigger: 'blur' }], |
||||
|
mobile: [{ required: true, message: '联系电话不能为空', trigger: 'blur' }], |
||||
|
vehMark: [{ required: true, message: '车牌号不能为空', trigger: 'blur' }], |
||||
|
vinNo: [{ required: true, message: '车架号不能为空', trigger: 'blur' }] |
||||
|
} |
||||
|
} |
||||
|
}, |
||||
|
methods: { |
||||
|
init() { |
||||
|
getProvince().then((res) => { |
||||
|
if (res.success) { |
||||
|
this.province_list = res.data |
||||
|
} |
||||
|
}) |
||||
|
typeValues({ type: 'customerLevel' }).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.level_list = res.data |
||||
|
} |
||||
|
}) |
||||
|
typeValues({ type: 'sex' }).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.sex_list = res.data |
||||
|
} |
||||
|
}) |
||||
|
typeValues({ type: 'customerSource' }).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.source_list = res.data |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
provinceChange(value) { |
||||
|
const choose = this.province_list.filter((item) => item.name === value) |
||||
|
if (choose !== null && choose.length > 0) { |
||||
|
this.formobj.provinceSid = choose[0].sid |
||||
|
this.getCity(this.formobj.provinceSid) |
||||
|
} else { |
||||
|
this.formobj.provinceSid = '' |
||||
|
this.formobj.citySid = '' |
||||
|
this.formobj.city = '' |
||||
|
this.city_list = [] |
||||
|
this.formobj.county = '' |
||||
|
this.formobj.countySid = '' |
||||
|
this.county_list = [] |
||||
|
} |
||||
|
}, |
||||
|
getCity(val) { |
||||
|
getCity({ sid: val }).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.city_list = res.data |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
cityChange(value) { |
||||
|
const choose = this.city_list.filter((item) => item.name === value) |
||||
|
if (choose !== null && choose.length > 0) { |
||||
|
this.formobj.citySid = choose[0].sid |
||||
|
this.getCounty(this.formobj.citySid) |
||||
|
} |
||||
|
}, |
||||
|
getCounty(val) { |
||||
|
getCounty({ sid: val }).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.county_list = res.data |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
countyChange(value) { |
||||
|
const choose = this.county_list.filter((item) => item.name === value) |
||||
|
if (choose !== null && choose.length > 0) { |
||||
|
this.formobj.countySid = choose[0].sid |
||||
|
} |
||||
|
}, |
||||
|
getNumber(val, limit) { |
||||
|
val = val.replace(/[^0-9.]/g, '') // 保留数字 |
||||
|
val = val.replace(/^00/, '0.') // 开头不能有两个0 |
||||
|
val = val.replace(/^\./g, '0.') // 开头为小数点转换为0. |
||||
|
val = val.replace(/\.{2,}/g, '.') // 两个以上的小数点转换成一个 |
||||
|
val = val.replace('.', '$#$').replace(/\./g, '').replace('$#$', '.'); // 只保留一个小数点 |
||||
|
/^0\d+/.test(val) ? val = val.slice(1) : '' // 两位以上数字开头不能为0 |
||||
|
const str = '^(\\d+)\\.(\\d{' + limit + '}).*$' |
||||
|
const reg = new RegExp(str) |
||||
|
if (limit === 0) { |
||||
|
// 不需要小数点 |
||||
|
val = val.replace(reg, '$1') |
||||
|
} else { |
||||
|
// 通过正则保留小数点后指定的位数 |
||||
|
val = val.replace(reg, '$1.$2') |
||||
|
} |
||||
|
return val |
||||
|
}, |
||||
|
showAdd(value, sid) { |
||||
|
this.$nextTick(() => { |
||||
|
this.$refs['form_obj'].clearValidate() |
||||
|
}) |
||||
|
this.init() |
||||
|
if (sid !== '') { |
||||
|
this.viewTitle = '【快捷新增】客户信息' |
||||
|
req.quickAddInit({ sid: sid }).then((resp) => { |
||||
|
if (resp.success) { |
||||
|
this.formobj = resp.data |
||||
|
this.basics(value) |
||||
|
} |
||||
|
}) |
||||
|
} else { |
||||
|
this.viewTitle = '【新增】客户信息' |
||||
|
this.basics(value) |
||||
|
} |
||||
|
}, |
||||
|
// 基础信息赋值 |
||||
|
basics(value) { |
||||
|
this.formobj.isOnRemind = '否' |
||||
|
this.formobj.isOnRemindKey = '0' |
||||
|
this.formobj.customerType = value.customerType |
||||
|
this.formobj.customerTypeKey = value.customerTypeKey |
||||
|
this.formobj.visitWay = value.visitWay |
||||
|
this.formobj.visitWayKey = value.visitWayKey |
||||
|
this.formobj.userSid = window.sessionStorage.getItem('userSid') |
||||
|
this.formobj.orgPath = window.sessionStorage.getItem('defaultOrgPath') |
||||
|
this.formobj.useOrgSid = window.sessionStorage.getItem('defaultOrgPath').substring(window.sessionStorage.getItem('defaultOrgPath').lastIndexOf('/') + 1) |
||||
|
if (this.formobj.customerType === '个人') { |
||||
|
this.formobj.certificateType = '身份证' |
||||
|
this.formobj.certificateTypeKey = '01' |
||||
|
} else { |
||||
|
this.formobj.certificateType = '营业执照' |
||||
|
this.formobj.certificateTypeKey = '02' |
||||
|
} |
||||
|
typeValues({ psid: value.psid, type: 'customerClass' }).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.customerClass_list = res.data |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
levelChange(value) { |
||||
|
const choose = this.level_list.filter((item) => item.dictKey === value) |
||||
|
if (choose.length > 0 && choose !== null) { |
||||
|
this.formobj.level = choose[0].dictValue |
||||
|
} else { |
||||
|
this.formobj.level = '' |
||||
|
} |
||||
|
}, |
||||
|
isOnRemindChange(val) { |
||||
|
if (val === '是') { |
||||
|
this.formobj.isOnRemindKey = '1' |
||||
|
} else if (val === '否') { |
||||
|
this.formobj.isOnRemindKey = '0' |
||||
|
} |
||||
|
}, |
||||
|
sexChange(value) { |
||||
|
const choose = this.sex_list.filter((item) => item.dictValue === value) |
||||
|
if (choose.length > 0 && choose !== null) { |
||||
|
this.formobj.sexKey = choose[0].dictKey |
||||
|
} |
||||
|
}, |
||||
|
sourceChange(value) { |
||||
|
const choose = this.source_list.filter((item) => item.dictKey === value) |
||||
|
if (choose.length > 0 && choose !== null) { |
||||
|
this.formobj.source = choose[0].dictValue |
||||
|
} else { |
||||
|
this.formobj.source = '' |
||||
|
} |
||||
|
}, |
||||
|
customerClassChange(value) { |
||||
|
const choose = this.customerClass_list.filter((item) => item.dictKey === value) |
||||
|
if (choose.length > 0 && choose !== null) { |
||||
|
this.formobj.customerClass = choose[0].dictValue |
||||
|
} else { |
||||
|
this.formobj.customerClass = '' |
||||
|
} |
||||
|
}, |
||||
|
saveOrUpdate() { |
||||
|
this.$refs['form_obj'].validate((valid) => { |
||||
|
if (valid) { |
||||
|
if (this.formobj.customerType === '企业' && this.formobj.name.length < 5) { |
||||
|
this.$message({ showClose: true, type: 'error', message: '因客户类型为企业,客户名称的长度应不少于5个汉字' }) |
||||
|
return |
||||
|
} |
||||
|
this.submitdisabled = true |
||||
|
req.quickAddSave(this.formobj).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.$message({ showClose: true, type: 'success', message: '保存成功' }) |
||||
|
this.handleReturn('true') |
||||
|
} else { |
||||
|
this.submitdisabled = false |
||||
|
} |
||||
|
}).catch(() => { |
||||
|
this.submitdisabled = false |
||||
|
}) |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
handleReturn(isreload) { |
||||
|
if (isreload === 'true') this.$emit('reloadlist') |
||||
|
this.formobj = { |
||||
|
name: '', |
||||
|
customerType: '', |
||||
|
customerTypeKey: '', |
||||
|
visitWay: '', |
||||
|
visitWayKey: '', |
||||
|
mobile: '', |
||||
|
weixin: '', |
||||
|
province: '', |
||||
|
city: '', |
||||
|
county: '', |
||||
|
address: '', |
||||
|
level: '', |
||||
|
levelKey: '', |
||||
|
isOnRemind: '', |
||||
|
isOnRemindKey: '', |
||||
|
remind_day: '', |
||||
|
remind_remark: '', |
||||
|
birthday: '', |
||||
|
sex: '', |
||||
|
sexKey: '', |
||||
|
certificateType: '', |
||||
|
certificateTypeKey: '', |
||||
|
idnumber: '', |
||||
|
endDate: '', |
||||
|
e_mail: '', |
||||
|
emergencyContact: '', |
||||
|
emergencyMobile: '', |
||||
|
source: '', |
||||
|
sourceKey: '', |
||||
|
customerClass: '', |
||||
|
customerClassKey: '', |
||||
|
remarks: '', |
||||
|
userSid: '', |
||||
|
orgPath: '', |
||||
|
useOrgSid: '', |
||||
|
sid: '', |
||||
|
customerOrgName: '', |
||||
|
customerOrgSid: '' |
||||
|
} |
||||
|
this.submitdisabled = false |
||||
|
this.$emit('doback') |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
|
||||
|
<style scoped> |
||||
|
.span-sty { |
||||
|
width: 130px !important; |
||||
|
} |
||||
|
.addinputInfo { |
||||
|
margin-left: 120px !important; |
||||
|
} |
||||
|
.formaddcopy02 .el-row .el-col /deep/ .el-form-item .addinputw { |
||||
|
margin-left: 120px !important; |
||||
|
width: calc(100% - 115px); |
||||
|
} |
||||
|
/deep/ .el-form-item__error { |
||||
|
margin-left: 120px !important; |
||||
|
} |
||||
|
.formaddcopy02 .el-row .el-col /deep/ .el-form-item .el-radio-group { |
||||
|
display: inline; |
||||
|
line-height: 1px; |
||||
|
vertical-align: middle; |
||||
|
} |
||||
|
</style> |
@ -0,0 +1,342 @@ |
|||||
|
<template> |
||||
|
<div class="app-container"> |
||||
|
<!--列表页面--> |
||||
|
<div v-show="viewState == 1"> |
||||
|
<button-bar view-title="选择客户" ref="btnbar" :btndisabled="btndisabled" @btnhandle="btnHandle"/> |
||||
|
<!--Start查询列表部分--> |
||||
|
<div class="main-content"> |
||||
|
<div class="searchcon"> |
||||
|
<el-button size="small" class="searchbtn" @click="clicksearchShow">{{ searchxianshitit }}</el-button> |
||||
|
<div v-show="isSearchShow" class="search"> |
||||
|
<el-form ref="listQueryform" :inline="true" :model="listQuery" class="tab-header"> |
||||
|
<el-form-item label="客户名称"> |
||||
|
<el-input v-model="listQuery.params.customerName" placeholder="" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="车牌号"> |
||||
|
<el-input v-model="listQuery.params.vehMark" placeholder="" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="车架号"> |
||||
|
<el-input v-model="listQuery.params.vinNo" placeholder="" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="联系电话"> |
||||
|
<el-input v-model="listQuery.params.mobile" placeholder="" clearable/> |
||||
|
</el-form-item> |
||||
|
<el-form-item label="客户类型"> |
||||
|
<el-select v-model="listQuery.params.customerTypeKey" class="addinputw" placeholder="请选择"> |
||||
|
<el-option v-for="(item, index) in customerType_list" :key="index.dictKey" :label="item.dictValue" :value="item.dictKey"/> |
||||
|
</el-select> |
||||
|
</el-form-item> |
||||
|
</el-form> |
||||
|
<div class="btn" style="text-align: center;"> |
||||
|
<el-button type="primary" icon="el-icon-search" size="small" @click="handleFilter">查询</el-button> |
||||
|
<el-button type="primary" icon="el-icon-refresh" size="small" @click="handleReset">重置</el-button> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
<!--End查询列表部分--> |
||||
|
<div class="listtop"> |
||||
|
<div class="tit">客户列表</div> |
||||
|
<pageye v-show="list.length > 0" :total="listQuery.total" :page.sync="listQuery.current" :limit.sync="listQuery.size" class="pagination" @pagination="getList"/> |
||||
|
</div> |
||||
|
<!--Start 主页面主要部分 --> |
||||
|
<div class=""> |
||||
|
<el-table :key="tableKey" v-loading="listLoading" :data="list" border style="width: 100%;" @selection-change="handleSelectionChange"> |
||||
|
<el-table-column type="selection" align="center" width="50" /> |
||||
|
<el-table-column fixed label="序号" type="index" width="80" :index="indexMethod" align="center"/> |
||||
|
<el-table-column fixed label="操作" width="100" align="center"> |
||||
|
<template slot-scope="scope"> |
||||
|
<el-button type="primary" size="small" @click="handleAffirm(scope.row)">确认</el-button> |
||||
|
</template> |
||||
|
</el-table-column> |
||||
|
<el-table-column prop="customerName" label="客户名称" width="120" align="center"/> |
||||
|
<el-table-column prop="customerType" label="客户类型" width="120" align="center"/> |
||||
|
<el-table-column prop="vehMark" label="车牌号" width="120" align="center" /> |
||||
|
<el-table-column prop="vinNo" label="车架号" width="120" align="center" /> |
||||
|
<el-table-column prop="mobile" label="联系电话" width="120" align="center" /> |
||||
|
<el-table-column prop="salesCompany" label="销售公司" min-width="120" align="center" /> |
||||
|
</el-table> |
||||
|
</div> |
||||
|
<!--End 主页面主要部分--> |
||||
|
<div class="pages"> |
||||
|
<div class="tit"/> |
||||
|
<!-- 翻页 --> |
||||
|
<pagination v-show="list.length > 0" :total="listQuery.total" :page.sync="listQuery.current" :limit.sync="listQuery.size" class="pagination" @pagination="getList"/> |
||||
|
</div> |
||||
|
<!--End查询列表部分--> |
||||
|
</div> |
||||
|
</div> |
||||
|
<!-- 快捷新增客户 --> |
||||
|
<quickAddCustomer ref="divQuickAdd" v-show="viewState == 3" @doback="resetState" @reloadlist="getList" /> |
||||
|
<!-- 客户登记 --> |
||||
|
<el-dialog :visible.sync="dialogVisible" width="30%" :show-close="false"> |
||||
|
<el-form ref="form_obj" v-model="formobj" class="formaddcopy02"> |
||||
|
<el-row style="border-top: 1px solid #E0E3EB"> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">联络方式</div> |
||||
|
<el-form-item> |
||||
|
<el-select v-model="formobj.visitWayKey" class="addinputInfo" filterable placeholder="" @change="visitWayChange"> |
||||
|
<el-option v-for="item in visitWay_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictKey"/> |
||||
|
</el-select> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
<el-col :span="24"> |
||||
|
<div class="span-sty">客户类型</div> |
||||
|
<el-form-item> |
||||
|
<el-radio-group class="addinputInfo" v-model="formobj.customerType"> |
||||
|
<el-radio v-for="item in customerType_list" :key="item.dictKey" :label="item.dictValue" @change="customerTypeChange">{{ item.dictValue }}</el-radio> |
||||
|
</el-radio-group> |
||||
|
</el-form-item> |
||||
|
</el-col> |
||||
|
</el-row> |
||||
|
</el-form> |
||||
|
<div slot="footer" class="dialog-footer"> |
||||
|
<el-button type="primary" @click="handleConfirm()">确 定</el-button> |
||||
|
<el-button @click="dialogVisible = false">关 闭</el-button> |
||||
|
</div> |
||||
|
</el-dialog> |
||||
|
</div> |
||||
|
</template> |
||||
|
|
||||
|
<script> |
||||
|
import Pagination from '@/components/pagination' |
||||
|
import pageye from '@/components/pagination/pageye' |
||||
|
import ButtonBar from '@/components/ButtonBar' |
||||
|
import { customerList, typeValues } from '@/api/Common/dictcommons' |
||||
|
import quickAddCustomer from './quickAddCustomer' |
||||
|
|
||||
|
export default { |
||||
|
name: 'Customer', |
||||
|
components: { |
||||
|
Pagination, |
||||
|
pageye, |
||||
|
ButtonBar, |
||||
|
quickAddCustomer |
||||
|
}, |
||||
|
data() { |
||||
|
return { |
||||
|
btndisabled: false, |
||||
|
isQuickAdd: false, // 是否快捷新增 |
||||
|
btnList: [ |
||||
|
{ |
||||
|
type: 'primary', |
||||
|
size: 'small', |
||||
|
icon: 'plus', |
||||
|
btnKey: 'toQuickAdd', |
||||
|
btnLabel: '快捷新增客户' |
||||
|
}, |
||||
|
{ |
||||
|
type: 'primary', |
||||
|
size: 'small', |
||||
|
icon: 'plus', |
||||
|
btnKey: 'toAdd', |
||||
|
btnLabel: '新增客户' |
||||
|
}, |
||||
|
{ |
||||
|
type: 'info', |
||||
|
size: 'small', |
||||
|
icon: 'cross', |
||||
|
btnKey: 'doClose', |
||||
|
btnLabel: '关闭' |
||||
|
} |
||||
|
], |
||||
|
isSearchShow: false, |
||||
|
searchxianshitit: '显示查询条件', |
||||
|
viewState: 1, // 1、列表 2、新增 3、编辑 4、查看 |
||||
|
tableKey: 0, |
||||
|
list: [], |
||||
|
sids: [], // 用于导出的时候保存已选择的SIDs |
||||
|
FormLoading: false, |
||||
|
listLoading: false, |
||||
|
// 翻页 |
||||
|
listQuery: { |
||||
|
current: 1, |
||||
|
size: 5, |
||||
|
total: 0, |
||||
|
params: { |
||||
|
customerName: '', |
||||
|
vehMark: '', |
||||
|
vinNo: '', |
||||
|
mobile: '', |
||||
|
customerTypeKey: '', |
||||
|
billType: '', |
||||
|
useOrgSid: '' |
||||
|
} |
||||
|
}, |
||||
|
dialogVisible: false, |
||||
|
formobj: { |
||||
|
visitWay: '', // 联络方式 |
||||
|
visitWayKey: '', |
||||
|
customerType: '', // 客户类型 |
||||
|
customerTypeKey: '', |
||||
|
psid: '' |
||||
|
}, |
||||
|
visitWay_list: [], |
||||
|
customerType_list: [] |
||||
|
} |
||||
|
}, |
||||
|
mounted() { |
||||
|
this.$refs['btnbar'].setButtonList(this.btnList) |
||||
|
}, |
||||
|
methods: { |
||||
|
init() { |
||||
|
typeValues({ type: 'visitWay' }).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.visitWay_list = res.data |
||||
|
} |
||||
|
}) |
||||
|
typeValues({ type: 'customerType' }).then((res) => { |
||||
|
if (res.success) { |
||||
|
this.customerType_list = res.data |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
// 搜索条件效果 |
||||
|
clicksearchShow() { |
||||
|
this.isSearchShow = !this.isSearchShow |
||||
|
if (this.isSearchShow) { |
||||
|
this.searchxianshitit = '隐藏查询条件' |
||||
|
} else { |
||||
|
this.searchxianshitit = '显示查询条件' |
||||
|
} |
||||
|
}, |
||||
|
btnHandle(btnKey) { |
||||
|
console.log('XXXXXXXXXXXXXXX ' + btnKey) |
||||
|
switch (btnKey) { |
||||
|
case 'toQuickAdd': |
||||
|
this.toQuickAdd() |
||||
|
break |
||||
|
case 'toAdd': |
||||
|
this.toAdd() |
||||
|
break |
||||
|
case 'doClose': |
||||
|
this.doClose() |
||||
|
break |
||||
|
default: |
||||
|
break |
||||
|
} |
||||
|
}, |
||||
|
// 信息条数 获取点击时当前的sid |
||||
|
handleSelectionChange(row) { |
||||
|
const aa = [] |
||||
|
this.multipleSelection = row |
||||
|
row.forEach(element => { |
||||
|
aa.push(element.sid) |
||||
|
}) |
||||
|
this.sids = aa |
||||
|
}, |
||||
|
// 表中序号 |
||||
|
indexMethod(index) { |
||||
|
var pagestart = (this.listQuery.current - 1) * this.listQuery.size |
||||
|
var pageindex = index + 1 + pagestart |
||||
|
return pageindex |
||||
|
}, |
||||
|
showData(deptSid, type) { |
||||
|
this.init() |
||||
|
this.listQuery.params.useOrgSid = deptSid |
||||
|
this.listQuery.params.billType = type // type工单类型 |
||||
|
this.getList() |
||||
|
}, |
||||
|
// 查询列表信息 |
||||
|
getList() { |
||||
|
this.listLoading = true |
||||
|
customerList(this.listQuery).then((response) => { |
||||
|
this.listLoading = false |
||||
|
if (response.success) { |
||||
|
this.list = response.data.records |
||||
|
this.listQuery.total = response.data.total |
||||
|
} else { |
||||
|
this.list = [] |
||||
|
this.listQuery.total = 0 |
||||
|
} |
||||
|
}) |
||||
|
}, |
||||
|
// 查询按钮 |
||||
|
handleFilter() { |
||||
|
this.listQuery.current = 1 |
||||
|
this.getList() |
||||
|
}, |
||||
|
// 点击重置 |
||||
|
handleReset() { |
||||
|
this.listQuery.current = 1 |
||||
|
this.listQuery.total = 0 |
||||
|
this.listQuery.size = 5 |
||||
|
this.listQuery.params.customerName = '' |
||||
|
this.listQuery.params.vehMark = '' |
||||
|
this.listQuery.params.vinNo = '' |
||||
|
this.listQuery.params.mobile = '' |
||||
|
this.listQuery.params.customerTypeKey = '' |
||||
|
this.getList() |
||||
|
}, |
||||
|
toQuickAdd() { |
||||
|
if (this.sids.length === 1) { |
||||
|
this.dialogVisible = true |
||||
|
this.isQuickAdd = true |
||||
|
this.formobj = { |
||||
|
visitWay: '', // 联络方式 |
||||
|
visitWayKey: '', |
||||
|
customerType: '', // 客户类型 |
||||
|
customerTypeKey: '', |
||||
|
psid: '' |
||||
|
} |
||||
|
} else { |
||||
|
this.$message({ showClose: true, type: 'error', message: '请选择一条记录进行操作' }) |
||||
|
} |
||||
|
}, |
||||
|
toAdd() { |
||||
|
this.dialogVisible = true |
||||
|
this.isQuickAdd = false |
||||
|
this.formobj = { |
||||
|
visitWay: '', // 联络方式 |
||||
|
visitWayKey: '', |
||||
|
customerType: '', // 客户类型 |
||||
|
customerTypeKey: '', |
||||
|
psid: '' |
||||
|
} |
||||
|
}, |
||||
|
visitWayChange(value) { |
||||
|
const choose = this.visitWay_list.filter((item) => item.dictKey === value) |
||||
|
if (choose.length > 0 && choose !== null) { |
||||
|
this.formobj.visitWay = choose[0].dictValue |
||||
|
} |
||||
|
}, |
||||
|
customerTypeChange(value) { |
||||
|
const choose = this.customerType_list.filter((item) => item.dictValue === value) |
||||
|
if (choose.length > 0 && choose !== null) { |
||||
|
this.formobj.customerTypeKey = choose[0].dictKey |
||||
|
this.formobj.psid = choose[0].sid |
||||
|
} |
||||
|
}, |
||||
|
handleConfirm() { |
||||
|
if (this.formobj.customerType !== '' && this.formobj.visitWay !== '') { |
||||
|
this.dialogVisible = false |
||||
|
if (this.isQuickAdd) { |
||||
|
this.viewState = 3 |
||||
|
this.$refs['divQuickAdd'].showAdd(this.formobj, this.sids[0]) |
||||
|
} else { |
||||
|
this.viewState = 3 |
||||
|
this.$refs['divQuickAdd'].showAdd(this.formobj, '') |
||||
|
} |
||||
|
} else { |
||||
|
this.$message({ showClose: true, message: '请填写联络方式和客户类型', type: 'warning' }) |
||||
|
} |
||||
|
}, |
||||
|
handleAffirm(row) { |
||||
|
this.$emit('backData', row) |
||||
|
}, |
||||
|
resetState() { |
||||
|
this.viewState = 1 |
||||
|
}, |
||||
|
doClose() { |
||||
|
this.$emit('doback') |
||||
|
} |
||||
|
} |
||||
|
} |
||||
|
</script> |
||||
|
<style scoped> |
||||
|
.span-sty { |
||||
|
width: 100px !important; |
||||
|
} |
||||
|
.addinputInfo { |
||||
|
margin-left: 90px !important; |
||||
|
} |
||||
|
</style> |
@ -1,192 +0,0 @@ |
|||||
<template> |
|
||||
<div class="app-container"> |
|
||||
<!--列表页面--> |
|
||||
<div v-show="viewState == 1"> |
|
||||
<button-bar view-title="选择客户" ref="btnbar" :btndisabled="btndisabled" @btnhandle="btnHandle"/> |
|
||||
<!--Start查询列表部分--> |
|
||||
<div class="main-content"> |
|
||||
<div class="searchcon"> |
|
||||
<el-button size="small" class="searchbtn" @click="clicksearchShow">{{ searchxianshitit }}</el-button> |
|
||||
<div v-show="isSearchShow" class="search"> |
|
||||
<el-form ref="listQueryform" :inline="true" :model="listQuery" class="tab-header"> |
|
||||
<el-form-item label="客户名称"> |
|
||||
<el-input v-model="listQuery.params.name" placeholder="" clearable/> |
|
||||
</el-form-item> |
|
||||
<el-form-item label="车牌号"> |
|
||||
<el-input v-model="listQuery.params.vehMark" placeholder="" clearable/> |
|
||||
</el-form-item> |
|
||||
<el-form-item label="车架号"> |
|
||||
<el-input v-model="listQuery.params.vinNo" placeholder="" clearable/> |
|
||||
</el-form-item> |
|
||||
<el-form-item label="联系电话"> |
|
||||
<el-input v-model="listQuery.params.mobile" placeholder="" clearable/> |
|
||||
</el-form-item> |
|
||||
<el-form-item label="客户单位"> |
|
||||
<el-input v-model="listQuery.params.orgName" placeholder="" clearable/> |
|
||||
</el-form-item> |
|
||||
</el-form> |
|
||||
<div class="btn" style="text-align: center;"> |
|
||||
<el-button type="primary" icon="el-icon-search" size="small" @click="handleFilter">查询</el-button> |
|
||||
<el-button type="primary" icon="el-icon-refresh" size="small" @click="handleReset">重置</el-button> |
|
||||
</div> |
|
||||
</div> |
|
||||
</div> |
|
||||
<!--End查询列表部分--> |
|
||||
<div class="listtop"> |
|
||||
<div class="tit">客户列表</div> |
|
||||
<pageye v-show="list.length > 0" :total="listQuery.total" :page.sync="listQuery.current" :limit.sync="listQuery.size" class="pagination" @pagination="getList"/> |
|
||||
</div> |
|
||||
<!--Start 主页面主要部分 --> |
|
||||
<div class=""> |
|
||||
<el-table :key="tableKey" v-loading="listLoading" :data="list" border style="width: 100%;"> |
|
||||
<el-table-column fixed label="序号" type="index" width="80" :index="indexMethod" align="center"/> |
|
||||
<el-table-column fixed label="操作" width="100" align="center"> |
|
||||
<template slot-scope="scope"> |
|
||||
<el-button type="primary" size="small" @click="handleConfirm(scope.row)">确认</el-button> |
|
||||
</template> |
|
||||
</el-table-column> |
|
||||
<el-table-column prop="name" label="客户名称" width="120" align="center"/> |
|
||||
<el-table-column prop="vehMark" label="车牌号" width="120" align="center" /> |
|
||||
<el-table-column prop="vinNo" label="车架号" width="120" align="center" /> |
|
||||
<el-table-column prop="mobile" label="联系电话" width="120" align="center" /> |
|
||||
<el-table-column prop="orgName" label="客户单位" min-width="120" align="center" /> |
|
||||
</el-table> |
|
||||
</div> |
|
||||
<!--End 主页面主要部分--> |
|
||||
<div class="pages"> |
|
||||
<div class="tit"/> |
|
||||
<!-- 翻页 --> |
|
||||
<pagination v-show="list.length > 0" :total="listQuery.total" :page.sync="listQuery.current" :limit.sync="listQuery.size" class="pagination" @pagination="getList"/> |
|
||||
</div> |
|
||||
<!--End查询列表部分--> |
|
||||
</div> |
|
||||
</div> |
|
||||
</div> |
|
||||
</template> |
|
||||
|
|
||||
<script> |
|
||||
import Pagination from '@/components/pagination' |
|
||||
import pageye from '@/components/pagination/pageye' |
|
||||
import ButtonBar from '@/components/ButtonBar' |
|
||||
import { customerListPage } from '@/api/Common/dictcommons' |
|
||||
|
|
||||
export default { |
|
||||
name: 'Customer', |
|
||||
components: { |
|
||||
Pagination, |
|
||||
pageye, |
|
||||
ButtonBar |
|
||||
}, |
|
||||
data() { |
|
||||
return { |
|
||||
btndisabled: false, |
|
||||
btnList: [ |
|
||||
{ |
|
||||
type: 'info', |
|
||||
size: 'small', |
|
||||
icon: 'cross', |
|
||||
btnKey: 'doClose', |
|
||||
btnLabel: '关闭' |
|
||||
} |
|
||||
], |
|
||||
isSearchShow: false, |
|
||||
searchxianshitit: '显示查询条件', |
|
||||
viewState: 1, // 1、列表 2、新增 3、编辑 4、查看 |
|
||||
tableKey: 0, |
|
||||
list: [], |
|
||||
sids: [], // 用于导出的时候保存已选择的SIDs |
|
||||
FormLoading: false, |
|
||||
listLoading: false, |
|
||||
// 翻页 |
|
||||
listQuery: { |
|
||||
current: 1, |
|
||||
size: 5, |
|
||||
total: 0, |
|
||||
params: { |
|
||||
orgPath: '', |
|
||||
name: '', |
|
||||
vehMark: '', |
|
||||
mobile: '', |
|
||||
orgName: '', |
|
||||
vinNo: '' |
|
||||
} |
|
||||
} |
|
||||
} |
|
||||
}, |
|
||||
mounted() { |
|
||||
this.$refs['btnbar'].setButtonList(this.btnList) |
|
||||
}, |
|
||||
methods: { |
|
||||
// 搜索条件效果 |
|
||||
clicksearchShow() { |
|
||||
this.isSearchShow = !this.isSearchShow |
|
||||
if (this.isSearchShow) { |
|
||||
this.searchxianshitit = '隐藏查询条件' |
|
||||
} else { |
|
||||
this.searchxianshitit = '显示查询条件' |
|
||||
} |
|
||||
}, |
|
||||
btnHandle(btnKey) { |
|
||||
console.log('XXXXXXXXXXXXXXX ' + btnKey) |
|
||||
switch (btnKey) { |
|
||||
case 'doClose': |
|
||||
this.doClose() |
|
||||
break |
|
||||
default: |
|
||||
break |
|
||||
} |
|
||||
}, |
|
||||
// 表中序号 |
|
||||
indexMethod(index) { |
|
||||
var pagestart = (this.listQuery.current - 1) * this.listQuery.size |
|
||||
var pageindex = index + 1 + pagestart |
|
||||
return pageindex |
|
||||
}, |
|
||||
// 查询列表信息 |
|
||||
getList() { |
|
||||
this.listLoading = true |
|
||||
this.listQuery.params.orgPath = window.sessionStorage.getItem('defaultOrgPath') |
|
||||
customerListPage(this.listQuery).then(response => { |
|
||||
this.listLoading = false |
|
||||
if (response.success) { |
|
||||
this.list = response.data.records |
|
||||
this.listQuery.total = response.data.total |
|
||||
} else { |
|
||||
this.list = [] |
|
||||
this.listQuery.total = 0 |
|
||||
} |
|
||||
}) |
|
||||
}, |
|
||||
// 查询按钮 |
|
||||
handleFilter() { |
|
||||
this.listQuery.current = 1 |
|
||||
this.getList() |
|
||||
}, |
|
||||
// 点击重置 |
|
||||
handleReset() { |
|
||||
this.listQuery = { |
|
||||
current: 1, |
|
||||
size: 5, |
|
||||
total: 0, |
|
||||
params: { |
|
||||
orgPath: '', |
|
||||
name: '', |
|
||||
vehMark: '', |
|
||||
mobile: '', |
|
||||
orgName: '', |
|
||||
vinNo: '' |
|
||||
} |
|
||||
} |
|
||||
this.getList() |
|
||||
}, |
|
||||
handleConfirm(row) { |
|
||||
this.$emit('backData', row) |
|
||||
}, |
|
||||
doClose() { |
|
||||
this.$emit('doback') |
|
||||
} |
|
||||
} |
|
||||
} |
|
||||
</script> |
|
||||
<style scoped> |
|
||||
</style> |
|
@ -0,0 +1,36 @@ |
|||||
|
package com.yxt.anrui.as.api.asbusrepairinventorybill; |
||||
|
|
||||
|
import com.yxt.common.core.query.Query; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @author Fan |
||||
|
* @description |
||||
|
* @date 2024/7/18 14:34 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class AsBusrepairBillQuery implements Query { |
||||
|
|
||||
|
|
||||
|
private String repairState; //维修状态
|
||||
|
private String billNo; //工单编号
|
||||
|
private String billType; //工单类型
|
||||
|
private String subject; //科目
|
||||
|
private String customerName; //是否外出
|
||||
|
private String vehMark; //车牌号
|
||||
|
private String vinNo; //车架号
|
||||
|
|
||||
|
private String createTimeEnd; //进厂结束日期
|
||||
|
private String createTimeStart; //进厂开始日期
|
||||
|
private String completeState; //0未完成 1已完成
|
||||
|
|
||||
|
@ApiModelProperty("使用组织sid") |
||||
|
private String orgPath; |
||||
|
private String userSid; |
||||
|
@ApiModelProperty("菜单url") |
||||
|
private String menuUrl; |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
@ -0,0 +1,27 @@ |
|||||
|
package com.yxt.anrui.as.api.asbusrepairinventorybill; |
||||
|
|
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @author Fan |
||||
|
* @description |
||||
|
* @date 2024/7/18 14:26 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class AsBusrepairBillVo { |
||||
|
|
||||
|
|
||||
|
private String repairState; //维修状态
|
||||
|
private String billSid; //维修工单sid
|
||||
|
private String billNo; //工单编号
|
||||
|
private String billTypeValue; //工单类型
|
||||
|
private String subjectValue; //科目
|
||||
|
private String customerName; //是否外出
|
||||
|
private String vehMark; //车牌号
|
||||
|
private String vinNo; //车架号
|
||||
|
private String isGoOut; //是否外出
|
||||
|
private String mobile; //联系电话
|
||||
|
private String entryTime; //进厂日期
|
||||
|
|
||||
|
|
||||
|
} |
@ -0,0 +1,16 @@ |
|||||
|
package com.yxt.anrui.as.api.asbusrepairinventorybill; |
||||
|
|
||||
|
import com.yxt.common.core.query.Query; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @author Fan |
||||
|
* @description |
||||
|
* @date 2024/7/18 10:19 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class AsBusrepairInventorybillListVo implements Query { |
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
@ -0,0 +1,16 @@ |
|||||
|
package com.yxt.anrui.as.api.asbusrepairinventorybill; |
||||
|
|
||||
|
import com.yxt.common.core.dto.Dto; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @author Fan |
||||
|
* @description |
||||
|
* @date 2024/7/18 16:48 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class ConfirmDto implements Dto { |
||||
|
|
||||
|
private String sid; |
||||
|
private String remarks; |
||||
|
} |
@ -0,0 +1,185 @@ |
|||||
|
package com.yxt.anrui.as.api.ascustomervehicle; |
||||
|
|
||||
|
import com.yxt.common.core.dto.Dto; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
import javax.validation.constraints.NotBlank; |
||||
|
|
||||
|
/** |
||||
|
* @author Fan |
||||
|
* @description |
||||
|
* @date 2024/7/19 9:48 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class QuickAddCustomer implements Dto { |
||||
|
@ApiModelProperty(value = "当前登录用户的sid") |
||||
|
private String userSid; |
||||
|
|
||||
|
@ApiModelProperty(value = "客户类型(1个人/2企业)", required = true) |
||||
|
@NotBlank(message = "客户类型为必选项") |
||||
|
private String customerType; |
||||
|
|
||||
|
@ApiModelProperty(value = "客户类型key", required = true) |
||||
|
@NotBlank(message = "客户类型为必选项") |
||||
|
private String customerTypeKey; |
||||
|
|
||||
|
@ApiModelProperty(value = "见面方式key", required = true) |
||||
|
@NotBlank(message = "见面方式为必选项") |
||||
|
private String visitWayKey; |
||||
|
|
||||
|
@ApiModelProperty(value = "见面方式(到店/电话/拜访)", required = true) |
||||
|
@NotBlank(message = "见面方式为必选项") |
||||
|
private String visitWay; |
||||
|
|
||||
|
@ApiModelProperty(value = "客户名称", required = true) |
||||
|
@NotBlank(message = "客户名称为必填项") |
||||
|
private String name; |
||||
|
|
||||
|
@ApiModelProperty("联系电话") |
||||
|
@NotBlank(message = "联系电话为必填项") |
||||
|
private String mobile; |
||||
|
|
||||
|
@ApiModelProperty("微信号码") |
||||
|
private String weixin; |
||||
|
|
||||
|
@ApiModelProperty("公司名称:个人客户时显示") |
||||
|
private String companyName; |
||||
|
|
||||
|
@ApiModelProperty("行政区划代码(省)") |
||||
|
private String address_province; |
||||
|
|
||||
|
@ApiModelProperty("行政区划代码(市)") |
||||
|
private String address_city; |
||||
|
@ApiModelProperty("行政区划代码(县)") |
||||
|
private String address_county; |
||||
|
@ApiModelProperty("客户地址:省") |
||||
|
private String province; |
||||
|
@ApiModelProperty("客户地址:市") |
||||
|
private String city; |
||||
|
@ApiModelProperty("客户地址:县") |
||||
|
private String county; |
||||
|
@ApiModelProperty("客户地址:详细地址") |
||||
|
private String address; |
||||
|
|
||||
|
@ApiModelProperty("客户级别(意向客户/准客户/成交客户/集团内销/黑名单客户)") |
||||
|
private String level; |
||||
|
@ApiModelProperty("客户级别key") |
||||
|
private String levelKey; |
||||
|
@ApiModelProperty("是否开启提醒(1开启,0不开启)") |
||||
|
private String isOnRemindkey; |
||||
|
@ApiModelProperty("是否开启提醒(1开启,0不开启)") |
||||
|
private String isOnRemind; |
||||
|
@ApiModelProperty("提醒日期") |
||||
|
private String remind_day; |
||||
|
@ApiModelProperty("提醒备注") |
||||
|
private String remind_remark; |
||||
|
//更多信息
|
||||
|
@ApiModelProperty("客户生日:个人客户时显示") |
||||
|
private String birthday; |
||||
|
@ApiModelProperty("性别:个人客户时显示") |
||||
|
private String sex; |
||||
|
@ApiModelProperty("性别key:个人客户时") |
||||
|
private String sexKey; |
||||
|
@ApiModelProperty("证件类型key") |
||||
|
private String certificateTypeKey; |
||||
|
@ApiModelProperty("证件类型(个人为身份证/企业为营业执照)") |
||||
|
private String certificateType; |
||||
|
@ApiModelProperty("证件号码(个人为身份证号/企业为统一社会信用代码)") |
||||
|
private String IDNumber; |
||||
|
@ApiModelProperty("证件有效期") |
||||
|
private String endDate; |
||||
|
@ApiModelProperty("电子邮箱") |
||||
|
private String e_mail; |
||||
|
@ApiModelProperty(value = "联系人") |
||||
|
private String contacts; |
||||
|
@ApiModelProperty("紧急联系人") |
||||
|
private String emergencyContact; |
||||
|
|
||||
|
@ApiModelProperty("紧急联系电话") |
||||
|
private String emergencyMobile; |
||||
|
|
||||
|
@ApiModelProperty("客户来源(公司资源/自主开发/交接客户/转介绍客户/集团内销)") |
||||
|
private String source; |
||||
|
|
||||
|
@ApiModelProperty("客户来源key") |
||||
|
private String sourceKey; |
||||
|
@ApiModelProperty("客户分类(个人:司机/个体老板/其他。企业:企业型客户/一级经销商/二级经销商/终端物流客户)") |
||||
|
private String customerClass; |
||||
|
@ApiModelProperty("客户分类key") |
||||
|
private String customerClassKey; |
||||
|
@ApiModelProperty(value = "备注") |
||||
|
private String remarks; |
||||
|
@ApiModelProperty("业务人员sid") |
||||
|
private String staffSid; |
||||
|
private String orgPath; |
||||
|
private String useOrgSid; |
||||
|
private String customerOrgSid; |
||||
|
private String customerOrgName; |
||||
|
|
||||
|
//--------------------车辆信息----------------------
|
||||
|
|
||||
|
private String customerVehSid; // 客户车辆信息sid
|
||||
|
@ApiModelProperty("客户sid") |
||||
|
private String customerSid; // 客户sid
|
||||
|
@ApiModelProperty("车牌号") |
||||
|
private String vehMark; // 车牌号
|
||||
|
@ApiModelProperty("车架号") |
||||
|
private String vinNo; // 车架号
|
||||
|
@ApiModelProperty("发动机号") |
||||
|
private String engineNo; // 发动机号
|
||||
|
@ApiModelProperty("车型sid") |
||||
|
private String vehModelSid; // 车型sid
|
||||
|
@ApiModelProperty("车型") |
||||
|
private String vehModel; // 车型
|
||||
|
@ApiModelProperty("行驶里程") |
||||
|
private String mileage; // 行驶里程
|
||||
|
@ApiModelProperty("上次保养里程") |
||||
|
private String lastMileage; // 上次保养里程
|
||||
|
@ApiModelProperty("下次保养日期") |
||||
|
private String nextMaintainDate; // 下次保养日期
|
||||
|
@ApiModelProperty("购车日期") |
||||
|
private String buyDate; // 购车日期
|
||||
|
@ApiModelProperty("商业险到期日期") |
||||
|
private String commercialInsuranceEndDate; // 商业险到期日期
|
||||
|
@ApiModelProperty("交强险到期日期") |
||||
|
private String compulsoryInsuranceEndDate; // 交强险到期日期
|
||||
|
|
||||
|
@ApiModelProperty("行驶里程") |
||||
|
private String currentMileage; // 行驶里程
|
||||
|
@ApiModelProperty("每月公里") |
||||
|
private String MonthKm; // 每月公里
|
||||
|
@ApiModelProperty("滤芯到期公里") |
||||
|
private String filter_km; // 滤芯到期公里
|
||||
|
@ApiModelProperty("滤芯到期日期") |
||||
|
private String filter_date; // 滤芯到期日期
|
||||
|
@ApiModelProperty("机油到期公里") |
||||
|
private String engineoil_km; // 机油到期公里
|
||||
|
@ApiModelProperty("机油到期日期") |
||||
|
private String engineoil_date; // 机油到期日期
|
||||
|
@ApiModelProperty("齿轮油到期公里") |
||||
|
private String gearoil_km; // 齿轮油到期公里
|
||||
|
@ApiModelProperty("齿轮油到期日期") |
||||
|
private String gearoil_date; // 齿轮油到期日期
|
||||
|
@ApiModelProperty("宝轮到期公里") |
||||
|
private String treasurewheel_km; // 宝轮到期公里
|
||||
|
@ApiModelProperty("宝轮到期日期") |
||||
|
private String treasurewheel_date; // 宝轮到期日期
|
||||
|
@ApiModelProperty("风扇皮带到期公里") |
||||
|
private String fanbelt_km; // 风扇皮带到期公里
|
||||
|
@ApiModelProperty("风扇皮带到期日期") |
||||
|
private String fanbelt_date; // 风扇皮带到期日期
|
||||
|
@ApiModelProperty("刹车片到期公里") |
||||
|
private String brakepads_km; // 刹车片到期公里
|
||||
|
@ApiModelProperty("刹车片到期日期") |
||||
|
private String brakepads_date; // 刹车片到期日期
|
||||
|
|
||||
|
@ApiModelProperty("车辆备注") |
||||
|
private String carRemarks; |
||||
|
@ApiModelProperty("保养备注") |
||||
|
private String byRemarks; |
||||
|
|
||||
|
|
||||
|
|
||||
|
|
||||
|
} |
@ -0,0 +1,19 @@ |
|||||
|
package com.yxt.anrui.as.api.asserviceclaimanu; |
||||
|
|
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @author Fan |
||||
|
* @description |
||||
|
* @date 2024/7/18 9:19 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class ServiceClaimanuVo { |
||||
|
|
||||
|
|
||||
|
private String sid; |
||||
|
@ApiModelProperty("索赔厂家名称") |
||||
|
private String claiManuName; // 索赔厂家名称
|
||||
|
} |
||||
|
|
@ -0,0 +1,19 @@ |
|||||
|
package com.yxt.anrui.as.api.asserviceitem; |
||||
|
|
||||
|
import com.yxt.common.core.query.Query; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
/** |
||||
|
* @author Fan |
||||
|
* @description |
||||
|
* @date 2024/7/18 17:21 |
||||
|
*/ |
||||
|
@Data |
||||
|
public class AsBusrepairServiceItemQuery implements Query { |
||||
|
|
||||
|
private String useOrgSid; // 部门sid
|
||||
|
private String subject; // 科目
|
||||
|
@ApiModelProperty("项目名称") |
||||
|
private String sitemName; |
||||
|
} |
@ -0,0 +1,50 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.yxt.anrui.as.biz.asbusrepairbillinsurancerecord; |
||||
|
|
||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper; |
||||
|
import com.yxt.anrui.as.api.asbusrepairbillinsurance.AsBusrepairBillInsurance; |
||||
|
import com.yxt.anrui.as.api.asbusrepairbillinsurancerecord.AsBusrepairBillInsuranceRecord; |
||||
|
import org.apache.ibatis.annotations.Delete; |
||||
|
import org.apache.ibatis.annotations.Mapper; |
||||
|
import org.apache.ibatis.annotations.Param; |
||||
|
import org.apache.ibatis.annotations.Select; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@Mapper |
||||
|
public interface AsBusrepairBillInsuranceRecordMapper extends BaseMapper<AsBusrepairBillInsuranceRecord> { |
||||
|
@Select("select * from as_busrepair_bill_insurance_record where billSid = #{billSid}") |
||||
|
List<AsBusrepairBillInsuranceRecord> fetchByBillSid(@Param("billSid") String billSid); |
||||
|
|
||||
|
@Delete("delete from as_busrepair_bill_insurance_record where billSid = #{sid}") |
||||
|
void delByBillSid(String billSid); |
||||
|
} |
@ -0,0 +1,6 @@ |
|||||
|
<?xml version="1.0" encoding="UTF-8" ?> |
||||
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
||||
|
<mapper namespace="com.yxt.anrui.as.biz.asbusrepairbillinsurancerecord.AsBusrepairBillInsuranceRecordMapper"> |
||||
|
<!-- <where> ${ew.sqlSegment} </where>--> |
||||
|
<!-- ${ew.customSqlSegment} --> |
||||
|
</mapper> |
@ -0,0 +1,45 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.yxt.anrui.as.biz.asbusrepairbillinsurancerecord; |
||||
|
|
||||
|
|
||||
|
import io.swagger.annotations.Api; |
||||
|
import org.springframework.web.bind.annotation.RequestMapping; |
||||
|
import org.springframework.web.bind.annotation.RestController; |
||||
|
|
||||
|
/** |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@Api(tags = "维修工单-保险信息") |
||||
|
@RestController |
||||
|
@RequestMapping("v1/AsBusrepairBillInsuranceRecord") |
||||
|
public class AsBusrepairBillInsuranceRecordRest { |
||||
|
|
||||
|
|
||||
|
} |
@ -0,0 +1,50 @@ |
|||||
|
/********************************************************* |
||||
|
********************************************************* |
||||
|
******************** ******************* |
||||
|
************* ************ |
||||
|
******* _oo0oo_ ******* |
||||
|
*** o8888888o *** |
||||
|
* 88" . "88 * |
||||
|
* (| -_- |) * |
||||
|
* 0\ = /0 * |
||||
|
* ___/`---'\___ * |
||||
|
* .' \\| |// '. *
|
||||
|
* / \\||| : |||// \ *
|
||||
|
* / _||||| -:- |||||- \ * |
||||
|
* | | \\\ - /// | | *
|
||||
|
* | \_| ''\---/'' |_/ | * |
||||
|
* \ .-\__ '-' ___/-. / * |
||||
|
* ___'. .' /--.--\ `. .'___ * |
||||
|
* ."" '< `.___\_<|>_/___.' >' "". * |
||||
|
* | | : `- \`.;`\ _ /`;.`/ - ` : | | * |
||||
|
* \ \ `_. \_ __\ /__ _/ .-` / / * |
||||
|
* =====`-.____`.___ \_____/___.-`___.-'===== * |
||||
|
* `=---=' * |
||||
|
* ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ * |
||||
|
*********__佛祖保佑__永无BUG__验收通过__钞票多多__********* |
||||
|
*********************************************************/ |
||||
|
package com.yxt.anrui.as.biz.asbusrepairbillinsurancerecord; |
||||
|
|
||||
|
import com.yxt.anrui.as.api.asbusrepairbillinsurance.AsBusrepairBillInsurance; |
||||
|
import com.yxt.anrui.as.api.asbusrepairbillinsurancerecord.AsBusrepairBillInsuranceRecord; |
||||
|
import com.yxt.common.base.service.MybatisBaseService; |
||||
|
import org.springframework.stereotype.Service; |
||||
|
|
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@Service |
||||
|
public class AsBusrepairBillInsuranceRecordService extends MybatisBaseService<AsBusrepairBillInsuranceRecordMapper, AsBusrepairBillInsuranceRecord> { |
||||
|
public List<AsBusrepairBillInsuranceRecord> fetchByBillSid(String billSid) { |
||||
|
return baseMapper.fetchByBillSid(billSid); |
||||
|
} |
||||
|
|
||||
|
public void delByBillSid(String billSid) { |
||||
|
baseMapper.delByBillSid(billSid); |
||||
|
} |
||||
|
|
||||
|
} |
@ -0,0 +1,146 @@ |
|||||
|
package com.yxt.anrui.as.feign.crm; |
||||
|
|
||||
|
|
||||
|
|
||||
|
import com.yxt.common.core.dto.Dto; |
||||
|
import io.swagger.annotations.ApiModel; |
||||
|
import io.swagger.annotations.ApiModelProperty; |
||||
|
import lombok.Data; |
||||
|
|
||||
|
import javax.validation.constraints.NotBlank; |
||||
|
import java.util.ArrayList; |
||||
|
import java.util.List; |
||||
|
|
||||
|
/** |
||||
|
* Project: anrui-crm(客户管理) <br/> |
||||
|
* File: CrmCustomerTempDto.java <br/> |
||||
|
* Class: com.yxt.anrui.crm.api.crmcustomertemp.CrmCustomerTempDto <br/> |
||||
|
* Description: 潜在客户信息 数据传输对象. <br/> |
||||
|
* Copyright: Copyright (c) 2011 <br/> |
||||
|
* Company: https://gitee.com/liuzp315 <br/>
|
||||
|
* Makedate: 2022-01-12 11:21:16 <br/> |
||||
|
* |
||||
|
* @author liupopo |
||||
|
* @version 1.0 |
||||
|
* @since 1.0 |
||||
|
*/ |
||||
|
@ApiModel(value = "潜在客户信息 数据传输对象", description = "潜在客户信息 数据传输对象") |
||||
|
@Data |
||||
|
public class CrmCustomerTempDto implements Dto { |
||||
|
|
||||
|
private static final long serialVersionUID = 793474187074718535L; |
||||
|
|
||||
|
@ApiModelProperty(value = "当前登录用户的sid") |
||||
|
private String userSid; |
||||
|
|
||||
|
@ApiModelProperty(value = "客户类型(1个人/2企业)", required = true) |
||||
|
@NotBlank(message = "客户类型为必选项") |
||||
|
private String customerType; |
||||
|
|
||||
|
@ApiModelProperty(value = "客户类型key", required = true) |
||||
|
@NotBlank(message = "客户类型为必选项") |
||||
|
private String customerTypeKey; |
||||
|
|
||||
|
@ApiModelProperty(value = "见面方式key", required = true) |
||||
|
@NotBlank(message = "见面方式为必选项") |
||||
|
private String visitWayKey; |
||||
|
|
||||
|
@ApiModelProperty(value = "见面方式(到店/电话/拜访)", required = true) |
||||
|
@NotBlank(message = "见面方式为必选项") |
||||
|
private String visitWay; |
||||
|
|
||||
|
@ApiModelProperty(value = "客户名称", required = true) |
||||
|
@NotBlank(message = "客户名称为必填项") |
||||
|
private String name; |
||||
|
|
||||
|
@ApiModelProperty("联系电话") |
||||
|
@NotBlank(message = "联系电话为必填项") |
||||
|
private String mobile; |
||||
|
|
||||
|
@ApiModelProperty("微信号码") |
||||
|
private String weixin; |
||||
|
|
||||
|
@ApiModelProperty("公司名称:个人客户时显示") |
||||
|
private String companyName; |
||||
|
|
||||
|
@ApiModelProperty("行政区划代码(省)") |
||||
|
private String address_province; |
||||
|
|
||||
|
@ApiModelProperty("行政区划代码(市)") |
||||
|
private String address_city; |
||||
|
@ApiModelProperty("行政区划代码(县)") |
||||
|
private String address_county; |
||||
|
@ApiModelProperty("客户地址:省") |
||||
|
private String province; |
||||
|
@ApiModelProperty("客户地址:市") |
||||
|
private String city; |
||||
|
@ApiModelProperty("客户地址:县") |
||||
|
private String county; |
||||
|
@ApiModelProperty("客户地址:详细地址") |
||||
|
private String address; |
||||
|
|
||||
|
@ApiModelProperty("客户级别(意向客户/准客户/成交客户/集团内销/黑名单客户)") |
||||
|
private String level; |
||||
|
@ApiModelProperty("客户级别key") |
||||
|
private String levelKey; |
||||
|
@ApiModelProperty("是否开启提醒(1开启,0不开启)") |
||||
|
private String isOnRemindkey; |
||||
|
@ApiModelProperty("是否开启提醒(1开启,0不开启)") |
||||
|
private String isOnRemind; |
||||
|
@ApiModelProperty("提醒日期") |
||||
|
private String remind_day; |
||||
|
@ApiModelProperty("提醒备注") |
||||
|
private String remind_remark; |
||||
|
//更多信息
|
||||
|
@ApiModelProperty("客户生日:个人客户时显示") |
||||
|
private String birthday; |
||||
|
@ApiModelProperty("性别:个人客户时显示") |
||||
|
private String sex; |
||||
|
@ApiModelProperty("性别key:个人客户时") |
||||
|
private String sexKey; |
||||
|
@ApiModelProperty("证件类型key") |
||||
|
private String certificateTypeKey; |
||||
|
@ApiModelProperty("证件类型(个人为身份证/企业为营业执照)") |
||||
|
private String certificateType; |
||||
|
@ApiModelProperty("证件号码(个人为身份证号/企业为统一社会信用代码)") |
||||
|
private String IDNumber; |
||||
|
@ApiModelProperty("证件有效期") |
||||
|
private String endDate; |
||||
|
@ApiModelProperty("电子邮箱") |
||||
|
private String e_mail; |
||||
|
@ApiModelProperty(value = "联系人") |
||||
|
private String contacts; |
||||
|
@ApiModelProperty("紧急联系人") |
||||
|
private String emergencyContact; |
||||
|
|
||||
|
@ApiModelProperty("紧急联系电话") |
||||
|
private String emergencyMobile; |
||||
|
|
||||
|
@ApiModelProperty("客户来源(公司资源/自主开发/交接客户/转介绍客户/集团内销)") |
||||
|
private String source; |
||||
|
|
||||
|
@ApiModelProperty("客户来源key") |
||||
|
private String sourceKey; |
||||
|
@ApiModelProperty("客户分类(个人:司机/个体老板/其他。企业:企业型客户/一级经销商/二级经销商/终端物流客户)") |
||||
|
private String customerClass; |
||||
|
@ApiModelProperty("客户分类key") |
||||
|
private String customerClassKey; |
||||
|
@ApiModelProperty(value = "备注") |
||||
|
private String remarks; |
||||
|
@ApiModelProperty("业务人员sid") |
||||
|
private String staffSid; |
||||
|
|
||||
|
//运营信息
|
||||
|
// @ApiModelProperty(value = "运营信息")
|
||||
|
// private CrmBusinessDto crmBusinessDto = new CrmBusinessDto();
|
||||
|
// //见证材料集合
|
||||
|
// @ApiModelProperty(value = "见证材料的集合,编辑保存时无此字段")
|
||||
|
// private List<PcCrmVisitAppendixDto> crmVisitAppendixDtoList = new ArrayList<>();
|
||||
|
|
||||
|
|
||||
|
private String orgPath; |
||||
|
private String useOrgSid; |
||||
|
private String customerOrgSid; |
||||
|
private String customerOrgName; |
||||
|
|
||||
|
} |
@ -0,0 +1,35 @@ |
|||||
|
package com.yxt.anrui.as.feign.crm; |
||||
|
|
||||
|
import com.yxt.common.core.result.ResultBean; |
||||
|
import io.swagger.annotations.Api; |
||||
|
import io.swagger.annotations.ApiOperation; |
||||
|
import org.springframework.cloud.openfeign.FeignClient; |
||||
|
import org.springframework.web.bind.annotation.PostMapping; |
||||
|
import org.springframework.web.bind.annotation.RequestBody; |
||||
|
|
||||
|
import javax.validation.Valid; |
||||
|
|
||||
|
/** |
||||
|
* @author Fan |
||||
|
* @description |
||||
|
* @date 2024/7/19 10:10 |
||||
|
*/ |
||||
|
@Api(tags = "潜在客户信息") |
||||
|
@FeignClient( |
||||
|
contextId = "anrui-crm-CrmCustomerTemp", |
||||
|
name = "anrui-crm", |
||||
|
path = "v1/crmcustomertemp" |
||||
|
) |
||||
|
public interface CrmCustomerTempFeign { |
||||
|
|
||||
|
/** |
||||
|
* pc端潜在客户新增保存 |
||||
|
* |
||||
|
* @param dto 客户信息及运行信息数据传输对象 |
||||
|
* @return |
||||
|
*/ |
||||
|
@ApiOperation("新增保存") |
||||
|
@PostMapping("/save") |
||||
|
public ResultBean save(@Valid @RequestBody CrmCustomerTempDto dto); |
||||
|
|
||||
|
} |
Loading…
Reference in new issue