更新小程序配置,切换 API 地址为本地开发环境。新增会员详情页面的头像逻辑,确保用户信息展示一致性。优化多个页面的交互提示,提升用户体验。调整图标组件,更新图标映射以支持新样式。
This commit is contained in:
@@ -13,8 +13,8 @@ const DEFAULT_WITHDRAW_TMPL_ID = 'u3MbZGPRkrZIk-I7QdpwzFxnO_CeQPaCWF2FkiIablE'
|
||||
App({
|
||||
globalData: {
|
||||
// API 基础地址:开发时修改下面一行切换环境
|
||||
baseUrl: "https://soulapi.quwanzhi.com",
|
||||
// baseUrl: 'http://localhost:8080', // 开发
|
||||
// baseUrl: "https://soulapi.quwanzhi.com",
|
||||
baseUrl: 'http://localhost:8080', // 开发
|
||||
// baseUrl: 'https://souldev.quwanzhi.com', // 测试
|
||||
// 小程序配置 - 真实AppID
|
||||
appId: DEFAULT_APP_ID,
|
||||
|
||||
@@ -42,38 +42,127 @@ Component({
|
||||
},
|
||||
|
||||
methods: {
|
||||
// iconfont 映射:将业务 name(lucide 风格)映射到 iconfont 的 unicode(形如 "\ue6aa")
|
||||
// iconfont 映射:与 static/iconfont.wxss 一一对应(icon-xxx -> xxx)
|
||||
// 小程序不支持通过 :before { content } 渲染,因此必须直接输出 unicode 字符
|
||||
getFontGlyph(name) {
|
||||
const map = {
|
||||
// 基础高频(来自 static/iconfont.css 的 content 值)
|
||||
'wallet': '\ue6c8',
|
||||
// === 来自 iconfont.wxss 完整映射 ===
|
||||
'qianbao': '\ue6c8',
|
||||
'gift': '\ue6c9',
|
||||
'zap1': '\ue75c',
|
||||
'user': '\ue6b9',
|
||||
'upload': '\ue6ba',
|
||||
'work': '\ue6bb',
|
||||
'training': '\ue6bc',
|
||||
'warning': '\ue6bd',
|
||||
'zoom-in': '\ue6be',
|
||||
'zoom-out': '\ue6bf',
|
||||
'arrow-left-bold': '\ue6c1',
|
||||
'arrow-up-bold': '\ue6c2',
|
||||
'close-bold': '\ue6c3',
|
||||
'arrow-down-bold': '\ue6c4',
|
||||
'minus-bold': '\ue6c5',
|
||||
'arrow-right-bold': '\ue6c6',
|
||||
'select-bold': '\ue6c7',
|
||||
'money-wallet': '\ue833',
|
||||
'book-open': '\ue993',
|
||||
'biaoshilei_yonghuzu': '\ue61b',
|
||||
'add': '\ue664',
|
||||
'add-circle': '\ue665',
|
||||
'adjust': '\ue666',
|
||||
'arrow-up-circle': '\ue667',
|
||||
'arrow-right-circle': '\ue668',
|
||||
'arrow-down': '\ue669',
|
||||
'ashbin': '\ue66a',
|
||||
'arrow-right': '\ue66b',
|
||||
'browse': '\ue66c',
|
||||
'bottom': '\ue66d',
|
||||
'back': '\ue66e',
|
||||
'bad': '\ue66f',
|
||||
'arrow-left-circle': '\ue670',
|
||||
'camera': '\ue671',
|
||||
'chart-bar': '\ue672',
|
||||
'attachment': '\ue673',
|
||||
'code': '\ue674',
|
||||
'close': '\ue675',
|
||||
'check-item': '\ue676',
|
||||
'calendar': '\ue677',
|
||||
'comment': '\ue678',
|
||||
'complete': '\ue679',
|
||||
'direction-down': '\ue67a',
|
||||
'direction-down-circle': '\ue67b',
|
||||
'direction-right': '\ue67c',
|
||||
'direction-up': '\ue67d',
|
||||
'discount': '\ue67e',
|
||||
'electronics': '\ue681',
|
||||
'elipsis': '\ue682',
|
||||
'export': '\ue683',
|
||||
'explain': '\ue684',
|
||||
'edit': '\ue685',
|
||||
'eye-close': '\ue686',
|
||||
'email': '\ue687',
|
||||
'error': '\ue688',
|
||||
'favorite': '\ue689',
|
||||
'file-common': '\ue68a',
|
||||
'file-delete': '\ue68b',
|
||||
'file-add': '\ue68c',
|
||||
'film': '\ue68d',
|
||||
'fabulous': '\ue68e',
|
||||
'file': '\ue68f',
|
||||
'folder-close': '\ue690',
|
||||
'filter': '\ue691',
|
||||
'good': '\ue692',
|
||||
'hide': '\ue693',
|
||||
'home': '\ue694',
|
||||
'file-open': '\ue695',
|
||||
'forward': '\ue696',
|
||||
'import': '\ue697',
|
||||
'layers': '\ue698',
|
||||
'lock': '\ue699',
|
||||
'map': '\ue69a',
|
||||
'menu': '\ue69b',
|
||||
'help': '\ue69c',
|
||||
'minus-circle': '\ue69d',
|
||||
'notification': '\ue69e',
|
||||
'more': '\ue69f',
|
||||
'mobile-phone': '\ue6a0',
|
||||
'minus': '\ue6a1',
|
||||
'navigation': '\ue6a2',
|
||||
'prompt': '\ue6a3',
|
||||
'refresh': '\ue6a4',
|
||||
'run-up': '\ue6a5',
|
||||
'picture': '\ue6a6',
|
||||
'run-in': '\ue6a7',
|
||||
'pin': '\ue6a8',
|
||||
'save': '\ue6a9',
|
||||
'search': '\ue6aa',
|
||||
'share': '\ue6ab',
|
||||
'home': '\ue694',
|
||||
'lock': '\ue699',
|
||||
'camera': '\ue671',
|
||||
'warning': '\ue6bd',
|
||||
'scanning': '\ue6ac',
|
||||
'security': '\ue6ad',
|
||||
'sign-out': '\ue6ae',
|
||||
'select': '\ue6af',
|
||||
'stop': '\ue6b0',
|
||||
'success': '\ue6b1',
|
||||
'switch': '\ue6b2',
|
||||
'setting': '\ue6b3',
|
||||
'survey': '\ue6b4',
|
||||
'time': '\ue6b5',
|
||||
'telephone': '\ue6b6',
|
||||
'top': '\ue6b7',
|
||||
'unlock': '\ue6b8',
|
||||
|
||||
// 箭头/展开
|
||||
// === 业务别名(兼容 lucide 等命名)===
|
||||
'wallet': '\ue6c8',
|
||||
'chevron-left': '\ue6c1',
|
||||
'chevron-right': '\ue6c6',
|
||||
'chevron-down': '\ue6c4',
|
||||
'chevron-up': '\ue6c2',
|
||||
'arrow-up-right': '\ue6c2',
|
||||
|
||||
// 交互/状态
|
||||
'x': '\ue6c3',
|
||||
'check': '\ue6c7',
|
||||
'plus': '\ue664',
|
||||
'trash-2': '\ue66a',
|
||||
'pencil': '\ue685',
|
||||
'zap': '\ue75c',
|
||||
'info': '\ue69c',
|
||||
|
||||
// 语义近似映射(iconfont 不一定有同名)
|
||||
'map-pin': '\ue6a8',
|
||||
'message-circle': '\ue678',
|
||||
'smartphone': '\ue6a0',
|
||||
@@ -81,9 +170,6 @@ Component({
|
||||
'shield': '\ue6ad',
|
||||
'star': '\ue689',
|
||||
'heart': '\ue68e',
|
||||
|
||||
// 其他:若 iconfont 里不存在,则继续走 SVG 兜底
|
||||
'book-open': '\ue993',
|
||||
'bar-chart': '\ue672',
|
||||
'clock': '\ue6b5',
|
||||
}
|
||||
|
||||
@@ -38,18 +38,19 @@
|
||||
<!-- Banner卡片 - 最新章节(异步加载) -->
|
||||
<view class="banner-card" wx:if="{{latestSection}}" bindtap="goToRead" data-id="{{latestSection.id}}" data-mid="{{latestSection.mid}}">
|
||||
<view class="banner-glow"></view>
|
||||
<view class="banner-tag">最新更新</view>
|
||||
<view class="banner-tag">推荐</view>
|
||||
<view class="banner-title">{{latestSection.title}}</view>
|
||||
<view class="banner-action">
|
||||
<text class="banner-action-text">开始阅读</text>
|
||||
<icon name="chevron-right" size="32" color="#fff" customClass="banner-arrow"></icon>
|
||||
<text class="banner-action-text">点击阅读123</text>
|
||||
<icon name="direction-right" size="32" color="#00CED1" customClass="banner-arrow"></icon>
|
||||
</view>
|
||||
</view>
|
||||
<view class="banner-card banner-skeleton" wx:else bindtap="goToChapters">
|
||||
<view class="banner-glow"></view>
|
||||
<view class="banner-tag">最新更新</view>
|
||||
<view class="banner-tag">推荐</view>
|
||||
<view class="banner-title">加载中...</view>
|
||||
<view class="banner-action"><text class="banner-action-text">开始阅读</text><icon name="chevron-right" size="32" color="#fff" customClass="banner-arrow"></icon></view>
|
||||
<view class="banner-action"><text class="banner-action-text">点击阅读</text><icon name="direction-right" size="32" color="#00CED1" customClass="banner-arrow"></icon></view>
|
||||
|
||||
</view>
|
||||
|
||||
<!-- 超级个体(横向滚动,已去掉「查看全部」;审核模式隐藏) -->
|
||||
@@ -78,7 +79,7 @@
|
||||
>
|
||||
<view class="super-avatar {{item.isVip ? 'super-avatar-vip' : ''}}">
|
||||
<image class="super-avatar-img" wx:if="{{item.avatar}}" src="{{item.avatar}}" mode="aspectFill"/>
|
||||
<text class="super-avatar-text" wx:else>{{item.name[0] || '会'}}</text>
|
||||
<text class="super-avatar-text" wx:else>{{(item.name && item.name[0]) || '会'}}</text>
|
||||
</view>
|
||||
<text class="super-name">{{item.name}}</text>
|
||||
</view>
|
||||
@@ -87,7 +88,7 @@
|
||||
<!-- 已加载无数据 -->
|
||||
<view wx:else class="super-empty">
|
||||
<text class="super-empty-text">成为会员,展示你的项目</text>
|
||||
<view class="super-empty-btn" bindtap="goToVip">加入创业派对 <icon name="chevron-right" size="28" color="#00CED1" customClass="inline-arrow"></icon></view>
|
||||
<view class="super-empty-btn" bindtap="goToVip">加入创业派对 →</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
@@ -112,7 +113,7 @@
|
||||
<view class="featured-content">
|
||||
<view class="featured-meta">
|
||||
<text class="featured-id brand-color">{{item.id}}</text>
|
||||
<text class="featured-tag {{item.tagClass || 'tag-rec'}}">{{item.tag || '精选'}}</text>
|
||||
<text class="featured-tag {{item.tagClass || 'tag-rec'}}" wx:if="{{item.tag}}">{{item.tag}}</text>
|
||||
</view>
|
||||
<text class="featured-title">{{item.title}}</text>
|
||||
</view>
|
||||
@@ -142,13 +143,7 @@
|
||||
<view class="timeline-dot"></view>
|
||||
<view class="timeline-content">
|
||||
<view class="timeline-row">
|
||||
<view class="timeline-left">
|
||||
<text class="latest-new-tag">NEW</text>
|
||||
<text class="timeline-title">{{item.title}}</text>
|
||||
</view>
|
||||
<view class="timeline-right">
|
||||
<text class="timeline-price">¥{{item.price}}</text>
|
||||
</view>
|
||||
<text class="timeline-title">{{item.title}}</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
<view class="avatar-outer">
|
||||
<view class="avatar-wrap {{member.isVip ? 'vip-ring' : ''}}">
|
||||
<image class="avatar-img" wx:if="{{member.avatar}}" src="{{member.avatar}}" mode="aspectFill"/>
|
||||
<view class="avatar-ph" wx:else><text>{{member.name[0] || '创'}}</text></view>
|
||||
<view class="avatar-ph" wx:else><text>{{(member.name && member.name[0]) || '创'}}</text></view>
|
||||
</view>
|
||||
<view class="vip-tag" wx:if="{{member.isVip}}">VIP</view>
|
||||
</view>
|
||||
@@ -132,7 +132,7 @@
|
||||
<view class="bottom-wrap">
|
||||
<view class="btn-super" bindtap="goToVip">
|
||||
<text>成为超级个体</text>
|
||||
<icon name="chevron-right" size="36" color="#00CED1" customClass="btn-arrow"></icon>
|
||||
<icon name="chevron-right" size="36" color="#F59E0B" customClass="btn-arrow"></icon>
|
||||
</view>
|
||||
</view>
|
||||
<view style="height:160rpx;"></view>
|
||||
|
||||
@@ -429,9 +429,12 @@ Page({
|
||||
return
|
||||
}
|
||||
const d = res.data
|
||||
// 我的收益 = 累计佣金;我的余额 = 可提现金额(兼容 snake_case)
|
||||
const totalCommission = d.totalCommission ?? d.total_commission ?? 0
|
||||
const availableEarnings = d.availableEarnings ?? d.available_earnings ?? 0
|
||||
this.setData({
|
||||
earnings: formatMoney(d.totalCommission),
|
||||
pendingEarnings: formatMoney(d.availableEarnings),
|
||||
earnings: formatMoney(totalCommission),
|
||||
pendingEarnings: formatMoney(availableEarnings),
|
||||
referralCount: d.referralCount ?? this.data.referralCount,
|
||||
earningsLoading: false,
|
||||
earningsRefreshing: false
|
||||
|
||||
@@ -88,10 +88,7 @@
|
||||
</view>
|
||||
<view class="receive-bottom">
|
||||
<text class="receive-tip">将依次调起微信收款页完成领取</text>
|
||||
<view class="receive-link" bindtap="handleMenuTap" data-id="withdrawRecords">
|
||||
<text>查看提现记录</text>
|
||||
<icon name="chevron-right" size="24" color="rgba(255,255,255,0.6)" customClass="receive-link-arrow"></icon>
|
||||
</view>
|
||||
<text class="receive-link" bindtap="handleMenuTap" data-id="withdrawRecords">查看提现记录 ›</text>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
@@ -144,7 +141,7 @@
|
||||
</view>
|
||||
<view class="recent-empty" wx:else>
|
||||
<text class="recent-empty-text">暂无阅读记录</text>
|
||||
<view class="recent-empty-btn" bindtap="goToChapters">去阅读 <icon name="chevron-right" size="24" color="#00CED1" customClass="recent-empty-arrow"></icon></view>
|
||||
<view class="recent-empty-btn" bindtap="goToChapters">去阅读 →</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
@@ -200,7 +197,7 @@
|
||||
<view class="modal-overlay contact-modal-overlay" wx:if="{{showContactModal}}" bindtap="closeContactModal">
|
||||
<view class="contact-modal" catchtap="stopPropagation">
|
||||
<text class="contact-modal-title">请完善联系方式</text>
|
||||
<view class="contact-modal-hint">手机号必填,微信号建议填写,以便使用提现和找伙伴功能</view>
|
||||
<view class="contact-modal-hint">需完善手机号或微信号才能使用提现和找伙伴功能</view>
|
||||
<view class="form-input-wrap">
|
||||
<text class="form-label">手机号</text>
|
||||
<view class="form-input-inner">
|
||||
|
||||
@@ -134,7 +134,7 @@
|
||||
<view class="user-avatar {{item.status === 'converted' ? 'avatar-converted' : item.status === 'expired' ? 'avatar-expired' : ''}}">
|
||||
<icon wx:if="{{item.status === 'converted'}}" name="check" size="28" color="#34C759"></icon>
|
||||
<icon wx:elif="{{item.status === 'expired'}}" name="clock" size="28" color="#ff9500"></icon>
|
||||
<text wx:else>{{item.nickname[0] || '用'}}</text>
|
||||
<text wx:else>{{(item.nickname && item.nickname[0]) || '用'}}</text>
|
||||
</view>
|
||||
<view class="user-info">
|
||||
<text class="user-name">{{item.nickname || '匿名用户'}}</text>
|
||||
|
||||
@@ -4,23 +4,22 @@
|
||||
<view class="nav-back" bindtap="goBack">
|
||||
<icon name="chevron-left" size="44" color="#ffffff" customClass="back-icon"></icon>
|
||||
</view>
|
||||
<text class="nav-title">卡若创业派对</text>
|
||||
<text class="nav-title">卡若创业派对VIP会员</text>
|
||||
<view class="nav-placeholder-r"></view>
|
||||
</view>
|
||||
<view style="height: {{statusBarHeight + 44}}px;"></view>
|
||||
<!-- 会员宣传区(已去掉 VIP PREMIUM 标签) -->
|
||||
<view class="vip-hero {{isVip ? 'vip-hero-active' : ''}}">
|
||||
<view class="vip-hero-title">加入卡若的</view>
|
||||
<view class="vip-hero-title gold">创业派对 会员</view>
|
||||
<view class="vip-hero-title">加入卡若</view>
|
||||
<view class="vip-hero-title gold">创业派对 VIP会员</view>
|
||||
<text class="vip-hero-sub" wx:if="{{isVip}}">有效期至 {{expireDateStr}}(剩余{{daysRemaining}}天)</text>
|
||||
<text class="vip-hero-sub" wx:else>一次加入 尊享终身陪伴与成长</text>
|
||||
</view>
|
||||
<!-- 双列权益:内容权益 + 社交权益 -->
|
||||
<view class="rights-grid">
|
||||
<view class="rights-col">
|
||||
<view class="rights-col-header">
|
||||
<text class="rights-dot rights-dot-teal"></text>
|
||||
<text class="rights-col-title">内容权益</text>
|
||||
<text class="rights-col-title">会员权利</text>
|
||||
</view>
|
||||
<view class="benefit-card" wx:for="{{contentRights}}" wx:key="title">
|
||||
<icon name="{{item.icon || 'check'}}" size="40" color="#00CED1" customClass="benefit-icon"></icon>
|
||||
@@ -33,7 +32,7 @@
|
||||
<view class="rights-col">
|
||||
<view class="rights-col-header">
|
||||
<text class="rights-dot rights-dot-gold"></text>
|
||||
<text class="rights-col-title rights-col-title-gold">社交权益</text>
|
||||
<text class="rights-col-title rights-col-title-gold">派对权利</text>
|
||||
</view>
|
||||
<view class="benefit-card" wx:for="{{socialRights}}" wx:key="title">
|
||||
<icon name="{{item.icon || 'check'}}" size="40" color="#FFD700" customClass="benefit-icon benefit-icon-gold"></icon>
|
||||
@@ -47,7 +46,7 @@
|
||||
<!-- 底部固定购买按钮(非 VIP 时显示,用 view 避让 button 默认 margin) -->
|
||||
<view class="buy-footer" wx:if="{{!isVip}}">
|
||||
<view class="buy-btn-fixed {{purchasing ? 'buy-btn-disabled' : ''}}" bindtap="handlePurchase">
|
||||
{{purchasing ? "处理中..." : "¥" + price + "/年 加入创业派对"}}
|
||||
{{purchasing ? "处理中..." : "立即支付" + price + "元 加入创业派对"}}
|
||||
</view>
|
||||
</view>
|
||||
|
||||
|
||||
@@ -23,12 +23,19 @@
|
||||
"condition": {
|
||||
"miniprogram": {
|
||||
"list": [
|
||||
{
|
||||
"name": "pages/member-detail/member-detail",
|
||||
"pathName": "pages/member-detail/member-detail",
|
||||
"query": "id=ogpTW5cVMxd5afBBtXdvmeMO8aho",
|
||||
"scene": null,
|
||||
"launchMode": "default"
|
||||
},
|
||||
{
|
||||
"name": "pages/my/my",
|
||||
"pathName": "pages/my/my",
|
||||
"query": "",
|
||||
"scene": null,
|
||||
"launchMode": "default"
|
||||
"launchMode": "default",
|
||||
"scene": null
|
||||
},
|
||||
{
|
||||
"name": "个人资料",
|
||||
|
||||
Reference in New Issue
Block a user