package com.cpop.oam.business.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.experimental.Accessors;

import java.time.LocalDateTime;
import java.util.List;

/**
 * @author DB
 * @createTime 2023/11/28 15:08
 * @description
 */
@Data
@Accessors(chain = true)
@Schema(description = "接收/处理/暂停中对象")
public class TaskWorkOrderReceiveDealPauseVo {

    /**
     * 待接收列表
     */
    @Schema(description = "待接收列表")
    private List<Receive> receiveList;

    /**
     * 处理中列表
     */
    @Schema(description = "处理中列表")
    private List<Deal> dealList;

    /**
     * 暂停中列表
     */
    @Schema(description = "暂停中列表")
    private List<Pause> pauseList;

    /**
     * 接收
     */
    @Data
    @Schema(description = "待接收")
    public static class Receive {

        /**
         * 工单id
         */
        @Schema(description = "工单id")
        private String id;

        /**
         * 机构/品牌
         */
        @Schema(description = "机构/品牌")
        private String brandName;

        /**
         * 校区/店铺
         */
        @Schema(description = "校区/店铺")
        private String storeName;

        /**
         * 机构/品牌ID
         */
        @Schema(description = "机构/品牌ID")
        private String brandId;

        /**
         * 校区/店铺ID
         */
        @Schema(description = "校区/店铺ID")
        private String storeId;

        /**
         * 问题描述
         */
        @Schema(description = "问题描述")
        private String taskContent;

        /**
         * 手机号
         */
        @Schema(description = "手机号")
        private String phoneNumber;

        /**
         * 提交人
         */
        @Schema(description = "提交人")
        private String recordStaffName;

        /**
         * 提交时间
         */
        @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
        @Schema(description = "提交时间")
        private LocalDateTime createTime;

    }

    /**
     * 接收
     */
    @Data
    @Schema(description = "处理中")
    public static class Deal {

        /**
         * 工单id
         */
        @Schema(description = "工单id")
        private String id;

        /**
         * 机构/品牌
         */
        @Schema(description = "机构/品牌")
        private String brandName;

        /**
         * 校区/店铺
         */
        @Schema(description = "校区/店铺")
        private String storeName;

        /**
         * 机构/品牌ID
         */
        @Schema(description = "机构/品牌ID")
        private String brandId;

        /**
         * 校区/店铺ID
         */
        @Schema(description = "校区/店铺ID")
        private String storeId;

        /**
         * 问题描述
         */
        @Schema(description = "问题描述")
        private String taskContent;

        /**
         * 提交人
         */
        @Schema(description = "提交人")
        private String recordStaffName;

        /**
         * 提交时间
         */
        @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
        @Schema(description = "提交时间")
        private LocalDateTime createTime;

        /**
         * 接收人
         */
        @Schema(description = "接收人")
        private String responsibleStaffName;

        /**
         * 任务接收时间
         */
        @Schema(description = "任务接收时间")
        @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
        private LocalDateTime taskReceiptTime;

        /**
         * 任务接收用时/min
         */
        @Schema(description = "任务接收用时/min")
        private Integer receivingTime;

        /**
         * 任务状态(-1:失败;0:待审核;1:待接受;2:进行中;3:待测试;5:暂停;7:接收超时;8:待部署;9:待归档;10:审核不通过)
         */
        @Schema(description = "任务状态(-1:失败;0:待审核;1:待接受;2:进行中;3:待测试;5:暂停;7:接收超时;8:待部署;9:待归档;10:审核不通过)")
        private Integer taskStatus;

    }

    /**
     * 暂停中
     */
    @Data
    @Schema(description = "暂停中")
    public static class Pause {

        /**
         * 工单id
         */
        @Schema(description = "工单id")
        private String id;

        /**
         * 机构/品牌
         */
        @Schema(description = "机构/品牌")
        private String brandName;

        /**
         * 校区/店铺
         */
        @Schema(description = "校区/店铺")
        private String storeName;

        /**
         * 机构/品牌ID
         */
        @Schema(description = "机构/品牌ID")
        private String brandId;

        /**
         * 校区/店铺ID
         */
        @Schema(description = "校区/店铺ID")
        private String storeId;

        /**
         * 问题描述
         */
        @Schema(description = "问题描述")
        private String taskContent;

        /**
         * 提交人
         */
        @Schema(description = "提交人")
        private String recordStaffName;

        /**
         * 提交时间
         */
        @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
        @Schema(description = "提交时间")
        private LocalDateTime createTime;

        /**
         * 接收人
         */
        @Schema(description = "接收人")
        private String responsibleStaffName;

        /**
         * 暂停员工
         */
        @Schema(description = "暂停员工")
        private String pauseStaffName;

        /**
         * 暂停记录时间
         */
        @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
        @Schema(description = "暂停记录时间")
        private LocalDateTime pauseRecordTime;

        /**
         * 暂停到期时间
         */
        @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
        @Schema(description = "暂停到期时间")
        private LocalDateTime pauseExpireTime;

    }
}
