277 lines
7.2 KiB
TypeScript
277 lines
7.2 KiB
TypeScript
import type { Request, Response } from "express";
|
|
const getOrderPage = (_req: Request, res: Response) => {
|
|
res.json({
|
|
data: {
|
|
list: [
|
|
{
|
|
id: 1,
|
|
orderNum: "BZ000548787",
|
|
createTime: "2025-10-1 14:00:00",
|
|
orderCategoryName: "宠物殡葬", // 订单类目
|
|
orderTerminal: 0, // 订单来源
|
|
userId: 0, // 用户编号
|
|
userName: "", // 用户姓名
|
|
userNickName: "张宁清", // 用户昵称
|
|
userAvatar: "", // 用户头像
|
|
userMobile: "18634556151", // 用户手机号
|
|
orderStatus: 10, // 订单状态
|
|
picUrl: "", // 商品图片
|
|
spuName:
|
|
"商品主标题商品主标题商品主标题商品主标题商品主题商品主标题商品主标题商品主", // 商品名称
|
|
skuName: "标准,单独火化,基础清洁", // 商品规格
|
|
count: 1, // 购买商品数量
|
|
price: 100, // 单价
|
|
handedPrice: 80, // 到手价
|
|
payPrice: "500", // 应付金额
|
|
unit: "", // 单位
|
|
subTime: 1760585499000, // 预约时间
|
|
serveAddress: "张宁清,18659156151,福州 台江区 鳌峰路 万达中心甲",
|
|
userRemark: "你好呀你好元", // 用户备注
|
|
payType: "wx", // 微信
|
|
financeStatus: "1", // 财务状态
|
|
},
|
|
{
|
|
id: 2,
|
|
orderNum: "3214421412",
|
|
createTime: "",
|
|
orderCategoryName: "宠物殡葬",
|
|
orderTerminal: 0,
|
|
userId: 0,
|
|
userName: "",
|
|
userNickName: "",
|
|
userAvatar: "",
|
|
userMobile: "",
|
|
orderStatus: 20,
|
|
picUrl: "",
|
|
spuName: "",
|
|
skuName: "",
|
|
subTime: 1760585499000, // 预约时间
|
|
count: 0,
|
|
price: 0,
|
|
handedPrice: 0,
|
|
payPrice: 0,
|
|
unit: "",
|
|
orderTime: "",
|
|
serveAddress: "",
|
|
userRemark: "",
|
|
payType: "",
|
|
financeStatus: "",
|
|
},
|
|
{
|
|
id: 3,
|
|
orderNum: "3214421412",
|
|
createTime: "",
|
|
orderCategoryName: "宠物殡葬",
|
|
orderTerminal: 0,
|
|
userId: 0,
|
|
userName: "",
|
|
subTime: 1760585499000, // 预约时间
|
|
userNickName: "",
|
|
userAvatar: "",
|
|
userMobile: "",
|
|
orderStatus: 30,
|
|
picUrl: "",
|
|
spuName: "",
|
|
skuName: "",
|
|
count: 0,
|
|
price: 0,
|
|
handedPrice: 0,
|
|
payPrice: 0,
|
|
unit: "",
|
|
orderTime: "",
|
|
serveAddress: "",
|
|
userRemark: "",
|
|
payType: "",
|
|
financeStatus: "",
|
|
},
|
|
{
|
|
id: 4,
|
|
orderNum: "3214421412",
|
|
createTime: "",
|
|
orderCategoryName: "宠物殡葬",
|
|
orderTerminal: 0,
|
|
userId: 0,
|
|
userName: "",
|
|
subTime: 1760585499000, // 预约时间
|
|
userNickName: "",
|
|
userAvatar: "",
|
|
userMobile: "",
|
|
orderStatus: 40,
|
|
picUrl: "",
|
|
spuName: "",
|
|
skuName: "",
|
|
count: 0,
|
|
price: 0,
|
|
handedPrice: 0,
|
|
payPrice: 0,
|
|
unit: "",
|
|
orderTime: "",
|
|
serveAddress: "",
|
|
userRemark: "",
|
|
payType: "",
|
|
financeStatus: "",
|
|
},
|
|
{
|
|
id: 5,
|
|
orderNum: "3214421412",
|
|
createTime: "",
|
|
orderCategoryName: "宠物殡葬",
|
|
orderTerminal: 0,
|
|
userId: 0,
|
|
userName: "",
|
|
subTime: 1760585499000, // 预约时间
|
|
userNickName: "",
|
|
userAvatar: "",
|
|
userMobile: "",
|
|
orderStatus: 50,
|
|
picUrl: "",
|
|
spuName: "",
|
|
skuName: "",
|
|
count: 0,
|
|
price: 0,
|
|
handedPrice: 0,
|
|
payPrice: 0,
|
|
unit: "",
|
|
orderTime: "",
|
|
serveAddress: "",
|
|
userRemark: "",
|
|
payType: "",
|
|
financeStatus: "",
|
|
},
|
|
{
|
|
id: 6,
|
|
orderNum: "3214421412",
|
|
createTime: "",
|
|
orderCategoryName: "宠物殡葬",
|
|
orderTerminal: 0,
|
|
userId: 0,
|
|
userName: "",
|
|
subTime: 1760585499000, // 预约时间
|
|
userNickName: "",
|
|
userAvatar: "",
|
|
userMobile: "",
|
|
orderStatus: 60,
|
|
picUrl: "",
|
|
spuName: "",
|
|
skuName: "",
|
|
count: 0,
|
|
price: 0,
|
|
handedPrice: 0,
|
|
payPrice: 0,
|
|
unit: "",
|
|
orderTime: "",
|
|
serveAddress: "",
|
|
userRemark: "",
|
|
payType: "",
|
|
financeStatus: "",
|
|
},
|
|
{
|
|
id: 7,
|
|
orderNum: "3214421412",
|
|
createTime: "",
|
|
orderCategoryName: "宠物殡葬",
|
|
orderTerminal: 0,
|
|
userId: 0,
|
|
userName: "",
|
|
subTime: 1760585499000, // 预约时间
|
|
userNickName: "",
|
|
userAvatar: "",
|
|
userMobile: "",
|
|
orderStatus: 70,
|
|
picUrl: "",
|
|
spuName: "",
|
|
skuName: "",
|
|
count: 0,
|
|
price: 0,
|
|
handedPrice: 0,
|
|
payPrice: 0,
|
|
unit: "",
|
|
orderTime: "",
|
|
serveAddress: "",
|
|
userRemark: "",
|
|
payType: "",
|
|
financeStatus: "",
|
|
},
|
|
],
|
|
total: 0,
|
|
},
|
|
code: 0,
|
|
});
|
|
};
|
|
|
|
const getOrderDetail = (_req: Request, res: Response) => {
|
|
res.json({
|
|
data: {
|
|
tradeOrderInfoBase: {
|
|
id: "7655265",
|
|
orderNo: "BZ000548787",
|
|
orderStatus: "50",
|
|
orderType: "1",
|
|
orderCategoryName: "宠物殡葬", // 订单类目
|
|
orderCategoryId: "3232321",
|
|
orderTerminal: "微信小程序",
|
|
userInfo: null,
|
|
userAvatar: null,
|
|
cancelTime: "2025-10-16T11:28:57",
|
|
cancelReason: "非常",
|
|
merchantRemark: "测试商家备注",
|
|
refundTime: null,
|
|
propertyTime: null,
|
|
propertyStatus: null,
|
|
price: null,
|
|
discountPrice: null,
|
|
payPrice: null,
|
|
refundPrice: null,
|
|
livePrice: null,
|
|
payType: "1",
|
|
payChannelCode: "1",
|
|
payOrderId: "12323123123",
|
|
payTime: 1760585391000,
|
|
createTime: 1760585499000,
|
|
finishTime: 1760585335000,
|
|
},
|
|
tradeProductInfo: {
|
|
shopLogoUrl: "",
|
|
shopName: "",
|
|
spuId: 0,
|
|
skuId: 0,
|
|
skuPicUrl: "",
|
|
spuName: "",
|
|
skuName: "",
|
|
count: 0,
|
|
price: 0,
|
|
unit: "",
|
|
handedPrice: 0,
|
|
expensePrice: 0,
|
|
properties: [""],
|
|
serveContent: "",
|
|
totalPrice: 0,
|
|
discountPrice: 0,
|
|
payPrice: 0,
|
|
refundPrice: 0,
|
|
refundCount: 0,
|
|
},
|
|
tradeServeInfo: {
|
|
properties: {
|
|
"": {},
|
|
},
|
|
},
|
|
tradeExtendServeInfo: {
|
|
properties: {
|
|
"": {},
|
|
},
|
|
},
|
|
tradeExtendCostInfo: {
|
|
properties: {
|
|
"": {},
|
|
},
|
|
},
|
|
},
|
|
code: 0,
|
|
});
|
|
};
|
|
export default {
|
|
"GET /admin-api/trade/order/page": getOrderPage,
|
|
"GET /admin-api/trade/order/get-detail": getOrderDetail,
|
|
};
|