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

import com.engine.salary.common.BaseQueryParam;
import com.engine.salary.common.LocalDateRange;
import com.engine.salary.enums.common.FilterEnum;
import com.engine.salary.enums.salarysob.SalaryEmployeeStatusEnum;
import com.engine.salary.util.valid.DataCheck;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.Collection;
import java.util.List;

/**
 * 薪资核算结果查询参数
 * <p>Copyright: Copyright (c) 2022</p>
 * <p>Company: 泛微软件</p>
 *
 * @author qiantao
 * @version 1.0
 **/
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class SalaryAcctResultQueryParam extends BaseQueryParam {

    //薪资核算记录id
    @DataCheck(require = true, message = "参数错误，薪资核算记录ID不能为空")
    private Long salaryAcctRecordId;

    //人员姓名
    private String employeeName;

    //个税扣缴义务人
    private Long taxAgentId;

    //分部
    private Collection<Long> subcompanyIds;

    //部门
    private Collection<Long> departmentIds;

    //岗位
    private Collection<Long> positionIds;

    //状态
    private SalaryEmployeeStatusEnum status;
    //状态(多选)
    private List<String> statuses;

    //离职日期
    private LocalDateRange dismissDate;

    //是否合并计税
    private String consolidatedTaxation;

    //列表主键id
    private Collection<Long> ids;

    private String workcode;

    //薪资项目id
    private Collection<Long> salaryItemIds;

    /**
     * 是否需要实时人员信息
     */
    private boolean dynamicEmpInfo;

    //其他条件
    private List<OtherCondition> otherConditions;


    @Data
    @NoArgsConstructor
    @AllArgsConstructor
    public static class OtherCondition {
        private Long itemId;
        private FilterEnum filter;
        private List<String> params;
    }
}
