package com.jpsoft.shinestar.modules.base.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;
import sun.util.resources.ga.LocaleNames_ga;

import java.util.Date;

/**
 * @author 墨鱼_mo
 * @date 2020-10-29 16:13
 */
@Data
@ApiModel(value = "base_medication_info的实体类")
public class MedicationInfo {

    private String id;

    @ApiModelProperty(value = "创建用药提醒的人")
    private String createPopedomId;

    @ApiModelProperty(value = "被用药提醒的人")
    private String beRemindPopedomId;
    @ApiModelProperty(value = "药品名称")
    private String medicationName;

    /**
     *用药开始时间
     */
    @DateTimeFormat(pattern="yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd",timezone ="GMT+8")
    @ApiModelProperty(value = "创建时间")
    private Date startTime;

    /**
     *用药结束时间
     */
    @DateTimeFormat(pattern="yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd",timezone ="GMT+8")
    @ApiModelProperty(value = "创建时间")
    private Date endTime;

    @ApiModelProperty(value = "用药天数")
    private Integer medicationDays;

    @ApiModelProperty(value = "每次用药隔多少天")
    private Integer nextDays;

    @ApiModelProperty(value = "当天用药的次数")
    private Integer medicationFrequency;

    @ApiModelProperty(value = "每次的用量")
    private String usage;

    @ApiModelProperty(value = "提醒时间")
    private String remindTime;

    @ApiModelProperty(value = "是否需要提醒")
    private Boolean needRemind;


    /**
     *是否删除
     */
    @ApiModelProperty(value = "是否删除")
    private Boolean delFlag;
    /**
     *创建人
     */
    @ApiModelProperty(value = "创建人")
    private String createBy;
    /**
     *创建时间
     */
    @DateTimeFormat(pattern="yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd",timezone ="GMT+8")
    @ApiModelProperty(value = "创建时间")
    private Date createTime;
    /**
     *更新人
     */
    @ApiModelProperty(value = "更新人")
    private String updateBy;
    /**
     *更新时间
     */
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm",timezone ="GMT+8")
    @ApiModelProperty(value = "更新时间")
    private Date updateTime;

    private String remark;

    @ApiModelProperty(value = "已服药天数")
    private Long hasUsedDays;

    @ApiModelProperty(value = "还需要服药天数")
    private Long needUsedDays;
}
