fix: 更新优惠券页面,订单列表页面,代客下单页面
This commit is contained in:
@@ -37,12 +37,30 @@ export const payTypeOptions: payTypeOptions[] = [
|
||||
value: "arrears",
|
||||
},
|
||||
];
|
||||
export type optionsType = "status";
|
||||
export const options: { [key in optionsType]: options[] } = {
|
||||
status: statusOptions,
|
||||
payType: payTypeOptions,
|
||||
platformType: [
|
||||
{ label: '微信小程序', value: 'wechat' },
|
||||
{ label: '网页后台管理端', value: 'WEB' },
|
||||
],
|
||||
sendType: [
|
||||
{ label: '快递', value: 'post' },
|
||||
{ label: '外卖', value: 'takeaway' },
|
||||
{ label: '自提', value: 'takeself' },
|
||||
{ label: '堂食', value: 'table' },
|
||||
],
|
||||
dineMode: [
|
||||
{ label: '堂食', value: 'dine-in' },
|
||||
{ label: '外带', value: 'take-out' },
|
||||
{ label: '外卖', value: 'take-away' },
|
||||
|
||||
]
|
||||
}
|
||||
export type optionsType = string;
|
||||
|
||||
export function returnOptions(type: optionsType) {
|
||||
if (type === "status") {
|
||||
return statusOptions;
|
||||
}
|
||||
return options[type];
|
||||
}
|
||||
|
||||
export function returnOptionsLabel(optionsType: optionsType, value: string | number) {
|
||||
@@ -54,6 +72,7 @@ export function returnOptionsLabel(optionsType: optionsType, value: string | num
|
||||
return option ? option.label : "";
|
||||
}
|
||||
|
||||
|
||||
export interface options {
|
||||
label: string;
|
||||
value: string | number;
|
||||
|
||||
Reference in New Issue
Block a user