package com.engine.salary.entity.salaryacct.dto;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.List;

/**
 * 薪资核算导入时生成导入模板的薪资项目
 * <p>Copyright: Copyright (c) 2022</p>
 * <p>Company: 泛微软件</p>
 *
 * @author qiantao
 * @version 1.0
 **/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class SalaryAcctImportFieldDTO {

//    //公式项
//    private Collection<ImportFieldDTO> formulaItems;
//
//    //sql项
//    private Collection<ImportFieldDTO> sqlItems;
//
//    //输入项
//    private Collection<ImportFieldDTO> inputItems;

    // 根据账套分组的薪资项目
    private List<SalaryAcctImportFieldDTO.ImportFieldByGroupDTO> itemsByGroup;

    // 缓存勾选项目
    private List<Long> checkItems;

    @Data
    @Builder
    @NoArgsConstructor
    @AllArgsConstructor
    public static class ImportFieldDTO {

        //薪资项目id
        private Long salaryItemId;

        //薪资项目名称
        private String salaryItemName;

        //薪资项目类型
        private String dataType;
    }

    @Data
    @Builder
    @NoArgsConstructor
    @AllArgsConstructor
    public static class ImportFieldByGroupDTO {

        //薪资账套分组id")
        private Long salarySobItemGroupId;

        //薪资项目分组名称")
        private String salarySobItemGroupName;

        //分组中包含的薪资项目
        private List<SalaryAcctImportFieldDTO.ImportFieldDTO> salaryItems;

        //分组顺序
        private Integer sortedIndex;
    }
}
