增加得分限制
This commit is contained in:
parent
0b6d9d75ec
commit
74e525a087
@ -134,9 +134,19 @@ public class GovEnterpriseScoreDetailController {
|
||||
@ApiOperation(value = " 添加企业对应工程得分明细信息", notes = "添加企业对应工程得分明细信息", httpMethod = "POST")
|
||||
@PostMapping(value = "/add")
|
||||
public Result<Object> add(@RequestBody EnterpriseScoreDetailVo enterpriseScoreDetailVo) {
|
||||
List<EnterpriseScoreDetail> enterpriseScoreDetails = enterpriseScoreDetailVo.getEnterpriseScoreDetails();
|
||||
boolean flag = true;
|
||||
for (EnterpriseScoreDetail enterpriseScoreDetail : enterpriseScoreDetails) {
|
||||
if (enterpriseScoreDetail.getScore() == null) {
|
||||
flag = false;
|
||||
}
|
||||
}
|
||||
if (flag) {
|
||||
enterpriseScoreDetailService.saveOrUpdateInfo(enterpriseScoreDetailVo);
|
||||
return Result.success("添加成功!");
|
||||
}
|
||||
return Result.error("评分失败,请输入对应得分!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user