添加tabbar及分类

This commit is contained in:
2026-03-23 12:00:28 +08:00
parent b9a48478b9
commit 9efd2bc3a3
332 changed files with 1438 additions and 467 deletions

View File

@@ -1,31 +1,300 @@
mp.esm.js:485 获取订单失败: UniError: request:fail url not in domain list
at new UniError2 (weapp:///http://127.0.0.1:54647/appservice/common/vendor.js?t=wechat&s=1774227639281&v=b23e154…:8560:5)
at fail (weapp:///http://127.0.0.1:54647/appservice/uni_modules/ak-req/ak-req.js?t=wechat&s=1774227639281&v=e613582…:296:114)
at weapp:///http://127.0.0.1:54647/appservice/common/vendor.js?t=wechat&s=1774227639281&v=b23e154…:6764:14
at Object.<anonymous> (http://127.0.0.1:54647/appservice/__dev__/WASubContext.js?t=wechat&v=3.14.2:1:142860)
at Object.<anonymous> (http://127.0.0.1:54647/appservice/__dev__/WASubContext.js?t=wechat&v=3.14.2:1:143133)
at http://127.0.0.1:54647/appservice/__dev__/WAServiceMainContext.js?t=wechat&v=3.14.2:1:2636686
at Module.jn (http://127.0.0.1:54647/appservice/__dev__/WASubContext.js?t=wechat&v=3.14.2:1:354029)
at Kke (http://127.0.0.1:54647/appservice/__dev__/WAServiceMainContext.js?t=wechat&v=3.14.2:1:2636666)
at Object.fail (http://127.0.0.1:54647/appservice/__dev__/WAServiceMainContext.js?t=wechat&v=3.14.2:1:2636727)
at Object.forEach.h.<computed> [as fail] (http://127.0.0.1:54647/appservice/__dev__/WAServiceMainContext.js?t=wechat&v=3.14.2:1:1541122)
(env: Windows,mp,1.06.2504030; lib: 3.14.2)
(anonymous) @ mp.esm.js:485
__f__ @ uni.api.esm.js:591
_callee2$ @ orders.uvue:338
s @ regeneratorRuntime.js?forceSync=true:1
(anonymous) @ regeneratorRuntime.js?forceSync=true:1
(anonymous) @ regeneratorRuntime.js?forceSync=true:1
fulfilled @ tslib.es6.js:73
Promise.then (async)
step @ tslib.es6.js:75
(anonymous) @ tslib.es6.js:76
__awaiter @ tslib.es6.js:72
loadOrders @ orders.uvue:295
switchTab @ orders.uvue:465
(anonymous) @ orders.uvue:622
callWithErrorHandling @ vue.runtime.esm.js:1356
callWithAsyncErrorHandling @ vue.runtime.esm.js:1363
invoke @ vue.runtime.esm.js:6108
setTimeout (async)
invoker
编译 pages/mall/merchant/exclusive-discounts.wxss
编译 pages/mall/merchant/exclusive-discounts.wxss
编译 pages/mall/merchant/profile.wxss
编译 pages/mall/merchant/profile.wxss
getDevCodeByFileList-miniProgram
编译 pages/mall/merchant/index.js
编译 pages/mall/merchant/index.js
getDevCodeByFileList-miniProgram
编译 pages/mall/merchant/orders.js
编译 pages/mall/merchant/orders.js
编译 app.json
编译 ext.json
编译 246 个页面json文件
getDevCodeByFileList-miniProgram
getDevCodeByFileList-miniProgram
getDevCodeByFileList-miniProgram
getDevCodeByFileList-miniProgram
getDevCodeByFileList-miniProgram
getDevCodeByFileList-miniProgram
getDevCodeByFileList-miniProgram
getDevCodeByFileList-miniProgram
getDevCodeByFileList-miniProgram
getDevCodeByFileList-miniProgram
getDevCodeByFileList-miniProgram
getDevCodeByFileList-miniProgram
getDevCodeByFileList-miniProgram
getDevCodeByFileList-miniProgram
getDevCodeByFileList-miniProgram
Cannot read properties of undefined (reading 'functionalPages')
Compile app.json
Cannot read properties of undefined (reading 'functionalPages')
Cannot read properties of undefined (reading 'functionalPages')
Cannot read properties of undefined (reading 'functionalPages')
Cannot read properties of undefined (reading 'functionalPages')
Cannot read properties of undefined (reading 'functionalPages')
Cannot read properties of undefined (reading 'functionalPages')
Cannot read properties of undefined (reading 'functionalPages')
Cannot read properties of undefined (reading 'functionalPages')
Cannot read properties of undefined (reading 'functionalPages')
Cannot read properties of undefined (reading 'functionalPages')
Cannot read properties of undefined (reading 'functionalPages')
Cannot read properties of undefined (reading 'functionalPages')
Cannot read properties of undefined (reading 'functionalPages')
Cannot read properties of undefined (reading 'functionalPages')
Compile ext.json
Compile json files of 246 pages
analyzing codes...
ignoring files: project.private.config.json,uni_modules/charts/EChartsView2.js,layouts/admin/components/PlaceholderPage.wxml,layouts/admin/pages/HomeIndex.wxml,components/analytics/AnalyticsAreaChart.js,pages/mall/admin/homePage/components/KpiMiniCard.js,pages/mall/admin/decoration/components/types.js,uni_modules/ak-req/index.js,pages/mall/admin/homePage/components/KpiMiniCard.wxss,components/analytics/AnalyticsAreaChart.wxss,components/analytics/AnalyticsAreaChart.json,pages/mall/admin/homePage/components/KpiMiniCard.json,pages/mall/admin/product/product-management/components/edit.wxml,pages/mall/admin/product/product-management/components/member-price.wxml,pages/mall/admin/homePage/components/KpiMiniCard.wxml,components/analytics/AnalyticsAreaChart.wxml
analyzing codes success
Ignored by code analyzer: project.private.config.json,uni_modules/charts/EChartsView2.js,layouts/admin/components/PlaceholderPage.wxml,layouts/admin/pages/HomeIndex.wxml,components/analytics/AnalyticsAreaChart.js,pages/mall/admin/homePage/components/KpiMiniCard.js,pages/mall/admin/decoration/components/types.js,uni_modules/ak-req/index.js,pages/mall/admin/homePage/components/KpiMiniCard.wxss,components/analytics/AnalyticsAreaChart.wxss,components/analytics/AnalyticsAreaChart.json,pages/mall/admin/homePage/components/KpiMiniCard.json,pages/mall/admin/product/product-management/components/edit.wxml,pages/mall/admin/product/product-management/components/member-price.wxml,pages/mall/admin/homePage/components/KpiMiniCard.wxml,components/analytics/AnalyticsAreaChart.wxml
analyzing codes...
ignoring files: project.private.config.json,uni_modules/charts/EChartsView2.js,layouts/admin/components/PlaceholderPage.wxml,layouts/admin/pages/HomeIndex.wxml,components/analytics/AnalyticsAreaChart.js,pages/mall/admin/homePage/components/KpiMiniCard.js,pages/mall/admin/decoration/components/types.js,uni_modules/ak-req/index.js,pages/mall/admin/homePage/components/KpiMiniCard.wxss,components/analytics/AnalyticsAreaChart.wxss,components/analytics/AnalyticsAreaChart.json,pages/mall/admin/homePage/components/KpiMiniCard.json,pages/mall/admin/product/product-management/components/edit.wxml,pages/mall/admin/product/product-management/components/member-price.wxml,pages/mall/admin/homePage/components/KpiMiniCard.wxml,components/analytics/AnalyticsAreaChart.wxml
analyzing codes success
analyzing codes...
ignoring files: project.private.config.json,uni_modules/charts/EChartsView2.js,layouts/admin/components/PlaceholderPage.wxml,layouts/admin/pages/HomeIndex.wxml,components/analytics/AnalyticsAreaChart.js,pages/mall/admin/homePage/components/KpiMiniCard.js,pages/mall/admin/decoration/components/types.js,uni_modules/ak-req/index.js,pages/mall/admin/homePage/components/KpiMiniCard.wxss,components/analytics/AnalyticsAreaChart.wxss,components/analytics/AnalyticsAreaChart.json,pages/mall/admin/homePage/components/KpiMiniCard.json,pages/mall/admin/product/product-management/components/edit.wxml,pages/mall/admin/product/product-management/components/member-price.wxml,pages/mall/admin/homePage/components/KpiMiniCard.wxml,components/analytics/AnalyticsAreaChart.wxml
analyzing codes success
Ignored by code analyzer: project.private.config.json,uni_modules/charts/EChartsView2.js,layouts/admin/components/PlaceholderPage.wxml,layouts/admin/pages/HomeIndex.wxml,components/analytics/AnalyticsAreaChart.js,pages/mall/admin/homePage/components/KpiMiniCard.js,uni_modules/ak-req/index.js,pages/mall/admin/homePage/components/KpiMiniCard.wxss,components/analytics/AnalyticsAreaChart.wxss,components/analytics/AnalyticsAreaChart.json,pages/mall/admin/homePage/components/KpiMiniCard.json,pages/mall/admin/homePage/components/KpiMiniCard.wxml,components/analytics/AnalyticsAreaChart.wxml
getDevCodeByFileList-miniProgram
Compiling layouts/admin/AdminLayout.wxml
Compiling layouts/admin/AdminLayout.wxml
Compiling layouts/admin/components/AdminAside.wxml
Compiling layouts/admin/components/AdminAside.wxml
Compiling layouts/admin/components/AdminFooter.wxml
Compiling layouts/admin/components/AdminFooter.wxml
Compiling layouts/admin/components/AdminHeader.wxml
Compiling layouts/admin/components/AdminHeader.wxml
Compiling layouts/admin/components/AdminPageLoading.wxml
Compiling layouts/admin/components/AdminPageLoading.wxml
Compiling layouts/admin/components/AdminSubSider.wxml
Compiling layouts/admin/components/AdminSubSider.wxml
Compiling layouts/admin/components/AdminTagsView.wxml
Compiling layouts/admin/components/AdminTagsView.wxml
Compiling common/uniView.wxs
Compiling common/uniView.wxs
Compiling pages/user/boot.wxml
Compiling pages/user/boot.wxml
Compiling pages/user/login.wxml
Compiling pages/user/login.wxml
Compiling pages/mall/admin/homePage/index.wxml
Compiling pages/mall/admin/homePage/index.wxml
Compiling pages/user/terms.wxml
Compiling pages/user/terms.wxml
Compiling pages/user/register.wxml
Compiling pages/user/register.wxml
Compiling pages/user/forgot-password.wxml
Compiling pages/user/forgot-password.wxml
Compiling pages/mall/admin/userCenter/index.wxml
Compiling pages/mall/admin/userCenter/index.wxml
Compiling pages/user/center.wxml
Compiling pages/user/center.wxml
Compiling pages/user/profile.wxml
Compiling pages/user/profile.wxml
Compiling pages/user/change-password.wxml
Compiling pages/user/change-password.wxml
Compiling pages/user/bind-phone.wxml
Compiling pages/user/bind-phone.wxml
Compiling pages/main/index.wxml
Compiling pages/main/index.wxml
Compiling pages/user/bind-email.wxml
Compiling pages/user/bind-email.wxml
Compiling pages/main/messages.wxml
Compiling pages/main/messages.wxml
Compiling pages/main/category.wxml
Compiling pages/main/category.wxml
Compiling pages/main/cart.wxml
Compiling pages/main/cart.wxml
Compiling pages/main/profile.wxml
Compiling pages/main/profile.wxml
Compiling pages/mall/merchant/index.wxml
Compiling pages/mall/merchant/index.wxml
Compiling pages/mall/merchant/orders.wxml
Compiling pages/mall/merchant/orders.wxml
Compiling pages/mall/merchant/order-detail.wxml
Compiling pages/mall/merchant/order-detail.wxml
Compiling pages/mall/merchant/products.wxml
Compiling pages/mall/merchant/products.wxml
Compiling pages/mall/merchant/product-edit.wxml
Compiling pages/mall/merchant/product-edit.wxml
Compiling pages/mall/merchant/product-detail.wxml
Compiling pages/mall/merchant/product-detail.wxml
Compiling pages/mall/merchant/inventory.wxml
Compiling pages/mall/merchant/inventory.wxml
Compiling pages/mall/merchant/reviews.wxml
Compiling pages/mall/merchant/reviews.wxml
Compiling pages/mall/merchant/messages.wxml
Compiling pages/mall/merchant/messages.wxml
Compiling pages/mall/merchant/shop-edit.wxml
Compiling pages/mall/merchant/shop-edit.wxml
Compiling pages/mall/merchant/promotions.wxml
Compiling pages/mall/merchant/promotions.wxml
Compiling pages/mall/merchant/statistics.wxml
Compiling pages/mall/merchant/statistics.wxml
Compiling pages/mall/merchant/finance.wxml
Compiling pages/mall/merchant/finance.wxml
Compiling pages/mall/merchant/members.wxml
Compiling pages/mall/merchant/members.wxml
Compiling pages/mall/merchant/chat.wxml
Compiling pages/mall/merchant/chat.wxml
Compiling pages/mall/merchant/exclusive-discounts.wxml
Compiling pages/mall/merchant/exclusive-discounts.wxml
Compiling pages/mall/merchant/profile.wxml
Compiling pages/mall/merchant/profile.wxml
Compiling components/CommonPagination/CommonPagination.wxml
Compiling components/CommonPagination/CommonPagination.wxml
Compiling components/StatusSwitch.wxml
Compiling components/StatusSwitch.wxml
Compiling uni_modules/charts/EChartsView.wxml
Compiling uni_modules/charts/EChartsView.wxml
Compiling components/analytics/AnalyticsSidebarMenu.wxml
Compiling components/analytics/AnalyticsSidebarMenu.wxml
Compiling components/analytics/AnalyticsTopBar.wxml
Compiling components/analytics/AnalyticsTopBar.wxml
Compiling components/analytics/AnalyticsDateRangePicker.wxml
Compiling components/analytics/AnalyticsDateRangePicker.wxml
Compiling components/analytics/AnalyticsMultiLineChart.wxml
Compiling components/analytics/AnalyticsMultiLineChart.wxml
Compiling components/analytics/AnalyticsUserGenderSection.wxml
Compiling components/analytics/AnalyticsUserGenderSection.wxml
Compiling components/analytics/AnalyticsUserMapTable.wxml
Compiling components/analytics/AnalyticsUserMapTable.wxml
Compiling components/analytics/AnalyticsPieChart.wxml
Compiling components/analytics/AnalyticsPieChart.wxml
Compiling components/analytics/AnalyticsComboChart.wxml
Compiling components/analytics/AnalyticsComboChart.wxml
Compiling components/analytics/AnalyticsRegionMap.wxml
Compiling components/analytics/AnalyticsRegionMap.wxml
getDevCodeByFileList-miniProgram
Compiling layouts/admin/AdminLayout.wxss
Compiling layouts/admin/AdminLayout.wxss
Compiling layouts/admin/components/AdminAside.wxss
Compiling layouts/admin/components/AdminAside.wxss
Compiling layouts/admin/components/AdminFooter.wxss
Compiling layouts/admin/components/AdminFooter.wxss
Compiling layouts/admin/components/AdminHeader.wxss
Compiling layouts/admin/components/AdminHeader.wxss
Compiling layouts/admin/components/AdminPageLoading.wxss
Compiling layouts/admin/components/AdminPageLoading.wxss
Compiling layouts/admin/components/AdminSubSider.wxss
Compiling layouts/admin/components/AdminSubSider.wxss
Compiling layouts/admin/components/AdminTagsView.wxss
Compiling layouts/admin/components/AdminTagsView.wxss
Compiling pages/mall/merchant/index.wxss
Compiling pages/mall/merchant/index.wxss
Compiling pages/mall/merchant/orders.wxss
Compiling pages/mall/merchant/orders.wxss
Compiling pages/mall/merchant/order-detail.wxss
Compiling pages/mall/merchant/order-detail.wxss
Compiling pages/mall/merchant/products.wxss
Compiling pages/mall/merchant/products.wxss
Compiling pages/mall/merchant/product-detail.wxss
Compiling pages/mall/merchant/product-detail.wxss
Compiling pages/mall/merchant/product-edit.wxss
Compiling pages/mall/merchant/product-edit.wxss
Compiling pages/mall/merchant/messages.wxss
Compiling pages/mall/merchant/messages.wxss
Compiling pages/mall/merchant/reviews.wxss
Compiling pages/mall/merchant/reviews.wxss
Compiling pages/mall/merchant/inventory.wxss
Compiling pages/mall/merchant/inventory.wxss
Compiling pages/mall/merchant/shop-edit.wxss
Compiling pages/mall/merchant/shop-edit.wxss
Compiling pages/mall/merchant/promotions.wxss
Compiling pages/mall/merchant/promotions.wxss
Compiling pages/mall/merchant/finance.wxss
Compiling pages/mall/merchant/finance.wxss
Compiling pages/mall/merchant/statistics.wxss
Compiling pages/mall/merchant/statistics.wxss
Compiling pages/mall/merchant/members.wxss
Compiling pages/mall/merchant/members.wxss
Compiling pages/mall/merchant/chat.wxss
Compiling pages/mall/merchant/chat.wxss
Compiling pages/mall/merchant/exclusive-discounts.wxss
Compiling pages/mall/merchant/exclusive-discounts.wxss
Compiling pages/mall/merchant/profile.wxss
Compiling pages/mall/merchant/profile.wxss
Compiling components/analytics/AnalyticsComboChart.wxss
Compiling components/analytics/AnalyticsComboChart.wxss
Compiling components/analytics/AnalyticsSidebarMenu.wxss
Compiling components/analytics/AnalyticsSidebarMenu.wxss
Compiling components/analytics/AnalyticsDateRangePicker.wxss
Compiling components/analytics/AnalyticsDateRangePicker.wxss
Compiling components/analytics/AnalyticsTopBar.wxss
Compiling components/analytics/AnalyticsTopBar.wxss
Compiling uni_modules/charts/EChartsView.wxss
Compiling uni_modules/charts/EChartsView.wxss
Compiling components/analytics/AnalyticsRegionMap.wxss
Compiling components/analytics/AnalyticsRegionMap.wxss
Compiling components/CommonPagination/CommonPagination.wxss
Compiling components/CommonPagination/CommonPagination.wxss
Compiling components/StatusSwitch.wxss
Compiling components/StatusSwitch.wxss
Compiling components/analytics/AnalyticsMultiLineChart.wxss
Compiling components/analytics/AnalyticsMultiLineChart.wxss
Compiling components/analytics/AnalyticsUserMapTable.wxss
Compiling components/analytics/AnalyticsUserMapTable.wxss
Compiling components/analytics/AnalyticsUserGenderSection.wxss
Compiling components/analytics/AnalyticsUserGenderSection.wxss
Compiling components/analytics/AnalyticsPieChart.wxss
Compiling components/analytics/AnalyticsPieChart.wxss
Compiling uvue.wxss
Compiling uvue.wxss
Compiling app.wxss
Compiling app.wxss
Compiling pages/user/boot.wxss
Compiling pages/user/boot.wxss
Compiling pages/user/login.wxss
Compiling pages/user/login.wxss
Compiling pages/mall/admin/homePage/index.wxss
Compiling pages/mall/admin/homePage/index.wxss
Compiling pages/user/register.wxss
Compiling pages/user/register.wxss
Compiling pages/mall/admin/userCenter/index.wxss
Compiling pages/mall/admin/userCenter/index.wxss
Compiling pages/user/forgot-password.wxss
Compiling pages/user/forgot-password.wxss
Compiling pages/user/terms.wxss
Compiling pages/user/terms.wxss
Compiling pages/user/center.wxss
Compiling pages/user/center.wxss
Compiling pages/user/profile.wxss
Compiling pages/user/profile.wxss
Compiling pages/user/change-password.wxss
Compiling pages/user/change-password.wxss
Compiling pages/user/bind-phone.wxss
Compiling pages/user/bind-phone.wxss
Compiling pages/main/index.wxss
Compiling pages/main/index.wxss
Compiling pages/user/bind-email.wxss
Compiling pages/user/bind-email.wxss
Compiling pages/main/category.wxss
Compiling pages/main/category.wxss
Compiling pages/main/messages.wxss
Compiling pages/main/messages.wxss
Compiling pages/main/cart.wxss
Compiling pages/main/cart.wxss
Compiling pages/main/profile.wxss
Compiling pages/main/profile.wxss
getDevCodeByFileList-miniProgram
Compiling app.js
Compiling app.js
getDevCodeByFileList-miniProgram
Compiling pages/mall/merchant/orders.js
Compiling pages/mall/merchant/orders.js
getDevCodeByFileList-miniProgram
Compiling pages/mall/merchant/inventory.js
Compiling pages/mall/merchant/inventory.js
getDevCodeByFileList-miniProgram
Compiling pages/mall/merchant/promotions.js
Compiling pages/mall/merchant/promotions.js
getDevCodeByFileList-miniProgram
Compiling pages/mall/merchant/products.js
Compiling pages/mall/merchant/products.js
getDevCodeByFileList-miniProgram
Compile app.json
app.json: app.json is not found in the project root directory
app.json: app.json is not found in the project root directory
Compile app.json
app.json: ["pages"][17]: "pages/mall/merchant/index" Should not exist in ["subPackages"][17] ["pages"][18]: "pages/mall/merchant/messages" Should not exist in ["subPackages"][17] ["pages"][19]: "pages/mall/merchant/orders" Should not exist in ["subPackages"][17] ["pages"][20]: "pages/mall/merchant/growth" Should not exist in ["subPackages"][17] ["pages"][21]: "pages/mall/merchant/profile" Should not exist in ["subPackages"][17]
Compile app.json
app.json: ["pages"][17]: "pages/mall/merchant/index" Should not exist in ["subPackages"][17] ["pages"][18]: "pages/mall/merchant/messages" Should not exist in ["subPackages"][17] ["pages"][19]: "pages/mall/merchant/orders" Should not exist in ["subPackages"][17] ["pages"][20]: "pages/mall/merchant/growth" Should not exist in ["subPackages"][17] ["pages"][21]: "pages/mall/merchant/profile" Should not exist in ["subPackages"][17]

View File

@@ -0,0 +1,709 @@
<!-- 商家端 - 成长页Tab4经营指南、流量获取方法、店铺经营建议、学习入口 -->
<template>
<view class="growth-page">
<!-- #ifdef MP-WEIXIN -->
<!-- Tab 页无返回按钮,显示顶部安全区 + 页面标题 -->
<view class="mp-tab-navbar">
<text class="mp-tab-title">成长</text>
</view>
<!-- #endif -->
<scroll-view direction="vertical" class="growth-scroll" :refresher-enabled="true" :refresher-triggered="refreshing" @refresherrefresh="onRefresh">
<!-- 成长等级卡片 -->
<view class="level-card">
<view class="level-header">
<view class="level-info">
<text class="level-label">商家成长等级</text>
<view class="level-badge">
<text class="level-text">{{ currentLevel.name }}</text>
</view>
</view>
<text class="level-icon">{{ currentLevel.icon }}</text>
</view>
<view class="level-progress-wrap">
<view class="level-progress-bar">
<view class="level-progress-fill" :style="{ width: currentLevel.progress + '%' }"></view>
</view>
<text class="level-progress-text">{{ currentLevel.progress }}% · 距下一级还需 {{ currentLevel.nextTarget }}</text>
</view>
<view class="level-tips">
<text class="level-tips-text">完善店铺信息、上传商品、获得订单可提升等级</text>
</view>
</view>
<!-- 流量获取方法 -->
<view class="section-card">
<view class="section-header">
<text class="section-title">📈 流量获取方法</text>
</view>
<view class="tips-list">
<view
v-for="(tip, index) in trafficTips"
:key="index"
class="tip-item"
@click="viewDetail(tip)"
>
<view class="tip-icon-wrap" :style="{ backgroundColor: tip.color + '22' }">
<text class="tip-icon">{{ tip.icon }}</text>
</view>
<view class="tip-content">
<text class="tip-title">{{ tip.title }}</text>
<text class="tip-desc">{{ tip.desc }}</text>
</view>
<text class="tip-arrow"></text>
</view>
</view>
</view>
<!-- 经营指南 -->
<view class="section-card">
<view class="section-header">
<text class="section-title">📋 经营指南</text>
</view>
<view class="guide-grid">
<view
v-for="(guide, index) in operationGuides"
:key="index"
class="guide-item"
@click="viewDetail(guide)"
>
<text class="guide-icon">{{ guide.icon }}</text>
<text class="guide-title">{{ guide.title }}</text>
</view>
</view>
</view>
<!-- 店铺经营建议 -->
<view class="section-card">
<view class="section-header">
<text class="section-title">💡 今日经营建议</text>
</view>
<view class="suggestion-list">
<view
v-for="(suggestion, index) in suggestions"
:key="index"
class="suggestion-item"
:class="{ done: suggestion.done }"
@click="toggleSuggestion(index)"
>
<view class="suggestion-check">
<text class="check-icon">{{ suggestion.done ? '✅' : '⬜' }}</text>
</view>
<view class="suggestion-content">
<text class="suggestion-title">{{ suggestion.title }}</text>
<text class="suggestion-desc">{{ suggestion.desc }}</text>
</view>
<view class="suggestion-tag" :style="{ backgroundColor: suggestion.tagColor + '22', color: suggestion.tagColor }">
<text class="tag-text">{{ suggestion.tag }}</text>
</view>
</view>
</view>
</view>
<!-- 学习中心入口 -->
<view class="section-card">
<view class="section-header">
<text class="section-title">🎓 学习中心</text>
</view>
<view class="learn-list">
<view
v-for="(course, index) in learnCourses"
:key="index"
class="learn-item"
@click="viewDetail(course)"
>
<view class="learn-cover">
<text class="learn-cover-icon">{{ course.icon }}</text>
</view>
<view class="learn-info">
<text class="learn-title">{{ course.title }}</text>
<text class="learn-subtitle">{{ course.subtitle }}</text>
<view class="learn-meta">
<text class="learn-tag">{{ course.tag }}</text>
<text class="learn-duration">{{ course.duration }}</text>
</view>
</view>
</view>
</view>
</view>
<!-- 底部安全区(覆盖 tabbar -->
<view class="safe-bottom"></view>
</scroll-view>
<!-- 商家端自定义 TabBar -->
<merchant-tab-bar :current="3"></merchant-tab-bar>
</view>
</template>
<script lang="uts">
import MerchantTabBar from '@/components/merchant-tabbar/MerchantTabBar.uvue'
type TipType = {
icon: string
title: string
desc: string
color: string
link: string
}
type GuideType = {
icon: string
title: string
link: string
}
type SuggestionType = {
title: string
desc: string
tag: string
tagColor: string
done: boolean
}
type CourseType = {
icon: string
title: string
subtitle: string
tag: string
duration: string
link: string
}
type LevelType = {
name: string
icon: string
progress: number
nextTarget: string
}
export default {
components: {
MerchantTabBar
},
data() {
return {
refreshing: false,
currentLevel: {
name: '新手商家',
icon: '🌱',
progress: 30,
nextTarget: '上传满5件商品'
} as LevelType,
trafficTips: [
{
icon: '🏷️',
title: '优化商品标题关键词',
desc: '精准标题可提升搜索曝光量 3-5 倍',
color: '#ff5000',
link: ''
},
{
icon: '📷',
title: '提升主图吸引力',
desc: '高质量主图点击率提升 40% 以上',
color: '#007AFF',
link: ''
},
{
icon: '💰',
title: '设置限时优惠活动',
desc: '促销期间订单量平均提升 60%',
color: '#34C759',
link: ''
},
{
icon: '⭐',
title: '维护好评率',
desc: '好评率 >95% 可获得平台推荐流量',
color: '#FF9500',
link: ''
},
{
icon: '📢',
title: '参与平台活动',
desc: '报名活动可获得额外曝光位置',
color: '#AF52DE',
link: ''
}
] as TipType[],
operationGuides: [
{ icon: '🛒', title: '商品管理', link: '/pages/mall/merchant/products' },
{ icon: '📦', title: '库存优化', link: '/pages/mall/merchant/inventory' },
{ icon: '🎯', title: '营销策略', link: '/pages/mall/merchant/promotions' },
{ icon: '💬', title: '客服技巧', link: '/pages/mall/merchant/chat' },
{ icon: '📊', title: '数据解读', link: '/pages/mall/merchant/statistics' },
{ icon: '💳', title: '财务管理', link: '/pages/mall/merchant/finance' }
] as GuideType[],
suggestions: [
{
title: '完善店铺基础信息',
desc: '补充店铺 Logo、简介、联系方式',
tag: '紧急',
tagColor: '#ff3b30',
done: false
},
{
title: '上传至少3件在售商品',
desc: '充足商品是获得流量的基础',
tag: '重要',
tagColor: '#ff9500',
done: false
},
{
title: '回复所有待回评价',
desc: '及时回复可提升用户信任度',
tag: '今日',
tagColor: '#007aff',
done: false
},
{
title: '检查低库存商品',
desc: '库存不足会导致订单自动取消',
tag: '常规',
tagColor: '#34c759',
done: false
}
] as SuggestionType[],
learnCourses: [
{
icon: '🚀',
title: '新手商家开店必读',
subtitle: '5分钟掌握开店核心流程',
tag: '入门',
duration: '5 分钟',
link: ''
},
{
icon: '📸',
title: '商品主图拍摄技巧',
subtitle: '用手机也能拍出专业大片',
tag: '进阶',
duration: '8 分钟',
link: ''
},
{
icon: '📣',
title: '营销活动策划方法',
subtitle: '节假日爆单秘诀全攻略',
tag: '进阶',
duration: '12 分钟',
link: ''
},
{
icon: '💬',
title: '提升客服转化率',
subtitle: '用话术留住每一位询问客户',
tag: '实战',
duration: '10 分钟',
link: ''
}
] as CourseType[]
}
},
onShow() {
// 预留:后续可对接成长等级接口
},
methods: {
onRefresh() {
this.refreshing = true
// 预留:刷新成长数据
setTimeout(() => {
this.refreshing = false
}, 1000)
},
toggleSuggestion(index: number) {
this.suggestions[index].done = !this.suggestions[index].done
},
viewDetail(item: TipType | GuideType | CourseType) {
if (item.link && item.link.length > 0) {
uni.navigateTo({ url: item.link })
} else {
uni.showToast({ title: '内容即将上线,敬请期待', icon: 'none' })
}
}
}
}
</script>
<style>
.growth-page {
background-color: #f5f7fa;
min-height: 100vh;
}
/* 微信小程序 Tab 页顶部导航 */
.mp-tab-navbar {
height: calc(88rpx + var(--status-bar-height));
padding-top: var(--status-bar-height);
background-color: #ffffff;
display: flex;
flex-direction: row;
align-items: center;
justify-content: center;
border-bottom-width: 1rpx;
border-bottom-style: solid;
border-bottom-color: #f0f0f0;
}
.mp-tab-title {
font-size: 34rpx;
font-weight: bold;
color: #333333;
}
.growth-scroll {
flex: 1;
padding: 24rpx;
}
/* 成长等级卡片 */
.level-card {
background: linear-gradient(135deg, #ff6b35 0%, #ff8c5a 100%);
border-radius: 24rpx;
padding: 36rpx 32rpx;
margin-bottom: 24rpx;
box-shadow: 0 8rpx 24rpx rgba(255, 107, 53, 0.3);
}
.level-header {
display: flex;
flex-direction: row;
align-items: center;
justify-content: space-between;
margin-bottom: 28rpx;
}
.level-info {
display: flex;
flex-direction: column;
}
.level-label {
font-size: 26rpx;
color: rgba(255, 255, 255, 0.8);
margin-bottom: 10rpx;
}
.level-badge {
background-color: rgba(255, 255, 255, 0.25);
border-radius: 20rpx;
padding-top: 8rpx;
padding-bottom: 8rpx;
padding-left: 24rpx;
padding-right: 24rpx;
align-self: flex-start;
}
.level-text {
font-size: 32rpx;
font-weight: bold;
color: #ffffff;
}
.level-icon {
font-size: 80rpx;
}
.level-progress-wrap {
margin-bottom: 16rpx;
}
.level-progress-bar {
height: 12rpx;
background-color: rgba(255, 255, 255, 0.3);
border-radius: 6rpx;
overflow: hidden;
margin-bottom: 12rpx;
}
.level-progress-fill {
height: 100%;
background-color: #ffffff;
border-radius: 6rpx;
}
.level-progress-text {
font-size: 24rpx;
color: rgba(255, 255, 255, 0.85);
}
.level-tips {
background-color: rgba(255, 255, 255, 0.15);
border-radius: 12rpx;
padding: 16rpx 20rpx;
}
.level-tips-text {
font-size: 24rpx;
color: rgba(255, 255, 255, 0.9);
}
/* 通用 section 卡片 */
.section-card {
background-color: #ffffff;
border-radius: 24rpx;
padding: 28rpx;
margin-bottom: 24rpx;
box-shadow: 0 4rpx 16rpx rgba(0, 0, 0, 0.05);
}
.section-header {
margin-bottom: 24rpx;
}
.section-title {
font-size: 32rpx;
font-weight: bold;
color: #333333;
}
/* 流量获取方法 */
.tips-list {
display: flex;
flex-direction: column;
}
.tip-item {
display: flex;
flex-direction: row;
align-items: center;
padding-top: 20rpx;
padding-bottom: 20rpx;
border-bottom-width: 1rpx;
border-bottom-style: solid;
border-bottom-color: #f5f5f5;
}
.tip-item:last-child {
border-bottom: none;
padding-bottom: 0;
}
.tip-icon-wrap {
width: 72rpx;
height: 72rpx;
border-radius: 18rpx;
display: flex;
align-items: center;
justify-content: center;
margin-right: 24rpx;
flex-shrink: 0;
}
.tip-icon {
font-size: 36rpx;
}
.tip-content {
flex: 1;
}
.tip-title {
font-size: 28rpx;
font-weight: 600;
color: #333333;
margin-bottom: 6rpx;
display: block;
}
.tip-desc {
font-size: 24rpx;
color: #999999;
}
.tip-arrow {
font-size: 40rpx;
color: #cccccc;
margin-left: 16rpx;
}
/* 经营指南宫格 */
.guide-grid {
display: flex;
flex-direction: row;
flex-wrap: wrap;
}
.guide-item {
width: 33.33%;
display: flex;
flex-direction: column;
align-items: center;
padding-top: 24rpx;
padding-bottom: 24rpx;
}
.guide-icon {
font-size: 56rpx;
margin-bottom: 12rpx;
}
.guide-title {
font-size: 24rpx;
color: #555555;
}
/* 今日经营建议 */
.suggestion-list {
display: flex;
flex-direction: column;
}
.suggestion-item {
display: flex;
flex-direction: row;
align-items: center;
padding-top: 20rpx;
padding-bottom: 20rpx;
border-bottom-width: 1rpx;
border-bottom-style: solid;
border-bottom-color: #f5f5f5;
}
.suggestion-item:last-child {
border-bottom: none;
padding-bottom: 0;
}
.suggestion-item.done .suggestion-title {
color: #cccccc;
text-decoration: line-through;
}
.suggestion-check {
margin-right: 16rpx;
flex-shrink: 0;
}
.check-icon {
font-size: 36rpx;
}
.suggestion-content {
flex: 1;
}
.suggestion-title {
font-size: 28rpx;
font-weight: 500;
color: #333333;
margin-bottom: 6rpx;
display: block;
}
.suggestion-desc {
font-size: 24rpx;
color: #999999;
}
.suggestion-tag {
margin-left: 16rpx;
padding-top: 6rpx;
padding-bottom: 6rpx;
padding-left: 16rpx;
padding-right: 16rpx;
border-radius: 8rpx;
flex-shrink: 0;
}
.tag-text {
font-size: 22rpx;
font-weight: 500;
}
/* 学习中心列表 */
.learn-list {
display: flex;
flex-direction: column;
}
.learn-item {
display: flex;
flex-direction: row;
align-items: center;
padding-top: 20rpx;
padding-bottom: 20rpx;
border-bottom-width: 1rpx;
border-bottom-style: solid;
border-bottom-color: #f5f5f5;
}
.learn-item:last-child {
border-bottom: none;
padding-bottom: 0;
}
.learn-cover {
width: 100rpx;
height: 80rpx;
border-radius: 12rpx;
background-color: #f5f7ff;
display: flex;
align-items: center;
justify-content: center;
margin-right: 20rpx;
flex-shrink: 0;
}
.learn-cover-icon {
font-size: 44rpx;
}
.learn-info {
flex: 1;
}
.learn-title {
font-size: 28rpx;
font-weight: 600;
color: #333333;
margin-bottom: 8rpx;
display: block;
}
.learn-subtitle {
font-size: 24rpx;
color: #999999;
margin-bottom: 12rpx;
display: block;
}
.learn-meta {
display: flex;
flex-direction: row;
align-items: center;
}
.learn-tag {
font-size: 22rpx;
color: #ff5000;
background-color: #fff3ef;
padding-top: 4rpx;
padding-bottom: 4rpx;
padding-left: 12rpx;
padding-right: 12rpx;
border-radius: 6rpx;
margin-right: 16rpx;
}
.learn-duration {
font-size: 22rpx;
color: #999999;
}
/* 底部安全区 */
.safe-bottom {
height: 160rpx;
}
</style>

View File

@@ -1,7 +1,13 @@
<!-- 商家端首页 -->
<template>
<view class="merchant-container">
<scroll-view scroll-y class="main-scroll" :refresher-enabled="true" :refresher-triggered="refreshing" @refresherrefresh="onRefresh">
<!-- #ifdef MP-WEIXIN -->
<!-- Tab 页无返回按鈕,展示顶部安全区 + 页面标题 -->
<view class="mp-tab-navbar">
<text class="mp-tab-title">商家工作台</text>
</view>
<!-- #endif -->
<scroll-view direction="vertical" class="main-scroll" :refresher-enabled="true" :refresher-triggered="refreshing" @refresherrefresh="onRefresh">
<!-- 头部区域 -->
<view class="header">
<view class="header-bg"></view>
@@ -231,15 +237,18 @@
</view>
</view>
<!-- 底部安全区域 -->
<!-- 底部安全区域(需要覆盖自定义 tabbar 高度) -->
<view class="safe-bottom"></view>
</view>
</scroll-view>
<!-- 商家端自定义 TabBar -->
<merchant-tab-bar :current="0"></merchant-tab-bar>
</view>
</template>
<script lang="uts">
import supa from '@/components/supadb/aksupainstance.uts'
import MerchantTabBar from '@/components/merchant-tabbar/MerchantTabBar.uvue'
type ShopInfoType = {
id: string | null
@@ -292,6 +301,7 @@
}
export default {
components: { MerchantTabBar },
data() {
return {
merchantId: '',
@@ -887,7 +897,9 @@
.amount-label { font-size: 24rpx; color: #999; margin-right: 8rpx; }
.amount-value { font-size: 32rpx; font-weight: bold; color: #FF6B35; }
.safe-bottom { height: 30rpx; }
.mp-tab-navbar { height: calc(88rpx + var(--status-bar-height)); padding-top: var(--status-bar-height); background-color: #ffffff; display: flex; flex-direction: row; align-items: center; justify-content: center; border-bottom-width: 1rpx; border-bottom-style: solid; border-bottom-color: #f0f0f0; }
.mp-tab-title { font-size: 34rpx; font-weight: bold; color: #333333; }
.safe-bottom { height: 160rpx; }
</style>

View File

@@ -2,11 +2,9 @@
<template>
<view class="messages-page">
<!-- #ifdef MP-WEIXIN -->
<view style="padding-top: var(--status-bar-height); background-color: #ffffff; display: flex; flex-direction: row; align-items: flex-end; border-bottom: 1rpx solid #eeeeee; box-sizing: border-box; height: calc(88rpx + var(--status-bar-height));">
<view style="display: flex; flex-direction: row; align-items: center; padding: 0 30rpx; height: 88rpx;" @click="uni.navigateBack()">
<text style="font-size: 44rpx; color: #333333; line-height: 1; margin-right: 6rpx;"></text>
<text style="font-size: 28rpx; color: #333333;">返回</text>
</view>
<!-- Tab 页无返回按鈕,展示顶部安全区 + 页面标题 -->
<view class="mp-tab-navbar">
<text class="mp-tab-title">消息</text>
</view>
<!-- #endif -->
<view class="header">
@@ -14,7 +12,7 @@
<text class="header-subtitle">与客户的聊天记录</text>
</view>
<scroll-view class="messages-list" scroll-y :refresher-enabled="true" :refresher-triggered="refreshing" @refresherrefresh="onRefresh">
<scroll-view class="messages-list" direction="vertical" :refresher-enabled="true" :refresher-triggered="refreshing" @refresherrefresh="onRefresh">
<view v-if="loading && conversations.length === 0" class="loading-container">
<text class="loading-icon">⏳</text>
<text class="loading-text">加载中...</text>
@@ -50,11 +48,14 @@
<view class="safe-bottom"></view>
</scroll-view>
<!-- 商家端自定义 TabBar -->
<merchant-tab-bar :current="1"></merchant-tab-bar>
</view>
</template>
<script lang="uts">
import supa from '@/components/supadb/aksupainstance.uts'
import MerchantTabBar from '@/components/merchant-tabbar/MerchantTabBar.uvue'
type MessageType = {
id: string
@@ -80,6 +81,7 @@
}
export default {
components: { MerchantTabBar },
data() {
return {
conversations: [] as ConversationType[],
@@ -212,6 +214,9 @@
<style>
.messages-page { background-color: #f5f7fa; min-height: 100vh; display: flex; flex-direction: column; }
.mp-tab-navbar { height: calc(88rpx + var(--status-bar-height)); padding-top: var(--status-bar-height); background-color: #ffffff; display: flex; flex-direction: row; align-items: center; justify-content: center; border-bottom-width: 1rpx; border-bottom-style: solid; border-bottom-color: #f0f0f0; }
.mp-tab-title { font-size: 34rpx; font-weight: bold; color: #333333; }
.header { background-color: #fff; padding-top: 60rpx; padding-bottom: 24rpx; padding-left: 30rpx; padding-right: 30rpx; border-bottom-width: 1rpx; border-bottom-style: solid; border-bottom-color: #eee; }
.header-title { font-size: 44rpx; font-weight: bold; color: #333; display: block; margin-bottom: 8rpx; }
.header-subtitle { font-size: 26rpx; color: #999; }
@@ -242,5 +247,5 @@
.unread-num { font-size: 22rpx; color: #fff; font-weight: bold; }
.conv-arrow { font-size: 40rpx; color: #ccc; margin-left: 10rpx; }
.safe-bottom { height: 30rpx; }
.safe-bottom { height: 160rpx; }
</style>

View File

@@ -2,11 +2,9 @@
<template>
<view class="orders-page">
<!-- #ifdef MP-WEIXIN -->
<view style="padding-top: var(--status-bar-height); background-color: #ffffff; display: flex; flex-direction: row; align-items: flex-end; border-bottom: 1rpx solid #eeeeee; box-sizing: border-box; height: calc(88rpx + var(--status-bar-height));">
<view style="display: flex; flex-direction: row; align-items: center; padding: 0 30rpx; height: 88rpx;" @click="uni.navigateBack()">
<text style="font-size: 44rpx; color: #333333; line-height: 1; margin-right: 6rpx;"></text>
<text style="font-size: 28rpx; color: #333333;">返回</text>
</view>
<!-- Tab 页无返回按鈕,展示顶部安全区 + 页面标题 -->
<view class="mp-tab-navbar">
<text class="mp-tab-title">订单管理</text>
</view>
<!-- #endif -->
<!-- 标签页切换 -->
@@ -174,11 +172,14 @@
</view>
</view>
</view>
<!-- 商家端自定义 TabBar -->
<merchant-tab-bar :current="2"></merchant-tab-bar>
</view>
</template>
<script lang="uts">
import supa from '@/components/supadb/aksupainstance.uts'
import MerchantTabBar from '@/components/merchant-tabbar/MerchantTabBar.uvue'
type OrderItemType = {
id: string
@@ -222,6 +223,7 @@
}
export default {
components: { MerchantTabBar },
data() {
return {
tabs: [
@@ -637,6 +639,9 @@
min-height: 100vh;
}
.mp-tab-navbar { height: calc(88rpx + var(--status-bar-height)); padding-top: var(--status-bar-height); background-color: #ffffff; display: flex; flex-direction: row; align-items: center; justify-content: center; border-bottom-width: 1rpx; border-bottom-style: solid; border-bottom-color: #f0f0f0; }
.mp-tab-title { font-size: 34rpx; font-weight: bold; color: #333333; }
.tabs-container {
background-color: #fff;
position: sticky;
@@ -723,7 +728,7 @@
.orders-list {
padding: 0 20rpx;
height: calc(100vh - 300rpx);
height: calc(100vh - 460rpx);
}
.loading-container, .empty-container {

View File

@@ -2,13 +2,12 @@
<template>
<view class="merchant-profile">
<!-- #ifdef MP-WEIXIN -->
<view style="padding-top: var(--status-bar-height); background-color: #ffffff; display: flex; flex-direction: row; align-items: flex-end; border-bottom: 1rpx solid #eeeeee; box-sizing: border-box; height: calc(88rpx + var(--status-bar-height));">
<view style="display: flex; flex-direction: row; align-items: center; padding: 0 30rpx; height: 88rpx;" @click="uni.navigateBack()">
<text style="font-size: 44rpx; color: #333333; line-height: 1; margin-right: 6rpx;"></text>
<text style="font-size: 28rpx; color: #333333;">返回</text>
</view>
<!-- Tab 页无返回按鈕,展示顶部安全区 + 页面标题 -->
<view class="mp-tab-navbar">
<text class="mp-tab-title">我的</text>
</view>
<!-- #endif -->
<scroll-view direction="vertical" class="profile-scroll">
<!-- 店铺信息头部 -->
<view class="profile-header">
<image :src="shopInfo.shop_logo || '/static/default-shop.png'" class="shop-logo" @click="editShop" />
@@ -23,6 +22,13 @@
<view class="settings-icon" @click="goToSettings">⚙️</view>
</view>
<!-- 前往店铺主页 -->
<view class="shop-home-entry" @click="goToShopHome">
<text class="shop-home-icon">🏪</text>
<text class="shop-home-text">前往店铺主页</text>
<text class="shop-home-arrow"></text>
</view>
<!-- 订单管理快捷入口 -->
<view class="order-shortcuts">
<view class="section-title">订单管理</view>
@@ -175,11 +181,17 @@
</view>
</view>
</view>
<!-- 底部安全区(覆盖 tabbar -->
<view class="safe-bottom"></view>
</scroll-view>
<!-- 商家端自定义 TabBar -->
<merchant-tab-bar :current="4"></merchant-tab-bar>
</view>
</template>
<script setup lang="uts">
import { ref, onMounted, computed } from 'vue'
import MerchantTabBar from '@/components/merchant-tabbar/MerchantTabBar.uvue'
import type { MerchantType, OrderType, ApiResponseType } from '@/types/mall-types'
// 响应式数据
@@ -346,6 +358,12 @@ function formatTime(dateStr: string): string {
}
// 导航方法
function goToShopHome() {
uni.navigateTo({
url: '/pages/mall/merchant/shop-edit'
})
}
function editShop() {
uni.navigateTo({
url: '/pages/mall/merchant/shop-edit'
@@ -433,11 +451,64 @@ function goToFeedback() {
<style scoped>
.merchant-profile {
padding: 0 0 120rpx 0;
background-color: #f5f5f5;
min-height: 100vh;
}
.mp-tab-navbar {
height: calc(88rpx + var(--status-bar-height));
padding-top: var(--status-bar-height);
background-color: #ffffff;
display: flex;
align-items: center;
justify-content: center;
border-bottom-width: 1rpx;
border-bottom-style: solid;
border-bottom-color: #f0f0f0;
}
.mp-tab-title {
font-size: 34rpx;
font-weight: bold;
color: #333333;
}
.profile-scroll {
flex: 1;
}
.shop-home-entry {
margin: 20rpx 30rpx;
background: white;
border-radius: 20rpx;
padding: 28rpx 30rpx;
display: flex;
flex-direction: row;
align-items: center;
box-shadow: 0 4rpx 16rpx rgba(0, 0, 0, 0.04);
}
.shop-home-icon {
font-size: 40rpx;
margin-right: 20rpx;
}
.shop-home-text {
flex: 1;
font-size: 30rpx;
font-weight: 600;
color: #333;
}
.shop-home-arrow {
font-size: 40rpx;
color: #ccc;
}
.safe-bottom {
height: 160rpx;
}
.profile-header {
display: flex;
align-items: center;