wpfw_ewei_wxapp/pages/diy/template/tpl_topmenu.wxml
2023-02-26 08:10:18 +08:00

22 lines
2.5 KiB
Plaintext

<view class="fui-topmenu fui-tabbar style1" wx:if="{{diyitem.id=='topmenu'&&diyitem.style.showtype=='1'}}">
<block wx:for="{{diyitem.data}}" wx:for-item="items" wx:key="index">
<view bindtap="tabtopmenu" class="item" data-id="{{diyitemid}}" data-index="m{{index}}" data-type="{{index}}" data-url="{{items.linkurl}}" id="m{{index}}" style="{{diyitem.data.length<=4?'flex: 1;':'flex-shrink:0;'}}{{index==0?'color:'+diyitem.style.activecolor+';background:'+diyitem.style.activebackground+';border-color:'+diyitem.style.activecolor:'color:'+diyitem.style.color+';background:'+diyitem.style.background}}" wx:if="{{diyitem.status==undefined||diyitem.status==''||!diyitem.status}}">
{{items.text||'选项'}}
</view>
<view bindtap="tabtopmenu" class="item" data-id="{{diyitemid}}" data-index="m{{index}}" data-type="{{index}}" data-url="{{items.linkurl}}" id="m{{index}}" style="{{diyitem.data.length<=4?'flex: 1;':'flex-shrink:0;'}}{{diyitem.status==index?'color:'+diyitem.style.activecolor+';background:'+diyitem.style.activebackground+';border-color:'+diyitem.style.activecolor:'color:'+diyitem.style.color+';background:'+diyitem.style.background}}" wx:if="{{diyitem.status}}">
{{items.text||'选项'}}
</view>
</block>
</view>
<view class="fui-topmenu fui-tabbar style2" wx:if="{{diyitem.id=='topmenu'&&diyitem.style.showtype=='2'}}">
<block wx:for="{{diyitem.data}}" wx:for-item="items" wx:key="index">
<view bindtap="tabtopmenu" class="item" data-id="{{diyitemid}}" data-type="{{index}}" data-url="{{items.linkurl}}" style="{{diyitem.data.length<=4?'flex: 1;':'flex-shrink:0;'}}{{index==0?'color:'+diyitem.style.activecolor+';background:'+diyitem.style.activebackground+';border-color:'+diyitem.style.activecolor:'color:'+diyitem.style.color+';background:'+diyitem.style.background}}" wx:if="{{diyitem.status==undefined||diyitem.status==''||!diyitem.status}}">
{{items.text||'选项'}}
</view>
<view bindtap="tabtopmenu" class="item" data-id="{{diyitemid}}" data-type="{{index}}" data-url="{{items.linkurl}}" style="{{diyitem.data.length<=4?'flex: 1;':'flex-shrink:0;'}}{{diyitem.status==index?'color:'+diyitem.style.activecolor+';background:'+diyitem.style.activebackground+';border-color:'+diyitem.style.activecolor:'color:'+diyitem.style.color+';background:'+diyitem.style.background}}" wx:if="{{diyitem.status}}">
{{items.text||'选项'}}
</view>
</block>
</view>
<include src="/pages/diy/template/tpl_tablist.wxml"></include>