index.wxml 3.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. <van-popup custom-class="aaa" show="{{ show }}" close-on-click-overlay="{{false}}" get-container="#app" bind:close="onClose" position="right" custom-style="width: 100%;height: 100%" safe-area-tab-bar="{{false}}" safe-area-inset-bottom="{{false}}" z-index="99999">
  2. <van-sticky>
  3. <van-nav-bar title="{{popupTitle}}" left-arrow bind:click-left="onClickLeft" />
  4. </van-sticky>
  5. <logout-show title="{{ popupTitle}}" showBtn="{{false}}" wx:if="{{ token==='' }}" />
  6. <view class="popup-container" wx:else>
  7. <view class="popup-radio" wx:if="{{popupType=='radio'}}">
  8. <view class="popup-radio-item {{value===item.id?'selected':''}}" wx:for="{{ popupOptions}}" wx:key="index" bindtap="radioChange" data-index="{{index}}">{{item.name}}</view>
  9. </view>
  10. <view class="popup-time" wx:elif="{{popupType=='time'}}">
  11. <van-calendar show-title="{{false}}" show-subtitle="{{false}}" color="#409EFF" round="{{false}}" type="range" poppable="{{ false }}" close-on-click-overlay="{{false}}" default-date="{{value}}" safe-area-inset-bottom="{{false}}" max-range="{{15}}" allow-same-day="{{true}}" bind:confirm="timeConfirm" show-confirm="{{false}}">
  12. </van-calendar>
  13. </view>
  14. <view class="popup-checkbox" wx:elif="{{popupType=='checkbox'}}">
  15. <view class="popup-checkbox-header">
  16. 温馨提示:{{ popupTitle}}可多选</view>
  17. <view class="popup-checkbox-main">
  18. <view class="popup-checkbox-item {{item.selected?'selected':''}}" wx:for="{{ popupOptions}}" wx:key="index" bindtap="checkboxChange" data-index="{{index}}">
  19. <view class="popup-checkbox-label">
  20. {{item.name}}
  21. </view>
  22. <view class="popup-checkbox-icon">
  23. <van-icon wx:if="{{item.selected}}" name="checked" size="20px" color="#409EFF" custom-style="background:#fff" />
  24. <van-icon wx:else name="circle" color="#909399" size="20px" custom-style="background:#fff" />
  25. </view>
  26. </view>
  27. </view>
  28. <view class="popup-checkbox-footer">
  29. <van-button type="info" custom-style="width:100%;margin:8px 0 0 0" bindtap="checkboxSelected">确定</van-button>
  30. </view>
  31. </view>
  32. <view class="popup-city" wx:elif="{{popupType=='city'}}">
  33. <van-index-bar index-list="{{ indexList }}">
  34. <view class="city-item current-city">
  35. <van-index-anchor index="当前城市" />
  36. <view class="city-value-row current-city-value">{{label}}</view>
  37. </view>
  38. <view class="city-item" wx:for="{{cityList}}" wx:key="index" data-type="{{item.id}}">
  39. <van-index-anchor index="{{item.letter}}">{{item.letter}}</van-index-anchor>
  40. <view class="city-value-row">
  41. <van-row>
  42. <van-col span="8" wx:for="{{item.list}}" wx:key="id" wx:for-index="idx" wx:for-item="small">
  43. <view class="city-value-item {{ small.order?'not-border':''}} {{small.value===value?'changed':''}}" data-pindex="{{index}}" data-index="{{idx}}" bindtap="bindViewTap">
  44. {{small.label}}
  45. </view>
  46. </van-col>
  47. </van-row>
  48. </view>
  49. </view>
  50. </van-index-bar>
  51. <!-- <city-bar changeValue="{{popupValue}}" changeLabel="{{'北京'}}" binditemClick="onItemClick" /> -->
  52. </view>
  53. </view>
  54. </van-popup>