61 lines
2.3 KiB
Plaintext
61 lines
2.3 KiB
Plaintext
<!-- 支付组件模板 -->
|
|
<view wx:if="{{ visible }}" class="pay-mask" catchtouchmove="prevent">
|
|
<!-- 支付方式选择 -->
|
|
<view wx:if="{{ step === 'method' }}" class="pay-panel">
|
|
<view class="pay-head">
|
|
<text class="pay-title">选择支付方式</text>
|
|
<view class="pay-close" bindtap="close">✕</view>
|
|
</view>
|
|
<view class="pay-body">
|
|
<view class="method-item" bindtap="chooseMethod" data-method="wx">
|
|
<text class="method-icon">💳</text>
|
|
<text class="method-name">微信支付</text>
|
|
</view>
|
|
<view class="method-item" bindtap="chooseMethod" data-method="balance">
|
|
<text class="method-icon">💰</text>
|
|
<text class="method-name">佣金抵扣</text>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
|
|
<!-- 余额抵扣身份选择 -->
|
|
<view wx:if="{{ step === 'balance' }}" class="pay-panel">
|
|
<view class="pay-head">
|
|
<text class="pay-title">选择抵扣身份</text>
|
|
<view class="pay-close" bindtap="close">✕</view>
|
|
</view>
|
|
<scroll-view scroll-y class="pay-body">
|
|
<view wx:for="{{ balanceOptions }}" wx:key="id" class="balance-item" bindtap="selectBalance" data-id="{{ item.id }}">
|
|
<text class="balance-name">{{ item.jieshao }}</text>
|
|
<text class="balance-amount">需¥{{ item.xuyao }}</text>
|
|
</view>
|
|
</scroll-view>
|
|
</view>
|
|
|
|
<!-- 余额抵扣确认 -->
|
|
<view wx:if="{{ step === 'confirm' }}" class="pay-panel">
|
|
<view class="pay-head">
|
|
<text class="pay-title">确认抵扣</text>
|
|
<view class="pay-close" bindtap="close">✕</view>
|
|
</view>
|
|
<view class="pay-body">
|
|
<view class="confirm-row">
|
|
<text>抵扣身份:{{ selectedBalance.jieshao }}</text>
|
|
</view>
|
|
<view class="confirm-row">
|
|
<text>需扣除:¥{{ selectedBalance.xuyao }}</text>
|
|
</view>
|
|
<text class="confirm-tip">确认后将从您的佣金/分红中扣除</text>
|
|
</view>
|
|
<view class="pay-foot">
|
|
<view class="btn default" bindtap="backToMethod">取消</view>
|
|
<view class="btn primary" bindtap="confirmBalance">确认</view>
|
|
</view>
|
|
</view>
|
|
|
|
<!-- 支付加载动画 -->
|
|
<view wx:if="{{ step === 'loading' }}" class="pay-mask loading-box">
|
|
<view class="spinner"></view>
|
|
<text class="loading-text">{{ loadingText }}</text>
|
|
</view>
|
|
</view> |