本地备份:商家UI调整前当前完整版本(未推送)
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
4
app.json
4
app.json
@@ -109,6 +109,10 @@
|
||||
"root": "pages/manager-rank",
|
||||
"pages": ["manager-rank"]
|
||||
},
|
||||
{
|
||||
"root": "pages/merchant-data-stats",
|
||||
"pages": ["merchant-data-stats"]
|
||||
},
|
||||
{
|
||||
"root": "pages/merchant-dispatch",
|
||||
"pages": ["merchant-dispatch"]
|
||||
|
||||
@@ -1,14 +1,8 @@
|
||||
// pages/qiangdan/qiangdan.js
|
||||
const app = getApp();
|
||||
import request from '../../utils/request.js';
|
||||
import { normalizeOrderTags } from '../../utils/order-tags.js';
|
||||
import { refreshDashouMembership, userHasHuiyuan } from '../../utils/dashou-profile.js';
|
||||
import { getDefaultAvatarUrl } from '../../utils/avatar.js';
|
||||
import { warmupPindaoConfig } from '../../utils/miniapp-icons.js';
|
||||
import PopupService from '../../services/popupService.js';
|
||||
import { reconnectForRole } from '../../utils/role-tab-bar.js';
|
||||
import { ensurePhoneAuth } from '../../utils/phone-auth.js';
|
||||
import { fetchGonggaoLunbo, isGonggaoCacheValid } from '../../utils/display-config.js';
|
||||
|
||||
Page({
|
||||
data: {
|
||||
@@ -35,7 +29,7 @@ Page({
|
||||
// 4. 刷新控制字段
|
||||
scrollViewRefreshing: false,
|
||||
lastRefreshTime: 0,
|
||||
refreshCooldown: 0,
|
||||
refreshCooldown: 2000,
|
||||
isLoadingMore: false,
|
||||
|
||||
// 5. 切换类型冷却
|
||||
@@ -52,59 +46,13 @@ Page({
|
||||
|
||||
// 商品轮播展示(只读 globalData,无额外接口)
|
||||
lunboList: [],
|
||||
gonggao: '',
|
||||
|
||||
examRequired: false,
|
||||
examPassed: false,
|
||||
_examChecked: false,
|
||||
},
|
||||
|
||||
async onLoad() {
|
||||
if (app.globalData._acceptOrderSessionReady && app.globalData._acceptOrderPageCache) {
|
||||
const cache = app.globalData._acceptOrderPageCache;
|
||||
this.setData({ ...cache });
|
||||
if ((!cache.lunboList || cache.lunboList.length === 0) && !cache.gonggao && isGonggaoCacheValid(app)) {
|
||||
const lunboList = this.processLunboUrls(app.globalData.shangpinlunbo);
|
||||
const gonggao = app.globalData.shangpingonggao || '';
|
||||
this.setData({ lunboList, gonggao });
|
||||
this.persistPageCache({ lunboList, gonggao });
|
||||
}
|
||||
this.loadGlobalStatus();
|
||||
this.registerNotificationComponent();
|
||||
await this.syncDashouProfileFromServer();
|
||||
this._skipShowRefresh = true;
|
||||
return;
|
||||
}
|
||||
|
||||
async onLoad(options) {
|
||||
this.syncShopBannerFromGlobal();
|
||||
this.loadGlobalStatus();
|
||||
const banner = await this.loadGonggaoAndLunbo(false);
|
||||
await this.syncDashouProfileFromServer();
|
||||
await this.loadShangpinLeixing(true, false, false);
|
||||
this.persistPageCache(banner);
|
||||
app.globalData._acceptOrderSessionReady = true;
|
||||
|
||||
if (!app.globalData._acceptOrderPopupDone) {
|
||||
PopupService.checkAndShow(this, 'jiedan');
|
||||
app.globalData._acceptOrderPopupDone = true;
|
||||
}
|
||||
this._skipShowRefresh = true;
|
||||
},
|
||||
|
||||
persistPageCache(extra = {}) {
|
||||
const d = this.data;
|
||||
app.globalData._acceptOrderPageCache = {
|
||||
shangpinleixing: d.shangpinleixing,
|
||||
xuanzhongLeixingId: d.xuanzhongLeixingId,
|
||||
dingdanList: d.dingdanList,
|
||||
page: d.page,
|
||||
hasMore: d.hasMore,
|
||||
bankuaiBiaoqian: d.bankuaiBiaoqian,
|
||||
xuanzhongBiaoqianId: d.xuanzhongBiaoqianId,
|
||||
lunboList: extra.lunboList ?? d.lunboList,
|
||||
gonggao: extra.gonggao ?? d.gonggao,
|
||||
lastRefreshTime: d.lastRefreshTime,
|
||||
ossImageUrl: d.ossImageUrl,
|
||||
};
|
||||
await this.loadShangpinLeixing();
|
||||
PopupService.checkAndShow(this, 'jiedan');
|
||||
},
|
||||
|
||||
onHide: function () {
|
||||
@@ -114,84 +62,63 @@ Page({
|
||||
}
|
||||
},
|
||||
|
||||
async onShow() {
|
||||
if (!app.globalData._dashouPhoneChecked) {
|
||||
const phoneOk = await ensurePhoneAuth({ redirect: true, role: 'dashou' });
|
||||
if (!phoneOk) return;
|
||||
app.globalData._dashouPhoneChecked = true;
|
||||
}
|
||||
|
||||
onShow() {
|
||||
this.syncShopBannerFromGlobal();
|
||||
this.registerNotificationComponent();
|
||||
await this.syncDashouProfileFromServer();
|
||||
warmupPindaoConfig(app);
|
||||
|
||||
this.loadGlobalStatus();
|
||||
if (wx.getStorageSync('uid')) {
|
||||
reconnectForRole('dashou');
|
||||
if (app.startImWhenReady) app.startImWhenReady();
|
||||
this.refreshDashouProfileSilent();
|
||||
}
|
||||
|
||||
await this.checkExamStatus(false);
|
||||
|
||||
if (this._skipShowRefresh) {
|
||||
this._skipShowRefresh = false;
|
||||
return;
|
||||
}
|
||||
|
||||
if (app.globalData._acceptOrderSessionReady && !this._silentRefreshRunning) {
|
||||
this._silentRefreshRunning = true;
|
||||
this.silentRefreshOnShow().finally(() => {
|
||||
this._silentRefreshRunning = false;
|
||||
});
|
||||
if (this.data.xuanzhongLeixingId) {
|
||||
this.loadDingdanList(true);
|
||||
}
|
||||
},
|
||||
|
||||
/** 进入页面静默刷新(无 loading 遮罩、不清空列表) */
|
||||
async silentRefreshOnShow() {
|
||||
try {
|
||||
const banner = await this.loadGonggaoAndLunbo(true);
|
||||
await this.syncDashouProfileFromServer();
|
||||
const leixingId = this.data.xuanzhongLeixingId;
|
||||
if (leixingId) {
|
||||
await this.loadDingdanList(true, true);
|
||||
await this.loadBankuaiBiaoqian();
|
||||
}
|
||||
this.loadGlobalStatus();
|
||||
this.persistPageCache(banner);
|
||||
} catch (e) {
|
||||
console.error('静默刷新失败:', e);
|
||||
}
|
||||
},
|
||||
|
||||
/** 公告 + 轮播(首次/下拉强制拉接口,其余读 globalData 或页面缓存) */
|
||||
processLunboUrls(urlList) {
|
||||
const oss = app.globalData.ossImageUrl || this.data.ossImageUrl || '';
|
||||
return (urlList || []).map((url) => {
|
||||
/** 同步点单端已加载的商品轮播图,仅展示用 */
|
||||
syncShopBannerFromGlobal() {
|
||||
const oss = app.globalData.ossImageUrl || '';
|
||||
const lunboList = (app.globalData.shangpinlunbo || []).map((url) => {
|
||||
if (!url) return '';
|
||||
return url.startsWith('http') ? url : oss + url;
|
||||
}).filter(Boolean);
|
||||
this.setData({ lunboList });
|
||||
},
|
||||
|
||||
async loadGonggaoAndLunbo(forceFetch = false) {
|
||||
let lunboRaw = app.globalData.shangpinlunbo || [];
|
||||
let gonggaoText = app.globalData.shangpingonggao || '';
|
||||
|
||||
if (forceFetch || !isGonggaoCacheValid(app)) {
|
||||
try {
|
||||
const data = await fetchGonggaoLunbo(app, 'accept_order');
|
||||
if (data) {
|
||||
lunboRaw = data.shangpinlunbo || app.globalData.shangpinlunbo || [];
|
||||
gonggaoText = data.shangpingonggao || app.globalData.shangpingonggao || '';
|
||||
}
|
||||
} catch (e) {
|
||||
lunboRaw = app.globalData.shangpinlunbo || [];
|
||||
gonggaoText = app.globalData.shangpingonggao || '';
|
||||
async refreshDashouProfileSilent() {
|
||||
try {
|
||||
const res = await request({ url: '/yonghu/dashouxinxi', method: 'POST' });
|
||||
if (!res || res.data.code != 200) return;
|
||||
const data = res.data.data || {};
|
||||
const patch = {
|
||||
dashouNicheng: data.dashounicheng || '',
|
||||
zhanghaoStatus: data.zhanghaostatus || '',
|
||||
dashouzhuangtai: data.dashouzhuangtai || '',
|
||||
yajin: data.yajin || 0,
|
||||
jifen: data.jifen || 0,
|
||||
clumber: data.clumber || [],
|
||||
};
|
||||
Object.assign(app.globalData, {
|
||||
dashouNicheng: patch.dashouNicheng,
|
||||
zhanghaoStatus: patch.zhanghaoStatus,
|
||||
dashouzhuangtai: patch.dashouzhuangtai,
|
||||
yajin: patch.yajin,
|
||||
jinfen: patch.jifen,
|
||||
clumber: patch.clumber,
|
||||
});
|
||||
if (data.dashoustatus !== undefined) {
|
||||
wx.setStorageSync('dashoustatus', data.dashoustatus);
|
||||
app.globalData.dashoustatus = data.dashoustatus;
|
||||
}
|
||||
}
|
||||
|
||||
const lunboList = this.processLunboUrls(lunboRaw);
|
||||
const gonggao = gonggaoText;
|
||||
this.setData({ lunboList, gonggao });
|
||||
return { lunboList, gonggao };
|
||||
this.setData({
|
||||
zhuanghaoStatus: patch.zhanghaoStatus,
|
||||
dashouzhuangtai: patch.dashouzhuangtai,
|
||||
huiyuanList: patch.clumber,
|
||||
yajin: patch.yajin,
|
||||
jifen: patch.jifen,
|
||||
});
|
||||
} catch (e) {}
|
||||
},
|
||||
|
||||
registerNotificationComponent() {
|
||||
@@ -217,22 +144,9 @@ Page({
|
||||
});
|
||||
},
|
||||
|
||||
/** 拉取最新打手信息(会员/押金/积分),并刷新订单卡片上的会员展示 */
|
||||
async syncDashouProfileFromServer() {
|
||||
if (!wx.getStorageSync('token')) return;
|
||||
await refreshDashouMembership(app);
|
||||
this.loadGlobalStatus();
|
||||
if (this.data.dingdanList && this.data.dingdanList.length) {
|
||||
this.setData({
|
||||
dingdanList: this.data.dingdanList.map((item) => this.processDingdanItem(item)),
|
||||
});
|
||||
}
|
||||
},
|
||||
|
||||
// 加载商品类型
|
||||
async loadShangpinLeixing(autoLoadOrders = false, preserveSelection = false, showLoading = true) {
|
||||
if (showLoading) wx.showLoading({ title: '加载商品类型...' });
|
||||
const prevId = this.data.xuanzhongLeixingId;
|
||||
async loadShangpinLeixing() {
|
||||
wx.showLoading({ title: '加载商品类型...' });
|
||||
try {
|
||||
const res = await request({
|
||||
url: '/dingdan/dsqdhqddlx',
|
||||
@@ -249,16 +163,14 @@ Page({
|
||||
else if (Array.isArray(data)) list = data;
|
||||
}
|
||||
const processedList = this.processTupianUrl(list);
|
||||
const firstId = processedList[0]?.id || null;
|
||||
const keepPrev = preserveSelection && prevId && processedList.some((i) => i.id === prevId);
|
||||
const selectedId = keepPrev ? prevId : firstId;
|
||||
this.setData({
|
||||
shangpinleixing: processedList,
|
||||
xuanzhongLeixingId: selectedId,
|
||||
xuanzhongLeixingId: processedList[0]?.id || null
|
||||
});
|
||||
if (autoLoadOrders && selectedId) {
|
||||
await this.loadDingdanList(true);
|
||||
await this.loadBankuaiBiaoqian();
|
||||
if (this.data.xuanzhongLeixingId) {
|
||||
this.loadDingdanList(true);
|
||||
// 🆕 加载板块标签
|
||||
this.loadBankuaiBiaoqian();
|
||||
}
|
||||
} else {
|
||||
wx.showToast({ title: res.data?.msg || '加载商品类型失败', icon: 'none' });
|
||||
@@ -266,7 +178,7 @@ Page({
|
||||
} catch (error) {
|
||||
wx.showToast({ title: '网络错误,加载失败', icon: 'none' });
|
||||
} finally {
|
||||
if (showLoading) wx.hideLoading();
|
||||
wx.hideLoading();
|
||||
}
|
||||
},
|
||||
|
||||
@@ -333,8 +245,8 @@ Page({
|
||||
xuanzhongBiaoqianId: 0 // 重置标签筛选
|
||||
});
|
||||
await this.loadDingdanList(true);
|
||||
// 🆕 切换类型后加载新标签
|
||||
await this.loadBankuaiBiaoqian();
|
||||
this.persistPageCache();
|
||||
} catch (error) {
|
||||
console.error('切换类型失败:', error);
|
||||
} finally {
|
||||
@@ -354,24 +266,19 @@ Page({
|
||||
hasMore: true
|
||||
});
|
||||
await this.loadDingdanList(true);
|
||||
this.persistPageCache();
|
||||
},
|
||||
|
||||
// 加载订单列表
|
||||
async loadDingdanList(isRefresh = false, silent = false) {
|
||||
if ((!silent && this.data.isLoading) || !this.data.xuanzhongLeixingId) return;
|
||||
if (silent && this._listRequesting) return;
|
||||
async loadDingdanList(isRefresh = false) {
|
||||
if (this.data.isLoading || !this.data.xuanzhongLeixingId) return;
|
||||
|
||||
const loadPage = isRefresh ? 1 : this.data.page;
|
||||
if (!isRefresh && !this.data.hasMore) return;
|
||||
|
||||
if (!silent) {
|
||||
this.setData({
|
||||
isLoading: true,
|
||||
isLoadingMore: !isRefresh,
|
||||
});
|
||||
}
|
||||
this._listRequesting = true;
|
||||
this.setData({
|
||||
isLoading: true,
|
||||
isLoadingMore: !isRefresh
|
||||
});
|
||||
|
||||
try {
|
||||
const res = await request({
|
||||
@@ -391,7 +298,6 @@ Page({
|
||||
isLoadingMore: false,
|
||||
scrollViewRefreshing: false
|
||||
});
|
||||
this._listRequesting = false;
|
||||
|
||||
if (res.data.code === 200 || res.data.code === 0) {
|
||||
const newList = res.data.data.list || [];
|
||||
@@ -407,7 +313,6 @@ Page({
|
||||
page: loadPage,
|
||||
hasMore: hasMore
|
||||
});
|
||||
this.persistPageCache();
|
||||
|
||||
if (isRefresh) {
|
||||
this.setData({ lastRefreshTime: Date.now() });
|
||||
@@ -422,28 +327,20 @@ Page({
|
||||
isLoadingMore: false,
|
||||
scrollViewRefreshing: false
|
||||
});
|
||||
this._listRequesting = false;
|
||||
if (!silent) {
|
||||
wx.showToast({ title: '网络请求失败', icon: 'none' });
|
||||
}
|
||||
wx.showToast({ title: '网络请求失败', icon: 'none' });
|
||||
}
|
||||
},
|
||||
|
||||
// 处理单条订单数据(包含标签、会员判断)
|
||||
processDingdanItem(item) {
|
||||
const ossUrl = app.globalData.ossImageUrl || '';
|
||||
const leixing = this.data.shangpinleixing.find((l) => l.id == item.leixing_id);
|
||||
let fullTupianUrl = '';
|
||||
|
||||
// 卡片左上角优先用订单类型图,没有再退回默认图(不用商品图/头像顶替类型)
|
||||
if (leixing && leixing.full_tupian_url) {
|
||||
fullTupianUrl = leixing.full_tupian_url;
|
||||
} else if (leixing && leixing.tupian_url) {
|
||||
fullTupianUrl = leixing.tupian_url.startsWith('http')
|
||||
? leixing.tupian_url
|
||||
: ossUrl + leixing.tupian_url;
|
||||
if (item.tupian) {
|
||||
fullTupianUrl = !item.tupian.startsWith('http') ? ossUrl + item.tupian : item.tupian;
|
||||
} else {
|
||||
fullTupianUrl = '/images/default-order.png';
|
||||
const leixing = this.data.shangpinleixing.find(l => l.id === item.leixing_id);
|
||||
fullTupianUrl = leixing ? leixing.full_tupian_url : '/images/default-order.png';
|
||||
}
|
||||
|
||||
const isZhiding = item.zhuangtai === 7;
|
||||
@@ -456,32 +353,25 @@ Page({
|
||||
}
|
||||
const zhidingNicheng = item.zhiding_nicheng || '';
|
||||
|
||||
// 订单要求指定会员时,核对用户是否持有该会员类型
|
||||
// 🆕 判断用户是否有订单所需的会员(仅当订单要求会员类型且存在huiyuan_id)
|
||||
let hasRequiredMember = true;
|
||||
if (item.yaoqiuleixing == 1 && item.huiyuan_id) {
|
||||
hasRequiredMember = userHasHuiyuan(this.data.huiyuanList, item.huiyuan_id);
|
||||
const userHasIt = this.data.huiyuanList.some(h => h.huiyuanid == item.huiyuan_id);
|
||||
hasRequiredMember = userHasIt;
|
||||
}
|
||||
|
||||
let shangjiaAvatar = getDefaultAvatarUrl(app);
|
||||
const sjAvatar = (item.sj_avatar || '').trim();
|
||||
if (sjAvatar) {
|
||||
shangjiaAvatar = sjAvatar.startsWith('http') ? sjAvatar : ossUrl + sjAvatar;
|
||||
}
|
||||
|
||||
const tags = normalizeOrderTags(item)
|
||||
|
||||
return {
|
||||
...item,
|
||||
full_tupian_url: fullTupianUrl,
|
||||
leixing_icon_url: fullTupianUrl,
|
||||
shangjia_avatar_full: shangjiaAvatar,
|
||||
isZhiding: isZhiding,
|
||||
isPingtai: item.pingtai == 1,
|
||||
isShangjia: item.pingtai == 2,
|
||||
zhiding_avatar_full: zhidingAvatar,
|
||||
zhiding_nicheng: zhidingNicheng,
|
||||
...tags,
|
||||
shangjia_youzhi: !!item.shangjia_youzhi,
|
||||
// 🆕 三层标签(后端返回,直接保留)
|
||||
xuqiu_biaoqian: item.xuqiu_biaoqian || [],
|
||||
dashou_biaoqian: item.dashou_biaoqian || [],
|
||||
shangjia_biaoqian: item.shangjia_biaoqian || [],
|
||||
// 🆕 是否有查看价格的权限
|
||||
hasRequiredMember: hasRequiredMember,
|
||||
};
|
||||
@@ -519,50 +409,11 @@ Page({
|
||||
});
|
||||
},
|
||||
|
||||
/** 抢单前考试状态(仅更新状态,不自动跳转考试页) */
|
||||
async checkExamStatus() {
|
||||
try {
|
||||
const res = await request({
|
||||
url: '/jituan/dashou-exam/status',
|
||||
method: 'POST',
|
||||
header: { 'content-type': 'application/json' },
|
||||
});
|
||||
const body = res?.data;
|
||||
if (body && (body.code === 200 || body.code === 0) && body.data) {
|
||||
const d = body.data;
|
||||
this.setData({
|
||||
examRequired: !!d.exam_required,
|
||||
examPassed: !!d.exam_passed,
|
||||
});
|
||||
}
|
||||
} catch (e) {
|
||||
console.error('考试状态检查失败', e);
|
||||
}
|
||||
return true;
|
||||
},
|
||||
|
||||
// 抢单按钮(原封不动)
|
||||
async onQiangdanTap(e) {
|
||||
const dingdanItem = e.currentTarget.dataset.item;
|
||||
if (!dingdanItem) return;
|
||||
|
||||
await this.checkExamStatus();
|
||||
|
||||
if (this.data.examRequired && !this.data.examPassed) {
|
||||
wx.showModal({
|
||||
title: '须通过接单考试',
|
||||
content: '抢单前需先通过接单考试,是否现在去考试?',
|
||||
confirmText: '去考试',
|
||||
cancelText: '暂不',
|
||||
success: (r) => {
|
||||
if (r.confirm) {
|
||||
wx.navigateTo({ url: '/pages/dashou-exam/dashou-exam' });
|
||||
}
|
||||
},
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
// 校验1: 打手身份
|
||||
if (!this.data.dashoustatus || this.data.dashoustatus != 1) {
|
||||
wx.showToast({ title: '请先开启接单员身份', icon: 'none' });
|
||||
@@ -587,7 +438,7 @@ Page({
|
||||
}
|
||||
// 校验5: 会员要求
|
||||
if (dingdanItem.yaoqiuleixing == 1) {
|
||||
const hasHuiyuan = userHasHuiyuan(this.data.huiyuanList, dingdanItem.huiyuan_id);
|
||||
const hasHuiyuan = this.data.huiyuanList.some(h => h.huiyuanid == dingdanItem.huiyuan_id);
|
||||
if (!hasHuiyuan) {
|
||||
wx.showToast({
|
||||
title: '未开通对应会员,无法抢单',
|
||||
@@ -653,7 +504,6 @@ Page({
|
||||
item => item.dingdan_id !== dingdanItem.dingdan_id
|
||||
);
|
||||
that.setData({ dingdanList: newList });
|
||||
that.persistPageCache();
|
||||
} else {
|
||||
wx.showToast({
|
||||
title: qiangdanRes.data.msg || '抢单失败',
|
||||
@@ -685,14 +535,42 @@ Page({
|
||||
},
|
||||
|
||||
onReachBottom() {
|
||||
const now = Date.now();
|
||||
const lastTime = this.data.lastRefreshTime;
|
||||
const cooldown = this.data.refreshCooldown;
|
||||
|
||||
if (now - lastTime < cooldown) {
|
||||
wx.showToast({
|
||||
title: `操作太快,请${Math.ceil((cooldown - (now - lastTime)) / 1000)}秒后再试`,
|
||||
icon: 'none',
|
||||
duration: 1500
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
if (this.data.isLoading || this.data.isLoadingMore) return;
|
||||
|
||||
if (this.data.hasMore && !this.data.isLoading && this.data.xuanzhongLeixingId) {
|
||||
this.setData({ page: this.data.page + 1 });
|
||||
this.loadDingdanList(false);
|
||||
}
|
||||
},
|
||||
|
||||
async onPullDownRefresh() {
|
||||
onPullDownRefresh() {
|
||||
const now = Date.now();
|
||||
const lastTime = this.data.lastRefreshTime;
|
||||
const cooldown = this.data.refreshCooldown;
|
||||
|
||||
if (now - lastTime < cooldown) {
|
||||
this.setData({ scrollViewRefreshing: false });
|
||||
wx.showToast({
|
||||
title: `操作太快,请${Math.ceil((cooldown - (now - lastTime)) / 1000)}秒后再试`,
|
||||
icon: 'none',
|
||||
duration: 1500
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
if (this.data.isLoading) {
|
||||
this.setData({ scrollViewRefreshing: false });
|
||||
return;
|
||||
@@ -700,25 +578,14 @@ Page({
|
||||
|
||||
this.setData({
|
||||
scrollViewRefreshing: true,
|
||||
lastRefreshTime: Date.now(),
|
||||
lastRefreshTime: now,
|
||||
page: 1,
|
||||
hasMore: true,
|
||||
hasMore: true
|
||||
});
|
||||
|
||||
try {
|
||||
const banner = await this.loadGonggaoAndLunbo(true);
|
||||
await this.syncDashouProfileFromServer();
|
||||
await this.loadShangpinLeixing(false, true, false);
|
||||
const leixingId = this.data.xuanzhongLeixingId;
|
||||
if (leixingId) {
|
||||
await this.loadBankuaiBiaoqian();
|
||||
await this.loadDingdanList(true);
|
||||
}
|
||||
this.loadGlobalStatus();
|
||||
this.persistPageCache(banner);
|
||||
} catch (e) {
|
||||
console.error('下拉刷新失败:', e);
|
||||
} finally {
|
||||
if (this.data.xuanzhongLeixingId) {
|
||||
this.loadDingdanList(true);
|
||||
} else {
|
||||
this.setData({ scrollViewRefreshing: false });
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,8 +1,6 @@
|
||||
{
|
||||
"navigationBarTitleText": "抢单大厅",
|
||||
"navigationBarBackgroundColor": "#f7dc51",
|
||||
"backgroundColor": "#f7dc51",
|
||||
"backgroundColorTop": "#f7dc51",
|
||||
"navigationBarTextStyle": "black",
|
||||
"enablePullDownRefresh": false,
|
||||
"backgroundTextStyle": "dark",
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
<!-- pages/qiangdan/qiangdan.wxml -->
|
||||
<!-- pages/qiangdan/qiangdan.wxml -->
|
||||
|
||||
<view class="qiangdan-page">
|
||||
|
||||
@@ -38,12 +38,6 @@
|
||||
|
||||
|
||||
|
||||
<!-- 公告置顶 -->
|
||||
<view class="xym-gonggao-bar" wx:if="{{gonggao}}">
|
||||
<image class="xym-gonggao-ico" src="/images/notice.png" mode="aspectFit"/>
|
||||
<text class="xym-gonggao-txt">{{gonggao}}</text>
|
||||
</view>
|
||||
|
||||
<!-- 商品轮播(只读 globalData,与点单端同源) -->
|
||||
|
||||
<view class="xym-lunbo-container" wx:if="{{lunboList.length > 0}}">
|
||||
@@ -80,7 +74,7 @@
|
||||
|
||||
</view>
|
||||
|
||||
<view class="xym-section-gap" wx:if="{{lunboList.length > 0}}"></view>
|
||||
|
||||
|
||||
<!-- 商品类型选择 -->
|
||||
|
||||
@@ -196,6 +190,16 @@
|
||||
|
||||
<view class="order-con">
|
||||
|
||||
<view wx:if="{{item.isZhiding}}" class="zhiding-strip myflex light">
|
||||
|
||||
<text class="zhiding-label">指定</text>
|
||||
|
||||
<image wx:if="{{item.zhiding_avatar_full}}" class="zhiding-avatar" src="{{item.zhiding_avatar_full}}" mode="aspectFill"/>
|
||||
|
||||
<text class="zhiding-name">{{item.zhiding_nicheng || '指定接单员'}}</text>
|
||||
|
||||
</view>
|
||||
|
||||
<view class="order-row myflex">
|
||||
|
||||
<image class="o-logo" src="{{item.full_tupian_url}}" mode="aspectFill"/>
|
||||
@@ -208,20 +212,6 @@
|
||||
|
||||
</view>
|
||||
|
||||
<block wx:if="{{item.isZhiding}}">
|
||||
<view class="zhiding-strip light">
|
||||
<view class="zhiding-strip-top myflex">
|
||||
<text class="zhiding-label">指定</text>
|
||||
<image wx:if="{{item.zhiding_avatar_full}}" class="zhiding-avatar" src="{{item.zhiding_avatar_full}}" mode="aspectFill"/>
|
||||
<text class="zhiding-name">{{item.zhiding_nicheng || '指定接单员'}}</text>
|
||||
</view>
|
||||
<view wx:if="{{item.dashou_biaoqian.length > 0 || item.zhiding_identity_biaoqian.length > 0}}" class="zhiding-strip-tags">
|
||||
<chenghao-tag wx:for="{{item.dashou_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
<chenghao-tag wx:for="{{item.zhiding_identity_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</view>
|
||||
</block>
|
||||
|
||||
<view class="reward-badge platform-reward" wx:if="{{item.hasRequiredMember}}">
|
||||
|
||||
<text class="reward-yen sm">¥</text>
|
||||
@@ -236,9 +226,9 @@
|
||||
|
||||
</view>
|
||||
|
||||
<view class="remark-block gold" data-type="beizhu" data-content="{{item.beizhu}}" bindtap="onViewDetail">
|
||||
<view wx:if="{{item.beizhu}}" class="remark-block gold" data-type="beizhu" data-content="{{item.beizhu}}" bindtap="onViewDetail">
|
||||
|
||||
<text class="remark-label">备注:</text>{{item.beizhu || '暂无'}}
|
||||
<text class="remark-label">备注:</text>{{item.beizhu}}
|
||||
|
||||
</view>
|
||||
|
||||
@@ -246,10 +236,10 @@
|
||||
|
||||
<text class="xuqiu-label">需求标签</text>
|
||||
|
||||
<scroll-view class="biaoqian-inline-scroll" scroll-x enable-flex>
|
||||
<view class="biaoqian-inline-inner">
|
||||
<chenghao-tag wx:for="{{item.xuqiu_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
<scroll-view class="biaoqian-inline-scroll" scroll-x>
|
||||
|
||||
<chenghao-tag wx:for="{{item.xuqiu_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
|
||||
</scroll-view>
|
||||
|
||||
</view>
|
||||
@@ -270,81 +260,6 @@
|
||||
|
||||
|
||||
|
||||
<!-- 优质商家订单(金牌卡片) -->
|
||||
<view wx:elif="{{item.isShangjia && item.shangjia_youzhi}}" class="xym-order-item gold-card" data-item="{{item}}">
|
||||
<view class="gold-head flexb">
|
||||
<view class="kehuduan-banner-wrap">
|
||||
<image class="gold-banner" src="https://bintao.xmxym88.com/xcx/bintao/82.png" mode="widthFix"/>
|
||||
</view>
|
||||
</view>
|
||||
<view class="gold-body-wrap">
|
||||
<view class="order-con gold-inner">
|
||||
<view class="order-row myflex">
|
||||
<image class="o-logo" src="{{item.leixing_icon_url}}" mode="aspectFill"/>
|
||||
<view class="o-col">
|
||||
<view class="o-goods line2" data-type="jieshao" data-content="{{item.jieshao}}" bindtap="onViewDetail">{{item.jieshao || '暂无介绍'}}</view>
|
||||
<view class="tag-row myflex">
|
||||
<text class="tag-pill tag-youzhi">优质商家</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<block wx:if="{{item.isZhiding}}">
|
||||
<view class="zhiding-strip">
|
||||
<view class="zhiding-strip-top myflex">
|
||||
<text class="zhiding-label">指定</text>
|
||||
<image wx:if="{{item.zhiding_avatar_full}}" class="zhiding-avatar" src="{{item.zhiding_avatar_full}}" mode="aspectFill"/>
|
||||
<text class="zhiding-name">{{item.zhiding_nicheng || '指定接单员'}}</text>
|
||||
</view>
|
||||
<view wx:if="{{item.dashou_biaoqian.length > 0 || item.zhiding_identity_biaoqian.length > 0}}" class="zhiding-strip-tags">
|
||||
<chenghao-tag wx:for="{{item.dashou_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
<chenghao-tag wx:for="{{item.zhiding_identity_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</view>
|
||||
</block>
|
||||
<view class="reward-badge normal-reward gold-reward" wx:if="{{item.hasRequiredMember}}">
|
||||
<text class="reward-yen sm">¥</text>
|
||||
<text class="reward-num dark">{{item.dashou_fencheng || 0}}</text>
|
||||
</view>
|
||||
<view class="reward-badge member-tip" wx:else>
|
||||
<text class="reward-tip">未开通会员</text>
|
||||
</view>
|
||||
<view class="remark-block dark" data-type="beizhu" data-content="{{item.beizhu}}" bindtap="onViewDetail">
|
||||
<text class="remark-label dark-t">商家备注:</text>{{item.beizhu || '暂无'}}
|
||||
</view>
|
||||
<view wx:if="{{item.shangjia_biaoqian.length > 0 || item.shangjia_identity_biaoqian.length > 0 || item.xuqiu_biaoqian.length > 0}}" class="xuqiu-tags-row">
|
||||
<scroll-view wx:if="{{item.shangjia_biaoqian.length > 0}}" class="biaoqian-inline-scroll" scroll-x enable-flex>
|
||||
<view class="biaoqian-inline-inner">
|
||||
<chenghao-tag wx:for="{{item.shangjia_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</scroll-view>
|
||||
<scroll-view wx:if="{{item.shangjia_identity_biaoqian.length > 0}}" class="biaoqian-inline-scroll" scroll-x enable-flex style="margin-top:8rpx">
|
||||
<view class="biaoqian-inline-inner">
|
||||
<chenghao-tag wx:for="{{item.shangjia_identity_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</scroll-view>
|
||||
<scroll-view wx:if="{{item.xuqiu_biaoqian.length > 0}}" class="biaoqian-inline-scroll" scroll-x enable-flex style="margin-top:8rpx">
|
||||
<view class="biaoqian-inline-inner">
|
||||
<chenghao-tag wx:for="{{item.xuqiu_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</scroll-view>
|
||||
</view>
|
||||
<view class="merchant-plain flexb">
|
||||
<view class="merchant-user myflex">
|
||||
<image class="m-avatar" src="{{item.shangjia_avatar_full}}" mode="aspectFill"/>
|
||||
<view class="m-info">
|
||||
<view class="m-name m-name-light line1">{{item.sjnicheng || '未知商家'}}</view>
|
||||
<view class="m-sn m-sn-light">发布于 {{item.creat_time}}</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="qiangdan flexa btn-bg btn-qiang" data-item="{{item}}" bindtap="onQiangdanTap">抢单</view>
|
||||
</view>
|
||||
<view class="o-foot flexb kehuduan-foot gold-foot-text-only">
|
||||
<text class="o-amt-grey">商家派单</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 商家订单(逍遥梦卡片布局) -->
|
||||
|
||||
<view wx:elif="{{item.isShangjia}}" class="xym-order-item xym-shangjia-order" data-item="{{item}}">
|
||||
@@ -361,23 +276,19 @@
|
||||
|
||||
<view class="order-con">
|
||||
|
||||
<block wx:if="{{item.isZhiding}}">
|
||||
<view class="zhiding-strip">
|
||||
<view class="zhiding-strip-top myflex">
|
||||
<text class="zhiding-label">指定</text>
|
||||
<image wx:if="{{item.zhiding_avatar_full}}" class="zhiding-avatar" src="{{item.zhiding_avatar_full}}" mode="aspectFill"/>
|
||||
<text class="zhiding-name">{{item.zhiding_nicheng || '指定接单员'}}</text>
|
||||
</view>
|
||||
<view wx:if="{{item.dashou_biaoqian.length > 0 || item.zhiding_identity_biaoqian.length > 0}}" class="zhiding-strip-tags">
|
||||
<chenghao-tag wx:for="{{item.dashou_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
<chenghao-tag wx:for="{{item.zhiding_identity_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</view>
|
||||
</block>
|
||||
<view wx:if="{{item.isZhiding}}" class="zhiding-strip myflex">
|
||||
|
||||
<text class="zhiding-label">指定</text>
|
||||
|
||||
<image wx:if="{{item.zhiding_avatar_full}}" class="zhiding-avatar" src="{{item.zhiding_avatar_full}}" mode="aspectFill"/>
|
||||
|
||||
<text class="zhiding-name">{{item.zhiding_nicheng || '指定接单员'}}</text>
|
||||
|
||||
</view>
|
||||
|
||||
<view class="merchant-line myflex">
|
||||
|
||||
<image class="m-avatar-sm" src="{{item.shangjia_avatar_full}}" mode="aspectFill"/>
|
||||
<image class="m-avatar-sm" src="{{item.full_tupian_url}}" mode="aspectFill"/>
|
||||
|
||||
<text class="m-name-sm">{{item.sjnicheng || '未知商家'}}</text>
|
||||
|
||||
@@ -407,33 +318,24 @@
|
||||
|
||||
</view>
|
||||
|
||||
<view class="remark-block dark" data-type="beizhu" data-content="{{item.beizhu}}" bindtap="onViewDetail">
|
||||
<view wx:if="{{item.beizhu}}" class="remark-block dark" data-type="beizhu" data-content="{{item.beizhu}}" bindtap="onViewDetail">
|
||||
|
||||
<text class="remark-label">商家备注:</text>{{item.beizhu || '暂无'}}
|
||||
<text class="remark-label">商家备注:</text>{{item.beizhu}}
|
||||
|
||||
</view>
|
||||
|
||||
<view wx:if="{{item.shangjia_biaoqian.length > 0 || item.shangjia_identity_biaoqian.length > 0 || item.xuqiu_biaoqian.length > 0}}" class="xuqiu-tags-row">
|
||||
<view wx:if="{{item.shangjia_biaoqian.length > 0 || item.xuqiu_biaoqian.length > 0}}" class="xuqiu-tags-row">
|
||||
|
||||
<scroll-view wx:if="{{item.shangjia_biaoqian.length > 0}}" class="biaoqian-inline-scroll" scroll-x enable-flex>
|
||||
<scroll-view wx:if="{{item.shangjia_biaoqian.length > 0}}" class="biaoqian-inline-scroll" scroll-x>
|
||||
|
||||
<chenghao-tag wx:for="{{item.shangjia_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
|
||||
<view class="biaoqian-inline-inner">
|
||||
<chenghao-tag wx:for="{{item.shangjia_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</scroll-view>
|
||||
|
||||
<scroll-view wx:if="{{item.shangjia_identity_biaoqian.length > 0}}" class="biaoqian-inline-scroll" scroll-x enable-flex style="margin-top:8rpx">
|
||||
<scroll-view wx:if="{{item.xuqiu_biaoqian.length > 0}}" class="biaoqian-inline-scroll" scroll-x style="margin-top:8rpx">
|
||||
|
||||
<view class="biaoqian-inline-inner">
|
||||
<chenghao-tag wx:for="{{item.shangjia_identity_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</scroll-view>
|
||||
<chenghao-tag wx:for="{{item.xuqiu_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
|
||||
<scroll-view wx:if="{{item.xuqiu_biaoqian.length > 0}}" class="biaoqian-inline-scroll" scroll-x enable-flex style="margin-top:8rpx">
|
||||
|
||||
<view class="biaoqian-inline-inner">
|
||||
<chenghao-tag wx:for="{{item.xuqiu_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</scroll-view>
|
||||
|
||||
</view>
|
||||
|
||||
@@ -1,11 +1,5 @@
|
||||
/* pages/qiangdan/qiangdan.wxss - 逍遥梦抢单页 */
|
||||
/* pages/qiangdan/qiangdan.wxss - 高级机甲风格重构版(对称优化) */
|
||||
@import '../../styles/dashou-xym-theme.wxss';
|
||||
@import '../../styles/dashou-xym-order-card.wxss';
|
||||
|
||||
page {
|
||||
background-color: #f7dc51;
|
||||
}
|
||||
|
||||
.qiangdan-page {
|
||||
height: 100vh;
|
||||
display: flex;
|
||||
@@ -132,7 +126,6 @@ page {
|
||||
flex: 1;
|
||||
height: 0;
|
||||
-webkit-overflow-scrolling: touch;
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
.scroll-bottom-spacer {
|
||||
@@ -770,3 +763,5 @@ page {
|
||||
margin-left: auto;
|
||||
max-width: 50%;
|
||||
}
|
||||
|
||||
@import '../../styles/dashou-xym-order-card.wxss';
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -49,14 +49,7 @@ Page(createPage({
|
||||
|
||||
onLoad() {
|
||||
wx.setNavigationBarTitle({ title: '我的接单' });
|
||||
this.loadShangpinLeixing().then(() => {
|
||||
if (this.data.xuanzhongLeixingId) {
|
||||
return this.loadCurrentStatusOrders(true);
|
||||
}
|
||||
}).finally(() => {
|
||||
this._ordersSessionReady = true;
|
||||
this._skipShowRefresh = true;
|
||||
});
|
||||
this.loadShangpinLeixing();
|
||||
this.registerNotificationComponent();
|
||||
},
|
||||
|
||||
@@ -66,15 +59,8 @@ Page(createPage({
|
||||
reconnectForRole('dashou');
|
||||
if (app.startImWhenReady) app.startImWhenReady();
|
||||
}
|
||||
if (this._skipShowRefresh) {
|
||||
this._skipShowRefresh = false;
|
||||
return;
|
||||
}
|
||||
if (this._ordersSessionReady && this.data.xuanzhongLeixingId && !this._silentRefreshRunning) {
|
||||
this._silentRefreshRunning = true;
|
||||
this.loadCurrentStatusOrders(true, true).finally(() => {
|
||||
this._silentRefreshRunning = false;
|
||||
});
|
||||
if (this.data.currentStatusKey && this.data.xuanzhongLeixingId) {
|
||||
this.loadCurrentStatusOrders(true);
|
||||
}
|
||||
},
|
||||
|
||||
@@ -155,21 +141,17 @@ Page(createPage({
|
||||
},
|
||||
|
||||
// 加载订单(核心)
|
||||
async loadCurrentStatusOrders(isRefresh = false, silent = false) {
|
||||
async loadCurrentStatusOrders(isRefresh = false) {
|
||||
const key = this.data.currentStatusKey;
|
||||
const tabData = this.data.dsDingdanShuju[key];
|
||||
if (tabData.isLoading && !silent) return;
|
||||
if (silent && this._listRequesting) return;
|
||||
if (tabData.isLoading) return;
|
||||
const page = isRefresh ? 1 : tabData.page;
|
||||
|
||||
if (!silent) {
|
||||
this.setData({
|
||||
[`dsDingdanShuju.${key}.isLoading`]: true,
|
||||
isLoading: true,
|
||||
isLoadingMore: !isRefresh,
|
||||
});
|
||||
}
|
||||
this._listRequesting = true;
|
||||
this.setData({
|
||||
[`dsDingdanShuju.${key}.isLoading`]: true,
|
||||
isLoading: true,
|
||||
isLoadingMore: !isRefresh
|
||||
});
|
||||
|
||||
try {
|
||||
const apiUrl = this.data.orderType === 'peihu'
|
||||
@@ -226,20 +208,14 @@ Page(createPage({
|
||||
}
|
||||
} catch (err) {
|
||||
console.error('加载订单失败', err);
|
||||
if (!silent) {
|
||||
wx.showToast({ title: err.message || '加载失败', icon: 'none' });
|
||||
}
|
||||
if (!silent) {
|
||||
this.setData({
|
||||
[`dsDingdanShuju.${key}.isLoading`]: false,
|
||||
isLoading: false,
|
||||
isLoadingMore: false,
|
||||
scrollViewRefreshing: false
|
||||
});
|
||||
this.refreshCurrentListView();
|
||||
}
|
||||
} finally {
|
||||
this._listRequesting = false;
|
||||
wx.showToast({ title: err.message || '加载失败', icon: 'none' });
|
||||
this.setData({
|
||||
[`dsDingdanShuju.${key}.isLoading`]: false,
|
||||
isLoading: false,
|
||||
isLoadingMore: false,
|
||||
scrollViewRefreshing: false
|
||||
});
|
||||
this.refreshCurrentListView();
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
{
|
||||
"usingComponents": {
|
||||
"global-notification": "/components/global-notification/global-notification",
|
||||
"tab-bar": "/tab-bar/index"
|
||||
"global-notification": "/components/global-notification/global-notification"
|
||||
},
|
||||
"navigationBarTitleText": "我的接单",
|
||||
"enablePullDownRefresh": false,
|
||||
|
||||
@@ -1,14 +1,9 @@
|
||||
/**
|
||||
* 排行榜
|
||||
* 默认 POST /yonghu/phbhqsj
|
||||
* 星之界(xzj) POST /yonghu/xzjphbhqsj(邀请人数排序等专用规则)
|
||||
* 排行榜 POST /yonghu/phbhqsj
|
||||
* 参数: shenfen(dashou|guanshi|zuzhang|shangjia), riqi(今日|本周|本月|总榜|昨日|上周|上月)
|
||||
*/
|
||||
import request from '../../utils/request.js'
|
||||
import { resolveAvatarUrl, getDefaultAvatarUrl } from '../../utils/avatar.js'
|
||||
import { CLUB_ID } from '../../config/club-config.js'
|
||||
|
||||
const IS_XZJ = CLUB_ID === 'xzj'
|
||||
const RANK_API = IS_XZJ ? '/yonghu/xzjphbhqsj' : '/yonghu/phbhqsj'
|
||||
|
||||
const ROLE_LIST = [
|
||||
{ key: 'dashou', label: '接单员' },
|
||||
@@ -32,7 +27,6 @@ const ROLE_META = {
|
||||
title: '接单员排行榜',
|
||||
sortField: 'chengjiao_zonge',
|
||||
sortLabel: '分红总额',
|
||||
mainType: 'money',
|
||||
metrics: [
|
||||
{ field: 'jiedan_zongliang', label: '接单量', type: 'int' },
|
||||
{ field: 'jiedan_zonge', label: '接单额', type: 'money' },
|
||||
@@ -43,7 +37,6 @@ const ROLE_META = {
|
||||
title: '管事排行榜',
|
||||
sortField: 'shouru_zonge',
|
||||
sortLabel: '收入总额',
|
||||
mainType: 'money',
|
||||
metrics: [
|
||||
{ field: 'yaoqing_dashou_shu', label: '邀请', type: 'int' },
|
||||
{ field: 'chongzhi_dashou_shu', label: '充值', type: 'int' },
|
||||
@@ -53,7 +46,6 @@ const ROLE_META = {
|
||||
title: '组长排行榜',
|
||||
sortField: 'shouru_zonge',
|
||||
sortLabel: '收入总额',
|
||||
mainType: 'money',
|
||||
metrics: [
|
||||
{ field: 'yaoqing_guanshi_shu', label: '邀请', type: 'int' },
|
||||
{ field: 'fenyong_jine', label: '分佣', type: 'money' },
|
||||
@@ -63,7 +55,6 @@ const ROLE_META = {
|
||||
title: '商家排行榜',
|
||||
sortField: 'jiesuan_jine',
|
||||
sortLabel: '成交总额',
|
||||
mainType: 'money',
|
||||
metrics: [
|
||||
{ field: 'jiesuan_dingdan_shu', label: '成交量', type: 'int' },
|
||||
{ field: 'paifa_dingdan_shu', label: '派单量', type: 'int' },
|
||||
@@ -72,55 +63,6 @@ const ROLE_META = {
|
||||
},
|
||||
}
|
||||
|
||||
/** 星之界专用展示与排序字段 */
|
||||
const XZJ_ROLE_META = {
|
||||
dashou: {
|
||||
title: '接单员排行榜',
|
||||
sortField: 'chengjiao_zonge',
|
||||
sortLabel: '成交金额',
|
||||
mainType: 'money',
|
||||
metrics: [
|
||||
{ field: 'jiedan_zongliang', label: '接单量', type: 'int' },
|
||||
{ field: 'jiedan_zonge', label: '接单额', type: 'money' },
|
||||
{ field: 'chengjiao_zongliang', label: '成交量', type: 'int' },
|
||||
],
|
||||
},
|
||||
guanshi: {
|
||||
title: '管事排行榜',
|
||||
sortField: 'yaoqing_dashou_shu',
|
||||
sortLabel: '邀请人数',
|
||||
mainType: 'int',
|
||||
metrics: [
|
||||
{ field: 'wuxiao_yaoqing_dashou_shu', label: '无效邀请', type: 'int' },
|
||||
{ field: 'chongzhi_dashou_shu', label: '有效人数', type: 'int' },
|
||||
{ field: 'shouru_zonge', label: '收入金额', type: 'money' },
|
||||
],
|
||||
},
|
||||
zuzhang: {
|
||||
title: '组长排行榜',
|
||||
sortField: 'yaoqing_guanshi_shu',
|
||||
sortLabel: '邀请人数',
|
||||
mainType: 'int',
|
||||
metrics: [
|
||||
{ field: 'wuxiao_yaoqing_guanshi_shu', label: '无效邀请', type: 'int' },
|
||||
{ field: 'youxiao_guanshi_shu', label: '有效人数', type: 'int' },
|
||||
{ field: 'shouru_zonge', label: '收入金额', type: 'money' },
|
||||
],
|
||||
},
|
||||
shangjia: {
|
||||
title: '商家排行榜',
|
||||
sortField: 'paifa_jine',
|
||||
sortLabel: '派单流水',
|
||||
mainType: 'money',
|
||||
metrics: [
|
||||
{ field: 'paifa_dingdan_shu', label: '派单量', type: 'int' },
|
||||
{ field: 'paifa_jine', label: '派单流水', type: 'money' },
|
||||
],
|
||||
},
|
||||
}
|
||||
|
||||
const ACTIVE_ROLE_META = IS_XZJ ? XZJ_ROLE_META : ROLE_META
|
||||
|
||||
function isInvalidAvatarPath(path) {
|
||||
if (path === null || path === undefined) return true
|
||||
if (typeof path !== 'string') return true
|
||||
@@ -157,7 +99,7 @@ Page({
|
||||
|
||||
onLoad(options) {
|
||||
const type = options.type || options.rankType || 'dashou'
|
||||
const validRole = ACTIVE_ROLE_META[type] ? type : 'dashou'
|
||||
const validRole = ROLE_META[type] ? type : 'dashou'
|
||||
this.initPage()
|
||||
this.applyRole(validRole, false)
|
||||
this.fetchRankList()
|
||||
@@ -220,7 +162,7 @@ Page({
|
||||
},
|
||||
|
||||
applyRole(role, reload = true) {
|
||||
const meta = ACTIVE_ROLE_META[role]
|
||||
const meta = ROLE_META[role]
|
||||
wx.setNavigationBarTitle({ title: meta.title })
|
||||
this.setData({ currentRole: role, roleMeta: meta, sortLabel: meta.sortLabel })
|
||||
if (reload) this.fetchRankList()
|
||||
@@ -254,7 +196,7 @@ Page({
|
||||
},
|
||||
|
||||
normalizeItem(raw, index, role) {
|
||||
const meta = ACTIVE_ROLE_META[role]
|
||||
const meta = ROLE_META[role]
|
||||
const app = getApp()
|
||||
const uid = raw.yonghuid || raw.uid || ''
|
||||
const nicheng = raw.nicheng || raw.nick || '用户'
|
||||
@@ -267,19 +209,12 @@ Page({
|
||||
value: m.type === 'money' ? this.formatMoney(v) : this.formatInt(v),
|
||||
}
|
||||
})
|
||||
const sortRaw = raw[meta.sortField]
|
||||
const mainType = meta.mainType || 'money'
|
||||
const mainValue = mainType === 'money'
|
||||
? this.formatMoney(sortRaw)
|
||||
: this.formatInt(sortRaw)
|
||||
return {
|
||||
mingci: raw.mingci || index + 1,
|
||||
uid,
|
||||
nicheng,
|
||||
avatar,
|
||||
mainType,
|
||||
mainPrefix: mainType === 'money' ? '¥' : '',
|
||||
mainValue,
|
||||
mainValue: this.formatMoney(raw[meta.sortField]),
|
||||
mainLabel: meta.sortLabel,
|
||||
metrics,
|
||||
}
|
||||
@@ -289,7 +224,7 @@ Page({
|
||||
this.setData({ isLoading: true, isEmpty: false })
|
||||
try {
|
||||
const res = await request({
|
||||
url: RANK_API,
|
||||
url: '/yonghu/phbhqsj',
|
||||
method: 'POST',
|
||||
data: { shenfen: this.data.currentRole, riqi: this.data.currentDate },
|
||||
})
|
||||
|
||||
@@ -52,7 +52,7 @@
|
||||
<text class="p-name">{{topThree[1].nicheng}}</text>
|
||||
<text class="p-uid">ID {{topThree[1].uid}}</text>
|
||||
<view class="p-amount">
|
||||
<text class="p-money">{{topThree[1].mainPrefix}}{{topThree[1].mainValue}}</text>
|
||||
<text class="p-money">¥{{topThree[1].mainValue}}</text>
|
||||
<text class="p-label">{{topThree[1].mainLabel}}</text>
|
||||
</view>
|
||||
<view class="p-metrics">
|
||||
@@ -70,7 +70,7 @@
|
||||
<text class="p-name p-name-first">{{topThree[0].nicheng}}</text>
|
||||
<text class="p-uid">ID {{topThree[0].uid}}</text>
|
||||
<view class="p-amount">
|
||||
<text class="p-money p-money-first">{{topThree[0].mainPrefix}}{{topThree[0].mainValue}}</text>
|
||||
<text class="p-money p-money-first">¥{{topThree[0].mainValue}}</text>
|
||||
<text class="p-label">{{topThree[0].mainLabel}}</text>
|
||||
</view>
|
||||
<view class="p-metrics">
|
||||
@@ -88,7 +88,7 @@
|
||||
<text class="p-name">{{topThree[2].nicheng}}</text>
|
||||
<text class="p-uid">ID {{topThree[2].uid}}</text>
|
||||
<view class="p-amount">
|
||||
<text class="p-money">{{topThree[2].mainPrefix}}{{topThree[2].mainValue}}</text>
|
||||
<text class="p-money">¥{{topThree[2].mainValue}}</text>
|
||||
<text class="p-label">{{topThree[2].mainLabel}}</text>
|
||||
</view>
|
||||
<view class="p-metrics">
|
||||
@@ -120,7 +120,7 @@
|
||||
</view>
|
||||
</view>
|
||||
<view class="lc-score">
|
||||
<text class="lc-money">{{item.mainPrefix}}{{item.mainValue}}</text>
|
||||
<text class="lc-money">¥{{item.mainValue}}</text>
|
||||
<text class="lc-label">{{item.mainLabel}}</text>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -47,12 +47,6 @@
|
||||
<view class="vip-badge" wx:if="{{item.isBought}}">
|
||||
<text class="badge-text">已拥有</text>
|
||||
</view>
|
||||
<view class="vip-badge trial-badge" wx:if="{{item.can_buy_trial}}">
|
||||
<text class="badge-text">可购体验</text>
|
||||
</view>
|
||||
<view class="vip-badge trial-off-badge" wx:elif="{{item.trial_enabled}}">
|
||||
<text class="badge-text">体验已用/不可购</text>
|
||||
</view>
|
||||
|
||||
<view class="vip-title">
|
||||
<text class="title-text">{{item.mingzi}}</text>
|
||||
@@ -62,11 +56,7 @@
|
||||
<view class="vip-price">
|
||||
<text class="price-symbol">¥</text>
|
||||
<text class="price-number">{{item.jiage}}</text>
|
||||
<text class="price-unit">/{{item.formal_days || 30}}天</text>
|
||||
</view>
|
||||
<view class="vip-trial-price" wx:if="{{item.trial_enabled || item.can_buy_trial}}">
|
||||
<text class="trial-price-label">体验</text>
|
||||
<text class="trial-price-value">¥{{item.trial_price}}/{{item.trial_days}}天</text>
|
||||
<text class="price-unit">/30天</text>
|
||||
</view>
|
||||
|
||||
<view class="vip-features">
|
||||
@@ -117,27 +107,20 @@
|
||||
<!-- 🔥 将“机甲能源”改为“价格” -->
|
||||
<text class="price-label">价格:</text>
|
||||
<text class="price-value">¥{{currentHuiyuan.jiage}}</text>
|
||||
<text class="price-days">/{{currentHuiyuan.formal_days || 30}}天</text>
|
||||
</view>
|
||||
<text class="buy-desc" wx:if="{{currentHuiyuan.isBought && currentHuiyuan.buyInfo}}">
|
||||
已激活,<text class="expire-date">{{currentHuiyuan.buyInfo.daoqi}}</text>后到期
|
||||
</text>
|
||||
<text class="buy-desc" wx:else>正式会员支持微信或余额抵扣</text>
|
||||
<text class="buy-desc trial-hint" wx:if="{{currentHuiyuan.can_buy_trial}}">
|
||||
体验版仅微信支付 ¥{{currentHuiyuan.trial_price}}/{{currentHuiyuan.trial_days}}天,终身1次
|
||||
</text>
|
||||
<text class="buy-desc trial-warn" wx:elif="{{!currentHuiyuan.trial_enabled}}">
|
||||
本俱乐部尚未为该会员开启体验版,请联系管理员在后台配置
|
||||
</text>
|
||||
<text class="buy-desc" wx:else>激活会员特权</text>
|
||||
</view>
|
||||
|
||||
<view class="buy-action">
|
||||
<view class="tech-buy-btn {{currentHuiyuan.isBought ? 'renew' : ''}}"
|
||||
bindtap="onBuyHuiyuanClick" data-id="{{currentHuiyuan.id}}" data-trial="false">
|
||||
bindtap="onBuyHuiyuanClick" data-id="{{currentHuiyuan.id}}">
|
||||
<view class="buy-btn-bg"></view>
|
||||
<view class="buy-btn-glow"></view>
|
||||
<text class="buy-btn-text">
|
||||
{{currentHuiyuan.isBought ? '正式续费' : '购买正式版'}}
|
||||
{{currentHuiyuan.isBought ? '立即续费' : '立即激活'}}
|
||||
</text>
|
||||
<view class="buy-btn-energy">
|
||||
<view class="energy-dot"></view>
|
||||
@@ -145,16 +128,6 @@
|
||||
<view class="energy-dot"></view>
|
||||
</view>
|
||||
</view>
|
||||
<view
|
||||
wx:if="{{currentHuiyuan.can_buy_trial}}"
|
||||
class="tech-buy-btn trial-buy-btn"
|
||||
bindtap="onBuyHuiyuanClick"
|
||||
data-id="{{currentHuiyuan.id}}"
|
||||
data-trial="true"
|
||||
>
|
||||
<view class="buy-btn-bg"></view>
|
||||
<text class="buy-btn-text">购买体验版</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
@@ -1,5 +1,4 @@
|
||||
/* pages/dashou-chongzhi/index.wxss - 逍遥梦主题覆盖 + 机甲基础样式 */
|
||||
@import '../../styles/dashou-xym-recharge-theme.wxss';
|
||||
/* pages/dashou-chongzhi/index.wxss - 完整保留原有样式,仅删除导航栏相关,调整间距和字体 */
|
||||
|
||||
/* ==================== 基础样式 ==================== */
|
||||
.page-container {
|
||||
@@ -677,32 +676,6 @@
|
||||
box-shadow: 0 0 15rpx rgba(255, 107, 157, 0.4);
|
||||
z-index: 20;
|
||||
}
|
||||
|
||||
.vip-badge.trial-badge {
|
||||
top: 60rpx;
|
||||
background: linear-gradient(135deg, #ffb347, #ff7043);
|
||||
}
|
||||
|
||||
.vip-badge.trial-off-badge {
|
||||
top: 60rpx;
|
||||
background: rgba(120, 120, 120, 0.85);
|
||||
box-shadow: none;
|
||||
}
|
||||
|
||||
.vip-trial-price {
|
||||
margin-top: 8rpx;
|
||||
font-size: 22rpx;
|
||||
color: #ffb347;
|
||||
}
|
||||
|
||||
.trial-price-label {
|
||||
margin-right: 8rpx;
|
||||
color: #a0c8ff;
|
||||
}
|
||||
|
||||
.trial-price-value {
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.vip-title {
|
||||
margin-bottom: 25rpx;
|
||||
@@ -882,35 +855,11 @@
|
||||
/* 购买区域 */
|
||||
.buy-section {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: stretch;
|
||||
gap: 20rpx;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
padding-top: 25rpx;
|
||||
border-top: 1px solid rgba(64, 156, 255, 0.2);
|
||||
}
|
||||
|
||||
.buy-action {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 16rpx;
|
||||
align-items: flex-end;
|
||||
}
|
||||
|
||||
.price-days {
|
||||
font-size: 22rpx;
|
||||
color: #a0c8ff;
|
||||
}
|
||||
|
||||
.trial-hint {
|
||||
margin-top: 6rpx;
|
||||
color: #ffb347;
|
||||
}
|
||||
|
||||
.trial-warn {
|
||||
margin-top: 6rpx;
|
||||
color: #ff8a8a;
|
||||
font-size: 22rpx;
|
||||
}
|
||||
|
||||
.buy-info {
|
||||
display: flex;
|
||||
@@ -979,11 +928,6 @@
|
||||
background: linear-gradient(135deg, #1e4b8f, #409cff);
|
||||
}
|
||||
|
||||
.tech-buy-btn.trial-buy-btn .buy-btn-bg {
|
||||
background: linear-gradient(135deg, rgba(255, 179, 71, 0.35), rgba(255, 120, 80, 0.45));
|
||||
border: 1px solid rgba(255, 179, 71, 0.6);
|
||||
}
|
||||
|
||||
.tech-buy-btn.renew .buy-btn-bg {
|
||||
background: linear-gradient(135deg, #0f2c5c, #36cfc9);
|
||||
}
|
||||
@@ -1758,4 +1702,6 @@
|
||||
display: flex !important;
|
||||
align-items: center !important;
|
||||
justify-content: center !important;
|
||||
}
|
||||
}
|
||||
|
||||
@import '../../styles/dashou-xym-recharge-theme.wxss';
|
||||
@@ -2,18 +2,6 @@
|
||||
import { createPage, request, isRoleStatusActive, isCenterPageActive, syncRoleStatuses, syncProfileFields, syncGroupFields, ensureRoleOnCenterPage, clearCacheAndEnterNormal, lockPrimaryRole, migrateLegacyCenterRole, enterLockedRole, parseSceneOptions } from '../../utils/base-page.js'
|
||||
import { resolveAvatarUrl } from '../../utils/avatar.js'
|
||||
import { openPrivateChat, buildInviterPeerId } from '../../utils/im-user.js'
|
||||
import { isStaffMode, getStaffContext } from '../../utils/staff-api.js'
|
||||
import { ensurePhoneAuth } from '../../utils/phone-auth.js'
|
||||
import {
|
||||
ICON_KEYS,
|
||||
resolveMiniappIcon,
|
||||
resolveConfiguredIcon,
|
||||
refreshPindaoConfig,
|
||||
getPindaoConfig,
|
||||
resolvePindaoImages,
|
||||
warmupPindaoConfig,
|
||||
PINDAO_ICON_FALLBACK,
|
||||
} from '../../utils/miniapp-icons.js'
|
||||
|
||||
const PLATFORM_INVITE_CODE = '0000008RffVgKHMj7kQC'
|
||||
|
||||
@@ -53,7 +41,6 @@ Page(createPage({
|
||||
zuzhangInviterCache: null,
|
||||
chenghaoList: [],
|
||||
guanshiChenghaoList: [],
|
||||
identityTagList: [],
|
||||
gszhstatus: '',
|
||||
yaoqingzongshu: 0,
|
||||
fenyongzonge: '0.00',
|
||||
@@ -78,25 +65,13 @@ Page(createPage({
|
||||
|
||||
statusBar: 20,
|
||||
navBar: 44,
|
||||
pindaoVisible: false,
|
||||
pindaoTitle: '频道',
|
||||
pindaoChannelNo: '',
|
||||
examEnabled: false,
|
||||
examPassed: false,
|
||||
pindaoImages: [],
|
||||
|
||||
scrollViewRefreshing: false,
|
||||
showRechargeBanners: false,
|
||||
showPindaoEntry: true,
|
||||
},
|
||||
|
||||
_buildImgUrls(ossImageUrl) {
|
||||
const app = getApp();
|
||||
const dsBase = ossImageUrl + 'beijing/dashouduan/';
|
||||
const iconBase = ossImageUrl + 'beijing/dashouduan/dashoutubiaobeijing/';
|
||||
const gsBase = ossImageUrl + 'beijing/guanshiduan/';
|
||||
const khBase = ossImageUrl + 'beijing/kaohe/';
|
||||
const icon = (key, fallback) => resolveMiniappIcon(app, key, fallback);
|
||||
return {
|
||||
pageBg: dsBase + 'page-bg.jpg',
|
||||
userCardBg: dsBase + 'user-card-bg.png',
|
||||
@@ -108,7 +83,7 @@ Page(createPage({
|
||||
listBg: dsBase + 'list-card-bg.png',
|
||||
topBg: iconBase + 'top-bg.jpg',
|
||||
cardBg: iconBase + 'card-bg.jpg',
|
||||
iconRefresh: icon(ICON_KEYS.ICON_REFRESH, gsBase + 'icon-refresh.png'),
|
||||
iconRefresh: gsBase + 'icon-refresh.png',
|
||||
iconCopy: gsBase + 'icon-copy.png',
|
||||
iconVip: dsBase + 'icon-vip.png',
|
||||
iconArrowLight: dsBase + 'icon-arrow-light.png',
|
||||
@@ -143,7 +118,6 @@ Page(createPage({
|
||||
iconSwitch: '/images/_exit.png',
|
||||
iconKefu: ossImageUrl + 'beijing/tubiao/grzx_kefu.jpg',
|
||||
iconKuaishou: ossImageUrl + 'beijing/tubiao/grzx_guanzhualong.jpg',
|
||||
iconPindao: icon(ICON_KEYS.MINE_PINDAO, ossImageUrl + PINDAO_ICON_FALLBACK),
|
||||
iconKaoheDafen: khBase + 'daofen.png',
|
||||
iconKaoheJilu: khBase + 'jilu.png',
|
||||
iconKaoheZhongxin: khBase + 'zhongxin.png',
|
||||
@@ -154,8 +128,8 @@ Page(createPage({
|
||||
kefuBannerBg: dsBase + 'kefu-banner-bg.png',
|
||||
totalAssetBg: dsBase + 'total-asset-bg.png',
|
||||
authPanelBg: dsBase + 'auth-panel-bg.png',
|
||||
bannerVip: resolveConfiguredIcon(app, ICON_KEYS.FIGHTER_RECHARGE_MEMBER),
|
||||
bannerDeposit: resolveConfiguredIcon(app, ICON_KEYS.FIGHTER_RECHARGE_DEPOSIT),
|
||||
bannerVip: 'https://bintao-1308403501.cos.ap-guangzhou.myqcloud.com/uploads/images/20260512123427531240452.png',
|
||||
bannerDeposit: 'https://bintao-1308403501.cos.ap-guangzhou.myqcloud.com/uploads/images/202605121234283091d3980.png',
|
||||
};
|
||||
},
|
||||
|
||||
@@ -203,28 +177,9 @@ Page(createPage({
|
||||
}
|
||||
}
|
||||
this.checkColdStartPopup('dashouduan');
|
||||
this.syncConfiguredAssets();
|
||||
},
|
||||
|
||||
syncConfiguredAssets() {
|
||||
const app = getApp();
|
||||
const bannerVip = resolveConfiguredIcon(app, ICON_KEYS.FIGHTER_RECHARGE_MEMBER);
|
||||
const bannerDeposit = resolveConfiguredIcon(app, ICON_KEYS.FIGHTER_RECHARGE_DEPOSIT);
|
||||
const imgUrls = { ...this.data.imgUrls, bannerVip, bannerDeposit };
|
||||
this.setData({
|
||||
imgUrls,
|
||||
showRechargeBanners: !!(bannerVip || bannerDeposit),
|
||||
showPindaoEntry: this.data.isDashou || this.data.isGuanshi || this.data.isZuzhang || this.data.isKaoheguan,
|
||||
});
|
||||
},
|
||||
|
||||
async onShow() {
|
||||
if (!app.globalData._dashouPhoneChecked) {
|
||||
const phoneOk = await ensurePhoneAuth({ redirect: true, role: 'dashou' });
|
||||
if (!phoneOk) return;
|
||||
app.globalData._dashouPhoneChecked = true;
|
||||
}
|
||||
|
||||
onShow() {
|
||||
migrateLegacyCenterRole(getApp());
|
||||
lockPrimaryRole('dashou', getApp());
|
||||
wx.setStorageSync('isJinpai', 0);
|
||||
@@ -235,17 +190,16 @@ Page(createPage({
|
||||
this.setData({ inviterCache, zuzhangInviterCache });
|
||||
|
||||
this.registerNotificationComponent();
|
||||
warmupPindaoConfig(app);
|
||||
this.checkRoleStatuses();
|
||||
this.syncConfiguredAssets();
|
||||
if (isCenterPageActive(this, 'isDashou', 'dashoustatus')) {
|
||||
if (!this.data.isDashou) this.setData({ isDashou: true });
|
||||
ensureRoleOnCenterPage(this, 'dashou');
|
||||
this.loadExamStatus();
|
||||
setTimeout(() => this.refreshAllInfo(false), 300);
|
||||
} else if (isRoleStatusActive(wx.getStorageSync('guanshistatus')) ||
|
||||
isRoleStatusActive(wx.getStorageSync('zuzhangstatus')) ||
|
||||
isRoleStatusActive(wx.getStorageSync('kaoheguanstatus'))) {
|
||||
ensureRoleOnCenterPage(this, 'dashou');
|
||||
setTimeout(() => this.refreshAllInfo(false), 300);
|
||||
}
|
||||
const pages = getCurrentPages();
|
||||
const currentPage = pages[pages.length - 1];
|
||||
@@ -323,17 +277,12 @@ Page(createPage({
|
||||
tag: d.shangjiaCertified ? '进入商家端' : '去认证',
|
||||
done: d.shangjiaCertified,
|
||||
});
|
||||
list.push({
|
||||
type: 'staff',
|
||||
name: '商家客服',
|
||||
icon: img.iconKefu || img.iconShangjia,
|
||||
tag: isStaffMode() ? '进入工作台' : '去入驻',
|
||||
done: isStaffMode(),
|
||||
});
|
||||
if (!d.isGuanshi) {
|
||||
list.push({ type: 'guanshi', name: '管事', icon: img.iconGuanshiAuth, tag: '去认证' });
|
||||
}
|
||||
// 组长由后台添加,前端不再展示「组长认证」入口
|
||||
if (!d.isZuzhang) {
|
||||
list.push({ type: 'zuzhang', name: '组长', icon: img.iconZuzhangAuth, tag: '去认证' });
|
||||
}
|
||||
if (!d.isDashou) {
|
||||
list.push({ type: 'dashou', name: '接单员', icon: img.iconDashouAuth, tag: '去认证' });
|
||||
}
|
||||
@@ -344,37 +293,35 @@ Page(createPage({
|
||||
},
|
||||
|
||||
async refreshAllInfo(showToast = true) {
|
||||
if (this._profileRefreshing) return;
|
||||
this._profileRefreshing = true;
|
||||
this.setData({ isLoading: true });
|
||||
try {
|
||||
this.checkRoleStatuses();
|
||||
const results = await Promise.allSettled([
|
||||
this._fetchDashouInfoSilent(),
|
||||
this.fetchChenghaoList(),
|
||||
this._fetchGuanshiInfoSilent(),
|
||||
this.fetchGuanshiChenghaoList(),
|
||||
this._fetchZuzhangInfoSilent(),
|
||||
this._fetchKaoheguanInfoSilent(),
|
||||
this.loadIdentityTags(),
|
||||
]);
|
||||
this.checkRoleStatuses();
|
||||
const dashouOk = results[0].status === 'fulfilled';
|
||||
if (showToast) {
|
||||
wx.showToast({
|
||||
title: dashouOk ? '刷新成功' : '刷新失败',
|
||||
icon: dashouOk ? 'success' : 'none',
|
||||
duration: 1500,
|
||||
});
|
||||
this.throttledRefresh(async () => {
|
||||
this.setData({ isLoading: true });
|
||||
try {
|
||||
this.checkRoleStatuses();
|
||||
const results = await Promise.allSettled([
|
||||
this._fetchDashouInfoSilent(),
|
||||
this.fetchChenghaoList(),
|
||||
this._fetchGuanshiInfoSilent(),
|
||||
this.fetchGuanshiChenghaoList(),
|
||||
this._fetchZuzhangInfoSilent(),
|
||||
this._fetchKaoheguanInfoSilent(),
|
||||
]);
|
||||
this.checkRoleStatuses();
|
||||
const dashouOk = results[0].status === 'fulfilled';
|
||||
if (showToast) {
|
||||
wx.showToast({
|
||||
title: dashouOk ? '刷新成功' : '刷新失败',
|
||||
icon: dashouOk ? 'success' : 'none',
|
||||
duration: 1500,
|
||||
});
|
||||
}
|
||||
} catch (e) {
|
||||
if (showToast) {
|
||||
wx.showToast({ title: '刷新失败', icon: 'none' });
|
||||
}
|
||||
} finally {
|
||||
this.setData({ isLoading: false });
|
||||
}
|
||||
} catch (e) {
|
||||
if (showToast) {
|
||||
wx.showToast({ title: '刷新失败', icon: 'none' });
|
||||
}
|
||||
} finally {
|
||||
this._profileRefreshing = false;
|
||||
this.setData({ isLoading: false });
|
||||
}
|
||||
}, 3000);
|
||||
},
|
||||
|
||||
refreshDashouInfo() {
|
||||
@@ -385,34 +332,6 @@ Page(createPage({
|
||||
this.refreshAllInfo(true);
|
||||
},
|
||||
|
||||
onPullDownRefresh() {
|
||||
this.setData({ scrollViewRefreshing: true });
|
||||
Promise.all([
|
||||
this.refreshAllInfo(false),
|
||||
this.loadExamStatus(),
|
||||
]).finally(() => {
|
||||
this.setData({ scrollViewRefreshing: false });
|
||||
wx.stopPullDownRefresh();
|
||||
});
|
||||
},
|
||||
|
||||
async loadIdentityTags() {
|
||||
try {
|
||||
const res = await request({ url: '/jituan/identity-tag/my-tags', method: 'POST' });
|
||||
if (res && res.data && (res.data.code === 0 || res.data.code === 200)) {
|
||||
const d = res.data.data || {};
|
||||
const merged = [
|
||||
...(d.dashou || []),
|
||||
...(d.zuzhang || []),
|
||||
...(d.guanshi || []),
|
||||
];
|
||||
this.setData({ identityTagList: merged });
|
||||
}
|
||||
} catch (e) {
|
||||
/* 静默 */
|
||||
}
|
||||
},
|
||||
|
||||
async _fetchDashouInfoSilent() {
|
||||
const res = await request({ url: '/yonghu/dashouxinxi', method: 'POST' });
|
||||
if (res && res.data.code == 200) {
|
||||
@@ -1096,14 +1015,6 @@ Page(createPage({
|
||||
|
||||
onTapAuthItem(e) {
|
||||
const type = e.currentTarget.dataset.type;
|
||||
if (type === 'staff') {
|
||||
if (isStaffMode()) {
|
||||
enterLockedRole('shangjia', getApp());
|
||||
} else {
|
||||
wx.navigateTo({ url: '/pages/staff-join/staff-join' });
|
||||
}
|
||||
return;
|
||||
}
|
||||
if (type === 'shangjia') {
|
||||
this.onTapShangjiaAuth();
|
||||
return;
|
||||
@@ -1127,21 +1038,6 @@ Page(createPage({
|
||||
wx.navigateTo({ url: '/pages/verify/verify?type=shangjia' });
|
||||
},
|
||||
goToReceiveOrder() { wx.navigateTo({ url: '/pages/accept-order/accept-order' }) },
|
||||
goToDashouExam() { wx.navigateTo({ url: '/pages/dashou-exam/dashou-exam' }) },
|
||||
|
||||
async loadExamStatus() {
|
||||
try {
|
||||
const res = await request({ url: '/jituan/dashou-exam/status', method: 'POST' });
|
||||
const body = res?.data;
|
||||
if (body && (body.code === 200 || body.code === 0) && body.data) {
|
||||
const d = body.data;
|
||||
this.setData({
|
||||
examEnabled: !!d.exam_enabled,
|
||||
examPassed: !!d.exam_passed,
|
||||
});
|
||||
}
|
||||
} catch (e) { /* 静默 */ }
|
||||
},
|
||||
goToMyOrders() { wx.navigateTo({ url: '/pages/fighter-orders/fighter-orders' }) },
|
||||
goToMyPunishment() { wx.navigateTo({ url: '/pages/penalty/penalty/penalty' }) },
|
||||
goToRecharge() { wx.navigateTo({ url: '/pages/fighter-recharge/fighter-recharge' }) },
|
||||
@@ -1149,33 +1045,7 @@ Page(createPage({
|
||||
const type = e?.currentTarget?.dataset?.type || 'dashou';
|
||||
wx.navigateTo({ url: `/pages/fighter-rank/fighter-rank?type=${type}` });
|
||||
},
|
||||
goToGuanzhuKs() {
|
||||
wx.navigateTo({ url: '/pages/manager-assign/manager-assign' });
|
||||
},
|
||||
|
||||
openPindaoModal() {
|
||||
const app = getApp();
|
||||
const cfg = getPindaoConfig(app);
|
||||
const images = resolvePindaoImages(app);
|
||||
this.setData({
|
||||
pindaoVisible: true,
|
||||
pindaoTitle: cfg.title || '频道',
|
||||
pindaoChannelNo: cfg.channel_no || '',
|
||||
pindaoImages: images,
|
||||
});
|
||||
refreshPindaoConfig(app).then(({ cfg: latest, images: latestImages }) => {
|
||||
if (!this.data.pindaoVisible) return;
|
||||
this.setData({
|
||||
pindaoTitle: latest.title || '频道',
|
||||
pindaoChannelNo: latest.channel_no || '',
|
||||
pindaoImages: latestImages,
|
||||
});
|
||||
}).catch(() => {});
|
||||
},
|
||||
|
||||
closePindaoModal() {
|
||||
this.setData({ pindaoVisible: false });
|
||||
},
|
||||
goToGuanzhuKs() { wx.navigateTo({ url: '/pages/manager-assign/manager-assign' }) },
|
||||
goToKaoheDafen() { wx.navigateTo({ url: '/pages/assess-score/assess-score' }) },
|
||||
goToKaoheJilu() { wx.navigateTo({ url: '/pages/assess-log/assess-log' }) },
|
||||
goToKaoheZhongxin() { wx.navigateTo({ url: '/pages/assess-center/assess-center' }) },
|
||||
|
||||
@@ -2,8 +2,7 @@
|
||||
"usingComponents": {
|
||||
"global-notification": "/components/global-notification/global-notification",
|
||||
"chenghao-tag": "/components/chenghao-tag/chenghao-tag",
|
||||
"tab-bar": "/tab-bar/index",
|
||||
"pindao-modal": "/components/pindao-modal/pindao-modal"
|
||||
"tab-bar": "/tab-bar/index"
|
||||
},
|
||||
"navigationStyle": "custom",
|
||||
"backgroundColor": "#fff8e1",
|
||||
|
||||
@@ -26,23 +26,14 @@
|
||||
<view class="user-page">
|
||||
<view class="page-header">
|
||||
<view class="status-bar" style="height:{{statusBar}}px"></view>
|
||||
<view class="nav-bar" style="height:{{navBar - statusBar}}px">
|
||||
<text class="nav-title">我的</text>
|
||||
</view>
|
||||
<view class="nav-bar" style="height:{{navBar - statusBar}}px"><text class="nav-title">我的</text></view>
|
||||
</view>
|
||||
|
||||
<scroll-view
|
||||
class="content"
|
||||
scroll-y
|
||||
enhanced
|
||||
show-scrollbar="{{false}}"
|
||||
refresher-enabled="{{true}}"
|
||||
refresher-threshold="80"
|
||||
refresher-default-style="black"
|
||||
refresher-background="#fff8e1"
|
||||
refresher-triggered="{{scrollViewRefreshing}}"
|
||||
bindrefresherrefresh="onPullDownRefresh"
|
||||
>
|
||||
<view class="refresh-float" bindtap="onTapRefresh">
|
||||
<image class="refresh-float-ico" src="{{imgUrls.iconRefresh}}" mode="aspectFit"/>
|
||||
</view>
|
||||
|
||||
<scroll-view class="content" scroll-y enhanced show-scrollbar="{{false}}">
|
||||
<!-- 用户信息 -->
|
||||
<view class="user-info flexb">
|
||||
<view class="flex">
|
||||
@@ -64,14 +55,11 @@
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="user-header-actions">
|
||||
<image class="header-action-ico" src="{{imgUrls.iconRefresh}}" mode="aspectFit" bindtap="onTapRefresh"/>
|
||||
<image class="setting-ico" src="{{imgUrls.iconEdit}}" mode="aspectFit" bindtap="goToModifyInfo"/>
|
||||
</view>
|
||||
<image class="setting-ico" src="{{imgUrls.iconEdit}}" mode="aspectFit" bindtap="goToModifyInfo"/>
|
||||
</view>
|
||||
|
||||
<!-- 称号 -->
|
||||
<view class="badge-zone" wx:if="{{chenghaoList.length > 0 || (isGuanshi && guanshiChenghaoList.length > 0) || identityTagList.length > 0}}">
|
||||
<view class="badge-zone" wx:if="{{chenghaoList.length > 0 || (isGuanshi && guanshiChenghaoList.length > 0)}}">
|
||||
<scroll-view scroll-x class="badge-scroll" wx:if="{{chenghaoList.length > 0}}">
|
||||
<view class="badge-tag-wrap" wx:for="{{chenghaoList}}" wx:key="index">
|
||||
<chenghao-tag mingcheng="{{item.mingcheng}}" texiaoJson="{{item.texiao_json}}"/>
|
||||
@@ -82,11 +70,6 @@
|
||||
<chenghao-tag mingcheng="{{item.mingcheng}}" texiaoJson="{{item.texiao_json}}"/>
|
||||
</view>
|
||||
</scroll-view>
|
||||
<scroll-view scroll-x class="badge-scroll identity-tag-scroll" wx:if="{{identityTagList.length > 0}}">
|
||||
<view class="badge-tag-wrap" wx:for="{{identityTagList}}" wx:key="id">
|
||||
<chenghao-tag mingcheng="{{item.mingcheng}}" texiaoJson="{{item.texiao_json}}"/>
|
||||
</view>
|
||||
</scroll-view>
|
||||
</view>
|
||||
|
||||
<!-- 佣金/资产卡(逍遥梦 wallet-card) -->
|
||||
@@ -102,14 +85,10 @@
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 会员充值 + 保证金(无后台图时显示文字按钮) -->
|
||||
<view class="banner-row flex" wx:if="{{showRechargeBanners}}">
|
||||
<image wx:if="{{imgUrls.bannerVip}}" class="banner-img" src="{{imgUrls.bannerVip}}" mode="widthFix" bindtap="goToRecharge"/>
|
||||
<image wx:if="{{imgUrls.bannerDeposit}}" class="banner-img" src="{{imgUrls.bannerDeposit}}" mode="widthFix" bindtap="goToRecharge"/>
|
||||
</view>
|
||||
<view class="recharge-text-row flex" wx:else>
|
||||
<view class="recharge-text-btn" catchtap="goToRecharge">充值会员</view>
|
||||
<view class="recharge-text-btn" catchtap="goToRecharge">充值保证金</view>
|
||||
<!-- 会员充值 + 保证金(均跳转同一充值页) -->
|
||||
<view class="banner-row flex">
|
||||
<image class="banner-img" src="{{imgUrls.bannerVip}}" mode="widthFix" bindtap="goToRecharge"/>
|
||||
<image class="banner-img" src="{{imgUrls.bannerDeposit}}" mode="widthFix" bindtap="goToRecharge"/>
|
||||
</view>
|
||||
|
||||
<!-- 资产统计(逍遥梦 freeze-row) -->
|
||||
@@ -144,7 +123,7 @@
|
||||
<!-- 接单服务(对应逍遥梦「我的订单」四宫格) -->
|
||||
<view class="panel shadow">
|
||||
<view class="panel-title flexb"><text class="lg">接单服务</text></view>
|
||||
<view class="order-nav">
|
||||
<view class="order-nav flexa">
|
||||
<view class="nav-item flexmc" bindtap="goToReceiveOrder">
|
||||
<image class="nav-icon" src="{{imgUrls.iconGame}}" mode="aspectFit"/><text class="sm">抢单大厅</text>
|
||||
</view>
|
||||
@@ -157,11 +136,6 @@
|
||||
<view class="nav-item flexmc" bindtap="goToKaohe">
|
||||
<image class="nav-icon" src="{{imgUrls.iconMedal}}" mode="aspectFit"/><text class="sm">考核金牌</text>
|
||||
</view>
|
||||
<view class="nav-item flexmc" bindtap="goToDashouExam">
|
||||
<image class="nav-icon" src="{{imgUrls.iconBook}}" mode="aspectFit"/>
|
||||
<text class="sm">接单考试</text>
|
||||
<text wx:if="{{examEnabled}}" class="exam-tag {{examPassed ? 'exam-tag-pass' : 'exam-tag-pending'}}">{{examPassed ? '已通过' : '待考试'}}</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
@@ -221,6 +195,7 @@
|
||||
<view class="func-item flexmc" bindtap="goToKaoheDafen"><image class="func-icon" src="{{imgUrls.iconKaoheDafen}}" mode="aspectFit"/><text class="func-txt">考核打分</text></view>
|
||||
<view class="func-item flexmc" bindtap="goToKaoheJilu"><image class="func-icon" src="{{imgUrls.iconKaoheJilu}}" mode="aspectFit"/><text class="func-txt">考核记录</text></view>
|
||||
<view class="func-item flexmc" bindtap="goToKaoheZhongxin"><image class="func-icon" src="{{imgUrls.iconKaoheZhongxin}}" mode="aspectFit"/><text class="func-txt">考核中心</text></view>
|
||||
<view class="func-item flexmc" bindtap="goToKaoheWithdraw"><image class="func-icon" src="{{imgUrls.iconWithdraw}}" mode="aspectFit"/><text class="func-txt">考核提现</text></view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
@@ -242,7 +217,6 @@
|
||||
<view class="func-grid">
|
||||
<view class="func-item flexmc" bindtap="goToKefu"><image class="func-icon" src="{{imgUrls.iconKefu}}" mode="aspectFit"/><text class="func-txt">在线客服</text></view>
|
||||
<view class="func-item flexmc" bindtap="goToGuanzhuKs"><image class="func-icon" src="{{imgUrls.iconKuaishou}}" mode="aspectFit"/><text class="func-txt">关注快手</text></view>
|
||||
<view class="func-item flexmc" wx:if="{{showPindaoEntry}}" bindtap="openPindaoModal"><image class="func-icon" src="{{imgUrls.iconPindao}}" mode="aspectFit"/><text class="func-txt">频道</text></view>
|
||||
<view class="func-item flexmc" bindtap="contactInviter"><image class="func-icon" src="{{imgUrls.iconInvite}}" mode="aspectFit"/><text class="func-txt">联系邀请人</text></view>
|
||||
<view class="func-item flexmc" bindtap="goToRules"><image class="func-icon" src="{{imgUrls.iconBook}}" mode="aspectFit"/><text class="func-txt">用户规则</text></view>
|
||||
<view class="func-item flexmc" bindtap="switchToNormal"><image class="func-icon" src="{{imgUrls.iconSwitch}}" mode="aspectFit"/><text class="func-txt">返回点单端</text></view>
|
||||
@@ -262,10 +236,3 @@
|
||||
|
||||
<global-notification id="global-notification"/>
|
||||
<popup-notice id="popupNotice"/>
|
||||
<pindao-modal
|
||||
visible="{{pindaoVisible}}"
|
||||
title="{{pindaoTitle}}"
|
||||
channelNo="{{pindaoChannelNo}}"
|
||||
images="{{pindaoImages}}"
|
||||
bind:close="closePindaoModal"
|
||||
/>
|
||||
|
||||
@@ -40,19 +40,6 @@ page {
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.nav-bar-actions {
|
||||
position: relative;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.nav-refresh-ico {
|
||||
position: absolute;
|
||||
right: 24rpx;
|
||||
width: 44rpx;
|
||||
height: 44rpx;
|
||||
padding: 8rpx;
|
||||
}
|
||||
|
||||
.nav-title {
|
||||
font-size: 34rpx;
|
||||
font-weight: 700;
|
||||
@@ -147,20 +134,6 @@ page {
|
||||
opacity: 0.6;
|
||||
}
|
||||
|
||||
.user-header-actions {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 16rpx;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.header-action-ico {
|
||||
width: 48rpx;
|
||||
height: 48rpx;
|
||||
padding: 6rpx;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.setting-ico {
|
||||
width: 53rpx;
|
||||
height: 53rpx;
|
||||
@@ -260,23 +233,6 @@ page {
|
||||
margin-right: 2%;
|
||||
}
|
||||
|
||||
.recharge-text-row {
|
||||
margin: 20rpx 24rpx 0;
|
||||
gap: 16rpx;
|
||||
}
|
||||
|
||||
.recharge-text-btn {
|
||||
flex: 1;
|
||||
text-align: center;
|
||||
padding: 22rpx 12rpx;
|
||||
border-radius: 16rpx;
|
||||
font-size: 28rpx;
|
||||
font-weight: 600;
|
||||
color: #492f00;
|
||||
background: linear-gradient(180deg, #fff8e1, #ffe8b8);
|
||||
border: 1rpx solid rgba(201, 169, 98, 0.45);
|
||||
}
|
||||
|
||||
.freeze-row {
|
||||
margin: 16rpx 30rpx 0;
|
||||
padding: 20rpx 10rpx;
|
||||
@@ -400,35 +356,11 @@ page {
|
||||
|
||||
.order-nav {
|
||||
padding: 10rpx 0 20rpx;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
flex-wrap: wrap;
|
||||
justify-content: flex-start;
|
||||
align-items: flex-start;
|
||||
}
|
||||
|
||||
.nav-item {
|
||||
width: 20%;
|
||||
box-sizing: border-box;
|
||||
width: 25%;
|
||||
padding: 10rpx 0;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.exam-tag {
|
||||
font-size: 20rpx;
|
||||
margin-top: 4rpx;
|
||||
padding: 2rpx 10rpx;
|
||||
border-radius: 8rpx;
|
||||
}
|
||||
|
||||
.exam-tag-pass {
|
||||
color: #52c41a;
|
||||
background: rgba(82, 196, 26, 0.12);
|
||||
}
|
||||
|
||||
.exam-tag-pending {
|
||||
color: #fa8c16;
|
||||
background: rgba(250, 140, 16, 0.12);
|
||||
}
|
||||
|
||||
.nav-icon {
|
||||
|
||||
67
pages/merchant-data-stats/merchant-data-stats.js
Normal file
67
pages/merchant-data-stats/merchant-data-stats.js
Normal file
@@ -0,0 +1,67 @@
|
||||
import { createPage, request } from '../../utils/base-page.js';
|
||||
import { fetchMerchantOrderStats, applyOrderStatsToPage } from '../../utils/merchant-order-stats.js';
|
||||
|
||||
Page(createPage({
|
||||
data: {
|
||||
statusBar: 20,
|
||||
loading: true,
|
||||
canViewFinance: true,
|
||||
orderStats: {
|
||||
pending_count: 0,
|
||||
pending_amount: '0.00',
|
||||
completed_count: 0,
|
||||
completed_amount: '0.00',
|
||||
refund_count: 0,
|
||||
refund_amount: '0.00',
|
||||
dispatch_count: 0,
|
||||
dispatch_amount: '0.00',
|
||||
},
|
||||
penaltyStats: {
|
||||
fakuan_pending: 0,
|
||||
fakuan_pending_amount: '0.00',
|
||||
jifen_pending: 0,
|
||||
},
|
||||
jinriliushui: '0.00',
|
||||
jinyueliushui: '0.00',
|
||||
jinridingdan: 0,
|
||||
jinrituikuan: 0,
|
||||
},
|
||||
|
||||
onLoad() {
|
||||
const sys = wx.getSystemInfoSync();
|
||||
this.setData({ statusBar: sys.statusBarHeight || 20 });
|
||||
this.loadData();
|
||||
},
|
||||
|
||||
onPullDownRefresh() {
|
||||
this.loadData().finally(() => wx.stopPullDownRefresh());
|
||||
},
|
||||
|
||||
async loadData() {
|
||||
this.setData({ loading: true });
|
||||
try {
|
||||
const statsData = await fetchMerchantOrderStats(request, {});
|
||||
applyOrderStatsToPage(this, statsData);
|
||||
try {
|
||||
const res = await request({ url: '/yonghu/shangjiaxinxi', method: 'POST' });
|
||||
if (res.data && res.data.code === 200) {
|
||||
const d = res.data.data || {};
|
||||
this.setData({
|
||||
jinriliushui: d.jinriliushui || '0.00',
|
||||
jinyueliushui: d.jinyueliushui || '0.00',
|
||||
jinridingdan: d.jinripaidan || 0,
|
||||
jinrituikuan: d.jinrituikuan || 0,
|
||||
});
|
||||
}
|
||||
} catch (e) {
|
||||
console.warn('商家流水加载失败', e);
|
||||
}
|
||||
} finally {
|
||||
this.setData({ loading: false });
|
||||
}
|
||||
},
|
||||
|
||||
goBack() {
|
||||
wx.navigateBack();
|
||||
},
|
||||
}));
|
||||
5
pages/merchant-data-stats/merchant-data-stats.json
Normal file
5
pages/merchant-data-stats/merchant-data-stats.json
Normal file
@@ -0,0 +1,5 @@
|
||||
{
|
||||
"navigationStyle": "custom",
|
||||
"enablePullDownRefresh": true,
|
||||
"usingComponents": {}
|
||||
}
|
||||
56
pages/merchant-data-stats/merchant-data-stats.wxml
Normal file
56
pages/merchant-data-stats/merchant-data-stats.wxml
Normal file
@@ -0,0 +1,56 @@
|
||||
<view class="sub-page sj-page">
|
||||
<view class="status-bar" style="height:{{statusBar}}px"></view>
|
||||
<view class="sub-nav flexb">
|
||||
<text class="back" bindtap="goBack">‹</text>
|
||||
<text class="sub-nav-title">经营数据</text>
|
||||
<text class="back placeholder"></text>
|
||||
</view>
|
||||
|
||||
<scroll-view scroll-y class="sub-scroll" enhanced show-scrollbar="{{false}}" refresher-enabled refresher-triggered="{{loading}}" bindrefresherrefresh="onPullDownRefresh">
|
||||
<view class="sj-panel sj-mx20 data-panel">
|
||||
<view class="data-highlight flexb">
|
||||
<view class="data-hl-item">
|
||||
<text class="data-hl-num accent">{{orderStats.pending_count}}</text>
|
||||
<text class="data-hl-lbl">待结算(单)</text>
|
||||
<text class="data-hl-sub" wx:if="{{canViewFinance}}">¥{{orderStats.pending_amount}}</text>
|
||||
</view>
|
||||
<view class="data-hl-item">
|
||||
<text class="data-hl-num">{{orderStats.completed_count}}</text>
|
||||
<text class="data-hl-lbl">成交总量</text>
|
||||
<text class="data-hl-sub" wx:if="{{canViewFinance}}">¥{{orderStats.completed_amount}}</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="data-grid">
|
||||
<view class="data-cell">
|
||||
<text class="data-cell-num">{{orderStats.refund_count}}</text>
|
||||
<text class="data-cell-lbl">退款总量</text>
|
||||
<text class="data-cell-sub" wx:if="{{canViewFinance}}">¥{{orderStats.refund_amount}}</text>
|
||||
</view>
|
||||
<view class="data-cell">
|
||||
<text class="data-cell-num">{{orderStats.dispatch_count}}</text>
|
||||
<text class="data-cell-lbl">发单总量</text>
|
||||
<text class="data-cell-sub" wx:if="{{canViewFinance}}">¥{{orderStats.dispatch_amount}}</text>
|
||||
</view>
|
||||
<view class="data-cell">
|
||||
<text class="data-cell-num">{{jinriliushui}}</text>
|
||||
<text class="data-cell-lbl">今日流水</text>
|
||||
</view>
|
||||
<view class="data-cell">
|
||||
<text class="data-cell-num">{{jinyueliushui}}</text>
|
||||
<text class="data-cell-lbl">今月流水</text>
|
||||
</view>
|
||||
<view class="data-cell">
|
||||
<text class="data-cell-num">{{jinridingdan}}</text>
|
||||
<text class="data-cell-lbl">今日派单</text>
|
||||
</view>
|
||||
<view class="data-cell">
|
||||
<text class="data-cell-num">{{jinrituikuan}}</text>
|
||||
<text class="data-cell-lbl">今日退款</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="penalty-mini" wx:if="{{penaltyStats.fakuan_pending || penaltyStats.jifen_pending}}">
|
||||
<text>处罚待处理:罚单 {{penaltyStats.fakuan_pending}}(¥{{penaltyStats.fakuan_pending_amount}})· 积分 {{penaltyStats.jifen_pending}}</text>
|
||||
</view>
|
||||
</view>
|
||||
</scroll-view>
|
||||
</view>
|
||||
84
pages/merchant-data-stats/merchant-data-stats.wxss
Normal file
84
pages/merchant-data-stats/merchant-data-stats.wxss
Normal file
@@ -0,0 +1,84 @@
|
||||
@import '../../styles/shangjia-xym-common.wxss';
|
||||
|
||||
page { background: #fff8e1; }
|
||||
|
||||
.sub-scroll { height: calc(100vh - 120rpx); }
|
||||
|
||||
.data-panel { padding: 24rpx; margin-top: 16rpx; }
|
||||
|
||||
.data-highlight {
|
||||
margin-bottom: 24rpx;
|
||||
gap: 16rpx;
|
||||
}
|
||||
|
||||
.data-hl-item {
|
||||
flex: 1;
|
||||
text-align: center;
|
||||
background: #fff;
|
||||
border-radius: 16rpx;
|
||||
padding: 20rpx 12rpx;
|
||||
}
|
||||
|
||||
.data-hl-num {
|
||||
display: block;
|
||||
font-size: 40rpx;
|
||||
font-weight: 700;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.data-hl-num.accent { color: #e65100; }
|
||||
|
||||
.data-hl-lbl {
|
||||
display: block;
|
||||
font-size: 24rpx;
|
||||
color: #888;
|
||||
margin-top: 8rpx;
|
||||
}
|
||||
|
||||
.data-hl-sub {
|
||||
display: block;
|
||||
font-size: 22rpx;
|
||||
color: #999;
|
||||
margin-top: 4rpx;
|
||||
}
|
||||
|
||||
.data-grid {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr 1fr;
|
||||
gap: 16rpx;
|
||||
}
|
||||
|
||||
.data-cell {
|
||||
background: #fff;
|
||||
border-radius: 16rpx;
|
||||
padding: 20rpx 16rpx;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.data-cell-num {
|
||||
display: block;
|
||||
font-size: 32rpx;
|
||||
font-weight: 600;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.data-cell-lbl {
|
||||
display: block;
|
||||
font-size: 22rpx;
|
||||
color: #888;
|
||||
margin-top: 6rpx;
|
||||
}
|
||||
|
||||
.data-cell-sub {
|
||||
display: block;
|
||||
font-size: 20rpx;
|
||||
color: #aaa;
|
||||
margin-top: 4rpx;
|
||||
}
|
||||
|
||||
.penalty-mini {
|
||||
margin-top: 20rpx;
|
||||
font-size: 24rpx;
|
||||
color: #666;
|
||||
line-height: 1.5;
|
||||
}
|
||||
@@ -34,6 +34,10 @@ Page({
|
||||
|
||||
list: [],
|
||||
|
||||
displayList: [],
|
||||
|
||||
searchKeyword: '',
|
||||
|
||||
isOwner: false,
|
||||
|
||||
},
|
||||
@@ -124,7 +128,9 @@ Page({
|
||||
|
||||
const raw = (res.data.data && res.data.data.list) || [];
|
||||
|
||||
this.setData({ list: this.formatList(raw) });
|
||||
this._allList = this.formatList(raw);
|
||||
|
||||
this.applySearchFilter();
|
||||
|
||||
}
|
||||
|
||||
@@ -140,9 +146,31 @@ Page({
|
||||
|
||||
goBack() { wx.navigateBack(); },
|
||||
|
||||
applySearchFilter() {
|
||||
const kw = (this.data.searchKeyword || '').trim().toLowerCase();
|
||||
const all = this._allList || [];
|
||||
if (!kw) {
|
||||
this.setData({ list: all, displayList: all });
|
||||
return;
|
||||
}
|
||||
const filtered = all.filter((item) => {
|
||||
const uid = String(item.uid || '').toLowerCase();
|
||||
const remark = String(item.merchant_remark || '').toLowerCase();
|
||||
const nick = String(item.nickname || '').toLowerCase();
|
||||
return uid.includes(kw) || remark.includes(kw) || nick.includes(kw);
|
||||
});
|
||||
this.setData({ list: all, displayList: filtered });
|
||||
},
|
||||
|
||||
onSearchInput(e) {
|
||||
this.setData({ searchKeyword: e.detail.value || '' });
|
||||
this.applySearchFilter();
|
||||
},
|
||||
|
||||
goBack() { wx.navigateBack(); },
|
||||
clearSearch() {
|
||||
this.setData({ searchKeyword: '' });
|
||||
this.applySearchFilter();
|
||||
},
|
||||
|
||||
goStaffOrders(e) {
|
||||
const id = e.currentTarget.dataset.id;
|
||||
|
||||
@@ -12,11 +12,17 @@
|
||||
|
||||
</view>
|
||||
|
||||
|
||||
<view class="filter-row sj-mx20">
|
||||
<view class="search-box">
|
||||
<image class="search-icon" src="/images/icon_search.svg" mode="aspectFit"/>
|
||||
<input class="search-input" placeholder="搜索用户ID或备注" value="{{searchKeyword}}" bindinput="onSearchInput" confirm-type="search"/>
|
||||
<view class="search-clear" wx:if="{{searchKeyword}}" bindtap="clearSearch"><text>✕</text></view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<scroll-view scroll-y class="sub-scroll" enhanced show-scrollbar="{{false}}">
|
||||
|
||||
<view wx:for="{{list}}" wx:key="id" class="kefu-card sj-mx20 {{item.isDisabled ? 'disabled-card' : ''}}">
|
||||
<view wx:for="{{displayList}}" wx:key="id" class="kefu-card sj-mx20 {{item.isDisabled ? 'disabled-card' : ''}}">
|
||||
|
||||
<view class="kefu-head flex">
|
||||
|
||||
@@ -153,7 +159,7 @@
|
||||
|
||||
</view>
|
||||
|
||||
<view wx:if="{{!list.length}}" class="load-tip">暂无客服成员</view>
|
||||
<view wx:if="{{!displayList.length}}" class="load-tip">暂无客服成员</view>
|
||||
|
||||
<view class="load-tip link-tip" bindtap="goAudit">操作日志 ›</view>
|
||||
|
||||
|
||||
@@ -155,3 +155,16 @@
|
||||
font-size: 22rpx;
|
||||
color: #bbb;
|
||||
}
|
||||
|
||||
.filter-row { margin-bottom: 8rpx; }
|
||||
.search-box {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
background: #fff;
|
||||
border-radius: 32rpx;
|
||||
padding: 12rpx 20rpx;
|
||||
box-shadow: 0 2rpx 8rpx rgba(0,0,0,0.06);
|
||||
}
|
||||
.search-icon { width: 32rpx; height: 32rpx; margin-right: 12rpx; }
|
||||
.search-input { flex: 1; font-size: 26rpx; }
|
||||
.search-clear { padding: 8rpx; color: #999; font-size: 24rpx; }
|
||||
|
||||
@@ -1,9 +1,7 @@
|
||||
// pages/order-pool/order-pool.js
|
||||
const app = getApp();
|
||||
import request from '../../utils/request.js';
|
||||
import { normalizeOrderTags } from '../../utils/order-tags.js';
|
||||
import PopupService from '../../services/popupService.js';
|
||||
import { ICON_KEYS, resolveMiniappIcon, MERCHANT_GOLD_BANNER_FALLBACK } from '../../utils/miniapp-icons.js';
|
||||
|
||||
Page({
|
||||
data: {
|
||||
@@ -30,7 +28,7 @@ Page({
|
||||
// 4. 刷新控制字段
|
||||
scrollViewRefreshing: false,
|
||||
lastRefreshTime: 0,
|
||||
refreshCooldown: 0,
|
||||
refreshCooldown: 2000,
|
||||
isLoadingMore: false,
|
||||
|
||||
// 5. 切换类型冷却时间控制
|
||||
@@ -47,34 +45,12 @@ Page({
|
||||
|
||||
// 商品轮播展示(只读 globalData,无额外接口)
|
||||
lunboList: [],
|
||||
gonggao: '',
|
||||
|
||||
// 标签筛选
|
||||
bankuaiBiaoqian: [],
|
||||
xuanzhongBiaoqianId: 0,
|
||||
|
||||
iconRefresh: '',
|
||||
goldBannerUrl: '',
|
||||
},
|
||||
|
||||
async onLoad(options) {
|
||||
const oss = app.globalData.ossImageUrl || '';
|
||||
this.syncConfiguredIcons(oss);
|
||||
this.syncShopBannerFromGlobal();
|
||||
this.loadGlobalStatus();
|
||||
const needLoadOrders = !app.globalData._acceptOrderDataLoaded;
|
||||
this.checkAuthorization(false, needLoadOrders);
|
||||
if (needLoadOrders && this.data.xuanzhongLeixingId) {
|
||||
app.globalData._acceptOrderDataLoaded = true;
|
||||
}
|
||||
},
|
||||
|
||||
syncConfiguredIcons(oss) {
|
||||
const ossBase = oss || app.globalData.ossImageUrl || '';
|
||||
this.setData({
|
||||
iconRefresh: resolveMiniappIcon(app, ICON_KEYS.ICON_REFRESH, ossBase + 'beijing/guanshiduan/icon-refresh.png'),
|
||||
goldBannerUrl: resolveMiniappIcon(app, ICON_KEYS.MERCHANT_GOLD_BANNER, MERCHANT_GOLD_BANNER_FALLBACK),
|
||||
});
|
||||
this.checkAuthorization();
|
||||
},
|
||||
// 页面隐藏时清理弹窗视图
|
||||
onHide: function () {
|
||||
@@ -86,10 +62,9 @@ Page({
|
||||
|
||||
onShow() {
|
||||
this.syncShopBannerFromGlobal();
|
||||
this.syncConfiguredIcons();
|
||||
this.registerNotificationComponent();
|
||||
this.loadGlobalStatus();
|
||||
this.checkAuthorization(true);
|
||||
this.checkAuthorization();
|
||||
},
|
||||
|
||||
registerNotificationComponent() {
|
||||
@@ -102,17 +77,14 @@ Page({
|
||||
}
|
||||
},
|
||||
|
||||
/** 同步轮播与公告(仅读缓存) */
|
||||
/** 同步点单端已加载的商品轮播图,仅展示用 */
|
||||
syncShopBannerFromGlobal() {
|
||||
const oss = app.globalData.ossImageUrl || '';
|
||||
const lunboList = (app.globalData.shangpinlunbo || []).map((url) => {
|
||||
if (!url) return '';
|
||||
return url.startsWith('http') ? url : oss + url;
|
||||
}).filter(Boolean);
|
||||
this.setData({
|
||||
lunboList,
|
||||
gonggao: app.globalData.shangpingonggao || '',
|
||||
});
|
||||
this.setData({ lunboList });
|
||||
},
|
||||
|
||||
loadGlobalStatus() {
|
||||
@@ -136,7 +108,7 @@ Page({
|
||||
});
|
||||
},
|
||||
|
||||
checkAuthorization(skipReload = false, loadOrdersOnAuth = false) {
|
||||
checkAuthorization() {
|
||||
const { dashoustatus, zhuanghaoStatus } = this.data;
|
||||
|
||||
const isDashouValid = (dashoustatus && dashoustatus == 1) || false;
|
||||
@@ -151,19 +123,16 @@ Page({
|
||||
this.setData({ unauthorizedMsg: msg || '无法使用抢单功能' });
|
||||
} else {
|
||||
this.setData({ showUnauthorized: false });
|
||||
if (!skipReload) {
|
||||
if (!this.data.shangpinleixing.length) {
|
||||
this.loadShangpinLeixing(loadOrdersOnAuth);
|
||||
} else if (loadOrdersOnAuth && this.data.xuanzhongLeixingId) {
|
||||
this.loadDingdanList(true);
|
||||
this.loadBankuaiBiaoqian();
|
||||
}
|
||||
PopupService.checkAndShow(this, 'jiedanchi');
|
||||
if (!this.data.shangpinleixing.length) {
|
||||
this.loadShangpinLeixing();
|
||||
} else if (this.data.xuanzhongLeixingId) {
|
||||
this.loadDingdanList(true);
|
||||
}
|
||||
PopupService.checkAndShow(this, 'jiedanchi');
|
||||
}
|
||||
},
|
||||
|
||||
async loadShangpinLeixing(autoLoadOrders = false) {
|
||||
async loadShangpinLeixing() {
|
||||
wx.showLoading({ title: '加载商品类型...' });
|
||||
try {
|
||||
const res = await request({
|
||||
@@ -191,9 +160,8 @@ Page({
|
||||
shangpinleixing: processedList,
|
||||
xuanzhongLeixingId: processedList[0]?.id || null
|
||||
});
|
||||
if (autoLoadOrders && this.data.xuanzhongLeixingId) {
|
||||
if (this.data.xuanzhongLeixingId) {
|
||||
this.loadDingdanList(true);
|
||||
this.loadBankuaiBiaoqian();
|
||||
}
|
||||
} else {
|
||||
wx.showToast({ title: res.data?.msg || '加载商品类型失败', icon: 'none', duration: 2000 });
|
||||
@@ -214,38 +182,6 @@ Page({
|
||||
}));
|
||||
},
|
||||
|
||||
async loadBankuaiBiaoqian() {
|
||||
const leixingId = this.data.xuanzhongLeixingId;
|
||||
if (!leixingId) return;
|
||||
try {
|
||||
const res = await request({
|
||||
url: '/dengji/bkqhbq',
|
||||
method: 'POST',
|
||||
data: { leixing_id: leixingId }
|
||||
});
|
||||
if (res && res.data.code === 0) {
|
||||
this.setData({
|
||||
bankuaiBiaoqian: res.data.data.biaoqian_list || [],
|
||||
xuanzhongBiaoqianId: 0
|
||||
});
|
||||
}
|
||||
} catch (e) {
|
||||
// 标签加载失败不影响主流程
|
||||
}
|
||||
},
|
||||
|
||||
async selectBiaoqian(e) {
|
||||
const id = e.currentTarget.dataset.id;
|
||||
if (id === this.data.xuanzhongBiaoqianId) return;
|
||||
this.setData({
|
||||
xuanzhongBiaoqianId: id,
|
||||
dingdanList: [],
|
||||
page: 1,
|
||||
hasMore: true
|
||||
});
|
||||
await this.loadDingdanList(true);
|
||||
},
|
||||
|
||||
async selectLeixing(e) {
|
||||
const now = Date.now();
|
||||
if (now - this.data.lastSwitchTime < this.data.switchCooldown) {
|
||||
@@ -266,11 +202,9 @@ Page({
|
||||
xuanzhongLeixingId: leixingId,
|
||||
dingdanList: [],
|
||||
page: 1,
|
||||
hasMore: true,
|
||||
xuanzhongBiaoqianId: 0
|
||||
hasMore: true
|
||||
});
|
||||
await this.loadDingdanList(true);
|
||||
await this.loadBankuaiBiaoqian();
|
||||
} catch (error) {
|
||||
console.error('切换类型失败:', error);
|
||||
} finally {
|
||||
@@ -297,8 +231,7 @@ Page({
|
||||
data: {
|
||||
leixing_id: this.data.xuanzhongLeixingId,
|
||||
page: loadPage,
|
||||
page_size: this.data.pageSize,
|
||||
biaoqian_id: this.data.xuanzhongBiaoqianId || undefined
|
||||
page_size: this.data.pageSize
|
||||
}
|
||||
});
|
||||
|
||||
@@ -343,56 +276,30 @@ Page({
|
||||
|
||||
processDingdanItem(item) {
|
||||
const ossUrl = app.globalData.ossImageUrl || '';
|
||||
const defaultAvatar = ossUrl + (app.globalData.morentouxiang || 'avatar/default.jpg');
|
||||
|
||||
const leixing = this.data.shangpinleixing.find((l) => l.id == item.leixing_id);
|
||||
let leixingIconUrl = '';
|
||||
if (leixing && leixing.full_tupian_url) {
|
||||
leixingIconUrl = leixing.full_tupian_url;
|
||||
} else if (leixing && leixing.tupian_url) {
|
||||
leixingIconUrl = leixing.tupian_url.startsWith('http')
|
||||
? leixing.tupian_url
|
||||
: ossUrl + leixing.tupian_url;
|
||||
let fullTupianUrl = '';
|
||||
if (item.tupian) {
|
||||
fullTupianUrl = !item.tupian.startsWith('http') ? ossUrl + item.tupian : item.tupian;
|
||||
} else {
|
||||
leixingIconUrl = '/images/default-order.png';
|
||||
const leixing = this.data.shangpinleixing.find(l => l.id === item.leixing_id);
|
||||
fullTupianUrl = leixing ? leixing.full_tupian_url : '/images/default-order.png';
|
||||
}
|
||||
|
||||
const isZhiding = item.zhuangtai === 7;
|
||||
|
||||
let zhidingAvatar = '';
|
||||
if (item.zhiding_avatar) {
|
||||
zhidingAvatar = !item.zhiding_avatar.startsWith('http')
|
||||
? ossUrl + item.zhiding_avatar
|
||||
: item.zhiding_avatar;
|
||||
zhidingAvatar = !item.zhiding_avatar.startsWith('http') ? ossUrl + item.zhiding_avatar : item.zhiding_avatar;
|
||||
}
|
||||
const zhidingNicheng = item.zhiding_nicheng || '';
|
||||
|
||||
let shangjiaAvatar = defaultAvatar;
|
||||
const sjAvatar = (item.sj_avatar || '').trim();
|
||||
if (sjAvatar) {
|
||||
shangjiaAvatar = sjAvatar.startsWith('http') ? sjAvatar : ossUrl + sjAvatar;
|
||||
}
|
||||
|
||||
let hasRequiredMember = true;
|
||||
if (item.yaoqiuleixing == 1 && item.huiyuan_id) {
|
||||
hasRequiredMember = this.data.huiyuanList.some((h) => h.huiyuanid == item.huiyuan_id);
|
||||
}
|
||||
|
||||
const tags = normalizeOrderTags(item);
|
||||
|
||||
return {
|
||||
...item,
|
||||
full_tupian_url: leixingIconUrl,
|
||||
leixing_icon_url: leixingIconUrl,
|
||||
shangjia_avatar_full: shangjiaAvatar,
|
||||
isZhiding,
|
||||
full_tupian_url: fullTupianUrl,
|
||||
isZhiding: isZhiding,
|
||||
isPingtai: item.pingtai == 1,
|
||||
isShangjia: item.pingtai == 2,
|
||||
zhiding_avatar_full: zhidingAvatar,
|
||||
zhiding_nicheng: zhidingNicheng,
|
||||
...tags,
|
||||
shangjia_youzhi: !!item.shangjia_youzhi,
|
||||
hasRequiredMember,
|
||||
zhiding_nicheng: zhidingNicheng
|
||||
};
|
||||
},
|
||||
|
||||
@@ -515,6 +422,15 @@ Page({
|
||||
},
|
||||
|
||||
onReachBottom() {
|
||||
const now = Date.now();
|
||||
if (now - this.data.lastRefreshTime < this.data.refreshCooldown) {
|
||||
wx.showToast({
|
||||
title: `操作太快,请${Math.ceil((this.data.refreshCooldown - (now - this.data.lastRefreshTime)) / 1000)}秒后再试`,
|
||||
icon: 'none',
|
||||
duration: 1500
|
||||
});
|
||||
return;
|
||||
}
|
||||
if (this.data.isLoading || this.data.isLoadingMore) return;
|
||||
if (this.data.hasMore && !this.data.isLoading && this.data.xuanzhongLeixingId) {
|
||||
this.setData({ page: this.data.page + 1 });
|
||||
@@ -522,24 +438,24 @@ Page({
|
||||
}
|
||||
},
|
||||
|
||||
onTapRefresh() {
|
||||
if (!this.data.xuanzhongLeixingId) {
|
||||
wx.showToast({ title: '请先选择订单类型', icon: 'none' });
|
||||
onPullDownRefresh() {
|
||||
const now = Date.now();
|
||||
if (now - this.data.lastRefreshTime < this.data.refreshCooldown) {
|
||||
this.setData({ scrollViewRefreshing: false });
|
||||
wx.showToast({
|
||||
title: `操作太快,请${Math.ceil((this.data.refreshCooldown - (now - this.data.lastRefreshTime)) / 1000)}秒后再试`,
|
||||
icon: 'none',
|
||||
duration: 1500
|
||||
});
|
||||
return;
|
||||
}
|
||||
if (this.data.isLoading) return;
|
||||
this.setData({ page: 1, hasMore: true, scrollViewRefreshing: true });
|
||||
this.loadDingdanList(true);
|
||||
},
|
||||
|
||||
onPullDownRefresh() {
|
||||
if (this.data.isLoading) {
|
||||
this.setData({ scrollViewRefreshing: false });
|
||||
return;
|
||||
}
|
||||
this.setData({
|
||||
this.setData({
|
||||
scrollViewRefreshing: true,
|
||||
lastRefreshTime: Date.now(),
|
||||
lastRefreshTime: now
|
||||
});
|
||||
if (this.data.xuanzhongLeixingId) {
|
||||
this.setData({ page: 1, hasMore: true });
|
||||
|
||||
@@ -1,12 +1,9 @@
|
||||
{
|
||||
"navigationBarTitleText": "接单池",
|
||||
"navigationBarBackgroundColor": "#f7dc51",
|
||||
"navigationBarTextStyle": "black",
|
||||
"enablePullDownRefresh": false,
|
||||
"backgroundTextStyle": "dark",
|
||||
"backgroundColor": "#fff8e1",
|
||||
"usingComponents": {
|
||||
"chenghao-tag": "/components/chenghao-tag/chenghao-tag",
|
||||
"global-notification": "/components/global-notification/global-notification"
|
||||
}
|
||||
}
|
||||
"navigationBarTitleText": "接单池",
|
||||
"enablePullDownRefresh": false,
|
||||
"backgroundTextStyle": "dark",
|
||||
"backgroundColor": "#f5f7fa",
|
||||
"usingComponents": {
|
||||
"global-notification": "/components/global-notification/global-notification"
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,6 @@
|
||||
<!-- pages/order-pool/order-pool.wxml 抢单池(逍遥梦布局) -->
|
||||
<!--pages/qiangdan/qiangdan.wxml-->
|
||||
<view class="qiangdan-page">
|
||||
<!-- 授权提示页(未开启打手功能时显示) -->
|
||||
<view class="unauthorized-container" wx:if="{{showUnauthorized}}">
|
||||
<view class="unauthorized-card">
|
||||
<view class="card-glow"></view>
|
||||
@@ -16,310 +17,266 @@
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 正常内容(授权后显示) -->
|
||||
<block wx:else>
|
||||
<view class="refresh-float" wx:if="{{xuanzhongLeixingId}}" bindtap="onTapRefresh">
|
||||
<image class="refresh-float-ico" src="{{iconRefresh}}" mode="aspectFit"/>
|
||||
<!-- 商品轮播(只读 globalData,与点单端同源) -->
|
||||
<view class="xym-lunbo-container" wx:if="{{lunboList.length > 0}}">
|
||||
<swiper
|
||||
class="xym-lunbo-swiper"
|
||||
indicator-dots="{{lunboList.length > 1}}"
|
||||
indicator-color="rgba(255,255,255,0.6)"
|
||||
indicator-active-color="#ffd061"
|
||||
autoplay="{{lunboList.length > 1}}"
|
||||
interval="4000"
|
||||
circular
|
||||
>
|
||||
<block wx:for="{{lunboList}}" wx:key="index">
|
||||
<swiper-item>
|
||||
<image class="xym-lunbo-image" src="{{item}}" mode="aspectFill" />
|
||||
</swiper-item>
|
||||
</block>
|
||||
</swiper>
|
||||
</view>
|
||||
|
||||
<scroll-view
|
||||
class="page-main-scroll"
|
||||
scroll-y
|
||||
enhanced
|
||||
show-scrollbar="{{false}}"
|
||||
refresher-enabled="{{xuanzhongLeixingId != null}}"
|
||||
refresher-threshold="80"
|
||||
refresher-default-style="black"
|
||||
refresher-background="#fff8e1"
|
||||
refresher-triggered="{{scrollViewRefreshing}}"
|
||||
bindrefresherrefresh="onPullDownRefresh"
|
||||
bindscrolltolower="onReachBottom"
|
||||
>
|
||||
<view class="refresher-container" slot="refresher">
|
||||
<text wx:if="{{scrollViewRefreshing}}" class="refreshing-text">正在刷新...</text>
|
||||
<text wx:else class="pull-down-text">下拉刷新订单</text>
|
||||
</view>
|
||||
|
||||
<!-- 公告置顶(逍遥梦:轮播之上) -->
|
||||
<view class="xym-gonggao-bar" wx:if="{{gonggao}}">
|
||||
<image class="xym-gonggao-ico" src="/images/notice.png" mode="aspectFit"/>
|
||||
<text class="xym-gonggao-txt">{{gonggao}}</text>
|
||||
</view>
|
||||
|
||||
<!-- 轮播 -->
|
||||
<view class="xym-lunbo-container" wx:if="{{lunboList.length > 0}}">
|
||||
<swiper
|
||||
class="xym-lunbo-swiper"
|
||||
indicator-dots="{{lunboList.length > 1}}"
|
||||
indicator-color="rgba(255,255,255,0.6)"
|
||||
indicator-active-color="#ffd061"
|
||||
autoplay="{{lunboList.length > 1}}"
|
||||
interval="4000"
|
||||
circular
|
||||
>
|
||||
<block wx:for="{{lunboList}}" wx:key="index">
|
||||
<swiper-item>
|
||||
<image class="xym-lunbo-image" src="{{item}}" mode="aspectFill"/>
|
||||
</swiper-item>
|
||||
<!-- 顶部区域:商品类型选择 -->
|
||||
<view class="leixing-quyu">
|
||||
<scroll-view class="leixing-scroll" scroll-x enhanced show-scrollbar="{{false}}">
|
||||
<view class="leixing-container">
|
||||
<block wx:for="{{shangpinleixing}}" wx:key="id">
|
||||
<view
|
||||
class="leixing-item {{xuanzhongLeixingId == item.id ? 'leixing-active' : ''}}"
|
||||
data-id="{{item.id}}"
|
||||
bindtap="selectLeixing"
|
||||
>
|
||||
<!-- 选中态的光晕特效 -->
|
||||
<view wx:if="{{xuanzhongLeixingId == item.id}}" class="guangyun-effect"></view>
|
||||
<image
|
||||
class="leixing-tupian"
|
||||
src="{{item.full_tupian_url}}"
|
||||
mode="aspectFill"
|
||||
/>
|
||||
<text class="leixing-jieshao">{{item.jieshao}}</text>
|
||||
</view>
|
||||
</block>
|
||||
</swiper>
|
||||
</view>
|
||||
</view>
|
||||
</scroll-view>
|
||||
</view>
|
||||
|
||||
<!-- 商品类型 -->
|
||||
<view class="leixing-quyu">
|
||||
<scroll-view class="leixing-scroll" scroll-x enhanced show-scrollbar="{{false}}">
|
||||
<view class="leixing-container">
|
||||
<block wx:for="{{shangpinleixing}}" wx:key="id">
|
||||
<view
|
||||
class="leixing-item {{xuanzhongLeixingId == item.id ? 'leixing-active' : ''}}"
|
||||
data-id="{{item.id}}"
|
||||
bindtap="selectLeixing"
|
||||
<!-- 分割线 -->
|
||||
<view class="fenge-xian"></view>
|
||||
|
||||
<!-- 订单列表容器 -->
|
||||
<view class="dingdan-container">
|
||||
<scroll-view
|
||||
class="dingdan-scroll-view"
|
||||
scroll-y
|
||||
enhanced
|
||||
show-scrollbar="{{false}}"
|
||||
refresher-enabled="{{xuanzhongLeixingId != null}}"
|
||||
refresher-threshold="80"
|
||||
refresher-default-style="black"
|
||||
refresher-background="#f5f5f5"
|
||||
refresher-triggered="{{scrollViewRefreshing}}"
|
||||
bindrefresherrefresh="onPullDownRefresh"
|
||||
bindscrolltolower="onReachBottom"
|
||||
>
|
||||
<!-- 下拉刷新区域 -->
|
||||
<view class="refresher-container" slot="refresher">
|
||||
<text wx:if="{{scrollViewRefreshing}}" class="refreshing-text">正在刷新...</text>
|
||||
<text wx:else class="pull-down-text">下拉刷新订单</text>
|
||||
</view>
|
||||
|
||||
<!-- 订单列表 -->
|
||||
<view class="dingdan-list">
|
||||
<!-- 状态提示 -->
|
||||
<view wx:if="{{!xuanzhongLeixingId}}" class="empty-tip">
|
||||
<image src="/images/icon_select.png" class="tip-icon"></image>
|
||||
<text class="tip-text">请先选择上方订单类型</text>
|
||||
</view>
|
||||
|
||||
<view wx:elif="{{dingdanList.length === 0 && !isLoading}}" class="empty-tip">
|
||||
<image src="/images/icon_empty_order.png" class="tip-icon"></image>
|
||||
<text class="tip-text">当前类型暂无待抢订单</text>
|
||||
</view>
|
||||
|
||||
<!-- 订单卡片列表 -->
|
||||
<block wx:for="{{dingdanList}}" wx:key="dingdan_id">
|
||||
<!-- 平台订单卡片 (pingtai == 1) -->
|
||||
<view
|
||||
wx:if="{{item.isPingtai}}"
|
||||
class="dingdan-card pingtai-card"
|
||||
data-item="{{item}}"
|
||||
>
|
||||
<!-- 顶部信息区 -->
|
||||
<view class="card-top">
|
||||
<text class="creat-time">{{item.creat_time}}</text>
|
||||
<view class="top-line"></view>
|
||||
<text class="pingtai-tag">平台订单</text>
|
||||
</view>
|
||||
|
||||
<!-- 指定单标识行 - 新增头像和昵称 -->
|
||||
<view wx:if="{{item.isZhiding}}" class="zhiding-row">
|
||||
<text class="zhiding-icon">指定</text>
|
||||
<image
|
||||
wx:if="{{item.zhiding_avatar_full}}"
|
||||
class="zhiding-avatar"
|
||||
src="{{item.zhiding_avatar_full}}"
|
||||
mode="aspectFill"
|
||||
/>
|
||||
<text class="zhiding-nicheng">{{item.zhiding_nicheng || '指定接单员'}}</text>
|
||||
<text class="zhiding-uid">UID: {{item.zhiding_uid || '未知'}}</text>
|
||||
</view>
|
||||
|
||||
<!-- 内容区:圆形图片 + 介绍 -->
|
||||
<view class="card-content">
|
||||
<image
|
||||
class="neirong-tupian"
|
||||
src="{{item.full_tupian_url}}"
|
||||
mode="aspectFill"
|
||||
/>
|
||||
<view
|
||||
class="jieshao-box {{item.jieshao && item.jieshao.length > 60 ? 'jieshao-ellipsis' : ''}}"
|
||||
data-type="jieshao"
|
||||
data-content="{{item.jieshao}}"
|
||||
bindtap="onViewDetail"
|
||||
>
|
||||
<text class="jieshao-label">介绍:</text>
|
||||
<text class="jieshao-text">{{item.jieshao || '暂无介绍'}}</text>
|
||||
<text wx:if="{{item.jieshao && item.jieshao.length > 60}}" class="view-more">[点击查看]</text>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 备注区 -->
|
||||
<view
|
||||
wx:if="{{item.beizhu}}"
|
||||
class="beizhu-box {{item.beizhu.length > 40 ? 'beizhu-ellipsis' : ''}}"
|
||||
data-type="beizhu"
|
||||
data-content="{{item.beizhu}}"
|
||||
bindtap="onViewDetail"
|
||||
>
|
||||
<view wx:if="{{xuanzhongLeixingId == item.id}}" class="guangyun-effect"></view>
|
||||
<image class="leixing-tupian" src="{{item.full_tupian_url}}" mode="aspectFill"/>
|
||||
<text class="leixing-jieshao">{{item.jieshao}}</text>
|
||||
<text class="beizhu-label">备注:</text>
|
||||
<text class="beizhu-text">{{item.beizhu}}</text>
|
||||
<text wx:if="{{item.beizhu.length > 40}}" class="view-more">[点击查看]</text>
|
||||
</view>
|
||||
</block>
|
||||
|
||||
<!-- 底部:分佣 + 抢单按钮 -->
|
||||
<view class="card-bottom">
|
||||
<view class="fenyong-box">
|
||||
<view class="fenyong-mark">佣</view>
|
||||
<text class="fenyong-text">分佣</text>
|
||||
<text class="fenyong-price">{{item.dashou_fencheng || 0}}</text>
|
||||
<text class="fenyong-unit">元</text>
|
||||
</view>
|
||||
<view
|
||||
class="qiangdan-btn pingtai-btn"
|
||||
data-item="{{item}}"
|
||||
bindtap="onQiangdanTap"
|
||||
>
|
||||
<text class="btn-text">立即抢单</text>
|
||||
<view class="btn-shine"></view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 商家订单卡片 (pingtai == 2) -->
|
||||
<view
|
||||
wx:elif="{{item.isShangjia}}"
|
||||
class="dingdan-card shangjia-card"
|
||||
data-item="{{item}}"
|
||||
>
|
||||
<!-- 顶部信息区 -->
|
||||
<view class="card-top">
|
||||
<text class="creat-time">{{item.creat_time}}</text>
|
||||
<view class="top-line"></view>
|
||||
<text class="pingtai-tag">商家发单</text>
|
||||
</view>
|
||||
|
||||
<!-- 指定单标识行 - 新增头像和昵称 -->
|
||||
<view wx:if="{{item.isZhiding}}" class="zhiding-row">
|
||||
<text class="zhiding-icon">指定</text>
|
||||
<image
|
||||
wx:if="{{item.zhiding_avatar_full}}"
|
||||
class="zhiding-avatar"
|
||||
src="{{item.zhiding_avatar_full}}"
|
||||
mode="aspectFill"
|
||||
/>
|
||||
<text class="zhiding-nicheng">{{item.zhiding_nicheng || '指定接单员'}}</text>
|
||||
<text class="zhiding-uid">UID: {{item.zhiding_uid || '未知'}}</text>
|
||||
</view>
|
||||
|
||||
<!-- 内容区:圆形商家头像 + 昵称 -->
|
||||
<view class="shangjia-info">
|
||||
<image
|
||||
class="shangjia-touxiang"
|
||||
src="{{item.full_tupian_url}}"
|
||||
mode="aspectFill"
|
||||
/>
|
||||
<text class="shangjia-nicheng">{{item.sjnicheng || '未知商家'}}</text>
|
||||
</view>
|
||||
|
||||
<!-- 介绍区 -->
|
||||
<view
|
||||
class="shangjia-jieshao {{item.jieshao && item.jieshao.length > 50 ? 'jieshao-ellipsis' : ''}}"
|
||||
data-type="jieshao"
|
||||
data-content="{{item.jieshao}}"
|
||||
bindtap="onViewDetail"
|
||||
>
|
||||
<text class="jieshao-label">订单介绍:</text>
|
||||
<text class="jieshao-text">{{item.jieshao || '暂无介绍'}}</text>
|
||||
<text wx:if="{{item.jieshao && item.jieshao.length > 50}}" class="view-more">[点击查看]</text>
|
||||
</view>
|
||||
|
||||
<!-- 备注区 -->
|
||||
<view
|
||||
wx:if="{{item.beizhu}}"
|
||||
class="shangjia-beizhu {{item.beizhu.length > 30 ? 'beizhu-ellipsis' : ''}}"
|
||||
data-type="beizhu"
|
||||
data-content="{{item.beizhu}}"
|
||||
bindtap="onViewDetail"
|
||||
>
|
||||
<text class="beizhu-label">商家备注:</text>
|
||||
<text class="beizhu-text">{{item.beizhu}}</text>
|
||||
<text wx:if="{{item.beizhu.length > 30}}" class="view-more">[点击查看]</text>
|
||||
</view>
|
||||
|
||||
<!-- 底部:分佣 + 抢单按钮 -->
|
||||
<view class="card-bottom">
|
||||
<view class="fenyong-box">
|
||||
<view class="fenyong-mark">佣</view>
|
||||
<text class="fenyong-text">分佣</text>
|
||||
<text class="fenyong-price">{{item.dashou_fencheng || 0}}</text>
|
||||
<text class="fenyong-unit">元</text>
|
||||
</view>
|
||||
<view
|
||||
class="qiangdan-btn shangjia-btn"
|
||||
data-item="{{item}}"
|
||||
bindtap="onQiangdanTap"
|
||||
>
|
||||
<text class="btn-text">立即抢单</text>
|
||||
<view class="btn-shine"></view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</block>
|
||||
|
||||
<!-- 加载更多状态 -->
|
||||
<view wx:if="{{isLoadingMore && dingdanList.length > 0}}" class="loading-more">
|
||||
<text class="loading-text">加载更多订单中...</text>
|
||||
</view>
|
||||
</scroll-view>
|
||||
<view wx:if="{{!hasMore && dingdanList.length > 0}}" class="no-more">
|
||||
<text class="no-more-text">没有更多订单了</text>
|
||||
</view>
|
||||
</view>
|
||||
</scroll-view>
|
||||
|
||||
<!-- 全局加载遮罩 -->
|
||||
<view wx:if="{{isLoading && dingdanList.length === 0 && xuanzhongLeixingId}}" class="loading-mask">
|
||||
<view class="loading-spinner"></view>
|
||||
<text class="loading-mask-text">订单加载中...</text>
|
||||
</view>
|
||||
|
||||
<!-- 标签筛选 -->
|
||||
<view class="biaoqian-quyu" wx:if="{{bankuaiBiaoqian.length > 0}}">
|
||||
<scroll-view class="biaoqian-scroll" scroll-x enhanced show-scrollbar="{{false}}">
|
||||
<view class="biaoqian-container">
|
||||
<view class="biaoqian-item {{xuanzhongBiaoqianId == 0 ? 'biaoqian-active' : ''}}" data-id="0" bindtap="selectBiaoqian">
|
||||
<text class="quanbu-text">全部</text>
|
||||
</view>
|
||||
<block wx:for="{{bankuaiBiaoqian}}" wx:key="id">
|
||||
<view class="biaoqian-item {{xuanzhongBiaoqianId == item.id ? 'biaoqian-active' : ''}}" data-id="{{item.id}}" bindtap="selectBiaoqian">
|
||||
<chenghao-tag mingcheng="{{item.mingcheng}}" texiaoJson="{{item.texiao_json}}" />
|
||||
</view>
|
||||
</block>
|
||||
</view>
|
||||
</scroll-view>
|
||||
</view>
|
||||
|
||||
<view class="fenge-xian"></view>
|
||||
|
||||
<!-- 订单列表 -->
|
||||
<view class="dingdan-list">
|
||||
<view wx:if="{{!xuanzhongLeixingId}}" class="empty-tip">
|
||||
<image src="/images/icon_select.png" class="tip-icon"></image>
|
||||
<text class="tip-text">请先选择上方订单类型</text>
|
||||
</view>
|
||||
<view wx:elif="{{dingdanList.length === 0 && !isLoading}}" class="empty-tip">
|
||||
<image src="/images/icon_empty_order.png" class="tip-icon"></image>
|
||||
<text class="tip-text">当前类型暂无待抢订单</text>
|
||||
</view>
|
||||
|
||||
<block wx:for="{{dingdanList}}" wx:key="dingdan_id">
|
||||
<!-- 平台订单 -->
|
||||
<view wx:if="{{item.isPingtai}}" class="xym-order-item xym-pingtai-order" data-item="{{item}}">
|
||||
<view class="xym-pingtai-head flexb">
|
||||
<text class="xym-head-time">{{item.creat_time}}</text>
|
||||
<view class="xym-head-tag">平台订单</view>
|
||||
</view>
|
||||
<view class="xym-pingtai-body">
|
||||
<view class="order-con">
|
||||
<block wx:if="{{item.isZhiding}}">
|
||||
<view class="zhiding-strip light">
|
||||
<view class="zhiding-strip-top myflex">
|
||||
<text class="zhiding-label">指定</text>
|
||||
<image wx:if="{{item.zhiding_avatar_full}}" class="zhiding-avatar" src="{{item.zhiding_avatar_full}}" mode="aspectFill"/>
|
||||
<text class="zhiding-name">{{item.zhiding_nicheng || '指定接单员'}}</text>
|
||||
</view>
|
||||
<view wx:if="{{item.dashou_biaoqian.length > 0 || item.zhiding_identity_biaoqian.length > 0}}" class="zhiding-strip-tags">
|
||||
<chenghao-tag wx:for="{{item.dashou_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
<chenghao-tag wx:for="{{item.zhiding_identity_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</view>
|
||||
</block>
|
||||
<view class="order-row myflex">
|
||||
<image class="o-logo" src="{{item.full_tupian_url}}" mode="aspectFill"/>
|
||||
<view class="o-col">
|
||||
<view class="o-goods light line2" data-type="jieshao" data-content="{{item.jieshao}}" bindtap="onViewDetail">{{item.jieshao || '暂无介绍'}}</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="reward-badge platform-reward" wx:if="{{item.hasRequiredMember}}">
|
||||
<text class="reward-yen sm">¥</text>
|
||||
<text class="reward-num">{{item.dashou_fencheng || 0}}</text>
|
||||
</view>
|
||||
<view class="reward-badge member-tip" wx:else>
|
||||
<text class="reward-tip">未开通会员</text>
|
||||
</view>
|
||||
<view class="remark-block gold" data-type="beizhu" data-content="{{item.beizhu}}" bindtap="onViewDetail">
|
||||
<text class="remark-label">备注:</text>{{item.beizhu || '暂无'}}
|
||||
</view>
|
||||
<view wx:if="{{item.xuqiu_biaoqian.length > 0}}" class="xuqiu-tags-row">
|
||||
<text class="xuqiu-label">需求标签</text>
|
||||
<scroll-view class="biaoqian-inline-scroll" scroll-x enable-flex>
|
||||
<view class="biaoqian-inline-inner">
|
||||
<chenghao-tag wx:for="{{item.xuqiu_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</scroll-view>
|
||||
</view>
|
||||
<view class="o-foot flexb">
|
||||
<text class="o-amt light">平台派单</text>
|
||||
<view class="qiangdan flexa btn-bg btn-qiang btn-qiang-brown" data-item="{{item}}" bindtap="onQiangdanTap">抢单</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 优质商家金牌卡 -->
|
||||
<view wx:elif="{{item.isShangjia && item.shangjia_youzhi}}" class="xym-order-item gold-card" data-item="{{item}}">
|
||||
<view class="gold-head flexb">
|
||||
<view class="kehuduan-banner-wrap">
|
||||
<image class="gold-banner" src="{{goldBannerUrl}}" mode="widthFix"/>
|
||||
</view>
|
||||
</view>
|
||||
<view class="gold-body-wrap">
|
||||
<view class="order-con gold-inner">
|
||||
<block wx:if="{{item.isZhiding}}">
|
||||
<view class="zhiding-strip">
|
||||
<view class="zhiding-strip-top myflex">
|
||||
<text class="zhiding-label">指定</text>
|
||||
<image wx:if="{{item.zhiding_avatar_full}}" class="zhiding-avatar" src="{{item.zhiding_avatar_full}}" mode="aspectFill"/>
|
||||
<text class="zhiding-name">{{item.zhiding_nicheng || '指定接单员'}}</text>
|
||||
</view>
|
||||
<view wx:if="{{item.dashou_biaoqian.length > 0 || item.zhiding_identity_biaoqian.length > 0}}" class="zhiding-strip-tags">
|
||||
<chenghao-tag wx:for="{{item.dashou_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
<chenghao-tag wx:for="{{item.zhiding_identity_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</view>
|
||||
</block>
|
||||
<view class="order-row myflex">
|
||||
<image class="o-logo" src="{{item.leixing_icon_url}}" mode="aspectFill"/>
|
||||
<view class="o-col">
|
||||
<view class="o-goods line2" data-type="jieshao" data-content="{{item.jieshao}}" bindtap="onViewDetail">{{item.jieshao || '暂无介绍'}}</view>
|
||||
<view class="tag-row myflex">
|
||||
<text class="tag-pill tag-youzhi">优质商家</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="reward-badge normal-reward" wx:if="{{item.hasRequiredMember}}">
|
||||
<text class="reward-yen sm">¥</text>
|
||||
<text class="reward-num dark">{{item.dashou_fencheng || 0}}</text>
|
||||
</view>
|
||||
<view class="reward-badge member-tip" wx:else>
|
||||
<text class="reward-tip">未开通会员</text>
|
||||
</view>
|
||||
<view class="remark-block dark" data-type="beizhu" data-content="{{item.beizhu}}" bindtap="onViewDetail">
|
||||
<text class="remark-label">商家备注:</text>{{item.beizhu || '暂无'}}
|
||||
</view>
|
||||
<view wx:if="{{item.shangjia_biaoqian.length > 0 || item.shangjia_identity_biaoqian.length > 0 || item.xuqiu_biaoqian.length > 0}}" class="xuqiu-tags-row">
|
||||
<scroll-view wx:if="{{item.shangjia_biaoqian.length > 0}}" class="biaoqian-inline-scroll" scroll-x enable-flex>
|
||||
<view class="biaoqian-inline-inner">
|
||||
<chenghao-tag wx:for="{{item.shangjia_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</scroll-view>
|
||||
<scroll-view wx:if="{{item.shangjia_identity_biaoqian.length > 0}}" class="biaoqian-inline-scroll" scroll-x enable-flex style="margin-top:8rpx">
|
||||
<view class="biaoqian-inline-inner">
|
||||
<chenghao-tag wx:for="{{item.shangjia_identity_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</scroll-view>
|
||||
<scroll-view wx:if="{{item.xuqiu_biaoqian.length > 0}}" class="biaoqian-inline-scroll" scroll-x enable-flex style="margin-top:8rpx">
|
||||
<view class="biaoqian-inline-inner">
|
||||
<chenghao-tag wx:for="{{item.xuqiu_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</scroll-view>
|
||||
</view>
|
||||
<view class="merchant-plain flexb">
|
||||
<view class="merchant-user myflex">
|
||||
<image class="m-avatar-sm" src="{{item.shangjia_avatar_full}}" mode="aspectFill"/>
|
||||
<view class="m-info">
|
||||
<text class="m-name-sm">{{item.sjnicheng || '未知商家'}}</text>
|
||||
<text class="m-sn-light">发布于 {{item.creat_time}}</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="qiangdan flexa btn-bg btn-qiang" data-item="{{item}}" bindtap="onQiangdanTap">抢单</view>
|
||||
</view>
|
||||
<view class="o-foot flexb gold-foot-text-only">
|
||||
<text class="o-amt">商家派单</text>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- 普通商家订单 -->
|
||||
<view wx:elif="{{item.isShangjia}}" class="xym-order-item xym-shangjia-order" data-item="{{item}}">
|
||||
<view class="xym-shangjia-head flexb">
|
||||
<text class="xym-head-time">{{item.creat_time}}</text>
|
||||
<view class="xym-head-tag">商家发单</view>
|
||||
</view>
|
||||
<view class="xym-shangjia-body">
|
||||
<view class="order-con">
|
||||
<block wx:if="{{item.isZhiding}}">
|
||||
<view class="zhiding-strip">
|
||||
<view class="zhiding-strip-top myflex">
|
||||
<text class="zhiding-label">指定</text>
|
||||
<image wx:if="{{item.zhiding_avatar_full}}" class="zhiding-avatar" src="{{item.zhiding_avatar_full}}" mode="aspectFill"/>
|
||||
<text class="zhiding-name">{{item.zhiding_nicheng || '指定接单员'}}</text>
|
||||
</view>
|
||||
<view wx:if="{{item.dashou_biaoqian.length > 0 || item.zhiding_identity_biaoqian.length > 0}}" class="zhiding-strip-tags">
|
||||
<chenghao-tag wx:for="{{item.dashou_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
<chenghao-tag wx:for="{{item.zhiding_identity_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</view>
|
||||
</block>
|
||||
<view class="order-row myflex">
|
||||
<view class="o-col">
|
||||
<view class="o-goods line2" data-type="jieshao" data-content="{{item.jieshao}}" bindtap="onViewDetail">{{item.jieshao || '暂无介绍'}}</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="reward-badge normal-reward" wx:if="{{item.hasRequiredMember}}">
|
||||
<text class="reward-yen sm">¥</text>
|
||||
<text class="reward-num dark">{{item.dashou_fencheng || 0}}</text>
|
||||
</view>
|
||||
<view class="reward-badge member-tip" wx:else>
|
||||
<text class="reward-tip">未开通会员</text>
|
||||
</view>
|
||||
<view class="remark-block dark" data-type="beizhu" data-content="{{item.beizhu}}" bindtap="onViewDetail">
|
||||
<text class="remark-label">商家备注:</text>{{item.beizhu || '暂无'}}
|
||||
</view>
|
||||
<view wx:if="{{item.shangjia_biaoqian.length > 0 || item.shangjia_identity_biaoqian.length > 0 || item.xuqiu_biaoqian.length > 0}}" class="xuqiu-tags-row">
|
||||
<scroll-view wx:if="{{item.shangjia_biaoqian.length > 0}}" class="biaoqian-inline-scroll" scroll-x enable-flex>
|
||||
<view class="biaoqian-inline-inner">
|
||||
<chenghao-tag wx:for="{{item.shangjia_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</scroll-view>
|
||||
<scroll-view wx:if="{{item.shangjia_identity_biaoqian.length > 0}}" class="biaoqian-inline-scroll" scroll-x enable-flex style="margin-top:8rpx">
|
||||
<view class="biaoqian-inline-inner">
|
||||
<chenghao-tag wx:for="{{item.shangjia_identity_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</scroll-view>
|
||||
<scroll-view wx:if="{{item.xuqiu_biaoqian.length > 0}}" class="biaoqian-inline-scroll" scroll-x enable-flex style="margin-top:8rpx">
|
||||
<view class="biaoqian-inline-inner">
|
||||
<chenghao-tag wx:for="{{item.xuqiu_biaoqian}}" wx:for-item="tag" wx:key="id" mingcheng="{{tag.mingcheng}}" texiaoJson="{{tag.texiao_json}}" />
|
||||
</view>
|
||||
</scroll-view>
|
||||
</view>
|
||||
<view class="o-foot flexb">
|
||||
<text class="o-amt">商家派单</text>
|
||||
<view class="qiangdan flexa btn-bg btn-qiang" data-item="{{item}}" bindtap="onQiangdanTap">抢单</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</block>
|
||||
|
||||
<view wx:if="{{isLoadingMore && dingdanList.length > 0}}" class="loading-more">
|
||||
<text class="loading-text">加载更多订单中...</text>
|
||||
</view>
|
||||
<view wx:if="{{!hasMore && dingdanList.length > 0}}" class="no-more">
|
||||
<text class="no-more-text">—— 没有更多订单了 ——</text>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="scroll-bottom-spacer"></view>
|
||||
</scroll-view>
|
||||
|
||||
<view wx:if="{{isLoading && dingdanList.length === 0 && xuanzhongLeixingId}}" class="loading-mask">
|
||||
<view class="loading-spinner"></view>
|
||||
<text class="loading-mask-text">订单加载中...</text>
|
||||
</view>
|
||||
</block>
|
||||
|
||||
<global-notification id="global-notification" />
|
||||
<popup-notice id="popupNotice" />
|
||||
</view>
|
||||
</view>
|
||||
@@ -1,188 +1,665 @@
|
||||
/* pages/order-pool/order-pool.wxss 抢单池(逍遥梦风格) */
|
||||
/* pages/qiangdan/qiangdan.wxss */
|
||||
@import '../../styles/dashou-xym-theme.wxss';
|
||||
@import '../../styles/dashou-xym-order-card.wxss';
|
||||
|
||||
.qiangdan-page {
|
||||
height: 100vh;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
}
|
||||
height: 100vh;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
background-color: #f5f7fa;
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
/* 授权提示页 */
|
||||
.unauthorized-container {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
background: radial-gradient(ellipse at top, #0b0f1a, #03050a);
|
||||
z-index: 100;
|
||||
}
|
||||
|
||||
.unauthorized-card {
|
||||
width: 600rpx;
|
||||
padding: 60rpx 40rpx;
|
||||
background: linear-gradient(145deg, #1a1f30, #0f1422);
|
||||
border-radius: 60rpx;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
border: 2rpx solid rgba(0, 247, 255, 0.3);
|
||||
box-shadow: 0 30rpx 60rpx rgba(0, 0, 0, 0.8), 0 0 30rpx rgba(0, 247, 255, 0.2);
|
||||
}
|
||||
|
||||
.card-glow {
|
||||
position: absolute;
|
||||
top: -20%;
|
||||
left: -20%;
|
||||
width: 140%;
|
||||
height: 140%;
|
||||
background: radial-gradient(circle at 30% 30%, rgba(0, 247, 255, 0.2), transparent 60%);
|
||||
animation: rotateGlow 10s linear infinite;
|
||||
z-index: 0;
|
||||
}
|
||||
|
||||
@keyframes rotateGlow {
|
||||
0% { transform: rotate(0deg); }
|
||||
100% { transform: rotate(360deg); }
|
||||
}
|
||||
|
||||
.card-content-unauth {
|
||||
position: relative;
|
||||
z-index: 2;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
color: #ffffff;
|
||||
}
|
||||
|
||||
.icon-lock {
|
||||
position: relative;
|
||||
width: 72rpx;
|
||||
height: 52rpx;
|
||||
margin-bottom: 30rpx;
|
||||
background: linear-gradient(180deg, #fae04d, #ffc0a3);
|
||||
border-radius: 10rpx;
|
||||
box-shadow: 0 8rpx 24rpx rgba(180, 130, 20, 0.25);
|
||||
}
|
||||
|
||||
.page-main-scroll {
|
||||
flex: 1;
|
||||
height: 0;
|
||||
-webkit-overflow-scrolling: touch;
|
||||
}
|
||||
|
||||
.scroll-bottom-spacer {
|
||||
height: 24rpx;
|
||||
}
|
||||
|
||||
.refresher-container {
|
||||
height: 100rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.leixing-scroll {
|
||||
width: 100%;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.leixing-container {
|
||||
display: inline-flex;
|
||||
padding: 0 30rpx;
|
||||
gap: 20rpx;
|
||||
}
|
||||
|
||||
.leixing-item {
|
||||
display: inline-flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.biaoqian-scroll {
|
||||
white-space: nowrap;
|
||||
height: 80rpx;
|
||||
}
|
||||
|
||||
.biaoqian-container {
|
||||
display: inline-flex;
|
||||
gap: 16rpx;
|
||||
padding-right: 20rpx;
|
||||
}
|
||||
|
||||
.biaoqian-item {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
padding: 0 12rpx;
|
||||
border-radius: 20rpx;
|
||||
}
|
||||
|
||||
.quanbu-text {
|
||||
font-size: 26rpx;
|
||||
padding: 0 12rpx;
|
||||
}
|
||||
|
||||
.xuqiu-tags-row {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-top: 12rpx;
|
||||
padding: 0 10rpx;
|
||||
}
|
||||
|
||||
.xuqiu-label {
|
||||
font-size: 24rpx;
|
||||
margin-right: 12rpx;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.biaoqian-inline-scroll {
|
||||
flex: 1;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.empty-tip {
|
||||
padding: 160rpx 0;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.tip-icon {
|
||||
width: 180rpx;
|
||||
height: 180rpx;
|
||||
opacity: 0.5;
|
||||
margin-bottom: 30rpx;
|
||||
}
|
||||
|
||||
.loading-more,
|
||||
.no-more {
|
||||
padding: 40rpx 0;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.loading-spinner {
|
||||
width: 90rpx;
|
||||
height: 90rpx;
|
||||
border: 6rpx solid rgba(255, 208, 97, 0.3);
|
||||
border-top: 6rpx solid #ffd061;
|
||||
border-radius: 50%;
|
||||
animation: spin 1s linear infinite;
|
||||
margin-bottom: 30rpx;
|
||||
}
|
||||
|
||||
@keyframes spin {
|
||||
to { transform: rotate(360deg); }
|
||||
}
|
||||
|
||||
/* 未授权页 */
|
||||
.unauthorized-container {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
z-index: 100;
|
||||
}
|
||||
|
||||
.unauthorized-card {
|
||||
width: 600rpx;
|
||||
padding: 60rpx 40rpx;
|
||||
border-radius: 60rpx;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.card-content-unauth {
|
||||
position: relative;
|
||||
z-index: 2;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.icon-lock {
|
||||
width: 72rpx;
|
||||
height: 52rpx;
|
||||
margin-bottom: 30rpx;
|
||||
background: linear-gradient(180deg, #fae04d, #ffc0a3);
|
||||
border-radius: 10rpx;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 36rpx;
|
||||
font-weight: 700;
|
||||
margin-bottom: 16rpx;
|
||||
}
|
||||
|
||||
.message {
|
||||
font-size: 28rpx;
|
||||
margin-bottom: 12rpx;
|
||||
}
|
||||
|
||||
.description {
|
||||
font-size: 24rpx;
|
||||
margin-bottom: 40rpx;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.btn-register {
|
||||
padding: 24rpx 80rpx;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.btn-register .btn-text {
|
||||
font-size: 30rpx;
|
||||
font-weight: 700;
|
||||
}
|
||||
.icon-lock::before {
|
||||
content: '';
|
||||
position: absolute;
|
||||
top: -34rpx;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
width: 44rpx;
|
||||
height: 36rpx;
|
||||
border: 8rpx solid #ffd061;
|
||||
border-bottom: none;
|
||||
border-radius: 22rpx 22rpx 0 0;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 48rpx;
|
||||
font-weight: 700;
|
||||
letter-spacing: 4rpx;
|
||||
margin-bottom: 20rpx;
|
||||
text-shadow: 0 0 15rpx #00f7ff;
|
||||
background: linear-gradient(135deg, #ffffff, #aaddff);
|
||||
-webkit-background-clip: text;
|
||||
-webkit-text-fill-color: transparent;
|
||||
}
|
||||
|
||||
.message {
|
||||
font-size: 32rpx;
|
||||
color: #ffaa00;
|
||||
margin-bottom: 16rpx;
|
||||
font-weight: 600;
|
||||
text-shadow: 0 0 10rpx #ffaa00;
|
||||
}
|
||||
|
||||
.description {
|
||||
font-size: 28rpx;
|
||||
color: #a0b0d0;
|
||||
margin-bottom: 50rpx;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.btn-register {
|
||||
position: relative;
|
||||
padding: 24rpx 80rpx;
|
||||
background: linear-gradient(145deg, #2a3050, #181e38);
|
||||
border-radius: 60rpx;
|
||||
overflow: hidden;
|
||||
border: 2rpx solid #00f7ff;
|
||||
box-shadow: 0 10rpx 30rpx rgba(0, 247, 255, 0.4);
|
||||
transition: transform 0.2s;
|
||||
}
|
||||
|
||||
.btn-register:active {
|
||||
transform: scale(0.96);
|
||||
}
|
||||
|
||||
.btn-text {
|
||||
font-size: 32rpx;
|
||||
color: #fff;
|
||||
font-weight: 700;
|
||||
letter-spacing: 4rpx;
|
||||
position: relative;
|
||||
z-index: 2;
|
||||
text-shadow: 0 0 10rpx #00f7ff;
|
||||
}
|
||||
|
||||
.btn-shine {
|
||||
position: absolute;
|
||||
top: -50%;
|
||||
left: -50%;
|
||||
width: 200%;
|
||||
height: 200%;
|
||||
background: linear-gradient(
|
||||
to right,
|
||||
rgba(255, 255, 255, 0) 0%,
|
||||
rgba(255, 255, 255, 0.2) 50%,
|
||||
rgba(255, 255, 255, 0) 100%
|
||||
);
|
||||
transform: rotate(30deg);
|
||||
animation: btn-shimmer 2.8s infinite linear;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
@keyframes btn-shimmer {
|
||||
0% { transform: translateX(-100%) rotate(30deg); }
|
||||
100% { transform: translateX(100%) rotate(30deg); }
|
||||
}
|
||||
|
||||
/* 原有样式 */
|
||||
.leixing-quyu {
|
||||
padding: 30rpx 0 20rpx;
|
||||
background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
|
||||
border-bottom: 1rpx solid #eaeaea;
|
||||
position: relative;
|
||||
z-index: 10;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.leixing-scroll {
|
||||
width: 100%;
|
||||
white-space: nowrap;
|
||||
height: 180rpx;
|
||||
}
|
||||
|
||||
.leixing-container {
|
||||
display: inline-flex;
|
||||
padding: 0 30rpx;
|
||||
}
|
||||
|
||||
.leixing-item {
|
||||
display: inline-flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
width: 160rpx;
|
||||
margin-right: 24rpx;
|
||||
position: relative;
|
||||
transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
|
||||
}
|
||||
|
||||
.leixing-active {
|
||||
transform: translateY(-6rpx);
|
||||
}
|
||||
|
||||
.guangyun-effect {
|
||||
position: absolute;
|
||||
top: -12rpx;
|
||||
left: -12rpx;
|
||||
right: -12rpx;
|
||||
bottom: -12rpx;
|
||||
background: radial-gradient(circle at center, rgba(82, 196, 26, 0.15) 0%, transparent 70%);
|
||||
border-radius: 40rpx;
|
||||
z-index: 0;
|
||||
animation: guangyun-pulse 2s infinite ease-in-out;
|
||||
}
|
||||
|
||||
@keyframes guangyun-pulse {
|
||||
0%, 100% { opacity: 0.6; transform: scale(1); }
|
||||
50% { opacity: 0.9; transform: scale(1.05); }
|
||||
}
|
||||
|
||||
.leixing-tupian {
|
||||
width: 120rpx;
|
||||
height: 120rpx;
|
||||
border-radius: 28rpx;
|
||||
z-index: 1;
|
||||
box-shadow: 0 8rpx 24rpx rgba(0, 0, 0, 0.08);
|
||||
transition: all 0.3s ease;
|
||||
}
|
||||
|
||||
.leixing-active .leixing-tupian {
|
||||
box-shadow: 0 16rpx 40rpx rgba(82, 196, 26, 0.3);
|
||||
border: 4rpx solid #52c41a;
|
||||
}
|
||||
|
||||
.leixing-jieshao {
|
||||
margin-top: 16rpx;
|
||||
font-size: 24rpx;
|
||||
color: #666;
|
||||
max-width: 100%;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
text-align: center;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.leixing-active .leixing-jieshao {
|
||||
color: #52c41a;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.fenge-xian {
|
||||
height: 16rpx;
|
||||
background: linear-gradient(to bottom, #f0f2f5, #f8f9fa);
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.dingdan-container {
|
||||
flex: 1;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.dingdan-scroll-view {
|
||||
height: 100%;
|
||||
-webkit-overflow-scrolling: touch;
|
||||
}
|
||||
|
||||
.refresher-container {
|
||||
height: 100rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.refreshing-text,
|
||||
.pull-down-text {
|
||||
font-size: 26rpx;
|
||||
color: #999;
|
||||
}
|
||||
|
||||
.empty-tip {
|
||||
padding: 120rpx 0;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.tip-icon {
|
||||
width: 160rpx;
|
||||
height: 160rpx;
|
||||
opacity: 0.4;
|
||||
margin-bottom: 30rpx;
|
||||
}
|
||||
|
||||
.tip-text {
|
||||
font-size: 28rpx;
|
||||
color: #aaa;
|
||||
}
|
||||
|
||||
.dingdan-card {
|
||||
margin: 20rpx 24rpx;
|
||||
border-radius: 20rpx;
|
||||
padding: 28rpx;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
box-shadow: 0 10rpx 30rpx rgba(0, 0, 0, 0.06);
|
||||
transition: all 0.2s ease;
|
||||
border: 1rpx solid rgba(0, 0, 0, 0.08);
|
||||
}
|
||||
|
||||
.dingdan-card:active {
|
||||
transform: scale(0.995);
|
||||
}
|
||||
|
||||
.pingtai-card {
|
||||
background: linear-gradient(145deg, #f8fff8 0%, #f0f9f0 100%);
|
||||
}
|
||||
|
||||
.shangjia-card {
|
||||
background: linear-gradient(145deg, #f9f0ff 0%, #f3e8ff 100%);
|
||||
}
|
||||
|
||||
.card-top {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-bottom: 20rpx;
|
||||
padding-bottom: 16rpx;
|
||||
border-bottom: 1rpx dashed #e0e0e0;
|
||||
}
|
||||
|
||||
.creat-time {
|
||||
font-size: 26rpx;
|
||||
color: #555;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.top-line {
|
||||
flex: 1;
|
||||
height: 1rpx;
|
||||
background: linear-gradient(to right, transparent, #ddd, transparent);
|
||||
margin: 0 20rpx;
|
||||
}
|
||||
|
||||
.pingtai-tag {
|
||||
font-size: 24rpx;
|
||||
color: #666;
|
||||
padding: 6rpx 16rpx;
|
||||
background: rgba(0, 0, 0, 0.04);
|
||||
border-radius: 20rpx;
|
||||
}
|
||||
|
||||
.zhiding-row {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-bottom: 20rpx;
|
||||
padding: 10rpx 16rpx;
|
||||
background: rgba(255, 77, 79, 0.08);
|
||||
border-radius: 12rpx;
|
||||
border-left: 4rpx solid #ff4d4f;
|
||||
gap: 10rpx;
|
||||
}
|
||||
|
||||
.zhiding-icon {
|
||||
font-size: 26rpx;
|
||||
margin-right: 4rpx;
|
||||
}
|
||||
|
||||
.zhiding-avatar {
|
||||
width: 48rpx;
|
||||
height: 48rpx;
|
||||
border-radius: 50%;
|
||||
border: 2rpx solid #ff4d4f;
|
||||
object-fit: cover;
|
||||
}
|
||||
|
||||
.zhiding-nicheng {
|
||||
font-size: 24rpx;
|
||||
color: #ff4d4f;
|
||||
font-weight: 500;
|
||||
max-width: 120rpx;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.zhiding-uid {
|
||||
font-size: 24rpx;
|
||||
color: #ff4d4f;
|
||||
font-weight: 400;
|
||||
flex: 1;
|
||||
text-align: right;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.card-content {
|
||||
display: flex;
|
||||
margin-bottom: 20rpx;
|
||||
}
|
||||
|
||||
.neirong-tupian {
|
||||
width: 140rpx;
|
||||
height: 140rpx;
|
||||
border-radius: 50%;
|
||||
margin-right: 24rpx;
|
||||
flex-shrink: 0;
|
||||
box-shadow: 0 6rpx 20rpx rgba(0, 0, 0, 0.08);
|
||||
object-fit: cover;
|
||||
}
|
||||
|
||||
.jieshao-box {
|
||||
flex: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
min-height: 140rpx;
|
||||
padding: 16rpx 0;
|
||||
}
|
||||
|
||||
.jieshao-label {
|
||||
font-size: 26rpx;
|
||||
color: #333;
|
||||
font-weight: 600;
|
||||
margin-bottom: 8rpx;
|
||||
}
|
||||
|
||||
.jieshao-text {
|
||||
font-size: 26rpx;
|
||||
color: #666;
|
||||
line-height: 1.4;
|
||||
}
|
||||
|
||||
.jieshao-ellipsis .jieshao-text {
|
||||
display: -webkit-box;
|
||||
-webkit-box-orient: vertical;
|
||||
-webkit-line-clamp: 3;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.shangjia-info {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-bottom: 20rpx;
|
||||
}
|
||||
|
||||
.shangjia-touxiang {
|
||||
width: 90rpx;
|
||||
height: 90rpx;
|
||||
border-radius: 50%;
|
||||
margin-right: 20rpx;
|
||||
border: 2rpx solid rgba(114, 46, 209, 0.15);
|
||||
box-shadow: 0 6rpx 18rpx rgba(114, 46, 209, 0.12);
|
||||
object-fit: cover;
|
||||
}
|
||||
|
||||
.shangjia-nicheng {
|
||||
font-size: 28rpx;
|
||||
color: #333;
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.shangjia-jieshao,
|
||||
.shangjia-beizhu {
|
||||
margin-bottom: 16rpx;
|
||||
padding: 14rpx 18rpx;
|
||||
background: rgba(255, 255, 255, 0.6);
|
||||
border-radius: 12rpx;
|
||||
}
|
||||
|
||||
.shangjia-jieshao .jieshao-label,
|
||||
.shangjia-beizhu .beizhu-label {
|
||||
display: block;
|
||||
margin-bottom: 6rpx;
|
||||
font-size: 24rpx;
|
||||
}
|
||||
|
||||
.shangjia-jieshao .jieshao-text,
|
||||
.shangjia-beizhu .beizhu-text {
|
||||
font-size: 24rpx;
|
||||
color: #555;
|
||||
line-height: 1.4;
|
||||
}
|
||||
|
||||
.shangjia-jieshao.jieshao-ellipsis .jieshao-text {
|
||||
display: -webkit-box;
|
||||
-webkit-box-orient: vertical;
|
||||
-webkit-line-clamp: 2;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.shangjia-beizhu.beizhu-ellipsis .beizhu-text {
|
||||
display: -webkit-box;
|
||||
-webkit-box-orient: vertical;
|
||||
-webkit-line-clamp: 2;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.beizhu-box {
|
||||
margin-bottom: 20rpx;
|
||||
padding: 14rpx 18rpx;
|
||||
background: rgba(255, 255, 255, 0.6);
|
||||
border-radius: 12rpx;
|
||||
}
|
||||
|
||||
.beizhu-label {
|
||||
font-size: 24rpx;
|
||||
color: #333;
|
||||
font-weight: 600;
|
||||
margin-bottom: 6rpx;
|
||||
display: block;
|
||||
}
|
||||
|
||||
.beizhu-text {
|
||||
font-size: 24rpx;
|
||||
color: #666;
|
||||
line-height: 1.4;
|
||||
}
|
||||
|
||||
.beizhu-ellipsis .beizhu-text {
|
||||
display: -webkit-box;
|
||||
-webkit-box-orient: vertical;
|
||||
-webkit-line-clamp: 2;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
.view-more {
|
||||
display: block;
|
||||
font-size: 22rpx;
|
||||
color: #1890ff;
|
||||
margin-top: 6rpx;
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
.card-bottom {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
padding-top: 20rpx;
|
||||
border-top: 1rpx solid rgba(0, 0, 0, 0.06);
|
||||
}
|
||||
|
||||
.fenyong-box {
|
||||
display: flex;
|
||||
align-items: baseline;
|
||||
}
|
||||
|
||||
.fenyong-icon {
|
||||
font-size: 30rpx;
|
||||
margin-right: 10rpx;
|
||||
}
|
||||
|
||||
.fenyong-text {
|
||||
font-size: 24rpx;
|
||||
color: #999;
|
||||
margin-right: 6rpx;
|
||||
}
|
||||
|
||||
.fenyong-price {
|
||||
font-size: 40rpx;
|
||||
color: #ff4d4f;
|
||||
font-weight: 700;
|
||||
margin-right: 4rpx;
|
||||
}
|
||||
|
||||
.fenyong-unit {
|
||||
font-size: 24rpx;
|
||||
color: #999;
|
||||
}
|
||||
|
||||
.qiangdan-btn {
|
||||
position: relative;
|
||||
padding: 18rpx 40rpx;
|
||||
border-radius: 50rpx;
|
||||
overflow: hidden;
|
||||
box-shadow: 0 8rpx 24rpx rgba(0, 0, 0, 0.12);
|
||||
}
|
||||
|
||||
.pingtai-btn {
|
||||
background: linear-gradient(135deg, #52c41a 0%, #73d13d 100%);
|
||||
}
|
||||
|
||||
.shangjia-btn {
|
||||
background: linear-gradient(135deg, #722ed1 0%, #9254de 100%);
|
||||
}
|
||||
|
||||
.btn-text {
|
||||
font-size: 28rpx;
|
||||
color: white;
|
||||
font-weight: 600;
|
||||
letter-spacing: 1rpx;
|
||||
position: relative;
|
||||
z-index: 2;
|
||||
}
|
||||
|
||||
.btn-shine {
|
||||
position: absolute;
|
||||
top: -50%;
|
||||
left: -50%;
|
||||
width: 200%;
|
||||
height: 200%;
|
||||
background: linear-gradient(
|
||||
to right,
|
||||
rgba(255, 255, 255, 0) 0%,
|
||||
rgba(255, 255, 255, 0.3) 50%,
|
||||
rgba(255, 255, 255, 0) 100%
|
||||
);
|
||||
transform: rotate(30deg);
|
||||
animation: btn-shimmer 3s infinite linear;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
@keyframes btn-shimmer {
|
||||
0% { transform: translateX(-100%) rotate(30deg); }
|
||||
100% { transform: translateX(100%) rotate(30deg); }
|
||||
}
|
||||
|
||||
.qiangdan-btn:active {
|
||||
transform: scale(0.96);
|
||||
}
|
||||
|
||||
.loading-more,
|
||||
.no-more {
|
||||
padding: 30rpx 0;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.loading-text {
|
||||
font-size: 26rpx;
|
||||
color: #999;
|
||||
}
|
||||
|
||||
.no-more-text {
|
||||
font-size: 26rpx;
|
||||
color: #ccc;
|
||||
}
|
||||
|
||||
.loading-mask {
|
||||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
background: rgba(255, 255, 255, 0.9);
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
z-index: 9999;
|
||||
}
|
||||
|
||||
.loading-spinner {
|
||||
width: 70rpx;
|
||||
height: 70rpx;
|
||||
border: 6rpx solid #f0f0f0;
|
||||
border-top: 6rpx solid #52c41a;
|
||||
border-radius: 50%;
|
||||
animation: spin 1s linear infinite;
|
||||
margin-bottom: 24rpx;
|
||||
}
|
||||
|
||||
@keyframes spin {
|
||||
0% { transform: rotate(0deg); }
|
||||
100% { transform: rotate(360deg); }
|
||||
}
|
||||
|
||||
.loading-mask-text {
|
||||
font-size: 28rpx;
|
||||
color: #666;
|
||||
}
|
||||
Reference in New Issue
Block a user