Merge remote-tracking branch 'origin/master'
This commit is contained in:
commit
4b0340d2b0
|
@ -5,7 +5,14 @@ import com.ruoyi.common.core.controller.BaseController;
|
||||||
import com.ruoyi.common.core.domain.AjaxResult;
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
import com.ruoyi.common.core.page.TableDataInfo;
|
import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
import com.ruoyi.database.domain.ApprovalProcess;
|
import com.ruoyi.database.domain.ApprovalProcess;
|
||||||
|
import com.ruoyi.database.domain.BusinessTripApproval;
|
||||||
|
import com.ruoyi.database.domain.NonWorkingDayDrinkingReport;
|
||||||
|
import com.ruoyi.database.domain.PoliceLeaveApproval;
|
||||||
|
import com.ruoyi.database.mapper.PoliceLeaveApprovalMapper;
|
||||||
import com.ruoyi.database.service.ApprovalProcessService;
|
import com.ruoyi.database.service.ApprovalProcessService;
|
||||||
|
import com.ruoyi.database.service.BusinessTripApprovalService;
|
||||||
|
import com.ruoyi.database.service.NonWorkingDayDrinkingReportService;
|
||||||
|
import com.ruoyi.database.service.PoliceLeaveApprovalService;
|
||||||
import io.swagger.annotations.Api;
|
import io.swagger.annotations.Api;
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.ApiOperation;
|
||||||
import lombok.RequiredArgsConstructor;
|
import lombok.RequiredArgsConstructor;
|
||||||
|
@ -32,6 +39,9 @@ import java.util.List;
|
||||||
public class ApprovalProcessController extends BaseController {
|
public class ApprovalProcessController extends BaseController {
|
||||||
|
|
||||||
private final ApprovalProcessService approvalsProcessService;
|
private final ApprovalProcessService approvalsProcessService;
|
||||||
|
private final BusinessTripApprovalService businessTripApprovalService;
|
||||||
|
private final NonWorkingDayDrinkingReportService nonWorkingDayDrinkingReportService;
|
||||||
|
private final PoliceLeaveApprovalService policeLeaveApprovalService;
|
||||||
|
|
||||||
|
|
||||||
@PostMapping("/list")
|
@PostMapping("/list")
|
||||||
|
@ -189,11 +199,31 @@ public class ApprovalProcessController extends BaseController {
|
||||||
@ApiOperation("根据id查")
|
@ApiOperation("根据id查")
|
||||||
@PostMapping("/getById/{id}")
|
@PostMapping("/getById/{id}")
|
||||||
public AjaxResult getById(@PathVariable Long id) {
|
public AjaxResult getById(@PathVariable Long id) {
|
||||||
List<ApprovalProcess> list = approvalsProcessService.lambdaQuery()
|
ApprovalProcess byId = approvalsProcessService.getById(id);
|
||||||
.eq(ApprovalProcess::getId, id)
|
Integer matterType = byId.getMatterType();
|
||||||
.orderByDesc(ApprovalProcess::getCreateTime)
|
if (matterType == 2){
|
||||||
.list();
|
BusinessTripApproval one = businessTripApprovalService.lambdaQuery()
|
||||||
return AjaxResult.success(list);
|
.eq(BusinessTripApproval::getUuid, byId.getUuid())
|
||||||
|
.last("LIMIT 1")
|
||||||
|
.one();
|
||||||
|
one.setDestinationIdCn(byId.getBusinessTripDestination());
|
||||||
|
return AjaxResult.success(one);
|
||||||
|
}
|
||||||
|
if (matterType == 3){
|
||||||
|
PoliceLeaveApproval one = policeLeaveApprovalService.lambdaQuery()
|
||||||
|
.eq(PoliceLeaveApproval::getUuid, byId.getUuid())
|
||||||
|
.last("LIMIT 1")
|
||||||
|
.one();
|
||||||
|
return AjaxResult.success(one);
|
||||||
|
}
|
||||||
|
if (matterType == 4){
|
||||||
|
NonWorkingDayDrinkingReport one = nonWorkingDayDrinkingReportService.lambdaQuery()
|
||||||
|
.eq(NonWorkingDayDrinkingReport::getUuid, byId.getUuid())
|
||||||
|
.last("LIMIT 1")
|
||||||
|
.one();
|
||||||
|
return AjaxResult.success(one);
|
||||||
|
}
|
||||||
|
return AjaxResult.success(null);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -102,6 +102,7 @@ public class BusinessTripApprovalController extends BaseController {
|
||||||
String uuids = uuid.toString();
|
String uuids = uuid.toString();
|
||||||
|
|
||||||
dto.setUuid(uuids);
|
dto.setUuid(uuids);
|
||||||
|
BaseAddressInfo byId = baseAddressInfoService.getById(dto.getDestinationId());
|
||||||
ApprovalProcess approvalProcess = new ApprovalProcess();
|
ApprovalProcess approvalProcess = new ApprovalProcess();
|
||||||
approvalProcess.setApprovalNo(s);
|
approvalProcess.setApprovalNo(s);
|
||||||
approvalProcess.setProcessTitle("出差呈请");
|
approvalProcess.setProcessTitle("出差呈请");
|
||||||
|
@ -111,8 +112,9 @@ public class BusinessTripApprovalController extends BaseController {
|
||||||
approvalProcess.setMatterType(2);
|
approvalProcess.setMatterType(2);
|
||||||
approvalProcess.setApprovalStatus(0);
|
approvalProcess.setApprovalStatus(0);
|
||||||
approvalProcess.setReadStatus(0);
|
approvalProcess.setReadStatus(0);
|
||||||
approvalProcess.setBusinessTripDestination(dto.getDestinationIdCn());
|
approvalProcess.setBusinessTripDestination(byId.getAddName());
|
||||||
approvalProcess.setStartTime(approvalProcess.getStartTime());
|
approvalProcess.setStartTime(dto.getStartDate());
|
||||||
|
approvalProcess.setEndTime(dto.getEndDate());
|
||||||
approvalProcess.setCreateTime(new Date().getTime());
|
approvalProcess.setCreateTime(new Date().getTime());
|
||||||
approvalProcess.setUuid(uuids);
|
approvalProcess.setUuid(uuids);
|
||||||
approvalsProcessService.save(approvalProcess);
|
approvalsProcessService.save(approvalProcess);
|
||||||
|
|
|
@ -23,4 +23,8 @@ public class DetailsApiController extends BaseController {
|
||||||
private final BusinessTripApprovalService businessTripApprovalService;
|
private final BusinessTripApprovalService businessTripApprovalService;
|
||||||
|
|
||||||
|
|
||||||
|
public void getUserPic(){
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -132,6 +132,7 @@ public class PoliceLeaveApprovalController extends BaseController {
|
||||||
approvalProcess.setMatterType(3);
|
approvalProcess.setMatterType(3);
|
||||||
approvalProcess.setApprovalStatus(0);
|
approvalProcess.setApprovalStatus(0);
|
||||||
approvalProcess.setReadStatus(0);
|
approvalProcess.setReadStatus(0);
|
||||||
|
approvalProcess.setLeaveType(policeLeaveApproval.getLeaveType());
|
||||||
approvalProcess.setStartTime(policeLeaveApproval.getStartDate());
|
approvalProcess.setStartTime(policeLeaveApproval.getStartDate());
|
||||||
approvalProcess.setEndTime(policeLeaveApproval.getEndDate());
|
approvalProcess.setEndTime(policeLeaveApproval.getEndDate());
|
||||||
approvalProcess.setCreateTime(new Date().getTime());
|
approvalProcess.setCreateTime(new Date().getTime());
|
||||||
|
|
|
@ -8,10 +8,7 @@ import com.ruoyi.database.service.gwglLogService;
|
||||||
import io.swagger.annotations.Api;
|
import io.swagger.annotations.Api;
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.ApiOperation;
|
||||||
import lombok.RequiredArgsConstructor;
|
import lombok.RequiredArgsConstructor;
|
||||||
import org.springframework.web.bind.annotation.PathVariable;
|
import org.springframework.web.bind.annotation.*;
|
||||||
import org.springframework.web.bind.annotation.RequestBody;
|
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
@ -30,7 +27,7 @@ public class gwglLogController extends BaseController {
|
||||||
private final gwglLogService gwglLogService;
|
private final gwglLogService gwglLogService;
|
||||||
|
|
||||||
@ApiOperation("查询审批日志")
|
@ApiOperation("查询审批日志")
|
||||||
@RequestMapping("/list")
|
@PostMapping("/list")
|
||||||
public TableDataInfo query(@RequestBody gwglLog gwglLog){
|
public TableDataInfo query(@RequestBody gwglLog gwglLog){
|
||||||
startPage();
|
startPage();
|
||||||
QueryWrapper<gwglLog> queryWrapper = new QueryWrapper<>(gwglLog);
|
QueryWrapper<gwglLog> queryWrapper = new QueryWrapper<>(gwglLog);
|
||||||
|
@ -39,7 +36,7 @@ public class gwglLogController extends BaseController {
|
||||||
}
|
}
|
||||||
|
|
||||||
@ApiOperation("根据编号查询日志")
|
@ApiOperation("根据编号查询日志")
|
||||||
@RequestMapping("/detail/{applyNo}")
|
@GetMapping("/detail/{applyNo}")
|
||||||
public TableDataInfo detail(@PathVariable String applyNo){
|
public TableDataInfo detail(@PathVariable String applyNo){
|
||||||
QueryWrapper<gwglLog> queryWrapper = new QueryWrapper<>();
|
QueryWrapper<gwglLog> queryWrapper = new QueryWrapper<>();
|
||||||
queryWrapper.eq("apply_no", applyNo);
|
queryWrapper.eq("apply_no", applyNo);
|
||||||
|
|
|
@ -125,4 +125,9 @@ public class ApprovalProcess {
|
||||||
@ApiModelProperty("关联用uuid")
|
@ApiModelProperty("关联用uuid")
|
||||||
private String uuid;
|
private String uuid;
|
||||||
|
|
||||||
|
@ApiModelProperty("请假类别(1-公休假 2-事假 3-探亲假 4-婚假 5-产假 6-护理假 7-病假 8-育儿假 9-其他)")
|
||||||
|
private Integer leaveType;
|
||||||
|
@TableField(exist = false)
|
||||||
|
private String leaveTypeCn;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -57,6 +57,8 @@ public class BusinessTripApproval extends BaseEntityMini {
|
||||||
|
|
||||||
@ApiModelProperty("是否自带公务车辆")
|
@ApiModelProperty("是否自带公务车辆")
|
||||||
private Integer hasOffcialCar;
|
private Integer hasOffcialCar;
|
||||||
|
@TableField(exist = false)
|
||||||
|
private String hasOffcialCarCn;
|
||||||
|
|
||||||
@ApiModelProperty("车型")
|
@ApiModelProperty("车型")
|
||||||
private Integer carModel;
|
private Integer carModel;
|
||||||
|
|
Loading…
Reference in New Issue