Commit 375c56e4 by 林冲

单元测试

1 parent 9822a618
...@@ -30,7 +30,7 @@ public class SalaryAppealSummaryResponse implements Serializable { ...@@ -30,7 +30,7 @@ public class SalaryAppealSummaryResponse implements Serializable {
private BigDecimal padDeductionAmount; private BigDecimal padDeductionAmount;
@ApiModelProperty("缺失日报日期") @ApiModelProperty("缺失日报日期")
private List<String> missingDailyReportDates; private List<Integer> missingDailyReportDates;
@ApiModelProperty("是否允许发起考勤申诉") @ApiModelProperty("是否允许发起考勤申诉")
private Boolean attendanceAppealable; private Boolean attendanceAppealable;
......
...@@ -16,6 +16,7 @@ import cn.com.glsx.framework.rop.response.RopResponse; ...@@ -16,6 +16,7 @@ import cn.com.glsx.framework.rop.response.RopResponse;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.apache.commons.collections4.CollectionUtils; import org.apache.commons.collections4.CollectionUtils;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import org.springframework.util.Assert;
import javax.annotation.Resource; import javax.annotation.Resource;
import java.util.List; import java.util.List;
...@@ -31,11 +32,16 @@ public class StaffSalaryAppealApplyRecordService { ...@@ -31,11 +32,16 @@ public class StaffSalaryAppealApplyRecordService {
RpcPagination<StaffSalaryAppealApplyRecordDTO> pagination = CommonUtil.getRpcPagination(StaffSalaryAppealApplyRecordDTO.class); RpcPagination<StaffSalaryAppealApplyRecordDTO> pagination = CommonUtil.getRpcPagination(StaffSalaryAppealApplyRecordDTO.class);
// 设置查询条件 // 设置查询条件
pagination.getCondition().setStaffName(request.getStaffName()); StaffSalaryAppealApplyRecordDTO condition = pagination.getCondition();
pagination.getCondition().setAppealType(request.getAppealType()); condition.setStaffName(request.getStaffName());
pagination.getCondition().setApplyStartTime(request.getApplyStartTime()); condition.setAppealType(request.getAppealType());
pagination.getCondition().setApplyEndTime(request.getApplyEndTime()); condition.setApplyStartTime(request.getApplyStartTime());
condition.setApplyEndTime(request.getApplyEndTime());
// 经理可以查询下面所有人的,超级管理员可以看所有的
LoginUserInfoResponse loginUserInfo = CommonUtil.getLoginUserInfo();
Assert.notNull(loginUserInfo, "用户信息不能为空");
condition.setIsSuper(loginUserInfo.getIsSuper());
condition.setLoginPhone(loginUserInfo.getPhone());
RpcResponse<RpcPagination<StaffSalaryAppealApplyRecordDTO>> rpcResponse = staffSalaryAppealApplyRecordRemote.pageList(pagination); RpcResponse<RpcPagination<StaffSalaryAppealApplyRecordDTO>> rpcResponse = staffSalaryAppealApplyRecordRemote.pageList(pagination);
return CommonUtil.convertPaginationRopResponse(rpcResponse, StaffSalaryAppealApplyRecordDTOConvert.INSTANCE::toPageResponse); return CommonUtil.convertPaginationRopResponse(rpcResponse, StaffSalaryAppealApplyRecordDTOConvert.INSTANCE::toPageResponse);
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!