Commit cf771308 authored by yangyang's avatar yangyang

Merge remote-tracking branch 'origin/developer' into developer

parents dfd6e539 23a98014
package com.yeejoin.amos.boot.module.jxiop.biz.controller;
import cn.hutool.core.collection.CollectionUtil;
import com.alibaba.fastjson.JSON;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
......@@ -180,6 +181,13 @@ public class IdxBizFanWeightController extends BaseController {
LambdaQueryWrapper<IdxBizFanWeight> qu1 = new LambdaQueryWrapper<>();
qu1.in(!list1.isEmpty(), IdxBizFanWeight::getSequenceNbr, list1);
List<IdxBizFanWeight> list = idxBizFanWeightMapper.selectList(qu1);
//如果区域为一个,则权重只能为1
Integer araeCount = idxBizFanWeightMapper.selectCount(new LambdaQueryWrapper<IdxBizFanWeight>().eq(IdxBizFanWeight::getType, "1"));
if(araeCount == 1 && CollectionUtil.isNotEmpty(list) && list.size()==1 && list.get(0).getType().equals("1")){
if(!"1.0000".equals(value.get("data").toString())){
throw new BadRequest("该区域权重只能配置为1");
}
}
IdxBizFanWeight reviewDto = list.get(0);
LambdaQueryWrapper<IdxBizFanWeight> qu = new LambdaQueryWrapper<>();
//获取所属,同类指标
......
package com.yeejoin.amos.boot.module.jxiop.biz.controller;
import cn.hutool.core.collection.CollectionUtil;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
......@@ -9,6 +10,7 @@ import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.yeejoin.amos.boot.biz.common.bo.ReginParams;
import com.yeejoin.amos.boot.biz.common.constants.BizConstant;
import com.yeejoin.amos.boot.biz.common.controller.BaseController;
import com.yeejoin.amos.boot.module.jxiop.biz.amosprojectentity.StdUserEmpower;
import com.yeejoin.amos.boot.module.jxiop.biz.amosprojectmapper.UserEmpowerMapper;
......@@ -191,6 +193,13 @@ public class IdxBizPvWeightController extends BaseController {
LambdaQueryWrapper<IdxBizPvWeight> qu1 = new LambdaQueryWrapper<>();
qu1.in(!list1.isEmpty(), IdxBizPvWeight::getSequenceNbr, list1);
List<IdxBizPvWeight> list = idxBizPvWeightMapper.selectList(qu1);
//如果区域为一个,则权重只能为1
Integer araeCount = idxBizPvWeightMapper.selectCount(new LambdaQueryWrapper<IdxBizPvWeight>().eq(IdxBizPvWeight::getType, "1"));
if(araeCount == 1 &&CollectionUtil.isNotEmpty(list) && list.size()==1 && list.get(0).getType().equals("1")){
if(!"1.0000".equals(value.get("data").toString())){
throw new BadRequest("该区域权重只能配置为1");
}
}
IdxBizPvWeight reviewDto = list.get(0);
LambdaQueryWrapper<IdxBizPvWeight> qu = new LambdaQueryWrapper<>();
//获取所属,同类指标
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment