细节调整

This commit is contained in:
老叶
2021-07-20 17:13:48 +08:00
parent 75208f4892
commit 5744f83400
15 changed files with 130 additions and 79 deletions
+62 -8
View File
@@ -1,5 +1,4 @@
import _ from '../../../commons/js/commons'
import popularData from '../../../commons/js/lib/popularData';
const app = getApp()
Page({
data: {
@@ -20,6 +19,9 @@ Page({
v_id:'',//车型级别id
cfrom:'',//客户来源
o_type:'',//排序类型
cid:[],//客户id
clerkid:'',//店员id
isShowEmployees: false,
},
onLoad(options) {
for (let key in options) {
@@ -28,6 +30,7 @@ Page({
})
}
this.getAppCustomersList()
this.getAppEmployees()
},
onShow(){
@@ -105,14 +108,65 @@ Page({
})
},
//选择客户
radioPicker(e){
if(e.currentTarget.dataset.index != this.data.customerIndex){
this.setData({
isSubmiting: false,
customerIndex:e.currentTarget.dataset.index,
})
//选择订单
checkboxChange(e) {
const list = this.data.list
const values = e.detail.value
for (let i = 0, lenI = list.length; i < lenI; ++i) {
list[i].checked = false
for (let j = 0, lenJ = values.length; j < lenJ; ++j) {
if (list[i].id === values[j]) {
list[i].checked = true
break
}
}
}
this.setData({
list:list,
cid:e.detail.value,
})
},
//获取店员列表
getAppEmployees(){
let params = {};
params['page'] = 1;
params['size'] = 20000;
_.apiQuery.getAppEmployees(params).then(res => {
if(res.data.total>0){
let employeeArray = []
res.data.list.forEach(item => {
employeeArray.push(item.uname)
})
this.setData({
employeeArray:employeeArray,
employeeList:res.data.list,
employeeIndex:-1,
})
}
wx.stopPullDownRefresh()
});
},
//选择店员
changeEmployee(e) {
let clerkid = ''
if(e.detail.value >= 0){
clerkid = this.data.employeeList[e.detail.value].id
}
this.setData({
clerkid:clerkid,
employeeIndex:e.detail.value,
})
},
//销售弹窗显示隐藏
optEmployees(){
this.setData({
isShowEmployees:!this.data.isShowEmployees,
})
},
//推送链接
+28 -14
View File
@@ -2,29 +2,43 @@
<view class="mt10 pl30 pr30">
<block wx:for='{{list}}' wx:key='index'>
<view class="inner40 relative ulib-r10 box-shadow-000-10-10 mb30 overflowhidden" bindtap="radioPicker" data-index="{{index}}">
<view class="relative pr180">
<view class="font-32">{{item.name}}</view>
<view class="mt10 font-22 color-666">{{item.mobile}}</view>
</view>
<i class="absolute right-0 box-middle mr30 iconfont {{customerIndex == index?'icon-danxuan_xuanzhong color-36afa2':'icon-danxuan color-999'}}"></i>
</view>
</block>
<checkbox-group bindchange="checkboxChange">
<block wx:for='{{list}}' wx:key='index' wx:key="{{item.id}}">
<label class="block inner40 relative ulib-r10 box-shadow-000-10-10 mb30 overflowhidden">
<view class="relative pr180">
<view class="font-32">{{item.name}}</view>
<view class="mt10 font-22 color-666">{{item.mobile}}</view>
</view>
<checkbox class="absolute right-0 box-middle mr30 font-30" value="{{item.id}}" checked="{{item.checked}}"/>
</label>
</block>
</checkbox-group>
<lcb-listmore isLoading='{{loading}}' isEnd='{{end}}' isNoData='{{noData}}'></lcb-listmore>
</view>
<view>
<view class="height-100"></view>
<view class="fixed left-0 right-0 bottom-0 pt30 pb30 pl100 pr100 bg-fff-op80">
<button class="wp100 btn-36afa2 pt10 pb10 text-center font-32 color-fff ulib-r750" hover-class="btn-36afa2-hover" disabled="{{cid.length==0}}" bindtap="optEmployees">分配给销售</button>
</view>
</view>
</view>
<lcb-footer></lcb-footer>
<lcb-msg isShow="{{isShowMessage}}">
<lcb-msg isShow="{{isShowEmployees}}">
<view slot="content">
<view class="inner40">
<textarea class="wp100 inner20 bds-1-eb font-28 ulib-r10" placeholder-class="color-ccc" maxlength='100' placeholder="请输入短信内容" bindinput='inputTx' data-key="content" name='content' value='{{content}}' />
<view class="pb30 text-center font-36">销售选择</view>
<picker class="relative bg-f6 pt20 pb20 pl30 pr30 font-32 ulib-r10" bindchange="changeEmployee" value="{{employeeIndex}}" range="{{employeeArray}}">
<text class="color-ccc" wx:if="{{employeeIndex == -1}}">请选择</text>
<text wx:else>{{employeeArray[employeeIndex]}}</text>
<i class="absolute right-0 box-middle iconfont mr30 color-999 icon-xiala"></i>
</picker>
</view>
<view class="fn-flex bts-1-eb text-center font-32 color-666">
<view class="fn-flex-item pt25 pb25" bindtap="hideMessage">取消</view>
<view class="fn-flex-item bls-1-eb pt25 pb25 color-36afa2" disabled="{{!submitFlag}}" bindtap="postAppSmsCustomer">确定</view>
<view class="fn-flex pl60 pr60 pb50 text-center font-32 color-666">
<button bindtap="optEmployees" class="fn-flex-item mr20 bds-2-36afa2 btn-no-bg wp100 font-28 color-36afa2 ulib-r750" hover-class="btn-36afa2-hover">取消</button>
<button disabled="{{!submitFlag}}" bindtap="postAppSmsCustomer" class="fn-flex-item ml20 btn-36afa2 wp100 font-28 color-fff ulib-r750" hover-class="btn-36afa2-hover">确定</button>
</view>
</view>
</lcb-msg>
-28
View File
@@ -1,28 +0,0 @@
.mobiletip{position:fixed;bottom:120rpx;right:40rpx;width:100rpx;height:100rpx;}
.tabmenu2{display:inline-block;line-height:72rpx;}
.tabmenu2.active view.relative{display:inline-block;}
.tabmenu2.active view.relative::before{display:inline-block;position:absolute;bottom:0;left:50%;transform:translate(-50%,0);width:64rpx;height:4rpx;content:"";background-color:#36afa2;}
.subtab{height:100rpx;}
.opt-item{border:#ebebeb 1rpx solid;line-height:40rpx;}
.opt-item.active{background-color:#36afa2;border:#36afa2 1rpx solid;}
.fixedopt{position:fixed;bottom:120rpx;right:40rpx;}
.optpin{width:100rpx;height:100rpx;}
.search-sort{right:-650rpx;width:650rpx;}
.search-sort.sortin{animation:sortin.5s;animation-fill-mode:forwards;}
.search-sort.sortout{animation:sortout.5s;animation-fill-mode:forwards;}
@keyframes sortin
{
from {right:-650rpx;}
to {right:0;}
}
@keyframes sortout
{
from {right:0;}
to {right:-650rpx;}
}
.radio-btn{min-width:104rpx;box-sizing:border-box;text-align:center;}
+3 -3
View File
@@ -103,9 +103,9 @@
<view class="inner40">
<textarea class="wp100 inner20 bds-1-eb font-28 ulib-r10" placeholder-class="color-ccc" maxlength='100' placeholder="请输入短信内容" bindinput='inputTx' data-key="content" name='content' value='{{content}}' />
</view>
<view class="fn-flex bts-1-eb text-center font-32 color-666">
<view class="fn-flex-item pt25 pb25" bindtap="hideMessage">取消</view>
<view class="fn-flex-item bls-1-eb pt25 pb25 color-36afa2" disabled="{{!submitFlag}}" bindtap="postAppSmsCustomer">确定</view>
<view class="fn-flex pl60 pr60 pb50 text-center font-32 color-666">
<button bindtap="hideMessage" class="fn-flex-item mr20 bds-2-36afa2 btn-no-bg wp100 font-28 color-36afa2 ulib-r750" hover-class="btn-36afa2-hover">取消</button>
<button disabled="{{submitFlag}}" bindtap="postAppSmsCustomer" class="fn-flex-item ml20 btn-36afa2 wp100 font-28 color-fff ulib-r750" hover-class="btn-36afa2-hover">确定</button>
</view>
</view>
</lcb-msg>
+3 -3
View File
@@ -48,9 +48,9 @@
<view class="inner40">
<textarea class="wp100 inner20 bds-1-eb font-28 ulib-r10" placeholder-class="color-ccc" maxlength='100' placeholder="请输入短信内容" bindinput='inputTx' data-key="content" name='content' value='{{content}}' />
</view>
<view class="fn-flex bts-1-eb text-center font-32 color-666">
<view class="fn-flex-item pt25 pb25" bindtap="hideMessage">取消</view>
<view class="fn-flex-item bls-1-eb pt25 pb25 color-36afa2" disabled="{{!submitFlag}}" bindtap="postAppSmsCustomer">确定</view>
<view class="fn-flex pl60 pr60 pb50 text-center font-32 color-666">
<button bindtap="hideMessage" class="fn-flex-item mr20 bds-2-36afa2 btn-no-bg wp100 font-28 color-36afa2 ulib-r750" hover-class="btn-36afa2-hover">取消</button>
<button disabled="{{submitFlag}}" bindtap="postAppSmsCustomer" class="fn-flex-item ml20 btn-36afa2 wp100 font-28 color-fff ulib-r750" hover-class="btn-36afa2-hover">确定</button>
</view>
</view>
</lcb-msg>
+2 -1
View File
@@ -393,10 +393,11 @@ Page({
},
//显示高级搜索
showfilter(){
optfilter(){
this.setData({
isShowfilter: !this.data.isShowfilter
})
this.resetFilter()
},
//确定高级搜索
+6 -6
View File
@@ -10,7 +10,7 @@
</view>
</block>
</view>
<scroll-view class="mt5 font-28 color-666 text-center space-nowrap" scroll-x="true" wx:else>
<scroll-view class="mt5 font-32 color-666 text-center space-nowrap" scroll-x="true" wx:else>
<block wx:for='{{tab}}' wx:key='list'>
<view class="pl20 pr20 tabmenu2 {{key == item.key?'active color-36afa2':''}}" data-index="{{index}}" bindtap="changeTab" >
<view class="relative">{{item.name}}</view>
@@ -29,7 +29,7 @@
</picker>
</view>
<view class="fn-fr pr180 relative">
<text bindtap="showfilter" class="inner5 iconfont icon-gaojisousuo ml10"></text>
<text bindtap="optfilter" class="inner5 iconfont icon-gaojisousuo ml10"></text>
<view bindtap="pushLink" data-url="/pages/customer/addCard/index" class="absolute right-0 box-middle pt5 pb5 pl10 pr30 space-nowrap bg-333 font-22 color-fff ulib-rl750"><i class="iconfont mr5 icon-jia"></i>客户建卡</view>
</view>
</view>
@@ -82,9 +82,9 @@
<view class="inner40">
<textarea class="wp100 inner20 bds-1-eb font-28 ulib-r10" placeholder-class="color-ccc" maxlength='100' placeholder="请输入短信内容" bindinput='inputTx' data-key="content" name='content' value='{{content}}' />
</view>
<view class="fn-flex bts-1-eb text-center font-32 color-666">
<view class="fn-flex-item pt25 pb25" bindtap="hideMessage">取消</view>
<view class="fn-flex-item bls-1-eb pt25 pb25 color-36afa2" disabled="{{!submitFlag}}" bindtap="postAppSmsCustomer">确定</view>
<view class="fn-flex pl60 pr60 pb50 text-center font-32 color-666">
<button bindtap="hideMessage" class="fn-flex-item mr20 bds-2-36afa2 btn-no-bg wp100 font-28 color-36afa2 ulib-r750" hover-class="btn-36afa2-hover">取消</button>
<button disabled="{{submitFlag}}" bindtap="postAppSmsCustomer" class="fn-flex-item ml20 btn-36afa2 wp100 font-28 color-fff ulib-r750" hover-class="btn-36afa2-hover">确定</button>
</view>
</view>
</lcb-msg>
@@ -181,4 +181,4 @@
</view>
</view>
<view class="search-bg fixed left-0 right-0 top-0 bottom-0" hidden="{{!isShowfilter}}" style="background-color:rgba(0,0,0,.5);"></view>
<view class="search-bg fixed left-0 right-0 top-0 bottom-0" bindtap="optfilter" hidden="{{!isShowfilter}}" style="background-color:rgba(0,0,0,.5);"></view>
+1 -1
View File
@@ -2,7 +2,7 @@
.tabmenu2{display:inline-block;line-height:72rpx;}
.tabmenu2.active view.relative{display:inline-block;}
.tabmenu2.active view.relative::before{display:inline-block;position:absolute;bottom:0;left:50%;transform:translate(-50%,0);width:64rpx;height:4rpx;content:"";background-color:#36afa2;}
.tabmenu2.active view.relative::before{display:inline-block;position:absolute;bottom:0;left:50%;transform:translate(-50%,0);width:64rpx;height:6rpx;content:"";background-color:#36afa2;}
.subtab{height:100rpx;}
.opt-item{border:#ebebeb 1rpx solid;line-height:40rpx;}
+1 -1
View File
@@ -20,7 +20,7 @@ Page({
this.getAppEmployees()
},
//获取客户列表
//获取店员列表
getAppEmployees() {
this.setData({
load: false,
+3 -3
View File
@@ -180,9 +180,9 @@
<view class="inner40">
<textarea class="wp100 inner20 bds-1-eb font-28 ulib-r10" placeholder-class="color-ccc" maxlength='100' placeholder="请输入短信内容" bindinput='inputTx' data-key="content" name='content' value='{{content}}' />
</view>
<view class="fn-flex bts-1-eb text-center font-32 color-666">
<view class="fn-flex-item pt25 pb25" bindtap="hideMessage">取消</view>
<view class="fn-flex-item bls-1-eb pt25 pb25 color-36afa2" disabled="{{!submitFlag}}" bindtap="postAppSmsCusorder">确定</view>
<view class="fn-flex pl60 pr60 pb50 text-center font-32 color-666">
<button bindtap="hideMessage" class="fn-flex-item mr20 bds-2-36afa2 btn-no-bg wp100 font-28 color-36afa2 ulib-r750" hover-class="btn-36afa2-hover">取消</button>
<button disabled="{{submitFlag}}" bindtap="postAppSmsCusorder" class="fn-flex-item ml20 btn-36afa2 wp100 font-28 color-fff ulib-r750" hover-class="btn-36afa2-hover">确定</button>
</view>
</view>
</lcb-msg>
+3 -3
View File
@@ -42,9 +42,9 @@
<view class="inner40">
<textarea class="wp100 inner20 bds-1-eb font-28 ulib-r10" placeholder-class="color-ccc" maxlength='100' placeholder="请输入短信内容" bindinput='inputTx' data-key="content" name='content' value='{{content}}' />
</view>
<view class="fn-flex bts-1-eb text-center font-32 color-666">
<view class="fn-flex-item pt25 pb25" bindtap="hideMessage">取消</view>
<view class="fn-flex-item bls-1-eb pt25 pb25 color-36afa2" disabled="{{!submitFlag}}" bindtap="postAppSmsCusorder">确定</view>
<view class="fn-flex pl60 pr60 pb50 text-center font-32 color-666">
<button bindtap="hideMessage" class="fn-flex-item mr20 bds-2-36afa2 btn-no-bg wp100 font-28 color-36afa2 ulib-r750" hover-class="btn-36afa2-hover">取消</button>
<button disabled="{{submitFlag}}" bindtap="postAppSmsCusorder" class="fn-flex-item ml20 btn-36afa2 wp100 font-28 color-fff ulib-r750" hover-class="btn-36afa2-hover">确定</button>
</view>
</view>
</lcb-msg>
+6 -6
View File
@@ -10,7 +10,7 @@
</view>
</block>
</view>
<scroll-view class="mt5 font-28 color-666 text-center space-nowrap" scroll-x="true" wx:else>
<scroll-view class="mt5 font-32 color-666 text-center space-nowrap" scroll-x="true" wx:else>
<view class="pl20 inline-block"></view>
<block wx:for='{{tab}}' wx:key='list'>
<view class="pl20 pr20 tabmenu2 {{key == item.key?'active color-36afa2':''}}" data-index="{{index}}" bindtap="changeTab" >
@@ -25,9 +25,9 @@
<view class="pl30 relative">
<view class="wp70 relative">
<view class="absolute box-center-middle font-22 color-ccc" bindtap="searchFocus" wx:if="{{searchInp.value == '' && searchInp.focus != true}}"><i class="iconfont mr10 icon-sousuo"></i>请输入客户姓名</view>
<input class="wp100 bg-f6 pl20 pr20 font-22 ulib-r750 text-center" bindinput="searchInput" bindfocus="searchFocus" bindblur="searchBlur" bindconfirm="searchSubmit" style="height:48rpx" type="text" />
<input class="wp100 bg-f6 pl20 pr20 font-22 ulib-r750 text-center" bindinput="searchInput" bindfocus="searchFocus" bindblur="searchBlur" bindconfirm="searchSubmit" style="height:56rpx" type="text" />
</view>
<view bindtap="pushLink" data-url="/pages/order/register/index" class="absolute right-0 box-middle pt5 pb5 pl10 pr30 space-nowrap bg-333 font-22 color-fff ulib-rl750"><i class="iconfont mr5 icon-jia"></i>登记订单</view>
<view bindtap="pushLink" data-url="/pages/order/register/index" class="absolute right-0 box-middle pt10 pb10 pl10 pr30 space-nowrap bg-333 font-22 color-fff ulib-rl750"><i class="iconfont mr5 icon-jia"></i>登记订单</view>
</view>
<view class="mt30 pl30 pr30">
@@ -72,9 +72,9 @@
<view class="inner40">
<textarea class="wp100 inner20 bds-1-eb font-28 ulib-r10" placeholder-class="color-ccc" maxlength='100' placeholder="请输入短信内容" bindinput='inputTx' data-key="content" name='content' value='{{content}}' />
</view>
<view class="fn-flex bts-1-eb text-center font-32 color-666">
<view class="fn-flex-item pt25 pb25" bindtap="hideMessage">取消</view>
<view class="fn-flex-item bls-1-eb pt25 pb25 color-36afa2" disabled="{{!submitFlag}}" bindtap="postAppSmsCusorder">确定</view>
<view class="fn-flex pl60 pr60 pb50 text-center font-32 color-666">
<button bindtap="hideMessage" class="fn-flex-item mr20 bds-2-36afa2 btn-no-bg wp100 font-28 color-36afa2 ulib-r750" hover-class="btn-36afa2-hover">取消</button>
<button disabled="{{submitFlag}}" bindtap="postAppSmsCusorder" class="fn-flex-item ml20 btn-36afa2 wp100 font-28 color-fff ulib-r750" hover-class="btn-36afa2-hover">确定</button>
</view>
</view>
</lcb-msg>
+1 -1
View File
@@ -2,7 +2,7 @@
.tabmenu2{display:inline-block;line-height:72rpx;}
.tabmenu2.active view.relative{display:inline-block;}
.tabmenu2.active view.relative::before{display:inline-block;position:absolute;bottom:0;left:50%;transform:translate(-50%,0);width:64rpx;height:4rpx;content:"";background-color:#36afa2;}
.tabmenu2.active view.relative::before{display:inline-block;position:absolute;bottom:0;left:50%;transform:translate(-50%,0);width:64rpx;height:6rpx;content:"";background-color:#36afa2;}
.subtab{height:100rpx;}
.opt-item{border:#ebebeb 1rpx solid;line-height:40rpx;}
+10
View File
@@ -44,9 +44,19 @@ Page({
this.getAppCustomersList()
this.getAppSeriesCars()
this.getUserInfo()
},
//获取用户信息
getUserInfo(){
_.apiQuery.getUserInfo().then(res => {
this.setData({
userInfo: res
})
});
},
//获取客户列表
getAppCustomersList(){
this.setData({
+1 -1
View File
@@ -2,7 +2,7 @@
<view class="inner30">
<view class="fn-clear font-22">
<view class="fn-fl"><i class="iconfont icon-yonghu mr10"></i>用户信息</view>
<view class="fn-fr">销售顾问:<text class="color-36afa2">王小胖</text></view>
<view class="fn-fr">销售顾问:<text class="color-36afa2">{{userInfo.uname}}</text></view>
</view>
<view class="mt30 pl40 pr40 pt10 pb10 relative ulib-r10 box-shadow-000-10-10 overflowhidden" bindtap="showSelectCustomer">
<view class="pt50 pb50 font-28" wx:if="{{customerIndex == -1}}">请选择客户</view>