
const statusMap = {
  unpay: "未支付",
  paid: "已支付",
  expired: "已过期",
  goodsFeeRefunded:'已退还中药饮品费用',
  refunded:'已退款',
  shipped: "已发货",
  completed: "已完成",
};

export const colorMap = {
  unpay: "red",
  paid: "#4cd964",
  expired: "#666",
  goodsFeeRefunded:'red',
  refunded:'red',
  shipped: "#4cd964",
  completed: "#4cd964",
};

export const statusOptions = Object.keys(statusMap).reduce((acc, key) => {
  acc.push({
    label: statusMap[key],
    value: key,
  });
  return acc;
}, []);

export function getStatus(item) {
  const color = colorMap[item.status] || '';
  const text = statusMap[item.status] || '';
  return { text, color }
}