在页面上存在5个及一上的input时, 第五和第六个input 在输入值 后失去焦点会自动隐藏 连placeholder都消失,但是在重新获得焦点的时候 输入的值有出现…还有在操作页面上除了input以外的元素,这两个自动隐藏input又会重新出现…
是固定第五第六… 无论是怎么样的input…都一样自动隐藏…
wxml页面 上增加 bindblur=‘BindBUG_value’ 和 style=“will-change: {{BUG_value}}”
<input value=’{{contactNumber}}’ bindblur=‘BindBUG_value’ style=“will-change: {{BUG_value}}” name=‘contactNumber’ bindinput=“bindReplaceNumber” type=“number” class=“weui-input-fire” placeholder=“请输入联系人电话” />
页面js
BindBUG_value:function(e){
this.setData({
BUG_value:‘transform’
});
},
实测可行
<!–index.wxml–>
<!-- <dialog-area id=‘dialog’ /> -->
<view class=“weui-toptips weui-toptips_warn” wx:if="{{showTopTips}}">{{errorMsg}}</view>
<view class=“container”>
<view class=“header”>
<image mode=“widthFix” src="/images/index/index-bg.png" ></image>
</view>
<view class=“header logo”>
<image mode=“widthFix” src="/images/index/index-logo.png" ></image>
</view>
<view class=“header title”>
<image mode=“widthFix” src="/images/index/index-title.png" ></image>
</view>
<view class=“content”>
<view class=‘content-title’>
<view class=‘red-vertical’></view>
培训汇报
</view>
<form id=‘drafts’ bindsubmit=“draftsSubmit” class=‘content-box’>
<form id=‘report’ bindsubmit=“formSubmit” class=‘content-box’>
<view class=‘item-input-box’>
<view class=‘item-input-icon’><image mode=“widthFix” src=’/images/input/map.png’></image></view>
<view class=‘item-input’>
<view class=“item-input-bd”>
<input value=’{{Geocoded}}’ name=‘Geocoded’ disabled=‘true’ bindtap=“bindGeocodedTap” type=“text” class=“weui-input-fire” placeholder=“请选择所在辖区” />
</view>
<block wx:if="{{showGps}}">
<view class=“item-input-ft”>
<view bindtap=‘gps’ hover-class=“navigator-hover” class=“gps-btn”>
<view class=“gps-btn-icon”><image mode=“widthFix” src=’/images/input/gps.png’></image></view>
<view class=“gps-btn-word”>定位辖区</view>
</view>
</view>
</block>
</view>
</view>
<view class=‘item-input-box’>
<view class=‘item-input-icon’><image mode=“widthFix” src=’/images/input/flag.png’></image></view>
<view class=‘item-input’>
<view class=“item-input-bd”>
<input name=‘address’ value=’{{address}}’ type=“text” class=“weui-input-fire” placeholder=“请输入详细地址” />
</view>
</view>
</view>
<view class=‘item-input-box’>
<view class=‘item-input-icon’><image mode=“widthFix” src=’/images/input/type.png’></image></view>
<view class=‘item-input’>
<view class=“item-input-bd”>
<picker name=‘publicityType’ bindchange=“bindTypeChange” value="{{publicityType}}" range="{{types}}" range-key=‘title’ >
<block wx:if="{{publicityType!=0}}">
<view class="weui-input-fire ">{{types[publicityType].title}}</view>
</block>
<block wx:else>
<view class=“weui-input-fire default”>{{types[publicityType].title}}</view>
</block>
</picker>
</view>
</view>
</view>
<view class=‘item-input-box’>
<view class=‘item-input-icon’><image mode=“widthFix” src=’/images/input/home.png’></image></view>
<view class=‘item-input’>
<view class=“item-input-bd”>
<input value=’{{organization}}’ name=‘organization’ type=“text” class=“weui-input-fire” placeholder=“请输入单位名称” />
</view>
</view>
</view>
<view class=‘item-input-box’>
<view class=‘item-input-icon’><image mode=“widthFix” src=’/images/input/number.png’></image></view>
<view class=‘item-input’>
<view class=“item-input-bd”>
<input value=’{{number}}’ name=‘number’ bindinput=“bindReplaceNumber” type=“number” class=“weui-input-fire” placeholder=“请输入培训人数” />
</view>
</view>
</view>
<view class=‘item-input-box’>
<view class=‘item-input-icon’><image mode=“widthFix” src=’/images/input/name.png’></image></view>
<view class=‘item-input’>
<view class=“item-input-bd”>
<input value=’{{contactName}}’ name=‘contactName’ type=“text” class=“weui-input-fire” placeholder=“请输入联系人姓名” />
</view>
</view>
</view>
<view class=‘item-input-box’>
<view class=‘item-input-icon’><image mode=“widthFix” src=’/images/input/phone.png’></image></view>
<view class=‘item-input’>
<view class=“item-input-bd”>
<input value=’{{contactNumber}}’ name=‘contactNumber’ bindinput=“bindReplaceNumber” type=“number” class=“weui-input-fire” placeholder=“请输入联系人电话” />
</view>
</view>
</view>
<view class=‘item-input-box’>
<view class=‘item-input-icon’><image mode=“widthFix” src=’/images/input/remarks.png’></image></view>
<view class=‘item-input’>
<view class=“item-input-bd”>
<textarea value=’{{remarks}}’ name=‘remarks’ maxlength=“200” bindinput=“bindInputRemarks” class=“weui-textarea” placeholder=“请输入备注信息” />
<view class=“weui-textarea-counter”>{{remarksCount}}/200</view>
</view>
</view>
</view>
<view class=‘item-input-box’ style=‘border: none; padding-bottom:0;’>
<view class=‘item-input-icon’><image mode=“widthFix” src=’/images/input/image.png’></image></view>
<view class=‘item-input’ >
<view class=“item-input-bd”>
<input disabled=‘true’ type=“number” class=“weui-input-fire” placeholder=“请上传照片” />
</view>
</view>
</view>
<view class=‘item-input-box’ >
<upload id=‘upload’ style=‘width:100%;’ />
</view>
<button class=‘report_button’ formType=“submit” >汇报</button>
</form>
<button class=‘drafts_button’ formType=“submit” ><image mode=“widthFix” src=’/images/input/drafts.png’></image></button>
</form>
</view>
<view class=‘footer’>
<span>©</span>
</view>
</view>