/*
 *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
 *
 *  Redistribution and use in source and binary forms, with or without
 *  modification, are permitted provided that the following conditions are met:
 *
 *  Redistributions of source code must retain the above copyright notice,
 *  this list of conditions and the following disclaimer.
 *  Redistributions in binary form must reproduce the above copyright
 *  notice, this list of conditions and the following disclaimer in the
 *  documentation and/or other materials provided with the distribution.
 *  Neither the name of the dreamlu.net developer nor the names of its
 *  contributors may be used to endorse or promote products derived from
 *  this software without specific prior written permission.
 *  Author: Chill 庄骞 (smallchill@163.com)
 */
package org.security.trans.task.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.security.ht.entity.common.BaseEntity;

import java.io.Serializable;
import java.util.Date;

/**
 * 任务-任务下发实体类
 *
 * @author BladeX
 * @since 2022-03-10
 */
@Data
@TableName("T_TASK")
@ApiModel(value = "Task对象", description = "任务-任务下发")
public class Task extends BaseEntity implements Serializable {

	private static final long serialVersionUID = 1L;

	/**
	* ID
	*/
		@ApiModelProperty(value = "ID")
		@TableId("ID")
	private String id;
	/**
	* 任务类型;1-日常 2-专项
	*/
		@ApiModelProperty(value = "任务类型;1-日常 2-专项")
		@TableField("FLAG")
	private String flag;
	/**
	* 任务名称
	*/
		@ApiModelProperty(value = "任务名称")
		@TableField("NAME")
	private String name;
	/**
	* 任务编号
	*/
		@ApiModelProperty(value = "任务编号")
		@TableField("NUM")
	private String num;
	/**
	* 所属模块
	*/
		@ApiModelProperty(value = "所属模块")
		@TableField("MODULE")
	private String module;
	/**
	* 业务类型code
	*/
		@ApiModelProperty(value = "业务类型code")
		@TableField("BUSINESS_TYPE")
	private String businessType;
	/**
	* 概述
	*/
		@ApiModelProperty(value = "概述")
		@TableField("SUMMARY")
	private String summary;
	/**
	* 提报类型;单次提报/按频次提报
	*/
		@ApiModelProperty(value = "提报类型;单次提报/按频次提报")
		@TableField("TYPE")
	private String type;
	/**
	* 提报频次(once-仅一次,
	 * byDay-每天一次,
	 * byWeek-每周一次,
	 * byMonth-每月一次,
	 * byQuarter-每季度一次,
	 * byHalfYear-每半年一次,
	 * byYear-每年一次)
	*/
		@ApiModelProperty(value = "提报频次(once-仅一次,\n" +
			"byDay-每天一次,\n" +
			"byWeek-每周一次,\n" +
			"byMonth-每月一次,\n" +
			"byQuarter-每季度一次,\n" +
			"byHalfYear-每半年一次,\n" +
			"byYear-每年一次)")
		@TableField("FREQUENCY")
	private String frequency;
	/**
	* 任务开始时间
	*/
		@ApiModelProperty(value = "任务开始时间")
		@TableField("BEGIN_DATE")
		@JsonFormat(pattern="yyyy-MM-dd")
		@JsonSerialize()
	private Date beginDate;
	/**
	* 任务结束时间
	*/
		@ApiModelProperty(value = "任务结束时间")
		@TableField("END_DATE")
		@JsonFormat(pattern="yyyy-MM-dd")
	private Date endDate;
	/**
	* 任务接收机构;任务接收机构的ID数组组成的字符串
	*/
		@ApiModelProperty(value = "任务接收机构;任务接收机构的ID数组组成的字符串")
		@TableField("DEPT_IDS")
	private String deptIds;
	/**
	* 任务状态;0-待下发 1-已下发 2-已终止
	*/
		@ApiModelProperty(value = "任务状态;0-待下发 1-已下发 2-已终止")
		@TableField("STATE")
	private String state;
	/**
	* 相关附件
	*/
		@ApiModelProperty(value = "相关附件ID")
		@TableField("FILE_IDS")
	private String fileIds;
	/**
	* 表单模板文件ID
	*/
		@ApiModelProperty(value = "表单模板文件ID")
		@TableField("FILE_TEMPLATE_IDS")
	private String fileTemplateIds;
	/**
	* 应报数量
	*/
		@ApiModelProperty(value = "应报数量")
		@TableField("OUGHT_NUM")
	private String oughtNum;
	/**
	* 已报数量
	*/
		@ApiModelProperty(value = "已报数量")
		@TableField("FINISH_NUM")
	private String finishNum;
	/**
	* 部门id
	*/
		@ApiModelProperty(value = "部门id")
		@TableField("DEPT_ID")
	private String deptId;
	/**
	* 逻辑删除标识符;0-正常，1-删除
	*/
		@ApiModelProperty(value = "逻辑删除标识符;0-正常，1-删除")
		@TableField("DEL_FLAG")
		@TableLogic
	private String delFlag;
	/**
	* 检查类型；针对‘检查整改’任务需要区分；1-自检自查；2-内部检查；3-外部检查
	*/
		@ApiModelProperty(value = "检查类型；针对‘检查整改’任务需要区分；1-自检自查；2-内部检查；3-外部检查")
		@TableField("CHECK_TYPE")
	private String checkType;
	/**
	* 关联事件；针对‘案件防控’的任务下发，需要选择相关联的异常事件
	*/
		@ApiModelProperty(value = "关联事件ID")
		@TableField("EVENT_ID")
	private String eventId;
	/**
	* 附件groupName
	*/
		@ApiModelProperty(value = "附件groupName")
		@TableField("GROUP_NAME")
	private String groupName;
	/**
	* 备用字段4
	*/
		@ApiModelProperty(value = "备用字段4")
		@TableField("RESERVE4")
	private String reserve4;
	/**
	* 备用字段5
	*/
		@ApiModelProperty(value = "备用字段5")
		@TableField("RESERVE5")
	private String reserve5;
	/**
	 * 检查机构
	 */
	@ApiModelProperty(value = "检查机构")
	@TableField("INSPECT_DEP")
	private String inspectDep;
	/**
	 * 提报角色
	 */
	@ApiModelProperty(value = "提报角色")
	@TableField("ROLE_ID")
	private String roleId;

}
