package com.ruoyi.web.modules.goods.support;

import com.ruoyi.web.modules.goods.constant.GoodsConstants;

/**
 * 商品状态展示
 */
public final class GoodsStatusUtils
{
    private GoodsStatusUtils()
    {
    }

    public static String label(String status)
    {
        if (GoodsConstants.STATUS_DRAFT.equals(status))
        {
            return "未上架";
        }
        if (GoodsConstants.STATUS_PENDING.equals(status))
        {
            return "待审核";
        }
        if (GoodsConstants.STATUS_ON_SALE.equals(status))
        {
            return "出售中";
        }
        if (GoodsConstants.STATUS_REJECTED.equals(status))
        {
            return "审核失败";
        }
        if (GoodsConstants.STATUS_OFF_SHELF.equals(status))
        {
            return "已下架";
        }
        return status;
    }
}
