/**
 * Copyright (c) 2018-2099, Chill Zhuang 庄骞 (bladejava@qq.com).
 * <p>
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 * <p>
 * http://www.apache.org/licenses/LICENSE-2.0
 * <p>
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.xiaoniu.subsystem.system.domain.dto;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.xiaoniu.subsystem.system.domain.Unit;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotNull;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serial;
import java.util.Date;

/**
 * 单位管理表数据传输对象实体类
 *
 * @author sst
 * @since 2024-11-26
 */
@Data
public class UnitUpdateDTO {
	@Serial
	private static final long serialVersionUID = 1L;
	/**
	 * 单位id
	 */
	@Schema(description = "单位id")
	@NotNull(message = "单位id不能为空")
	private Long unitId;
	/**
	 * 单位名称
	 */
	@Schema(description = "单位名称")
	private String unitName;
	/**
	 * 单位代码
	 */
	@Schema(description = "单位代码")
	private String unitCode;
	/**
	 * 父单位id
	 */
	@Schema(description = "父单位id")
	private Long parentId;
	/**
	 * 父单位名称
	 */
	@Schema(description = "父单位名称")
	private String parentName;
	/**
	 * 父单位代码
	 */
	@Schema(description = "父单位代码")
	private String parentCode;
	/**
	 * 祖级列表
	 */
	@Schema(description = "祖级列表")
	private String ancestors;
	/**
	 * 旧单位代码
	 */
	@Schema(description = "旧单位代码")
	private String unitOldCode;
	/**
	 * 单位简称
	 */
	@Schema(description = "单位简称")
	private String forShort;
	/**
	 * 部队番号
	 */
	@Schema(description = "部队番号")
	private String unitDesignation;
	/**
	 * 联系人
	 */
	@Schema(description = "联系人")
	private String contactPerson;
	/**
	 * 联系电话
	 */
	@Schema(description = "联系电话")
	private String phone;
	/**
	 * 单位地址
	 */
	@Schema(description = "单位地址")
	private String address;
	/**
	 * 邮政编码
	 */
	@Schema(description = "邮政编码")
	private String postalCode;
	/**
	 * 显示顺序
	 */
	@Schema(description = "显示顺序")
	private Integer orderNum;
	/**
	 * 类型（0机关单位 1承训单位）
	 */
	@Schema(description = "类型（0机关单位 1承训单位）")
	private String type;
	/**
	 * 备注/说明
	 */
	@Schema(description = "备注/说明")
	private String remark;

	/**
	 * 单位更新时间
	 */
	@DateTimeFormat(pattern = "yyyy-MM-dd")
	@JsonFormat(pattern = "yyyy-MM-dd")
	@Schema(description = "单位更新时间")
	private Date unitUpdateTime;

	/**
	 * 状态（0正常 1停用）
	 */
	@Schema(description = "状态（0正常 1停用）")
	private Integer status;

}
