from表单提交,点击提交无反应
发布于 5 年前 作者 thao 5637 次浏览 来自 问答
  • 当前 Bug 的表现(可附上截图)点击提交表单,无反应
  • 预期表现 正常提交表单
  • 复现路径 from表单提交,填写input输入框,将里面的值提交无反应
  • 提供一个最简复现 Demo

<form bindsubmit=“bindSaveTap” report-submit=‘true’>

<view class=‘content’>

<view class=‘content_title’>

<text class=‘star1’>*</text>产品描述:</view>

<textarea hidden="{{!claimer}}" placeholder=“请输入产品描述” value="{{contenttext}}" auto-height=“true” bindblur=“productInformation” maxlength=“1000” placeholder-style=“font-size:30rpx;” />

</view>

<view class=‘line1’>

<view class=‘address_l’>规格成分:</view>

<input class=“middle_input” maxlength=“200” placeholder=“请输入规格成分” bindblur=“composition” value="{{composition}}" placeholder-style=“color:#999;”/>

</view>

<view class=‘line1’>

<view class=‘address_l’>数量:</view>

<input class=“middle_input” maxlength=“200” placeholder=“请输入数量” bindblur=“productNub” value="{{productNub}}" placeholder-style=“color:#999;”/>

</view>

<view class=‘line1’>

<view class=‘address_l’>价格:</view>

<input class=“middle_input” maxlength=“200” placeholder=“请输入价格” bindblur=“price” value="{{price}}" placeholder-style=“color:#999;”/>

</view>

<view class=‘address’>

<view class=‘address_l’>

<text class=‘star1’>*</text>存放地:</view>

<view class=“address_r {{provinceval?‘color1’:’’}}” bindtap=‘chooseAddress’>

{{provinceval?provinceval+’ '+cityval:‘请选择存放地’}}

<view class=‘address_r_jiantou’></view>

</view>

</view>

<view class=“release”>

<view class=“inp-images”>

<image src="{{item.imageUrl}}" mode=“aspectFill” wx:for="{{imageUrl}}" wx:key="{{index}}" class=“choose-images”>

<image src=http://mmwtest2.oss-cn-hangzhou.aliyuncs.com/image/wxapp/trash.png data-index="{{index}}" class=“delete-images” bindtap=“deleteimage2”></image>

</image>

<image src="{{item}}" mode=“aspectFill” wx:for="{{array}}" wx:key="{{index}}" class=“choose-images”>

<image src=http://mmwtest2.oss-cn-hangzhou.aliyuncs.com/image/wxapp/trash.png data-index="{{index}}" class=“delete-images” bindtap=“deleteimage”></image>

</image>

<view class=“add-images” bindtap=“chooseImageTap” hidden=’{{imageUrl.length + array.length >= 9}}’>

<view class=“add_bt”>上传照片</view>

</view>

</view>

<view class=‘type’>

<view class=‘tit’>行业类型</view>

<view class=‘type_bt’>

<view class=“type_btn {{industrytype == item.typekey?‘type_choose’:’’}}” wx:for="{{list.industryTypeList}}" wx:key="{{index}}" bindtap=‘type_btn’ data-seek="{{item.typekey}}">{{item.typeval}}</view>

</view>

</view>

<button size=“default” class=“submit” bindtap=“submit” hover-class=“xd-subBtn-hover”>保存</button>

</view>

<view class=‘disclaimer’ bindtap=‘openclaimer’>发布前,请阅读

<text class=‘disclaimer-tit’>《免责声明》</text>

</view>

<view style=‘height:100px;’></view>

<!-- 提示消息 -->

<view class=“modal” hidden="{{!ms}}">

<view class=“modal_profession”>

<view class=“modal_profession_t” style=“color:#333;”>

{{ms}}

</view>

<view class=“examine_sub” bindtap=“colse_ms”>

确定

</view>

</view>

</view>

<!-- 弹框 -->

<view class=“modal2” hidden="{{modal2}}">

<view class=‘modal2_con’>

<view class=‘modal2_tit’>联系方式</view>

<view class=‘name_line’>

<view class=‘name’>姓名</view>

<view class=‘star’>*</view>

<input class=‘name_input’ placeholder="" bindblur=“name” maxlength=“10” value="{{name}}" type=‘text’></input>

</view>

<view class=‘name_line’>

<view class=‘name’>公司</view>

<view class=‘star’>*</view>

<input class=‘name_input’ placeholder="" bindblur=“sellComName” maxlength=“40” value="{{sellComName}}" type=‘text’></input>

</view>

<view class=‘name_line’>

<view class=‘name’>电话</view>

<view class=‘star’>*</view>

<input class=‘name_input’ placeholder="" bindblur=“telephone” maxlength=“20” value="{{telephone}}" type=‘text’></input>

</view>

<view class=‘modal2_footer’>

<view class=‘footer_left’ bindtap=‘quxiao’>取消</view>

<button size=“default” class=‘footer_right’ formType=“submit” hover-class=“xd-subBtn-hover”>确定</button>

</view>

</view>

</view>

</form>

4 回复

每个组件是不是都少一个name=‘xxx’ 导致的呀?

额。。里面有公司信息,我就摘着重要的黏贴的,没敲好。除了6.7.4都是没问题的

表单提交submit的bug
https://developers.weixin.qq.com/community/develop/doc/000ec807b74660c150b7b1ba156000

关于这类问题的反馈,我们在做调整哈

看你代码  form提交事件应该是  最后的

然后会调用你js里面的方法 bindSaveTap

回到顶部