|
|
@@ -1,34 +1,16 @@
|
|
|
package com.jzg.organization.controller;
|
|
|
|
|
|
-import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
|
-import com.jzg.commons.constants.OperationTypeEnum;
|
|
|
import com.jzg.commons.core.base.BaseController;
|
|
|
import com.jzg.commons.core.page.HttpResult;
|
|
|
-import com.jzg.commons.entity.dto.*;
|
|
|
-import com.jzg.commons.entity.enums.YesNoEnum;
|
|
|
-import com.jzg.commons.entity.po.OperatorTrajectory;
|
|
|
-import com.jzg.commons.entity.po.PtlAgreement;
|
|
|
import com.jzg.commons.entity.po.PtlNewCarJudgeRules;
|
|
|
-import com.jzg.commons.entity.vo.AgreementVo;
|
|
|
import com.jzg.commons.entity.vo.NewCarQuery;
|
|
|
-import com.jzg.commons.entity.vo.UpAndDownVo;
|
|
|
-import com.jzg.commons.service.OperatorTrajectoryService;
|
|
|
-import com.jzg.commons.util.AssertionUtils;
|
|
|
-import com.jzg.commons.util.spring.SpringUtils;
|
|
|
-import com.jzg.organization.mapper.PtlAgreementMapper;
|
|
|
import com.jzg.organization.service.NewCarJudgeRulesService;
|
|
|
-import com.jzg.organization.service.PtlAgreementDeptService;
|
|
|
-import com.jzg.organization.service.PtlAgreementService;
|
|
|
import io.swagger.v3.oas.annotations.Operation;
|
|
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
|
|
-import org.springframework.beans.BeanUtils;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
-import org.springframework.validation.annotation.Validated;
|
|
|
import org.springframework.web.bind.annotation.*;
|
|
|
|
|
|
import java.time.LocalDateTime;
|
|
|
-import java.util.List;
|
|
|
-import java.util.Objects;
|
|
|
|
|
|
/**
|
|
|
* 协议管理接口
|
|
|
@@ -60,12 +42,14 @@ public class NewCarJudgeRulesController extends BaseController {
|
|
|
@PostMapping("addNewCar")
|
|
|
public HttpResult addNewCar(@RequestBody PtlNewCarJudgeRules newCarJudgeRules){
|
|
|
newCarJudgeRules.setSystemCode(getUserSystemCode());
|
|
|
+ newCarJudgeRules.setSaveDate(LocalDateTime.now());
|
|
|
return newCarJudgeRulesService.addNewCar(newCarJudgeRules) ? HttpResult.ok("添加新旧车规则成功") : HttpResult.error("添加新旧车规则失败");
|
|
|
}
|
|
|
|
|
|
@Operation(summary = "修改新旧车规则")
|
|
|
@PostMapping("updateNewCar")
|
|
|
public HttpResult updateNewCar(@RequestBody PtlNewCarJudgeRules newCarJudgeRules){
|
|
|
+ newCarJudgeRules.setSaveDate(LocalDateTime.now());
|
|
|
return newCarJudgeRulesService.updateNewCar(newCarJudgeRules) ? HttpResult.ok("修改新旧车规则成功") : HttpResult.error("修改新旧车规则失败");
|
|
|
}
|
|
|
|