对接部分接口
This commit is contained in:
@@ -85,7 +85,9 @@
|
|||||||
min-height: 100% !important;
|
min-height: 100% !important;
|
||||||
height: auto !important;
|
height: auto !important;
|
||||||
}
|
}
|
||||||
|
.u-popup__content{
|
||||||
|
border-radius: 20px 20px 0px 0px;
|
||||||
|
}
|
||||||
.uni-top-window uni-tabbar .uni-tabbar {
|
.uni-top-window uni-tabbar .uni-tabbar {
|
||||||
background-color: #fff !important;
|
background-color: #fff !important;
|
||||||
}
|
}
|
||||||
|
|||||||
+3
-2
@@ -1,6 +1,7 @@
|
|||||||
const baseUrl = "https://api.collect.hs.hnzhwlkj.club/"; //这里放置url域名32044
|
// const baseUrl = "https://api.collect.hs.hnzhwlkj.club/"; //这里放置url域名32044
|
||||||
// const baseUrl = "http://192.168.0.72:8083/api/v1/"; //这里放置url域名32044
|
// const baseUrl = "http://192.168.0.72:8083/api/v1/"; //这里放置url域名32044
|
||||||
// const baseUrl = "https://114.215.24.240:8106/api/v1/"; //这里放置url域名32044
|
const baseUrl = "http://192.168.50.4:8787/"; //这里放置url域名32044
|
||||||
|
// const baseUrl = "/api/"; //这里放置url域名32044
|
||||||
export function request(options){//封装的requset
|
export function request(options){//封装的requset
|
||||||
let { url,data,method } = options;
|
let { url,data,method } = options;
|
||||||
data = data || {},
|
data = data || {},
|
||||||
|
|||||||
@@ -68,5 +68,15 @@ export default {
|
|||||||
gender2:'女',
|
gender2:'女',
|
||||||
Region:'国家地区',
|
Region:'国家地区',
|
||||||
Regioninputhd:'去选择',
|
Regioninputhd:'去选择',
|
||||||
|
login:'登录',
|
||||||
|
threelogin:'第三方登录',
|
||||||
|
account:'账号',
|
||||||
|
password:'密码',
|
||||||
|
fgpassword:'忘记密码',
|
||||||
|
Facebook:'飞书',
|
||||||
|
email:'邮箱',
|
||||||
|
phone:'手机号',
|
||||||
|
agreeMsg:'我已经阅读并同意',
|
||||||
|
and:'和',
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -2,20 +2,25 @@
|
|||||||
<view class="">
|
<view class="">
|
||||||
<view class="contents" v-for="(item, index) in list" :key="index" @click="handleItemClick(item)">
|
<view class="contents" v-for="(item, index) in list" :key="index" @click="handleItemClick(item)">
|
||||||
<view class="top">
|
<view class="top">
|
||||||
<view class="">2025.03.11 12:00</view>
|
<view class="">{{item.created_at}}</view>
|
||||||
<view class="tag">{{$t('followup')}}</view>
|
<view class="right">
|
||||||
|
<!-- <text class="medal" :style="color:(item.magnitude == 0 ?'#F5AB00' : item.magnitude == 1 ?'#8495B8': '#9B7200')}">{{item.magnitude_txt}}</text> -->
|
||||||
|
<text class="medal" >{{item.magnitude_txt}}</text>
|
||||||
|
<text class="tag">{{$t('followup')}}</text>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text="" :hairline="true"></u-divider>
|
<u-line margin="20rpx 0px"></u-line>
|
||||||
<view class="cont">
|
<view class="cont">
|
||||||
<view class="title">
|
<view class="title">
|
||||||
<view class=""><text class="name">刘德华</text><text class="phone">138****2264</text></view>
|
<view class=""><text class="name">{{item.contacts}}</text><text class="phone">{{item.phone}}</text></view>
|
||||||
<view class="ststus">初步接触</view>
|
<view class="ststus">{{item.grade_txt}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="info"><text class="sex">男</text> | <text class="addr">迪拜</text><text class="type">越野车</text>
|
<view class="info"><text class="sex">男</text> | <text class="addr">迪拜</text><text class="type">越野车</text>
|
||||||
</view>
|
</view>
|
||||||
<slot name="footer">
|
<view class="desc">{{item.describe}}</view>
|
||||||
|
<!-- <slot name="footer">
|
||||||
<text></text>
|
<text></text>
|
||||||
</slot>
|
</slot> -->
|
||||||
<!-- <slot name="footertab">
|
<!-- <slot name="footertab">
|
||||||
<view class="desc1">
|
<view class="desc1">
|
||||||
<view class="" @click="phoneClick(item)"><image src="/static/image/customer/phone.png" mode=""></image> 呼叫</view>
|
<view class="" @click="phoneClick(item)"><image src="/static/image/customer/phone.png" mode=""></image> 呼叫</view>
|
||||||
@@ -62,6 +67,13 @@
|
|||||||
padding: 3px 10px;
|
padding: 3px 10px;
|
||||||
margin-right: -15px;
|
margin-right: -15px;
|
||||||
}
|
}
|
||||||
|
.right{
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
.medal{
|
||||||
|
margin-right: 10px;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
.cont{
|
.cont{
|
||||||
padding: 0px 15px 10px;
|
padding: 0px 15px 10px;
|
||||||
|
|||||||
+195
-35
@@ -3,36 +3,62 @@
|
|||||||
<uni-nav-bar leftText=" " :fixed="true" :border="false" leftIcon="back" @clickLeft="leftClick" color="#000000" backgroundColor="#fff" :statusBar="true" title="客户资料"></uni-nav-bar>
|
<uni-nav-bar leftText=" " :fixed="true" :border="false" leftIcon="back" @clickLeft="leftClick" color="#000000" backgroundColor="#fff" :statusBar="true" title="客户资料"></uni-nav-bar>
|
||||||
<view class="content">
|
<view class="content">
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view>客户称呼</view>
|
<view>渠道</view>
|
||||||
<view class="right">
|
<view class="right select" @click="showchannel = true">
|
||||||
<input placeholder="输入称呼" v-model="form.contacts" />
|
<input placeholder="选择渠道" disabled v-model="channel_name" />
|
||||||
|
<u-picker :cancel-text="$t('cancel')" :confirm-text="$t('confirm')" :show="showchannel" @cancel="cancel('showchannel')" :columns="channelList" keyName="name" @confirm="channelChange"></u-picker>
|
||||||
|
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text=""></u-divider>
|
<u-line></u-line>
|
||||||
|
<view class="cell">
|
||||||
|
<view>客户商机</view>
|
||||||
|
<view class="right select" @click="showmagnitude = true">
|
||||||
|
<input placeholder="选择客户商机" disabled v-model="magnitude_name" />
|
||||||
|
<u-picker :cancel-text="$t('cancel')" :confirm-text="$t('confirm')" :show="showmagnitude" @cancel="cancel('showmagnitude')" :columns="magnitudeList" keyName="name" @confirm="magnitudeChange"></u-picker>
|
||||||
|
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<u-line></u-line>
|
||||||
|
<view class="cell">
|
||||||
|
<view>客户名称 <text class="red">*</text></view>
|
||||||
|
<view class="right">
|
||||||
|
<input placeholder="输入名称" v-model="form.contacts" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<u-line></u-line>
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view>性别</view>
|
<view>性别</view>
|
||||||
<view class="right">
|
<view class="right">
|
||||||
<u-radio-group v-model="form.gender">
|
<u-radio-group v-model="form.sex">
|
||||||
<u-radio name="男">男</u-radio>
|
<u-radio name="0">未知</u-radio>
|
||||||
<u-radio name="女">女</u-radio>
|
<u-radio name="1">男</u-radio>
|
||||||
|
<u-radio name="2">女</u-radio>
|
||||||
</u-radio-group>
|
</u-radio-group>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text=""></u-divider>
|
<u-line></u-line>
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view>联系方式 <text class="red">*</text></view>
|
<view>联系方式 <text class="red">*</text></view>
|
||||||
<view class="right">
|
<view class="right">
|
||||||
<input placeholder="输入联系方式" v-model="form.phone" />
|
<input placeholder="输入联系方式" v-model="form.phone" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text=""></u-divider>
|
<u-line></u-line>
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view>Email</view>
|
<view>Email</view>
|
||||||
<view class="right">
|
<view class="right">
|
||||||
<input placeholder="输入Email" v-model="form.email" />
|
<input placeholder="输入Email" v-model="form.email" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text=""></u-divider>
|
<u-line></u-line>
|
||||||
|
<view class="cell">
|
||||||
|
<view>WhatsApp</view>
|
||||||
|
<view class="right">
|
||||||
|
<input placeholder="输入WhatsApp" v-model="form.WhatsApp" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<u-line></u-line>
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view>客户偏好</view>
|
<view>客户偏好</view>
|
||||||
<view class="right select" @click="showcartype = true">
|
<view class="right select" @click="showcartype = true">
|
||||||
@@ -41,78 +67,133 @@
|
|||||||
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text=""></u-divider>
|
<u-line></u-line>
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view>客户等级</view>
|
<view>客户分级</view>
|
||||||
<view class="right select" @click="showgrade = true">
|
<view class="right select" @click="showgrade = true">
|
||||||
<input placeholder="选择客户等级" disabled v-model="grade_name" />
|
<input placeholder="选择客户分级" disabled v-model="grade_name" />
|
||||||
<u-picker :cancel-text="$t('cancel')" :confirm-text="$t('confirm')" :show="showgrade" @cancel="cancel('showgrade')" :columns="getGradeList" keyName="name" @confirm="gradeHandler"></u-picker>
|
<u-picker :cancel-text="$t('cancel')" :confirm-text="$t('confirm')" :show="showgrade" @cancel="cancel('showgrade')" :columns="getGradeList" keyName="name" @confirm="gradeHandler"></u-picker>
|
||||||
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text=""></u-divider>
|
<u-line></u-line>
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view>国家地区</view>
|
<view>国家</view>
|
||||||
<view class="right select" @click="showenergy = true">
|
<view class="right select" @click="showarea = true">
|
||||||
<input placeholder="选择国家地区" disabled v-model="country_name" />
|
<input placeholder="选择国家" disabled v-model="country_name" />
|
||||||
<u-picker :cancel-text="$t('cancel')" :confirm-text="$t('confirm')" :show="showenergy" @cancel="cancel('showenergy')" :columns="areaList" keyName="name" @confirm="areaChange"></u-picker>
|
<u-picker :cancel-text="$t('cancel')" :confirm-text="$t('confirm')" :show="showarea" @cancel="cancel('showarea')" :columns="areaList" keyName="name" @confirm="areaChange"></u-picker>
|
||||||
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text=""></u-divider>
|
<u-line></u-line>
|
||||||
|
<view class="cell">
|
||||||
|
<view>公司</view>
|
||||||
|
<view class="right select" @click="showmap = true">
|
||||||
|
<input placeholder="去定位" type="text" disabled v-model="form.address"/>
|
||||||
|
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<!-- <u-line></u-line>
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view>首次跟进</view>
|
<view>首次跟进</view>
|
||||||
<view class="right">
|
<view class="right">
|
||||||
<input placeholder="首次跟进" type="digit" v-model="form.mileage"/>
|
<input placeholder="首次跟进" type="text" v-model="form.mileage"/>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view> -->
|
||||||
<u-divider text=""></u-divider>
|
<u-line></u-line>
|
||||||
<view class="cell1">
|
<view class="cell1">
|
||||||
<view>详细情况</view>
|
<view>备注(非必填)</view>
|
||||||
<view class="">
|
<view class="">
|
||||||
<textarea auto-height v-model="form.describe" placeholder="详细情况..."/>
|
<textarea auto-height v-model="form.describe" placeholder="请输入备注内容~"/>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-gap height="100" bgColor="#fff"></u-gap>
|
<u-gap height="100" bgColor="#fff"></u-gap>
|
||||||
</view>
|
</view>
|
||||||
<view class="foot">
|
<view class="foot">
|
||||||
<button class="btn" @click="nextFn">提交</button>
|
<button class="btn" @click="saveFn">提交</button>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
|
<u-popup :show="showmap" :round="10" mode="bottom" @close="mapclose">
|
||||||
|
<view class="mapcont">
|
||||||
|
<view class="header">
|
||||||
|
<view class="cancel" @click="mapclose">取消</view>
|
||||||
|
<view class="title">地图位置</view>
|
||||||
|
<view class="confirm" @click="mapconfirm">确定</view>
|
||||||
|
</view>
|
||||||
|
<view class="map">
|
||||||
|
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</u-popup>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { request,showToast } from '@/api/apiT.js'
|
import { request,showToast } from '@/api/apiT.js'
|
||||||
// import ldSelect from '@/components/ld-select/ld-select.vue'
|
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
showmap: false,
|
||||||
|
showmagnitude: false,
|
||||||
showgrade: false,
|
showgrade: false,
|
||||||
showcartype: false,
|
showcartype: false,
|
||||||
showenergy: false,
|
showchannel: false,
|
||||||
|
showarea: false,
|
||||||
getGradeList:[],
|
getGradeList:[],
|
||||||
carTypeList:[],
|
carTypeList:[],
|
||||||
|
channelList:[],
|
||||||
|
magnitudeList:[],
|
||||||
areaList:[],
|
areaList:[],
|
||||||
grade_name:'',
|
grade_name:'',
|
||||||
car_type_name:'',
|
car_type_name:'',
|
||||||
country_name:'',
|
country_name:'',
|
||||||
|
channel_name:'',
|
||||||
|
magnitude_name:'',
|
||||||
form: {
|
form: {
|
||||||
contacts: '',
|
contacts: '',
|
||||||
gender: '男',
|
sex: '0',
|
||||||
phone: '',
|
phone: '',
|
||||||
email: '',
|
email: '',
|
||||||
describe: '',
|
describe: '',
|
||||||
grade:'',
|
grade:'',
|
||||||
country_id:'',
|
country_id:'',
|
||||||
car_type_id:''
|
car_type_id:'',
|
||||||
|
channel_id:'',
|
||||||
|
magnitude:'',
|
||||||
|
address:'',
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad() {
|
onLoad() {
|
||||||
|
this.getChannel()
|
||||||
|
this.getMagnitude()
|
||||||
|
this.getGrade()
|
||||||
|
this.carType()
|
||||||
|
this.area()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
leftClick(){
|
leftClick(){
|
||||||
uni.navigateBack({})
|
uni.navigateBack({})
|
||||||
},
|
},
|
||||||
|
mapclose(){
|
||||||
|
this.showmap = false
|
||||||
|
},
|
||||||
|
mapconfirm(){
|
||||||
|
this.showmap = false
|
||||||
|
},
|
||||||
|
//渠道
|
||||||
|
getChannel(){
|
||||||
|
request({
|
||||||
|
url:'customer/getChannel',
|
||||||
|
method:'get',
|
||||||
|
}).then(res => {
|
||||||
|
var list = res.data.data
|
||||||
|
this.channelList = [list]
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//客户等级
|
||||||
getGrade(){
|
getGrade(){
|
||||||
request({
|
request({
|
||||||
url:'customer/getGrade',
|
url:'customer/getGrade',
|
||||||
@@ -122,6 +203,7 @@
|
|||||||
this.getGradeList = [list]
|
this.getGradeList = [list]
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
//偏好
|
||||||
carType(){
|
carType(){
|
||||||
request({
|
request({
|
||||||
url:'carType/getAll',
|
url:'carType/getAll',
|
||||||
@@ -131,33 +213,93 @@
|
|||||||
this.carTypeList = [list]
|
this.carTypeList = [list]
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
//国家
|
||||||
area(){
|
area(){
|
||||||
request({
|
request({
|
||||||
url:'area/getAll',
|
url:'area/getCountry',
|
||||||
method:'get',
|
method:'get',
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
var list = res.data.data
|
var list = res.data.data
|
||||||
this.areaList = [list]
|
this.areaList = [list]
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
//商机
|
||||||
|
getMagnitude(){
|
||||||
|
request({
|
||||||
|
url:'customer/getMagnitude',
|
||||||
|
method:'get',
|
||||||
|
}).then(res => {
|
||||||
|
var list = res.data.data
|
||||||
|
this.magnitudeList = [list]
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//商机切换事件
|
||||||
|
magnitudeChange(val){
|
||||||
|
this.form.magnitude = val.value[0].id
|
||||||
|
this.magnitude_name = val.value[0].name
|
||||||
|
this.showmagnitude = false
|
||||||
|
},
|
||||||
|
//通道切换事件
|
||||||
|
channelChange(val){
|
||||||
|
this.form.channel_id = val.value[0].id
|
||||||
|
this.channel_name = val.value[0].name
|
||||||
|
this.showchannel = false
|
||||||
|
},
|
||||||
|
//客户等级切换事件
|
||||||
gradeHandler(val){
|
gradeHandler(val){
|
||||||
this.form.grade = val.value[0].brand_id
|
this.form.grade = val.value[0].id
|
||||||
this.grade_name = val.value[0].name
|
this.grade_name = val.value[0].name
|
||||||
this.showgrade = false
|
this.showgrade = false
|
||||||
},
|
},
|
||||||
|
//国家切换事件
|
||||||
areaChange(val){
|
areaChange(val){
|
||||||
this.form.country_id = val.value[0].energy_id
|
this.form.country_id = val.value[0].id
|
||||||
this.country_name = val.value[0].name
|
this.country_name = val.value[0].name
|
||||||
this.showarea = false
|
this.showarea = false
|
||||||
},
|
},
|
||||||
|
//偏好切换事件
|
||||||
cartypesChange(val){
|
cartypesChange(val){
|
||||||
this.form.car_type_id = val.value[0].energy_id
|
this.form.car_type_id = val.value[0].id
|
||||||
this.car_type_name = val.value[0].name
|
this.car_type_name = val.value[0].name
|
||||||
this.showcartype = false
|
this.showcartype = false
|
||||||
},
|
},
|
||||||
cancel(val){
|
cancel(val){
|
||||||
this[val] = false
|
this[val] = false
|
||||||
},
|
},
|
||||||
|
//提交保存
|
||||||
|
saveFn(){
|
||||||
|
if(this.form.contacts==''){
|
||||||
|
uni.showToast({
|
||||||
|
title:'客户名称不能为空',
|
||||||
|
icon: 'none'
|
||||||
|
});
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
if(this.form.phone==''){
|
||||||
|
uni.showToast({
|
||||||
|
title:'联系方式不能为空',
|
||||||
|
icon: 'none'
|
||||||
|
});
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
request({
|
||||||
|
url:'customer/save',
|
||||||
|
method:'post',
|
||||||
|
data:this.form
|
||||||
|
}).then(res => {
|
||||||
|
uni.showToast({
|
||||||
|
title: res.data.message,
|
||||||
|
icon: 'none'
|
||||||
|
});
|
||||||
|
if(res.data.code ==0){
|
||||||
|
setTimeout(() => {
|
||||||
|
uni.reLaunch({
|
||||||
|
url: '/pages/index/customer',// 替换为你要跳转的页面路径
|
||||||
|
});
|
||||||
|
}, 1000);
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
@@ -182,8 +324,6 @@
|
|||||||
}
|
}
|
||||||
.content{
|
.content{
|
||||||
padding-top: 10px;
|
padding-top: 10px;
|
||||||
background: #FFFFFF;
|
|
||||||
height: calc(100vh - 44px);
|
|
||||||
}
|
}
|
||||||
.cell{
|
.cell{
|
||||||
position: relative;
|
position: relative;
|
||||||
@@ -231,4 +371,24 @@
|
|||||||
margin-bottom: 40px;
|
margin-bottom: 40px;
|
||||||
margin: 15px 4%;
|
margin: 15px 4%;
|
||||||
}
|
}
|
||||||
|
.mapcont{
|
||||||
|
.header{
|
||||||
|
line-height: 50px;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
|
text-align: center;
|
||||||
|
.cancel{
|
||||||
|
width: 20%;
|
||||||
|
color: #999999;
|
||||||
|
}
|
||||||
|
.confirm{
|
||||||
|
width: 20%;
|
||||||
|
color: #3471FF;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.map{
|
||||||
|
height: 350px;
|
||||||
|
}
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
+34
-10
@@ -3,12 +3,20 @@
|
|||||||
<uni-nav-bar leftText=" " :fixed="true" :border="false" leftIcon="back" @clickLeft="leftClick" color="#000000" backgroundColor="#fff" :statusBar="true" title="客户资料"></uni-nav-bar>
|
<uni-nav-bar leftText=" " :fixed="true" :border="false" leftIcon="back" @clickLeft="leftClick" color="#000000" backgroundColor="#fff" :statusBar="true" title="客户资料"></uni-nav-bar>
|
||||||
<view class="content">
|
<view class="content">
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view>客户称呼</view>
|
<view>渠道</view>
|
||||||
<view class="right">
|
<view class="right select" @click="showcartype = true">
|
||||||
<input placeholder="输入称呼" v-model="form.contacts" />
|
<input placeholder="选择渠道" disabled v-model="car_type_name" />
|
||||||
|
<u-picker :cancel-text="$t('cancel')" :confirm-text="$t('confirm')" :show="showcartype" @cancel="cancel('showcartype')" :columns="carTypeList" keyName="name" @confirm="cartypesChange"></u-picker>
|
||||||
|
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text=""></u-divider>
|
<view class="cell">
|
||||||
|
<view>客户名称</view>
|
||||||
|
<view class="right">
|
||||||
|
<input placeholder="输入客户名称" v-model="form.contacts" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<u-line></u-line>
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view>性别</view>
|
<view>性别</view>
|
||||||
<view class="right">
|
<view class="right">
|
||||||
@@ -18,21 +26,28 @@
|
|||||||
</u-radio-group>
|
</u-radio-group>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text=""></u-divider>
|
<u-line></u-line>
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view>联系方式 <text class="red">*</text></view>
|
<view>联系方式 <text class="red">*</text></view>
|
||||||
<view class="right">
|
<view class="right">
|
||||||
<input placeholder="输入联系方式" v-model="form.phone" />
|
<input placeholder="输入联系方式" v-model="form.phone" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text=""></u-divider>
|
<u-line></u-line>
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view>Email</view>
|
<view>Email</view>
|
||||||
<view class="right">
|
<view class="right">
|
||||||
<input placeholder="输入Email" v-model="form.email" />
|
<input placeholder="输入Email" v-model="form.email" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text=""></u-divider>
|
<u-line></u-line>
|
||||||
|
<view class="cell">
|
||||||
|
<view>WhatsApp</view>
|
||||||
|
<view class="right">
|
||||||
|
<input placeholder="输入WhatsApp" v-model="form.WhatsApp" />
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<u-line></u-line>
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view>客户偏好</view>
|
<view>客户偏好</view>
|
||||||
<view class="right select" @click="showcartype = true">
|
<view class="right select" @click="showcartype = true">
|
||||||
@@ -41,7 +56,7 @@
|
|||||||
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text=""></u-divider>
|
<u-line></u-line>
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view>客户等级</view>
|
<view>客户等级</view>
|
||||||
<view class="right select" @click="showgrade = true">
|
<view class="right select" @click="showgrade = true">
|
||||||
@@ -50,7 +65,16 @@
|
|||||||
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text=""></u-divider>
|
<u-line></u-line>
|
||||||
|
<view class="cell">
|
||||||
|
<view>国家</view>
|
||||||
|
<view class="right select" @click="showenergy = true">
|
||||||
|
<input placeholder="选择国家" disabled v-model="country_name" />
|
||||||
|
<u-picker :cancel-text="$t('cancel')" :confirm-text="$t('confirm')" :show="showenergy" @cancel="cancel('showenergy')" :columns="areaList" keyName="name" @confirm="areaChange"></u-picker>
|
||||||
|
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<u-line></u-line>
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view>公司</view>
|
<view>公司</view>
|
||||||
<view class="right select" @click="showenergy = true">
|
<view class="right select" @click="showenergy = true">
|
||||||
@@ -58,7 +82,7 @@
|
|||||||
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
<u-icon class="arrowright" name="arrow-right" size="18" color="#747474"></u-icon>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text=""></u-divider>
|
<u-line></u-line>
|
||||||
<view class="cell1">
|
<view class="cell1">
|
||||||
<view>备注(非必填)</view>
|
<view>备注(非必填)</view>
|
||||||
<view class="">
|
<view class="">
|
||||||
|
|||||||
+152
-89
@@ -5,56 +5,56 @@
|
|||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view>跟进方式</view>
|
<view>跟进方式</view>
|
||||||
<view class="right">
|
<view class="right">
|
||||||
<u-radio-group v-model="form.followType">
|
<u-radio-group v-model="form.type">
|
||||||
<u-radio name="1">在线跟进</u-radio>
|
<u-radio name="1">在线跟进</u-radio>
|
||||||
<u-radio name="2">拜访</u-radio>
|
<u-radio name="0">拜访</u-radio>
|
||||||
</u-radio-group>
|
</u-radio-group>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text=""></u-divider>
|
<u-line></u-line>
|
||||||
<view class="cell">
|
<view class="cell">
|
||||||
<view>跟进时间</view>
|
<view>跟进时间</view>
|
||||||
<view class="right" @click="show = true">
|
<view class="right" @click="show = true">
|
||||||
<input placeholder="跟进时间" v-model="form.firstFollow" />
|
<input placeholder="跟进时间" v-model="form.firstFollowtime" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text=""></u-divider>
|
<u-line></u-line>
|
||||||
<view class="cell1" v-if="form.followType==1">
|
<view class="cell1" v-if="form.type==1">
|
||||||
<view>上传跟进最后聊天截图</view>
|
<view>上传跟进最后聊天截图</view>
|
||||||
<view>
|
<view style="margin-top: 10px;">
|
||||||
<uni-file-picker fileMediatype="image" limit="1" :del-icon="false" disable-preview @select="select" @delete="delfn('front_45_degree')">
|
<uni-file-picker fileMediatype="image" limit="1" :del-icon="false" disable-preview @select="select" @delete="delfn('picture')">
|
||||||
<image src="/static/image/customer/upimg.png" mode="" class="addimg"></image>
|
<image src="/static/image/customer/upimg.png" mode="" class="addimg"></image>
|
||||||
</uni-file-picker>
|
</uni-file-picker>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="cell" v-if="form.followType==2">
|
<view class="cell" v-if="form.type==0">
|
||||||
<view>当前位置</view>
|
<view>当前位置</view>
|
||||||
<view class="right">
|
<view class="right">
|
||||||
<input placeholder="输入当前位置" v-model="form.phone" />
|
<input placeholder="输入当前位置" v-model="form.address" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text="" v-if="form.followType==2"></u-divider>
|
<u-line v-if="form.type==0"></u-line>
|
||||||
<view class="cell1" v-if="form.followType==2">
|
<view class="cell1" v-if="form.type==0">
|
||||||
<view>当前位置拍照上传</view>
|
<view>当前位置拍照上传</view>
|
||||||
<view style="margin-top: 10px;">
|
<view style="margin-top: 10px;">
|
||||||
<uni-file-picker fileMediatype="image" limit="1" :del-icon="false" disable-preview @select="select1" @delete="delfn('front_45_degree')">
|
<uni-file-picker fileMediatype="image" limit="1" :del-icon="false" disable-preview @select="select1" @delete="delfn('picture')">
|
||||||
<image src="/static/image/customer/upimg.png" mode="" class="addimg"></image>
|
<image src="/static/image/customer/upimg.png" mode="" class="addimg"></image>
|
||||||
</uni-file-picker>
|
</uni-file-picker>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text="" v-if="form.followType==2"></u-divider>
|
<u-line v-if="form.type==0"></u-line>
|
||||||
<view class="cell1" v-if="form.followType==2">
|
<view class="cell1" v-if="form.type==0">
|
||||||
<view>拜访内容</view>
|
<view>拜访内容</view>
|
||||||
<view class="yuyin">
|
<view class="yuyin">
|
||||||
<textarea auto-height v-model="form.bf_desc" placeholder="拜访内容..."/>
|
<textarea auto-height v-model="form.audio_text" placeholder="拜访内容..."/>
|
||||||
<image src="/static/image/customer/yuyin.png" mode="" @tap="startRecognizebd"></image>
|
<image src="/static/image/customer/yuyin.png" mode="" @tap="startRecognizebd"></image>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<u-divider text="" v-if="form.followType==2"></u-divider>
|
<u-line v-if="form.type==0"></u-line>
|
||||||
<view class="cell1" v-if="form.followType==2">
|
<view class="cell1" v-if="form.type==0">
|
||||||
<view>备注(非必填)</view>
|
<view>备注(非必填)</view>
|
||||||
<view class="yuyin">
|
<view class="yuyin">
|
||||||
<textarea auto-height v-model="form.mom_desc" placeholder="详细情况..."/>
|
<textarea auto-height v-model="form.remark" placeholder="详细情况..."/>
|
||||||
<image src="/static/image/customer/yuyin.png" mode="" @tap="startRecognize"></image>
|
<image src="/static/image/customer/yuyin.png" mode="" @tap="startRecognize"></image>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@@ -64,51 +64,37 @@
|
|||||||
<view class="title">
|
<view class="title">
|
||||||
跟进记录 <text class="status">跟进中</text>
|
跟进记录 <text class="status">跟进中</text>
|
||||||
</view>
|
</view>
|
||||||
<u-steps current="0" direction="column" dot>
|
<u-steps v-if="followList.length>0" :current="followList.length" direction="column" dot>
|
||||||
<u-steps-item title="在线跟进">
|
<u-steps-item :title="item.type_txt" v-for="(item, index) in followList" :key="index">
|
||||||
<view slot="desc">
|
|
||||||
<view class="">
|
|
||||||
时间:2025-03-11 12:00:01
|
|
||||||
</view>
|
|
||||||
<view class="">
|
|
||||||
<image src="/static/image/customer/addr.png" mode=""></image>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</u-steps-item>
|
|
||||||
<u-steps-item title="拜访跟进">
|
|
||||||
<view slot="desc" class="desc">
|
<view slot="desc" class="desc">
|
||||||
<view class="">
|
<view class="" v-if="item.type==0">
|
||||||
<view class="">
|
<view class="">
|
||||||
时间:2025-03-11 12:00:01
|
<view class="">
|
||||||
|
时间:{{item.created_at}}
|
||||||
|
</view>
|
||||||
|
<view class="">地址:{{item.address}}</view>
|
||||||
|
<view class="">拜访内容:{{item.audio_text}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="">地址:迪拜某某地方</view>
|
|
||||||
<view class="">拜访内容:讨论需求</view>
|
|
||||||
</view>
|
|
||||||
<view class="">
|
|
||||||
<image src="/static/image/customer/addr.png" mode=""></image>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</u-steps-item>
|
|
||||||
<u-steps-item title="拜访跟进">
|
|
||||||
<view slot="desc" class="desc">
|
|
||||||
<view class="">
|
|
||||||
<view class="">
|
<view class="">
|
||||||
时间:2025-03-11 12:00:01
|
<image :src="item.oss_picture" mode=""></image>
|
||||||
</view>
|
</view>
|
||||||
<view class="">地址:迪拜某某地方</view>
|
|
||||||
<view class="">拜访内容:讨论需求</view>
|
|
||||||
</view>
|
</view>
|
||||||
<view class="">
|
<view class="" v-else>
|
||||||
<image src="/static/image/customer/addr.png" mode=""></image>
|
<view class="">
|
||||||
|
时间:{{item.created_at}}
|
||||||
|
</view>
|
||||||
|
<view class="">
|
||||||
|
<image :src="item.oss_picture" mode=""></image>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</u-steps-item>
|
</u-steps-item>
|
||||||
</u-steps>
|
</u-steps>
|
||||||
<!-- <empty :list="brandList"></empty> -->
|
<empty :list="followList"></empty>
|
||||||
</view>
|
</view>
|
||||||
<u-gap height="100" bgColor="#fff"></u-gap>
|
<u-gap height="100" bgColor="#fff"></u-gap>
|
||||||
<view class="foot">
|
<view class="foot">
|
||||||
<button class="btn1" @click="nextFn">下次跟进提醒</button>
|
<button class="btn1" @click="shownexttime=true">下次跟进提醒</button>
|
||||||
<button class="btn" @click="nextFn">提交</button>
|
<button class="btn" @click="nextFn">提交</button>
|
||||||
</view>
|
</view>
|
||||||
<u-datetime-picker
|
<u-datetime-picker
|
||||||
@@ -119,6 +105,13 @@
|
|||||||
@cancel="cancel"
|
@cancel="cancel"
|
||||||
@change="change"
|
@change="change"
|
||||||
></u-datetime-picker>
|
></u-datetime-picker>
|
||||||
|
<u-datetime-picker
|
||||||
|
:show="shownexttime"
|
||||||
|
v-model="nexttime"
|
||||||
|
mode="datetime"
|
||||||
|
@confirm="confirmnext"
|
||||||
|
@cancel="cancelnext"
|
||||||
|
></u-datetime-picker>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
@@ -127,49 +120,99 @@
|
|||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
brandList:[],
|
id:'',
|
||||||
energyList:[],
|
|
||||||
typesList:[],
|
|
||||||
show:false,
|
show:false,
|
||||||
firstFollow: '2025-03-11 12:00:01',
|
shownexttime:false,
|
||||||
|
firstFollow: Number(new Date()),
|
||||||
|
nexttime: Number(new Date()),
|
||||||
|
followList:[],
|
||||||
form: {
|
form: {
|
||||||
name: '',
|
customer_id:'',
|
||||||
followType: '1',
|
type: '1',
|
||||||
phone: '',
|
address: '',
|
||||||
preference: '赵野军',
|
lat: '',
|
||||||
level: '初步接触',
|
lng: '',
|
||||||
region: '',
|
firstFollowtime:'',
|
||||||
firstFollow: '2025-03-11 12:00:01',
|
audio_text:'',
|
||||||
details: '',
|
remark:'',
|
||||||
bf_desc:'',
|
picture:''
|
||||||
mom_desc:'',
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad() {
|
onLoad(options) {
|
||||||
const { windowWidth, windowHeight } = uni.getSystemInfoSync();
|
console.log(options);
|
||||||
this.x = windowWidth-70
|
this.id = options.id;
|
||||||
this.y = windowHeight-185
|
this.form.customer_id = options.id;
|
||||||
|
var that = this
|
||||||
|
this.getlocahost()
|
||||||
|
this.followlistfn()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
|
||||||
leftClick(){
|
leftClick(){
|
||||||
uni.navigateBack({})
|
uni.navigateBack({})
|
||||||
},
|
},
|
||||||
|
// 获取当前位置
|
||||||
|
getlocahost(){
|
||||||
|
uni.getLocation({
|
||||||
|
type: 'wgs84', // 默认为 wgs84 坐标系,可选 gcj02
|
||||||
|
success: function (res) {
|
||||||
|
console.log('当前位置的经度:' + res.longitude);
|
||||||
|
console.log('当前位置的纬度:' + res.latitude);
|
||||||
|
// 如果需要将经纬度转换为具体地址,可以使用逆地理编码
|
||||||
|
// 这里调用 uni.chooseLocation 或第三方地图服务(如高德、腾讯地图)
|
||||||
|
},
|
||||||
|
fail: function (err) {
|
||||||
|
console.log('获取位置失败:', err);
|
||||||
|
},
|
||||||
|
complete: function () {
|
||||||
|
console.log('获取位置完成');
|
||||||
|
}
|
||||||
|
});
|
||||||
|
// uni.chooseLocation({
|
||||||
|
// success: function (res) {
|
||||||
|
// console.log('位置名称:' + res.name);
|
||||||
|
// console.log('详细地址:' + res.address);
|
||||||
|
// console.log('经度:' + res.longitude);
|
||||||
|
// console.log('纬度:' + res.latitude);
|
||||||
|
// },
|
||||||
|
// fail: function (err) {
|
||||||
|
// console.log('选择位置失败:', err);
|
||||||
|
// }
|
||||||
|
// });
|
||||||
|
},
|
||||||
|
// 跟进记录
|
||||||
|
followlistfn(){
|
||||||
|
request({
|
||||||
|
url:'follow/list',
|
||||||
|
method:'get',
|
||||||
|
data: {
|
||||||
|
customer_id:this.id,
|
||||||
|
}
|
||||||
|
}).then(res => {
|
||||||
|
this.followList = res.data.data.list
|
||||||
|
console.log(res.data.data)
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//保存跟进
|
||||||
nextFn(){
|
nextFn(){
|
||||||
|
request({
|
||||||
},
|
url:'follow/save',
|
||||||
cancel() {
|
method:'post',
|
||||||
this.show = false
|
data:this.form
|
||||||
},
|
}).then(res => {
|
||||||
confirm(e) {
|
uni.showToast({
|
||||||
this.show = false
|
title: res.data.message,
|
||||||
this.form.firstFollow = this.result(e.value, e.mode)
|
icon: 'none'
|
||||||
console.log(this.result(e.value, e.mode))
|
});
|
||||||
console.log(this.form.firstFollow )
|
if(res.data.code ==0){
|
||||||
},
|
// setTimeout(() => {
|
||||||
change(e) {
|
// uni.reLaunch({
|
||||||
// console.log('change', e)
|
// url: '/pages/index/index',// 替换为你要跳转的页面路径
|
||||||
|
// });
|
||||||
|
// }, 1000);
|
||||||
|
|
||||||
|
}
|
||||||
|
})
|
||||||
},
|
},
|
||||||
result(time, mode) {
|
result(time, mode) {
|
||||||
const timeFormat = uni.$u.timeFormat
|
const timeFormat = uni.$u.timeFormat
|
||||||
@@ -186,6 +229,26 @@
|
|||||||
return ''
|
return ''
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
cancel() {
|
||||||
|
this.show = false
|
||||||
|
},
|
||||||
|
confirm(e) {
|
||||||
|
this.show = false
|
||||||
|
this.form.firstFollowtime = this.result(e.value, e.mode)
|
||||||
|
console.log(this.result(e.value, e.mode))
|
||||||
|
},
|
||||||
|
cancelnext() {
|
||||||
|
this.shownexttime = false
|
||||||
|
},
|
||||||
|
confirmnext(e) {
|
||||||
|
this.shownexttime = false
|
||||||
|
this.nexttime = this.result(e.value, e.mode)
|
||||||
|
console.log(this.nexttime)
|
||||||
|
},
|
||||||
|
change(e) {
|
||||||
|
// console.log('change', e)
|
||||||
|
},
|
||||||
|
|
||||||
delfn(name){
|
delfn(name){
|
||||||
console.log(name)
|
console.log(name)
|
||||||
that.carinfo[name] =''
|
that.carinfo[name] =''
|
||||||
@@ -193,26 +256,26 @@
|
|||||||
uploadfn(imgUrl,name){
|
uploadfn(imgUrl,name){
|
||||||
var that = this;
|
var that = this;
|
||||||
uni.uploadFile({
|
uni.uploadFile({
|
||||||
url: 'https://api.collect.hs.hnzhwlkj.club/upload',
|
url: 'http://192.168.50.4:8787/upload',
|
||||||
filePath: imgUrl,
|
filePath: imgUrl,
|
||||||
name: 'image',
|
name: 'files',
|
||||||
header:{'content-type': 'application/x-www-form-urlencoded','Authorization': 'Bearer ' + uni.getStorageSync('token')},
|
header:{'content-type': 'application/x-www-form-urlencoded','Authorization': 'Bearer ' + uni.getStorageSync('token')},
|
||||||
success: (uploadFileRes) => {
|
success: (uploadFileRes) => {
|
||||||
const path=JSON.parse(uploadFileRes.data)
|
const path=JSON.parse(uploadFileRes.data)
|
||||||
that.carinfo[name] = path.data.image_name
|
that.form[name] = path.data.path
|
||||||
console.log(that.carinfo)
|
console.log(that.form)
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
select(e){
|
select(e){
|
||||||
const tempFilePaths = e.tempFilePaths;
|
const tempFilePaths = e.tempFilePaths;
|
||||||
const imgUrl=tempFilePaths[0]
|
const imgUrl=tempFilePaths[0]
|
||||||
this.uploadfn(imgUrl,'front_45_degree')
|
this.uploadfn(imgUrl,'picture')
|
||||||
},
|
},
|
||||||
select1(e){
|
select1(e){
|
||||||
const tempFilePaths = e.tempFilePaths;
|
const tempFilePaths = e.tempFilePaths;
|
||||||
const imgUrl=tempFilePaths[0]
|
const imgUrl=tempFilePaths[0]
|
||||||
this.uploadfn(imgUrl,'front_45_degree')
|
this.uploadfn(imgUrl,'picture')
|
||||||
},
|
},
|
||||||
async startRecognizebd () {
|
async startRecognizebd () {
|
||||||
// #ifdef APP-PLUS
|
// #ifdef APP-PLUS
|
||||||
|
|||||||
+50
-33
@@ -14,31 +14,33 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<z-paging ref="paging" v-model="datalist" @query="queryList" style="margin-top: 100px;" empty-view-text='暂无数据!'>
|
||||||
<view class="list">
|
<view class="list">
|
||||||
<view class="contents" v-for="(item, index) in datalist" :key="index" >
|
|
||||||
<view class="" @click="godetile(item)">
|
<view class="contents" v-for="(item, index) in datalist" :key="index" >
|
||||||
<view class="top">
|
<view class="" @click="godetile(item)">
|
||||||
<view class="">2025.03.11 12:00</view>
|
<view class="top">
|
||||||
<view class="tag">{{$t('followup')}}</view>
|
<view class="">{{item.created_at}}</view>
|
||||||
</view>
|
<view class="tag">{{$t('followup')}}</view>
|
||||||
<u-divider text="" :hairline="true"></u-divider>
|
|
||||||
<view class="cont">
|
|
||||||
<view class="title">
|
|
||||||
<view class=""><text class="name">刘德华</text><text class="phone">138****2264</text></view>
|
|
||||||
<view class="ststus">初步接触</view>
|
|
||||||
</view>
|
</view>
|
||||||
<view class="info"><text class="sex">男</text> | <text class="addr">迪拜</text><text class="type">越野车</text>
|
<u-line margin="20rpx 0px"></u-line>
|
||||||
|
<view class="cont">
|
||||||
|
<view class="title">
|
||||||
|
<view class=""><text class="name">{{item.contacts}}</text><text class="phone">{{item.phone}}</text></view>
|
||||||
|
<view class="ststus">{{item.grade_txt}}</view>
|
||||||
|
</view>
|
||||||
|
<view class="info"><text class="sex">男</text> | <text class="addr">迪拜</text><text class="type">越野车</text>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
<view class="desc1">
|
||||||
<view class="desc1">
|
<view class="" @click="callPhone(item)"><image src="/static/image/customer/phone.png" mode=""></image> {{$t('call')}}</view>
|
||||||
<view class="" @click="callPhone(item)"><image src="/static/image/customer/phone.png" mode=""></image> {{$t('call')}}</view>
|
<view class="" @click="editClick(item)"><image src="/static/image/customer/edit.png" mode=""></image> {{$t('followup')}}</view>
|
||||||
<view class="" @click="editClick(item)"><image src="/static/image/customer/edit.png" mode=""></image> {{$t('followup')}}</view>
|
<view class="" @click="delClick(item)"><image src="/static/image/customer/trash.png" mode=""></image> {{$t('delete')}}</view>
|
||||||
<view class="" @click="delClick(item)"><image src="/static/image/customer/trash.png" mode=""></image> {{$t('delete')}}</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</z-paging>
|
||||||
<u-picker :show="show" :columns="columns" @cancel="cancel" @confirm="confirm" title="客户筛选" keyName="label"></u-picker>
|
<u-picker :show="show" :columns="columns" @cancel="cancel" @confirm="confirm" title="客户筛选" keyName="label"></u-picker>
|
||||||
<u-popup :show="showts" :closeOnClickOverlay="false" :round="20" mode="center">
|
<u-popup :show="showts" :closeOnClickOverlay="false" :round="20" mode="center">
|
||||||
<view class="popupcontent">
|
<view class="popupcontent">
|
||||||
@@ -63,7 +65,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
// import { request,showToast } from '@/api/apiT.js'
|
import { request,showToast } from '@/api/apiT.js'
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@@ -84,35 +86,49 @@
|
|||||||
id: 3
|
id: 3
|
||||||
}]
|
}]
|
||||||
],
|
],
|
||||||
datalist:[
|
datalist:[],
|
||||||
{id:1,phone:'17839087603'},
|
|
||||||
{id:2,phone:'18437931136'},
|
|
||||||
{id:3,phone:'18339827479'},
|
|
||||||
{id:4,phone:'17839087603'}
|
|
||||||
],
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad() {
|
onLoad() {
|
||||||
const { windowWidth, windowHeight } = uni.getSystemInfoSync();
|
const { windowWidth, windowHeight } = uni.getSystemInfoSync();
|
||||||
this.x = windowWidth-70
|
this.x = windowWidth-70
|
||||||
this.y = windowHeight-25
|
this.y = windowHeight-55
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
searchCli(){
|
searchCli(){
|
||||||
|
|
||||||
},
|
},
|
||||||
close() {
|
close() {
|
||||||
// console.log('close');
|
|
||||||
this.show= false
|
this.show= false
|
||||||
},
|
},
|
||||||
confirm(e) {
|
confirm(e) {
|
||||||
// console.log('confirm', e);
|
|
||||||
this.show = false
|
this.show = false
|
||||||
},
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
// console.log('cancel');
|
|
||||||
this.show = false
|
this.show = false
|
||||||
},
|
},
|
||||||
|
//客户列表数据
|
||||||
|
queryList(pageNo, pageSize) {
|
||||||
|
var that = this;
|
||||||
|
request({
|
||||||
|
url:'customer/list',
|
||||||
|
method:'get',
|
||||||
|
data: {
|
||||||
|
page:pageNo,
|
||||||
|
per_page:10
|
||||||
|
}
|
||||||
|
}).then(res => {
|
||||||
|
console.log(res.data)
|
||||||
|
if(res.data.code ==0){
|
||||||
|
var datas = res.data.data.list;
|
||||||
|
this.$refs.paging.complete(datas);
|
||||||
|
}else{
|
||||||
|
// this.$refs.paging.complete(null);
|
||||||
|
// that.listlength=0
|
||||||
|
}
|
||||||
|
uni.stopPullDownRefresh();
|
||||||
|
})
|
||||||
|
},
|
||||||
godetile(item){
|
godetile(item){
|
||||||
console.log(item)
|
console.log(item)
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
@@ -142,7 +158,7 @@
|
|||||||
},
|
},
|
||||||
editClick(item){
|
editClick(item){
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/pages/customer/followup'
|
url: '/pages/customer/followup?id='+item.id
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
delClick(item){
|
delClick(item){
|
||||||
@@ -165,6 +181,7 @@
|
|||||||
background-image: url("/static/image/customer/bg.png");
|
background-image: url("/static/image/customer/bg.png");
|
||||||
background-size: 100%;
|
background-size: 100%;
|
||||||
background-repeat: no-repeat;
|
background-repeat: no-repeat;
|
||||||
|
height: calc(100vh - 50px);
|
||||||
}
|
}
|
||||||
.navbar{
|
.navbar{
|
||||||
height: 44px;
|
height: 44px;
|
||||||
@@ -211,7 +228,7 @@
|
|||||||
.list{
|
.list{
|
||||||
padding: 15px;
|
padding: 15px;
|
||||||
overflow: auto;
|
overflow: auto;
|
||||||
height: calc(100vh-140px);
|
// height: calc(100vh - 350rpx);
|
||||||
.contents{
|
.contents{
|
||||||
background-color: #FFFFFF;
|
background-color: #FFFFFF;
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
|
|||||||
+58
-29
@@ -1,5 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class="content">
|
<view class="content">
|
||||||
|
<z-paging ref="paging" v-model="datalist" @query="queryList" style="background: #F3F3F3;" empty-view-text='暂无数据!'>
|
||||||
<view class="contop">
|
<view class="contop">
|
||||||
<view class="changeyy" @click="showlang = true" >
|
<view class="changeyy" @click="showlang = true" >
|
||||||
<image src="/static/image/change.png" mode=""></image>{{$t('home.langbtn')}}
|
<image src="/static/image/change.png" mode=""></image>{{$t('home.langbtn')}}
|
||||||
@@ -21,11 +22,7 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="cont">
|
<view class="cont">
|
||||||
<u-grid :border="false" col="4">
|
<u-grid :border="false">
|
||||||
<u-grid-item>
|
|
||||||
<text class="grid-num">20</text>
|
|
||||||
<text class="grid-text">{{$t('home.addxs')}}</text>
|
|
||||||
</u-grid-item>
|
|
||||||
<u-grid-item>
|
<u-grid-item>
|
||||||
<text class="grid-num">20</text>
|
<text class="grid-num">20</text>
|
||||||
<text class="grid-text">{{$t('home.addkh')}}</text>
|
<text class="grid-text">{{$t('home.addkh')}}</text>
|
||||||
@@ -41,35 +38,36 @@
|
|||||||
</u-grid>
|
</u-grid>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="userlist">
|
<view class="userlist">
|
||||||
<u-sticky offset-top="-44">
|
<u-sticky offset-top="-44" >
|
||||||
<u-tabs :list="list1" :scrollable="false"></u-tabs>
|
<view class="tabsbg">
|
||||||
|
<u-tabs :list="list1" :scrollable="false"></u-tabs>
|
||||||
|
</view>
|
||||||
</u-sticky>
|
</u-sticky>
|
||||||
<view class="list">
|
<view class="list">
|
||||||
<userlist :list="datalist" @click="godetile">
|
<userlist :list="datalist" @click="godetile">
|
||||||
<template v-slot:footer>
|
</userlist>
|
||||||
<view class="desc">客户想要性价比高,偏爱宝马</view>
|
</view>
|
||||||
</template>
|
|
||||||
<template v-slot:footertab>
|
|
||||||
<view></view>
|
|
||||||
</template>
|
|
||||||
</userlist>
|
|
||||||
</view>
|
|
||||||
</view>
|
</view>
|
||||||
|
</z-paging>
|
||||||
<u-datetime-picker :cancel-text="$t('cancel')" :confirm-text="$t('confirm')" :show="show" v-model="value1" @confirm="confirm" @cancel="cancel" mode="year-month"></u-datetime-picker>
|
<u-datetime-picker :cancel-text="$t('cancel')" :confirm-text="$t('confirm')" :show="show" v-model="value1" @confirm="confirm" @cancel="cancel" mode="year-month"></u-datetime-picker>
|
||||||
<u-picker :cancel-text="$t('cancel')" :confirm-text="$t('confirm')" :show="showlang" :columns="columns" @cancel="cancellang" @confirm="confirmlang" :title="$t('home.langbtn')" keyName="label"></u-picker>
|
<u-picker :cancel-text="$t('cancel')" :confirm-text="$t('confirm')" :show="showlang" :columns="columns" @cancel="cancellang" @confirm="confirmlang" :title="$t('home.langbtn')" keyName="label"></u-picker>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import { request,showToast } from '@/api/apiT.js'
|
||||||
import userlist from '@/components/userlist/index.vue';
|
import userlist from '@/components/userlist/index.vue';
|
||||||
// import { request,showToast } from '@/api/apiT.js'
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
userlist
|
userlist
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
headerBgColor: 'transparent', // 初始背景色为透明
|
||||||
home: this.$t('tabbar.home'),
|
home: this.$t('tabbar.home'),
|
||||||
value0: 0,
|
value0: 0,
|
||||||
show: false,
|
show: false,
|
||||||
@@ -77,12 +75,7 @@
|
|||||||
value1: Number(new Date()),
|
value1: Number(new Date()),
|
||||||
timevalue:this.result(Number(new Date())),
|
timevalue:this.result(Number(new Date())),
|
||||||
time:this.result(Number(new Date())),
|
time:this.result(Number(new Date())),
|
||||||
datalist:[
|
datalist:[],
|
||||||
{id:1},
|
|
||||||
{id:2},
|
|
||||||
{id:3},
|
|
||||||
{id:4}
|
|
||||||
],
|
|
||||||
columns:[
|
columns:[
|
||||||
[{
|
[{
|
||||||
label: '中文',
|
label: '中文',
|
||||||
@@ -109,16 +102,22 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad() {
|
onLoad() {
|
||||||
|
// this.getcustomerlist()
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
confirm(e) {
|
// 处理滚动事件
|
||||||
// console.log('confirm', e);
|
onPageScroll(event) {
|
||||||
this.show = false
|
const scrollTop = event.scrollTop || 0;
|
||||||
|
if (scrollTop > 310) { // 吸顶条件
|
||||||
|
this.headerBgColor = '#E6EDFF'; // 吸顶时设置背景色
|
||||||
|
} else {
|
||||||
|
this.headerBgColor = 'transparent'; // 取消吸顶时恢复背景色
|
||||||
|
}
|
||||||
},
|
},
|
||||||
cancellang() {
|
cancellang() {
|
||||||
// console.log('cancel');
|
|
||||||
this.showlang = false
|
this.showlang = false
|
||||||
},
|
},
|
||||||
|
//语言切换事件
|
||||||
confirmlang(e) {
|
confirmlang(e) {
|
||||||
this.$i18n.locale = e.value[0].id
|
this.$i18n.locale = e.value[0].id
|
||||||
this.showlang = false
|
this.showlang = false
|
||||||
@@ -146,6 +145,10 @@
|
|||||||
text: this.$t('tabbar.mine')
|
text: this.$t('tabbar.mine')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
//日期选择组件
|
||||||
|
confirm(e) {
|
||||||
|
this.show = false
|
||||||
|
},
|
||||||
cancel() {
|
cancel() {
|
||||||
this.show = false
|
this.show = false
|
||||||
},
|
},
|
||||||
@@ -159,6 +162,28 @@
|
|||||||
this.time=timeFormat(time, 'yyyy-mm')
|
this.time=timeFormat(time, 'yyyy-mm')
|
||||||
return timeFormat(time, 'yyyy-mm')
|
return timeFormat(time, 'yyyy-mm')
|
||||||
},
|
},
|
||||||
|
//客户列表数据
|
||||||
|
queryList(pageNo, pageSize) {
|
||||||
|
var that = this;
|
||||||
|
request({
|
||||||
|
url:'customer/list',
|
||||||
|
method:'get',
|
||||||
|
data: {
|
||||||
|
page:pageNo,
|
||||||
|
per_page:10
|
||||||
|
}
|
||||||
|
}).then(res => {
|
||||||
|
console.log(res.data)
|
||||||
|
if(res.data.code ==0){
|
||||||
|
var datas = res.data.data.list;
|
||||||
|
this.$refs.paging.complete(datas);
|
||||||
|
}else{
|
||||||
|
// this.$refs.paging.complete(null);
|
||||||
|
// that.listlength=0
|
||||||
|
}
|
||||||
|
uni.stopPullDownRefresh();
|
||||||
|
})
|
||||||
|
},
|
||||||
godetile(item){
|
godetile(item){
|
||||||
console.log(item)
|
console.log(item)
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
@@ -174,6 +199,10 @@
|
|||||||
width: 18px;
|
width: 18px;
|
||||||
height: 18px;
|
height: 18px;
|
||||||
}
|
}
|
||||||
|
.tabsbg{
|
||||||
|
border-radius: 16px 16px 0px 0px;
|
||||||
|
background:linear-gradient(to bottom, #E6EDFF, #eaeffa);
|
||||||
|
}
|
||||||
.changeyy{
|
.changeyy{
|
||||||
padding: 10px 15px;
|
padding: 10px 15px;
|
||||||
border-radius: 50px;
|
border-radius: 50px;
|
||||||
@@ -250,7 +279,7 @@
|
|||||||
}
|
}
|
||||||
.grid-text{
|
.grid-text{
|
||||||
color: #222222;
|
color: #222222;
|
||||||
font-size: 20rpx;
|
font-size: 24rpx;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
+12
-5
@@ -8,12 +8,13 @@
|
|||||||
<view class="inputs_button">
|
<view class="inputs_button">
|
||||||
<view class="inputs">
|
<view class="inputs">
|
||||||
<view class="account">
|
<view class="account">
|
||||||
<input type="number" v-model="email" :adjust-position="false" placeholder="手机号" />
|
<input type="text" v-model="email" placeholder="账号" />
|
||||||
</view>
|
</view>
|
||||||
<view class="password">
|
<view class="password">
|
||||||
<u--input
|
<u--input
|
||||||
type="password"
|
type="password"
|
||||||
placeholder="请输入内容"
|
placeholder="密码"
|
||||||
|
v-model="password"
|
||||||
border="none"
|
border="none"
|
||||||
></u--input>
|
></u--input>
|
||||||
</view>
|
</view>
|
||||||
@@ -46,6 +47,7 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="pact">
|
<view class="pact">
|
||||||
<radio :checked="pactChecked" activeBackgroundColor="#3264ed" activeBorderColor="#3264ed"
|
<radio :checked="pactChecked" activeBackgroundColor="#3264ed" activeBorderColor="#3264ed"
|
||||||
|
borderColor="#3264ed" color="#fff" @click="pactChange" />
|
||||||
<view>我已经阅读并同意<text @click="toPact">《用户协议》</text>和<text @click="toPact">《隐私协议》</text></view>
|
<view>我已经阅读并同意<text @click="toPact">《用户协议》</text>和<text @click="toPact">《隐私协议》</text></view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@@ -58,8 +60,8 @@
|
|||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
email: "",
|
email: "1696136552@qq.com",
|
||||||
password: "",
|
password: "123456",
|
||||||
pactChecked: false,
|
pactChecked: false,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@@ -67,6 +69,9 @@
|
|||||||
|
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
pactChange() {
|
||||||
|
this.pactChecked = !this.pactChecked
|
||||||
|
},
|
||||||
login() {
|
login() {
|
||||||
if(this.email==''){
|
if(this.email==''){
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
@@ -102,9 +107,11 @@
|
|||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: res.data.msg,
|
title: res.data.msg,
|
||||||
icon: 'none'
|
icon: 'none'
|
||||||
});
|
});token
|
||||||
|
|
||||||
} else if (res.data.code == 0) {
|
} else if (res.data.code == 0) {
|
||||||
|
//存取session
|
||||||
|
uni.setStorageSync('token', res.data.data.token);
|
||||||
//返回数据接收成功
|
//返回数据接收成功
|
||||||
uni.reLaunch({
|
uni.reLaunch({
|
||||||
url: '/pages/index/index',// 替换为你要跳转的页面路径
|
url: '/pages/index/index',// 替换为你要跳转的页面路径
|
||||||
|
|||||||
Reference in New Issue
Block a user