package com.bocloud.cmp.model.common;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

import com.bocloud.common.utils.DateDeserializer;
import com.bocloud.common.utils.DateSerializer;
import com.bocloud.nms.enums.OrderItemStatus;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * 订单明细
 *
 * @author wangyu
 * @version 1.0
 * @since 2020年3月10日
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
public class OrderItemBean {

	private Long id;
	private String sn;
	private Long orderId;
	private Catalog catalog;
	private Long skuId;
	private OrderItemStatus status;
	private BigDecimal basicPrice;
	private BigDecimal finalPrice;
	private String duration;
	private Boolean deleted;
	private String errorMsg;
	private Long changerId;
	private Long auditorId;
	private String auditStatus;
	@JsonSerialize(using = DateSerializer.class)
	@JsonDeserialize(using = DateDeserializer.class)
	private Date auditTime;
	@JsonSerialize(using = DateSerializer.class)
	@JsonDeserialize(using = DateDeserializer.class)
	private Date effectiveTime;
	@JsonSerialize(using = DateSerializer.class)
	@JsonDeserialize(using = DateDeserializer.class)
	private Date expiredTime;
	@JsonSerialize(using = DateSerializer.class)
	@JsonDeserialize(using = DateDeserializer.class)
	private Date moveOutTime;
	private String resources;
	private String elements;
	private String serviceCode;
	private String inventory;
	@JsonSerialize(using = DateSerializer.class)
	@JsonDeserialize(using = DateDeserializer.class)
	private Date orderTime;
	private String serviceName;
	private String elementNames;
	private List<String> elementList;
	private List<String> discountList;
	private Long categoryId;
	private Long tenantId;
	private Long vendorId;
	private Long systemDiskCategoryId;

	/**
	 * 订单类别
	 *
	 * @author wangyu
	 * @version 1.0
	 * @since 2020年4月13日
	 */
	public enum Catalog {
		complex, // 复合
		single// 单一
	}

}
