Commit aefdb3e3 by 王志慧

输入框交互调整

1 parent df6f3f57
...@@ -45,7 +45,7 @@ Page({ ...@@ -45,7 +45,7 @@ Page({
} = e.target.dataset } = e.target.dataset
this.setData({ this.setData({
bussinessType: type, bussinessType: type,
nothing:false, nothing: false,
pageNum: 1, pageNum: 1,
}, () => { }, () => {
this.getList(true) this.getList(true)
...@@ -68,7 +68,7 @@ Page({ ...@@ -68,7 +68,7 @@ Page({
pageNum: isReset ? 1 : pageNum, pageNum: isReset ? 1 : pageNum,
searchdate, searchdate,
keyword, keyword,
BussinessType:bussinessType BussinessType: bussinessType
} }
if (RecMerchantNo) params.RecMerchantNo = RecMerchantNo if (RecMerchantNo) params.RecMerchantNo = RecMerchantNo
if (nothing) return if (nothing) return
...@@ -84,7 +84,7 @@ Page({ ...@@ -84,7 +84,7 @@ Page({
if (e.seconds) e._seconds = this.formatTime(e.seconds) if (e.seconds) e._seconds = this.formatTime(e.seconds)
// e.tempServer = e.serviceList.slice(0, 3) // e.tempServer = e.serviceList.slice(0, 3)
console.log(e.merchantDTOList) console.log(e.merchantDTOList)
e.tempStore = e.merchantDTOList&&e.merchantDTOList.length>0?e.merchantDTOList.slice(0, 3):[] e.tempStore = e.merchantDTOList && e.merchantDTOList.length > 0 ? e.merchantDTOList.slice(0, 3) : []
}) })
this.setData({ this.setData({
inspectList: tempList, inspectList: tempList,
...@@ -213,7 +213,7 @@ Page({ ...@@ -213,7 +213,7 @@ Page({
selectedYqMerchantList, selectedYqMerchantList,
RecMerchantNo, RecMerchantNo,
merchantName, merchantName,
nothing:false nothing: false
}) })
this.getList(true) this.getList(true)
}, },
...@@ -278,10 +278,23 @@ Page({ ...@@ -278,10 +278,23 @@ Page({
} }
}, },
showOpen() { showOpen(e) {
console.log(e.currentTarget.dataset)
let {
open
} = e.currentTarget.dataset
this.setData({ this.setData({
isopen: !this.data.isopen isopen: !this.data.isopen
}) })
if (open) {
this.setData({
pageNum: 1,
nothing: false,
keyword: ''
}, () => {
this.getList(true)
})
}
}, },
/** /**
* 生命周期函数--监听页面初次渲染完成 * 生命周期函数--监听页面初次渲染完成
...@@ -292,11 +305,11 @@ Page({ ...@@ -292,11 +305,11 @@ Page({
this.setData({ this.setData({
pageNum: 1, pageNum: 1,
nothing: false, nothing: false,
searchdate:detail searchdate: detail
},()=>{ }, () => {
this.getList(true) this.getList(true)
}) })
}, },
onReady() { onReady() {
......
...@@ -29,7 +29,6 @@ page{ ...@@ -29,7 +29,6 @@ page{
.search-input { .search-input {
background: #F7F8FA; background: #F7F8FA;
border-radius: var(--fontSize38); border-radius: var(--fontSize38);
width:100%;
height: var(--fontSize72); height: var(--fontSize72);
display: flex; display: flex;
align-items: center; align-items: center;
......
...@@ -7,8 +7,8 @@ ...@@ -7,8 +7,8 @@
<image class="solidArrow" src="/tabIndex/images/arrSolid.png" /> <image class="solidArrow" src="/tabIndex/images/arrSolid.png" />
</view> </view>
</block> </block>
<block wx:if="{{isopen}}">
<view class="search-input"> <view class="search-input" style="width:{{isopen?'100%':''}}" bindtap="showOpen">
<image src="/images/search.png" class="search-icon" /> <image src="/images/search.png" class="search-icon" />
<input type="text" placeholder="员工姓名/手机号" class="input" confirm-type="search" value="{{keyword}}" placeholder-class="input-placeholder" catchinput="input" catchconfirm="inputConfifm" /> <input type="text" placeholder="员工姓名/手机号" class="input" confirm-type="search" value="{{keyword}}" placeholder-class="input-placeholder" catchinput="input" catchconfirm="inputConfifm" />
<block wx:if="{{keyword}}"> <block wx:if="{{keyword}}">
...@@ -17,12 +17,12 @@ ...@@ -17,12 +17,12 @@
</view> </view>
</block> </block>
</view> </view>
<view class="cancel-text" bindtap="showOpen" wx:if="{{isopen}}">取消</view> <view class="cancel-text" bindtap="showOpen" data-open="true" wx:if="{{isopen}}">取消</view>
</block>
<view class="search-icon-wrap" wx:if="{{!isopen}}" bindtap="showOpen"> <!-- <view class="search-icon-wrap" wx:if="{{!isopen}}" bindtap="showOpen">
<image src="/images/search-black.png" class="search-icon" /> <image src="/images/search-black.png" class="search-icon" />
</view> </view> -->
</view> </view>
<date-box bindchange="changeDate"></date-box> <date-box bindchange="changeDate"></date-box>
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!