package cn.iocoder.yudao.module.smartfactory.controller.admin.staffsalary.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import javax.validation.constraints.NotNull;
import java.math.BigDecimal;
import java.util.List;

@Schema(description = "管理后台 - 厂区员工工资新增/修改 Request VO")
@Data
public class StaffSalarySaveReqVO {

    @Schema(description = "主键id", requiredMode = Schema.RequiredMode.NOT_REQUIRED, example = "1")
    private Long id;

    @Schema(description = "用户编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "146")
    @NotNull(message = "用户编号不能为空")
    private Long staffId;

    @Schema(description = "所属工厂编号", requiredMode = Schema.RequiredMode.REQUIRED, example = "146")
    @NotNull(message = "所属工厂不能为空")
    private Long factoryId;

    @Schema(description = "工资月份 | YYYY-MM", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "月份不能为空")
    private String month;

    @Schema(description = "考勤天数")
    private Integer attendanceDays;

    @Schema(description = "应发工资")
    private BigDecimal payableAmount;

    @Schema(description = "归还金额")
    private BigDecimal returnAmount;

    @Schema(description = "扣款金额")
    private BigDecimal deductionAmount;

    @Schema(description = "实发工资", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "实发工资不能为空")
    private BigDecimal realAmount;

    @Schema(description = "扣款明细")
    private List<DeductionItemsVO> deductionItems;

    @Schema(description = "薪资主体明细")
    private List<SalarySubjectItemsVO> salarySubjectItems;

    @Schema(description = "复核状态 | 0未复核 1已复核", requiredMode = Schema.RequiredMode.NOT_REQUIRED, example = "0")
    private Integer status;

}