使用模版时模版里的bindtap渲染时不显示
引用
<include src="/assets/template/shenche.wxml"/>
模版页相关代码
<view class=“form_section_gap” bindtap=‘ooo’>
结果在引用页面渲染的时候bindtap事件被隐藏了。
只有开发工具存在此问题,真机没问题
10 回复
<import src="/assets/template/form.wxml" />
< view class = 'container' > < template is = "textarea" data = "{{title:'提醒商家需要注意的地方,例如:口味、偏好等。字数150字内',start:content_start,all:'150',name:'content'}}" /> </ view >
|
<!-- form.wxml 文本域 --> < template name = "textarea" > < view class = "weui-cell" > < view class = "weui-cell__bd" > < textarea class = "weui-textarea" maxlength = "{{all}}" bindinput = "bindtextareaChange" placeholder = "{{title}}" style = "height: 8em" data-model = "form.{{name}}" data-start = "{{name}}_start" /> < view class = "weui-textarea-counter" wx:if = "{{all}}" >{{start?start:'0'}}/{{all}}</ view > </ view > </ view > </ template > |
< block > < include src = "/assets/template/waimai_f.wxml" /> </ block > |