61 lines
2.0 KiB
Java
61 lines
2.0 KiB
Java
|
|
package com.engine.salary.web;
|
||
|
|
|
||
|
|
import com.engine.common.util.ServiceUtil;
|
||
|
|
import com.engine.salary.entity.salaryarchive.param.SalaryArchiveQueryParam;
|
||
|
|
import com.engine.salary.entity.siaccount.param.InsuranceAccountBatchParam;
|
||
|
|
import com.engine.salary.service.SIAccountService;
|
||
|
|
import com.engine.salary.service.impl.SIAccountServiceImpl;
|
||
|
|
import com.engine.salary.util.ResponseResult;
|
||
|
|
import io.swagger.v3.oas.annotations.parameters.RequestBody;
|
||
|
|
import weaver.hrm.HrmUserVarify;
|
||
|
|
import weaver.hrm.User;
|
||
|
|
|
||
|
|
import javax.servlet.http.HttpServletRequest;
|
||
|
|
import javax.servlet.http.HttpServletResponse;
|
||
|
|
import javax.ws.rs.*;
|
||
|
|
import javax.ws.rs.core.Context;
|
||
|
|
import javax.ws.rs.core.MediaType;
|
||
|
|
import java.util.Map;
|
||
|
|
|
||
|
|
/**
|
||
|
|
* @Author weaver_cl
|
||
|
|
* @Description: TODO 福利核算控制器
|
||
|
|
* @Date 2022/4/11
|
||
|
|
* @Version V1.0
|
||
|
|
**/
|
||
|
|
public class SIAccountController {
|
||
|
|
|
||
|
|
public SIAccountService getService(User user) {
|
||
|
|
return ServiceUtil.getService(SIAccountServiceImpl.class,user);
|
||
|
|
}
|
||
|
|
|
||
|
|
/**
|
||
|
|
* 获取台账列表页
|
||
|
|
* @param request
|
||
|
|
* @param response
|
||
|
|
* @return
|
||
|
|
*/
|
||
|
|
@GET
|
||
|
|
@Path("/batch/list")
|
||
|
|
@Produces(MediaType.APPLICATION_JSON)
|
||
|
|
public String list(@Context HttpServletRequest request, @Context HttpServletResponse response,@RequestBody InsuranceAccountBatchParam insuranceAccountBatchParam) {
|
||
|
|
User user = HrmUserVarify.getUser(request, response);
|
||
|
|
return new ResponseResult<InsuranceAccountBatchParam, Map<String, Object>>().run(getService(user)::listPage, insuranceAccountBatchParam);
|
||
|
|
}
|
||
|
|
|
||
|
|
@GET
|
||
|
|
@Path("/detail/common/list")
|
||
|
|
@Produces(MediaType.APPLICATION_JSON)
|
||
|
|
public String commonList(@Context HttpServletRequest request, @Context HttpServletResponse response,
|
||
|
|
@QueryParam("billMonth") String billMonth) {
|
||
|
|
User user = HrmUserVarify.getUser(request, response);
|
||
|
|
return new ResponseResult<String, Map<String, Object>>().run(getService(user)::listCommonPage, billMonth);
|
||
|
|
}
|
||
|
|
|
||
|
|
|
||
|
|
|
||
|
|
|
||
|
|
|
||
|
|
|
||
|
|
}
|