调试茶艺师订单接口

This commit is contained in:
wangxiaowei
2026-01-03 01:40:12 +08:00
parent 66ee35285d
commit 3a31777431
18 changed files with 717 additions and 344 deletions

View File

@ -7,7 +7,7 @@ export enum TeaSpecialistLevel {
Enthusiast = '茶艺爱好者'
}
// 订单来源对应名称
// 等级名称对应值
export const TeaSpecialistLevelValue = {
['金牌茶艺师']: 'gold',
['高级茶艺师']: 'senior',
@ -18,9 +18,9 @@ export const TeaSpecialistLevelValue = {
// 茶艺师对象结构
export const TeaSpecialistLevels = [
{ id: 1, value: 'gold', label: TeaSpecialistLevel.Gold},
{ id: 2, value: 'senior', label: TeaSpecialistLevel.Senior },
{ id: 3, value: 'intermediate', label: TeaSpecialistLevel.Intermediate },
{ id: 4, value: 'junior', label: TeaSpecialistLevel.Junior },
{ id: 5, value: 'enthusiast', label: TeaSpecialistLevel.Enthusiast }
];
{ id: 1, value: 'gold', label: TeaSpecialistLevel.Gold, level: 1 },
{ id: 2, value: 'senior', label: TeaSpecialistLevel.Senior, level: 2 },
{ id: 3, value: 'intermediate', label: TeaSpecialistLevel.Intermediate, level: 3 },
{ id: 4, value: 'junior', label: TeaSpecialistLevel.Junior, level: 4 },
{ id: 5, value: 'enthusiast', label: TeaSpecialistLevel.Enthusiast, level: 5 }
];

View File

@ -155,3 +155,15 @@ export function randomLabelColor (index: number) {
return tagColors[index % tagColors.length]
}
/**
* 获取当前年月日格式YYYY-MM-DD
*/
export function getCurrentDate() {
const now = new Date();
const year = now.getFullYear();
const month = String(now.getMonth() + 1).padStart(2, '0');
const day = String(now.getDate()).padStart(2, '0');
return `${year}-${month}-${day}`;
}