action-bar.wxml 2.93 KB
<!--page/subPackage/pages/zeroSell/components/action-bar.wxml-->

<view class="action-bar">
  <view class="action-item action-list" bindtap="goList">
    <image class="action-image" src="../images/list_icon@2x.png"></image>
  </view>

  <block wx:if="{{status === 1}}">
    <view class="action-item over">即将开始</view>
  </block>

  <block wx:elif="{{status === 2}}">
    <form bindsubmit='submitFormId' report-submit='true' class="action-item">
        <button class="action-item confirm" style="border-radius: unset;" form-type="submit" bindtap="fetchCode">0元参加抽奖</button>
    </form>
  </block>

  <block wx:elif="{{status === 3}}">
    <view class="action-item ok" bindtap="goShare">
      分享得更多抽奖码,增加中奖率
    </view>
  </block>

  <block wx:elif="{{status === 4}}">
    <view class="action-item confirm" bindtap="goMyList">
        我的抽奖码({{num}})
    </view>
  </block>

  <block wx:elif="{{status === 5}}">
    <view class="action-item confirm" bindtap="goMyList">
        我的抽奖码({{num}})
    </view>

    <view class="action-item ok" bindtap="openFellowAlert">
        查看开奖结果
    </view>
  </block>

  <block wx:elif="{{status === 6}}">
    <view class="action-item over">活动已结束</view>
  </block>

  <block wx:elif="{{status === 7}}">
    <block wx:if="{{num > 0}}">
        <view class="action-item confirm" bindtap="goMyList">
            我的抽奖码({{num}})
        </view>
    </block>
    <block wx:else>
        <view class="action-item over">活动已结束</view>
    </block>  
  </block>
</view>
<new-lucky-alert wx:if="{{show}}" bindhiddenalert="hiddenAlert">
  <view class="code-alert">
    <text class="code-title">参加抽奖成功</text>
    <view class="code-bg">
      <view class="title">你的抽奖码是</view>
      <view class="code">{{code}}</view>
    </view>
    <button class="share" bindtap="hadJoinToShare">分享一下,中奖概率立马double</button>
    <view class="share-desc">1个好友参加=1个抽奖码=中奖几率UP!</view>
    <!-- <radio class="radio"  value="{{msgChecked}}" bindtap="msgSwitch" color="#979797" checked="{{msgChecked}}">
      <text>同意接收开奖结果通知</text>
    </radio> -->
    <label class="radio-box" for="{{msgChecked}}" bindtap="msgSwitch">
      <radio hidden value="{{msgChecked}}" checked="{{msgChecked}}"/> 
      <image class="radio" src="../../../images/default-{{msgChecked ? 'select' : 'normal'}}@3x.png"></image>
      <text>同意接收开奖结果通知</text>
    </label>
  </view>
</new-lucky-alert>

<zero-alert wx:if="{{error}}">
  <view class="error-alert">
    <view class="error-title">OOPS</view>
    <view class="error-content">{{errorText}}</view>
  </view>

  <view class="foot">
    <view class="foot-item" bindtap="cancelAlert">确定</view>
  </view>
</zero-alert>

<fellow-alert show="{{fellow}}" bindok="cancelFellow" copyText="{{copyText}}" type="{{type}}" text="{{text}}"></fellow-alert>