package com.tzy.common.utils.http.forest.param;

public enum OrderStatusEnum {

	unpayed(100, "待支付"),
	payed(101, "已支付"),
	unshipp(103, "待发货"),
	shipped(104, "待收货"),
	expired(201, "订单超时"),
	cancel(202, "用户取消"),
	refunding(204, "退款中"),
	refund(205, "退款完成"),
	refund_fail(206, "退款中"),
	over(301, "订单完成");

	private Integer status;

	private String msg;

	OrderStatusEnum(Integer status, String msg) {
		this.status = status;
		this.msg = msg;
	}

	public static String getMsgByStatus(Integer status) {
		if (status == null) {
			return "";
		}
		for (OrderStatusEnum n : OrderStatusEnum.values()) {
			if (n.status.equals(status)) {
				return n.msg;
			}
		}
		return "";
	}

}