统一店务小程序主导航视觉与信息层级

This commit is contained in:
2026-07-25 16:47:12 +08:00
parent 67d493be85
commit 87862a3c36
9 changed files with 161 additions and 30 deletions
+1
View File
@@ -32,6 +32,7 @@ Page({
customers: list.map(item => ({
id: item.id,
name: item.nickname || item.name || item.account || '客户',
shortName: (item.nickname || item.name || item.account || '客户').slice(-1),
phone: item.contactPhone || item.phone || '未填写',
lastTime: item.lastOrderTime || item.lastConsumeTime || '-'
}))
+11 -5
View File
@@ -3,7 +3,7 @@
<view class="search-card card">
<input value="{{keyword}}" bindinput="onSearchInput" placeholder="搜索客户姓名或手机号" />
</view>
<button class="compact-btn" bindtap="addCustomer">新增</button>
<button class="compact-btn add-customer-btn" bindtap="addCustomer">+</button>
</view>
<view class="list section">
@@ -13,10 +13,16 @@
</view>
<view wx:elif="{{customers.length === 0}}" class="empty card">暂无客户</view>
<view wx:for="{{customers}}" wx:key="id" class="card list-card customer-card" data-id="{{item.id}}" bindtap="openDetail">
<view>
<text class="name">{{item.name}}</text>
<text class="meta">{{item.phone}}</text>
<text class="meta">最近消费 {{item.lastTime}}</text>
<view class="customer-identity">
<view class="customer-avatar">{{item.shortName}}</view>
<view class="customer-copy">
<view class="customer-name-row">
<text class="name">{{item.name}}</text>
<text class="customer-status">已建档</text>
</view>
<text class="meta">{{item.phone}}</text>
<text class="meta">最近消费 {{item.lastTime}}</text>
</view>
</view>
<text class="arrow">›</text>
</view>
+69 -1
View File
@@ -2,6 +2,7 @@
display: flex;
align-items: center;
gap: 14rpx;
margin-bottom: 8rpx;
}
.search-card {
@@ -10,6 +11,9 @@
height: 84rpx;
display: flex;
align-items: center;
border-color: rgba(111, 143, 131, 0.12);
background: rgba(255, 255, 255, 0.82);
box-shadow: 0 8rpx 22rpx rgba(78, 96, 78, 0.05);
}
.search-card input {
@@ -17,10 +21,74 @@
font-size: 26rpx;
}
.add-customer-btn {
width: 84rpx;
min-width: 84rpx;
max-width: 84rpx;
height: 84rpx;
min-height: 84rpx;
padding: 0;
border-radius: 50%;
background: #6f8f83;
color: #fffdf8;
font-size: 42rpx;
font-weight: 400;
line-height: 84rpx;
box-shadow: 0 10rpx 22rpx rgba(111, 143, 131, 0.2);
}
.customer-card {
display: flex;
align-items: center;
justify-content: space-between;
padding: 22rpx 20rpx;
border-color: rgba(111, 143, 131, 0.1);
background: rgba(255, 255, 255, 0.86);
box-shadow: 0 8rpx 20rpx rgba(78, 96, 78, 0.045);
}
.customer-identity {
display: flex;
align-items: center;
min-width: 0;
gap: 18rpx;
}
.customer-avatar {
display: flex;
align-items: center;
justify-content: center;
flex: 0 0 auto;
width: 76rpx;
height: 76rpx;
border: 4rpx solid #f4faf2;
border-radius: 50%;
background: #dcece0;
color: #4f8068;
font-size: 30rpx;
font-weight: 900;
}
.customer-copy {
min-width: 0;
}
.customer-name-row {
display: flex;
align-items: center;
gap: 10rpx;
}
.customer-status {
display: inline-flex;
align-items: center;
min-height: 32rpx;
padding: 0 10rpx;
border-radius: 999rpx;
background: #eff7ef;
color: #6a9876;
font-size: 18rpx;
font-weight: 800;
}
.name,
@@ -30,7 +98,7 @@
.name {
color: #292520;
font-size: 30rpx;
font-size: 29rpx;
font-weight: 800;
}
+3 -3
View File
@@ -1,7 +1,7 @@
<view class="page">
<view class="list-heading">
<text>美甲师</text>
<button class="compact-btn" bindtap="addEmployee">新增</button>
<button class="compact-btn add-employee-btn" bindtap="addEmployee">+</button>
</view>
<view class="list">
@@ -28,7 +28,7 @@
<text class="employee-meta">本月 {{item.monthOrders}} 单 · ¥{{item.monthAmount}}</text>
</view>
</view>
<view class="color-pill" style="background: {{item.color}};"></view>
<view class="employee-state">{{item.scheduleSummary === '未设置' ? '待排班' : '正常'}}</view>
</view>
</view>
@@ -49,7 +49,7 @@
<text class="employee-meta">本月 {{item.monthOrders}} 单 · ¥{{item.monthAmount}}</text>
</view>
</view>
<view class="color-pill" style="background: {{item.color}};"></view>
<view class="employee-state">{{item.scheduleSummary === '未设置' ? '待排班' : '正常'}}</view>
</view>
</view>
</view>
+33 -3
View File
@@ -17,11 +17,30 @@
margin-left: auto;
}
.add-employee-btn {
width: 84rpx;
min-width: 84rpx;
max-width: 84rpx;
height: 84rpx;
min-height: 84rpx;
padding: 0;
border-radius: 50%;
background: #6f8f83;
color: #fffdf8;
font-size: 42rpx;
font-weight: 400;
line-height: 84rpx;
box-shadow: 0 10rpx 22rpx rgba(111, 143, 131, 0.2);
}
.employee-card {
display: flex;
align-items: center;
justify-content: space-between;
padding: 22rpx;
border-color: rgba(111, 143, 131, 0.1);
background: rgba(255, 255, 255, 0.86);
box-shadow: 0 8rpx 20rpx rgba(78, 96, 78, 0.045);
animation: cardIn 180ms ease both;
transition: transform 160ms ease, box-shadow 160ms ease;
}
@@ -48,7 +67,8 @@
}
.manager-card {
border-color: rgba(111, 143, 131, 0.22);
border-color: rgba(111, 143, 131, 0.26);
background: #f4faf2;
}
.employee-left {
@@ -125,9 +145,19 @@
}
.color-pill {
width: 44rpx;
height: 18rpx;
display: none;
}
.employee-state {
flex: 0 0 auto;
min-height: 34rpx;
padding: 0 12rpx;
border-radius: 999rpx;
background: #eff7ef;
color: #5f9070;
font-size: 19rpx;
font-weight: 800;
line-height: 34rpx;
}
.retry-btn {
@@ -22,6 +22,9 @@
.control-card {
padding: 18rpx;
border-color: rgba(111, 143, 131, 0.12);
background: rgba(255, 255, 255, 0.84);
box-shadow: 0 10rpx 24rpx rgba(78, 96, 78, 0.05);
animation: pageFadeIn 180ms ease both;
}
@@ -193,10 +196,14 @@
display: grid;
grid-template-columns: repeat(3, 1fr);
gap: 12rpx;
margin-top: 18rpx;
}
.summary-item {
padding: 16rpx;
border-color: rgba(111, 143, 131, 0.1);
background: rgba(255, 255, 255, 0.82);
box-shadow: 0 8rpx 18rpx rgba(78, 96, 78, 0.04);
}
.summary-value {
@@ -217,6 +224,8 @@
height: 820rpx;
margin-top: 18rpx;
overflow: hidden;
border-color: rgba(111, 143, 131, 0.1);
box-shadow: 0 8rpx 20rpx rgba(78, 96, 78, 0.04);
}
.timeline-wrap {
+4 -4
View File
@@ -31,7 +31,7 @@
</view>
<view class="menu-section">
<text class="section-title">我的管理</text>
<text class="section-title">店铺经营</text>
<view class="menu-card">
<view class="menu-row" data-url="/pages/shop-settings/index" bindtap="go">
<view class="menu-mark">店</view>
@@ -50,7 +50,7 @@
<text class="arrow">›</text>
</view>
<view class="menu-row" data-url="/pages/customers/index" bindtap="go">
<view class="menu-mark">会</view>
<view class="menu-mark customer-mark">会</view>
<view class="menu-copy">
<text class="menu-title">会员管理</text>
<text class="menu-desc">客户管理、会员等级</text>
@@ -58,7 +58,7 @@
<text class="arrow">›</text>
</view>
<view class="menu-row" data-url="/pages/export/index" bindtap="go">
<view class="menu-mark">数</view>
<view class="menu-mark data-mark">数</view>
<view class="menu-copy">
<text class="menu-title">经营数据</text>
<text class="menu-desc">营业统计、数据分析</text>
@@ -69,7 +69,7 @@
</view>
<view class="menu-section">
<text class="section-title">设置与帮助</text>
<text class="section-title">账号与帮助</text>
<view class="menu-card">
<view class="menu-row" data-url="/pages/profile-settings/index" bindtap="go">
<view class="menu-mark">人</view>
+22 -14
View File
@@ -1,18 +1,15 @@
.profile-page {
min-height: 100vh;
padding: 18rpx 24rpx 156rpx;
background:
linear-gradient(180deg, rgba(253, 249, 242, 0.98), rgba(248, 244, 237, 0.98)),
linear-gradient(135deg, rgba(116, 148, 130, 0.12), rgba(230, 205, 160, 0.1));
background: #f8f5ef;
}
.profile-hero {
overflow: hidden;
border-radius: 8px;
background:
radial-gradient(circle at 92% 4%, rgba(255, 255, 255, 0.72), transparent 32%),
linear-gradient(135deg, #eef8eb, #fffaf2);
box-shadow: 0 16rpx 40rpx rgba(77, 91, 72, 0.1);
border: 1rpx solid rgba(91, 132, 102, 0.14);
border-radius: 24rpx;
background: #f1f8ee;
box-shadow: 0 12rpx 28rpx rgba(77, 91, 72, 0.06);
}
.hero-main {
@@ -218,23 +215,24 @@
}
.menu-section {
margin-top: 32rpx;
margin-top: 28rpx;
}
.section-title {
display: block;
margin: 0 8rpx 18rpx;
color: #302b26;
font-size: 28rpx;
font-size: 26rpx;
font-weight: 900;
line-height: 1.2;
}
.menu-card {
overflow: hidden;
border-radius: 8px;
background: rgba(255, 255, 255, 0.92);
box-shadow: 0 12rpx 30rpx rgba(65, 54, 42, 0.06);
border: 1rpx solid rgba(111, 143, 131, 0.08);
border-radius: 18rpx;
background: rgba(255, 255, 255, 0.86);
box-shadow: 0 8rpx 22rpx rgba(65, 54, 42, 0.04);
}
.menu-row {
@@ -257,7 +255,7 @@
flex: 0 0 auto;
width: 50rpx;
height: 50rpx;
border-radius: 14rpx;
border-radius: 50%;
background: #e6f3e8;
color: #5f936d;
font-size: 23rpx;
@@ -265,6 +263,16 @@
line-height: 1;
}
.customer-mark {
background: #fff2dc;
color: #b38343;
}
.data-mark {
background: #e9e6f5;
color: #7569a5;
}
.menu-copy {
flex: 1;
min-width: 0;
+9
View File
@@ -603,3 +603,12 @@
- 规则口径:店长账号类型仍保持 `type=2`,不改成美甲师账号;是否进入预约队列通过规划查询和参与制作资料共同体现。
- 数据库说明:本次不新增 SQL,不修改初始化 SQL,不需要执行数据库迁移;历史已存在且缺少美甲师资料的店长可通过兜底资料展示为参与制作,但若需要持久化资料和默认排班,后续可单独补数据迁移。
- 验证结果:`PlanningServiceImplTest`、`UserServiceImplPermissionAssignmentTest`、`NailArtistInfoServiceImplTest` 共 39 个测试通过。
## 2026-07-25 店务小程序主导航视觉与信息层级改造
- 变更原因:依据店务小程序构思图,将规划、客户、员工、我的四个主导航统一为低饱和米白、浅鼠尾草绿、轻卡片和摘要优先的店务工作台风格。
- 处理方式:规划页统一顶部控制卡、日视图统计卡和时间轴卡片的视觉;客户列表增加头像缩写、建档状态和圆形新增入口;员工列表增加店长高亮、员工状态标签和圆形新增入口;我的页面调整经营分组标题、菜单卡片和入口色彩。
- 月视图边界:仅复用页面整体视觉,不修改月视图 WXML 结构、布局和交互逻辑。
- 影响范围:`JY-Salon-WeChat/pages/planning/`、`pages/customers/`、`pages/employees/`、`pages/profile/`;不涉及后端、SQL、接口和其他端。
- 数据库说明:本次不新增 SQL,不修改初始化 SQL,不需要执行数据库迁移。
- 验证结果:店务小程序 21 个 JS 文件语法检查通过;120 个 JSON/WXML/WXSS 文件 BOM 检查通过;`git diff --check` 通过;微信开发者工具 `JY-Salon-WeChat` 在 `ws://127.0.0.1:9420` 下四个 tabBar 页面路由和关键元素验收 16/16 通过;GitNexus unstaged 变更检测为 low risk、0 个受影响流程。