156 lines
8.0 KiB
Plaintext
156 lines
8.0 KiB
Plaintext
<view class="page">
|
||
<view class="nav-placeholder" style="height: {{navBarHeight || (statusBarHeight + 44)}}px;"></view>
|
||
|
||
<block wx:if="{{!matchEnabled}}">
|
||
<view class="closed-wrap">
|
||
<view class="closed-icon">🔒</view>
|
||
<text class="closed-title">功能暂未开放</text>
|
||
<text class="closed-desc">找伙伴功能即将上线,请先逛逛首页与目录。</text>
|
||
<view class="btn-primary" bindtap="goToIndex">返回首页</view>
|
||
</view>
|
||
</block>
|
||
|
||
<block wx:else>
|
||
<view class="header safe-header-right">
|
||
<text class="header-title">找伙伴</text>
|
||
<view class="header-btn"></view>
|
||
</view>
|
||
|
||
<view class="match-count-card" wx:if="{{hasPurchased}}">
|
||
<view class="match-count-left">
|
||
<text class="match-count-label {{matchesRemaining <= 0 && !needPayToMatch ? '' : ''}}">{{needPayToMatch ? '今日匹配机会已用完' : (totalMatchesAllowed > 999 ? '无限匹配机会' : '剩余匹配机会')}}</text>
|
||
</view>
|
||
<view class="match-count-right">
|
||
<text class="match-count-num {{matchesRemaining > 0 ? 'active' : 'red'}}">{{totalMatchesAllowed > 999 ? '无限' : matchesRemaining + '/' + totalMatchesAllowed}}</text>
|
||
<view class="btn-buy-section" wx:if="{{needPayToMatch}}" bindtap="goToChapters">购买小节+1次</view>
|
||
</view>
|
||
</view>
|
||
|
||
<block wx:if="{{!isMatching && !currentMatch}}">
|
||
<view class="idle-wrap">
|
||
<view class="circle-wrap {{hasPurchased ? 'active' : ''}} {{needPayToMatch ? 'need-pay' : ''}}" bindtap="startMatch">
|
||
<view class="circle-inner">
|
||
<block wx:if="{{!hasPurchased}}">
|
||
<text class="circle-icon">🔒</text>
|
||
<text class="circle-title">购买后解锁</text>
|
||
<text class="circle-desc">购买9.9元即可使用</text>
|
||
</block>
|
||
<block wx:elif="{{needPayToMatch}}">
|
||
<text class="circle-icon gold">⚡</text>
|
||
<text class="circle-title">需要解锁</text>
|
||
<text class="circle-desc">今日免费次数已用完</text>
|
||
</block>
|
||
<block wx:else>
|
||
<text class="circle-icon">👥</text>
|
||
<text class="circle-title">开始匹配</text>
|
||
<text class="circle-desc">匹配{{currentMatchLabel}}</text>
|
||
</block>
|
||
</view>
|
||
</view>
|
||
<text class="idle-mode">当前模式: {{selectedType === 'partner' ? '创业合伙' : (selectedType === 'investor' ? '资源对接' : (selectedType === 'mentor' ? '导师顾问' : '团队招募'))}}</text>
|
||
<view class="buy-tip" wx:if="{{!hasPurchased}}" bindtap="goToChapters">
|
||
<view class="buy-tip-left">
|
||
<text class="buy-tip-title">购买书籍解锁匹配功能</text>
|
||
<text class="buy-tip-desc">仅需9.9元,每天3次免费匹配</text>
|
||
</view>
|
||
<view class="btn-go-buy">去购买</view>
|
||
</view>
|
||
<view class="divider"></view>
|
||
<text class="type-label">选择匹配类型</text>
|
||
<view class="type-grid">
|
||
<view class="type-item {{selectedType === item.id ? 'active' : ''}}" wx:for="{{matchTypes}}" wx:key="id" data-id="{{item.id}}" bindtap="selectType">
|
||
<text class="type-icon">{{item.icon}}</text>
|
||
<text class="type-text">{{item.label}}</text>
|
||
</view>
|
||
</view>
|
||
</view>
|
||
</block>
|
||
|
||
<block wx:if="{{isMatching}}">
|
||
<view class="matching-wrap">
|
||
<view class="matching-spinner"></view>
|
||
<text class="matching-title">正在匹配{{currentMatchLabel}}...</text>
|
||
<text class="matching-count">已匹配 {{matchAttempts}} 次</text>
|
||
<view class="btn-cancel" bindtap="cancelMatch">取消匹配</view>
|
||
</view>
|
||
</block>
|
||
|
||
<block wx:if="{{currentMatch && !isMatching}}">
|
||
<view class="matched-wrap">
|
||
<text class="matched-emoji">✨</text>
|
||
<view class="matched-card">
|
||
<view class="matched-head">
|
||
<image class="matched-avatar" src="{{currentMatch.avatar || '/images/placeholder-user.jpg'}}" mode="aspectFill" />
|
||
<view class="matched-info">
|
||
<text class="matched-name">{{currentMatch.nickname}}</text>
|
||
<view class="matched-tags">
|
||
<text class="matched-tag" wx:for="{{currentMatch.tags}}" wx:key="*this" wx:for-item="tag">{{tag}}</text>
|
||
</view>
|
||
</view>
|
||
<view class="matched-score-wrap">
|
||
<text class="matched-score">{{currentMatch.matchScore}}%</text>
|
||
<text class="matched-score-label">匹配度</text>
|
||
</view>
|
||
</view>
|
||
<view class="matched-interests">
|
||
<text class="matched-label">共同兴趣</text>
|
||
<view class="interest-row" wx:for="{{currentMatch.commonInterests}}" wx:key="text">
|
||
<text class="interest-icon">{{item.icon}}</text>
|
||
<text class="interest-text">{{item.text}}</text>
|
||
</view>
|
||
</view>
|
||
<view class="matched-concept">
|
||
<text class="matched-label">核心理念</text>
|
||
<text class="matched-concept-text">{{currentMatch.concept}}</text>
|
||
</view>
|
||
</view>
|
||
<view class="btn-add-wechat" bindtap="addWechat">一键加好友</view>
|
||
<view class="btn-next" bindtap="nextMatch">重新匹配</view>
|
||
</view>
|
||
</block>
|
||
</block>
|
||
|
||
<view class="mask" wx:if="{{showUnlockModal}}" catchtap="closeUnlockModal">
|
||
<view class="modal unlock-modal" catchtap="">
|
||
<view class="modal-icon-wrap"><text class="modal-icon gold">⚡</text></view>
|
||
<text class="modal-title">匹配机会已用完</text>
|
||
<text class="modal-desc">每购买一个小节内容即可额外获得1次匹配机会</text>
|
||
<view class="modal-row"><text class="modal-row-label">解锁方式</text><text class="modal-row-value">购买任意小节</text></view>
|
||
<view class="modal-row"><text class="modal-row-label">获得次数</text><text class="modal-row-value brand">+1次匹配</text></view>
|
||
<view class="btn-primary" bindtap="goBuySection">去购买小节 (¥1/节)</view>
|
||
<view class="btn-ghost" bindtap="closeUnlockModal">明天再来</view>
|
||
</view>
|
||
</view>
|
||
|
||
<view class="mask" wx:if="{{showJoinModal}}" catchtap="closeJoinModal">
|
||
<view class="modal join-modal" catchtap="">
|
||
<view class="modal-head">
|
||
<text class="modal-head-title">加入{{joinType === 'partner' ? '创业伙伴' : (joinType === 'investor' ? '资源对接' : (joinType === 'mentor' ? '商业顾问' : '加入项目'))}}</text>
|
||
<view class="modal-close" bindtap="closeJoinModal">×</view>
|
||
</view>
|
||
<view class="modal-body" wx:if="{{!joinSuccess}}">
|
||
<text class="modal-hint">请填写您的联系方式以便我们联系您</text>
|
||
<view class="contact-tabs">
|
||
<view class="contact-tab {{contactType === 'phone' ? 'active' : ''}}" data-type="phone" bindtap="setContactType">手机号</view>
|
||
<view class="contact-tab {{contactType === 'wechat' ? 'active' : ''}}" data-type="wechat" bindtap="setContactType">微信号</view>
|
||
</view>
|
||
<view class="input-wrap" wx:if="{{contactType === 'phone'}}">
|
||
<input class="input" type="number" maxlength="11" placeholder="请输入11位手机号" value="{{phoneNumber}}" bindinput="onPhoneInput" />
|
||
</view>
|
||
<view class="input-wrap" wx:else>
|
||
<input class="input" placeholder="请输入微信号" value="{{wechatId}}" bindinput="onWechatInput" />
|
||
</view>
|
||
<text class="error-text" wx:if="{{joinError}}">{{joinError}}</text>
|
||
<view class="btn-primary {{(contactType === 'phone' ? !phoneNumber : !wechatId) || isJoining ? 'disabled' : ''}}" bindtap="submitJoin">{{isJoining ? '提交中...' : '确认加入'}}</view>
|
||
</view>
|
||
<view class="modal-body success-wrap" wx:else>
|
||
<text class="success-emoji">✓</text>
|
||
<text class="success-title">加入成功!</text>
|
||
<text class="success-desc">我们会尽快与您联系</text>
|
||
</view>
|
||
</view>
|
||
</view>
|
||
|
||
<view class="bottom-space"></view>
|
||
</view>
|