/**
 * Copyright &copy; 2015-2020 <a href="http://www.jeeplus.org/">JeePlus</a> All rights reserved.
 */
package com.jeeplus.modules.workinvoicereturnalter.entity;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.jeeplus.common.persistence.ActEntity;
import com.jeeplus.common.utils.excel.annotation.ExcelField;
import com.jeeplus.modules.workinvoicedetail.entity.WorkInvoiceDetail;
import com.jeeplus.modules.workinvoicereturn.entity.WorkInvoiceReturn;
import org.activiti.engine.history.HistoricProcessInstance;
import org.activiti.engine.repository.ProcessDefinition;
import org.activiti.engine.runtime.ProcessInstance;
import org.activiti.engine.task.Task;

import java.util.Date;
import java.util.Map;

/**
 * 退票管理Entity
 * @version 2018-06-15
 * @author lw
 */
public class WorkInvoiceReturnAlter extends ActEntity<WorkInvoiceReturnAlter> {
	public static final String SERIAL_BIZCODE = "4";//编号模板类型

	private static final long serialVersionUID = 1L;
	private String processInstanceId;		// 实例流程id
	private String officeId;		// 部门id
	private String companyId;		// 公司Id
	private String status;		// 状态
	private WorkInvoiceDetail invoiceDetail;		// 发票明细主键
	private String returnNumber;      //退票申请编号
	private String reason;		// 退票原因
	private String cancleReturn;		// 作废/退票
	private String returnType;		// 原票是否退回
	private String code;		// 发票代码
	private String number;		// 发票号
	private String uname;		// 退票人
	private Date returnDate;		// 退票日期
	private String home;
	private WorkInvoiceReturn workInvoiceReturn;      //变更前数据
	private Date beginContractDate;		// 开始
	private Date endContractDate;		// 结束
	// 流程任务
	private Task task;
	private Map<String, Object> variables;
	// 运行中的流程实例
	private ProcessInstance processInstance;
	// 历史的流程实例
	private HistoricProcessInstance historicProcessInstance;
	// 流程定义
	private ProcessDefinition processDefinition;

	public WorkInvoiceReturnAlter() {
		super();
	}

	public WorkInvoiceReturnAlter(String id){
		super(id);
	}

	@ExcelField(title="实例流程id", align=2, sort=7)
	public String getProcessInstanceId() {
		return processInstanceId;
	}

	public void setProcessInstanceId(String processInstanceId) {
		this.processInstanceId = processInstanceId;
	}
	
	@ExcelField(title="部门id", align=2, sort=8)
	public String getOfficeId() {
		return officeId;
	}

	public void setOfficeId(String officeId) {
		this.officeId = officeId;
	}
	
	@ExcelField(title="公司Id", align=2, sort=9)
	public String getCompanyId() {
		return companyId;
	}

	public void setCompanyId(String companyId) {
		this.companyId = companyId;
	}
	
	@ExcelField(title="状态", align=2, sort=10)
	public String getStatus() {
		return status;
	}

	public void setStatus(String status) {
		this.status = status;
	}

	public WorkInvoiceDetail getInvoiceDetail() {
		return invoiceDetail;
	}

	public Date getBeginContractDate() {
		return beginContractDate;
	}

	public void setBeginContractDate(Date beginContractDate) {
		this.beginContractDate = beginContractDate;
	}

	public Date getEndContractDate() {
		return endContractDate;
	}

	public void setEndContractDate(Date endContractDate) {
		this.endContractDate = endContractDate;
	}

	public void setInvoiceDetail(WorkInvoiceDetail invoiceDetail) {
		this.invoiceDetail = invoiceDetail;
	}

	public String getReturnNumber() {
		return returnNumber;
	}

	public WorkInvoiceReturn getWorkInvoiceReturn() {
		return workInvoiceReturn;
	}

	public void setWorkInvoiceReturn(WorkInvoiceReturn workInvoiceReturn) {
		this.workInvoiceReturn = workInvoiceReturn;
	}

	public void setReturnNumber(String returnNumber) {
		this.returnNumber = returnNumber;
	}

	public Task getTask() {
		return task;
	}

	public void setTask(Task task) {
		this.task = task;
	}

	public String getHome() {
		return home;
	}

	public void setHome(String home) {
		this.home = home;
	}

	public Map<String, Object> getVariables() {
		return variables;
	}

	public void setVariables(Map<String, Object> variables) {
		this.variables = variables;
	}

	public ProcessInstance getProcessInstance() {
		return processInstance;
	}

	public void setProcessInstance(ProcessInstance processInstance) {
		this.processInstance = processInstance;
	}

	public HistoricProcessInstance getHistoricProcessInstance() {
		return historicProcessInstance;
	}

	public void setHistoricProcessInstance(HistoricProcessInstance historicProcessInstance) {
		this.historicProcessInstance = historicProcessInstance;
	}

	public ProcessDefinition getProcessDefinition() {
		return processDefinition;
	}

	public void setProcessDefinition(ProcessDefinition processDefinition) {
		this.processDefinition = processDefinition;
	}

	@ExcelField(title="退票原因", align=2, sort=12)
	public String getReason() {
		return reason;
	}

	public void setReason(String reason) {
		this.reason = reason;
	}
	
	@ExcelField(title="作废/退票", align=2, sort=13)
	public String getCancleReturn() {
		return cancleReturn;
	}

	public void setCancleReturn(String cancleReturn) {
		this.cancleReturn = cancleReturn;
	}
	
	@ExcelField(title="原票是否退回", align=2, sort=14)
	public String getReturnType() {
		return returnType;
	}

	public void setReturnType(String returnType) {
		this.returnType = returnType;
	}
	
	@ExcelField(title="发票代码", align=2, sort=15)
	public String getCode() {
		return code;
	}

	public void setCode(String code) {
		this.code = code;
	}
	
	@ExcelField(title="发票号", align=2, sort=16)
	public String getNumber() {
		return number;
	}

	public void setNumber(String number) {
		this.number = number;
	}
	
	@ExcelField(title="退票人", align=2, sort=17)
	public String getUname() {
		return uname;
	}

	public void setUname(String uname) {
		this.uname = uname;
	}
	
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
	@ExcelField(title="退票日期", align=2, sort=18)
	public Date getReturnDate() {
		return returnDate;
	}

	public void setReturnDate(Date returnDate) {
		this.returnDate = returnDate;
	}
	
}