页面功能修改
This commit is contained in:
+94
-43
@@ -3,7 +3,9 @@
|
||||
<z-paging ref="paging" v-model="datalist" @query="queryList" empty-view-text='暂无数据!'>
|
||||
<template #top>
|
||||
<view class="top">
|
||||
<view class="navbar">{{$t('customer.title')}}</view>
|
||||
<!-- <view class="navbar">{{$t('customer.title')}}</view> -->
|
||||
<uni-nav-bar leftText=" " :fixed="true" :border="false" @clickLeft="leftClick" color="#fff" backgroundColor="#3471ff" :statusBar="true" :title="$t('customer.title')"></uni-nav-bar>
|
||||
|
||||
<view class="topSearch">
|
||||
<view class="left">
|
||||
<u-search v-model="keyword" bgColor="#fff" search-icon=" " :show-action="false" :placeholder="$t('customer.inputhd')"></u-search>
|
||||
@@ -16,37 +18,43 @@
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="tabsbg">
|
||||
<u-tabs :list="list1" lineColor="#fff" :scrollable="false" @click="tabclick" :inactiveStyle="{color: '#fff'}" :activeStyle="{color: '#fff',fontWeight: 'bold',transform: 'scale(1.05)'}"></u-tabs>
|
||||
</view>
|
||||
</template>
|
||||
<view class="list">
|
||||
|
||||
<view class="contents" v-for="(item, index) in datalist" :key="index" >
|
||||
<view class="" @click="godetile(item)">
|
||||
<view class="top">
|
||||
<view class="">{{item.created_at}}</view>
|
||||
<view class="right">
|
||||
<text class="medal" :style="{color:(item.magnitude == 0 ?'#F5AB00' : item.magnitude == 1 ?'#8495B8': '#9B7200')}">{{item.magnitude_txt}}</text>
|
||||
<text class="tag" :style="{background:(item.follow == 0 ?'#3471FF' : item.follow == 1 ?'#27C89C': '#FF4040')}">{{item.follow_txt}}</text>
|
||||
<u-swipe-action>
|
||||
<u-swipe-action-item :options="options1" v-for="(item, index) in datalist" :key="index" @click="delClick(item)">
|
||||
<view class="contents" >
|
||||
<view class="" @click="godetile(item)">
|
||||
<view class="top">
|
||||
<view class="">{{item.created_at}}</view>
|
||||
<view class="right">
|
||||
<text class="medal" :style="{color:(item.magnitude == 0 ?'#F5AB00' : item.magnitude == 1 ?'#8495B8': '#9B7200')}">{{item.magnitude_txt}}</text>
|
||||
<text class="tag" :style="{background:(item.follow == 0 ?'#3471FF' : item.follow == 1 ?'#27C89C': '#FF4040')}">{{item.follow_txt}}</text>
|
||||
</view>
|
||||
</view>
|
||||
<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">{{item.sex_txt}}</text> | <text class="addr">{{item.country_name}}</text><text class="type">{{item.car_type_name}}</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="desc1">
|
||||
<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('customer.addfollow')}}</view>
|
||||
<!-- <view class="" @click="delClick(item)"><image src="/static/image/customer/trash.png" mode=""></image> {{$t('delete')}}</view> -->
|
||||
</view>
|
||||
</view>
|
||||
<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">{{item.sex_txt}}</text> | <text class="addr">{{item.country_name}}</text><text class="type">{{item.car_type_name}}</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="desc1">
|
||||
<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="delClick(item)"><image src="/static/image/customer/trash.png" mode=""></image> {{$t('delete')}}</view>
|
||||
</view>
|
||||
</view>
|
||||
</u-swipe-action-item>
|
||||
</u-swipe-action>
|
||||
</view>
|
||||
</z-paging>
|
||||
<u-picker :cancel-text="$t('cancel')" :confirm-text="$t('confirm')" :show="show" :columns="columns" @cancel="cancel" @confirm="confirm" :title="$t('customer.CustomerScreening')" keyName="label"></u-picker>
|
||||
<u-picker closeOnClickOverlay :cancel-text="$t('cancel')" :confirm-text="$t('confirm')" :show="show" :columns="columns" @cancel="cancel" @close="cancel" @confirm="confirm" :title="$t('customer.CustomerScreening')" keyName="label"></u-picker>
|
||||
<u-popup :show="showts" :closeOnClickOverlay="false" :round="20" mode="center">
|
||||
<view class="popupcontent">
|
||||
<view class="title">{{$t('prompt')}}</view>
|
||||
@@ -74,28 +82,17 @@
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
options1: [],
|
||||
x: 300, //x坐标
|
||||
y: 550, //y坐标
|
||||
keyword:'',
|
||||
follow_last:'',
|
||||
follow:'',
|
||||
show:false,
|
||||
showts:false,
|
||||
del_id:'',
|
||||
columns:[
|
||||
[{
|
||||
label: this.$t('all'),
|
||||
id:''
|
||||
},{
|
||||
label:this.$t('tday'),
|
||||
id: 0
|
||||
}, {
|
||||
label: this.$t('threeday'),
|
||||
id: 1
|
||||
}, {
|
||||
label: this.$t('sevenday'),
|
||||
id: 2
|
||||
}]
|
||||
],
|
||||
columns:[],
|
||||
list1: [],
|
||||
datalist:[],
|
||||
}
|
||||
},
|
||||
@@ -105,6 +102,42 @@
|
||||
this.y = windowHeight-55
|
||||
uni.removeStorageSync('location')
|
||||
},
|
||||
onShow() {
|
||||
this.options1=[{
|
||||
text: this.$t('delete'),
|
||||
style: {
|
||||
backgroundColor: '#f56c6c'
|
||||
}
|
||||
}]
|
||||
this.list1=[{
|
||||
name: this.$t('all'),
|
||||
id:'all'
|
||||
}, {
|
||||
name: this.$t('followup'),
|
||||
id:'followup'
|
||||
}, {
|
||||
name: this.$t('deal'),
|
||||
id:'deal'
|
||||
}, {
|
||||
name: this.$t('lost'),
|
||||
id:'lost'
|
||||
}]
|
||||
this.columns=[
|
||||
[{
|
||||
label: this.$t('all'),
|
||||
id:''
|
||||
},{
|
||||
label:this.$t('tday'),
|
||||
id: 0
|
||||
}, {
|
||||
label: this.$t('threeday'),
|
||||
id: 1
|
||||
}, {
|
||||
label: this.$t('sevenday'),
|
||||
id: 2
|
||||
}]
|
||||
]
|
||||
},
|
||||
methods: {
|
||||
searchCli(){
|
||||
this.queryList(1, 10)
|
||||
@@ -121,6 +154,16 @@
|
||||
cancel() {
|
||||
this.show = false
|
||||
},
|
||||
//tab标签切换
|
||||
tabclick(e){
|
||||
console.log(e)
|
||||
if(e.id=='all'){
|
||||
this.follow=''
|
||||
}else{
|
||||
this.follow=e.index - 1
|
||||
}
|
||||
this.queryList(1, 10)
|
||||
},
|
||||
//客户列表数据
|
||||
queryList(pageNo, pageSize) {
|
||||
var that = this;
|
||||
@@ -128,6 +171,7 @@
|
||||
url:'customer/list',
|
||||
method:'get',
|
||||
data: {
|
||||
follow:this.follow,
|
||||
page:pageNo,
|
||||
per_page:10,
|
||||
keyword:this.keyword,
|
||||
@@ -216,6 +260,10 @@
|
||||
uni-page-body {
|
||||
background-color: #F6F6F6 !important;
|
||||
}
|
||||
.u-swipe-action-item {
|
||||
margin-bottom: 10px;
|
||||
border-radius: 10px;
|
||||
}
|
||||
.conts{
|
||||
background-image: url("/static/image/customer/bg.png");
|
||||
background-size: 100%;
|
||||
@@ -224,7 +272,7 @@
|
||||
}
|
||||
.navbar{
|
||||
/* #ifdef APP-PLUS */
|
||||
padding-top: 44px;
|
||||
// padding-top: 20px;
|
||||
/* #endif */
|
||||
height: 44px;
|
||||
line-height: 44px;
|
||||
@@ -257,7 +305,10 @@
|
||||
padding: 6px 16px 2px;
|
||||
text-align: center;
|
||||
position: absolute;
|
||||
top: 3px;
|
||||
/* #ifdef APP-PLUS */
|
||||
top: 3px;
|
||||
/* #endif */
|
||||
top: 2px;
|
||||
right: 5px;
|
||||
font-size: 12px;
|
||||
image{
|
||||
|
||||
Reference in New Issue
Block a user