Commit 97faf008 authored by 高建强's avatar 高建强

item:【JCS】bug修改提交

parent ded4b9e1
...@@ -427,14 +427,16 @@ public class WaterResourceController extends BaseController { ...@@ -427,14 +427,16 @@ public class WaterResourceController extends BaseController {
@GetMapping(value = "/page") @GetMapping(value = "/page")
@ApiOperation(httpMethod = "GET", value = "分页查询", notes = "分页查询") @ApiOperation(httpMethod = "GET", value = "分页查询", notes = "分页查询")
public ResponseModel<Page<WaterResourceDto>> queryForPage(@RequestParam(value = "pageNum") int pageNum, public ResponseModel<Page<WaterResourceDto>> queryForPage(@RequestParam(value = "pageNum") int pageNum,
@RequestParam(value = "pageSize") int pageSize, String name, @RequestParam(value = "pageSize") int pageSize,
@RequestParam(value = "name", required = false) String name,
@RequestParam(value = "belongBuildingId", required = false) ArrayList<Long> belongBuildingId, @RequestParam(value = "belongBuildingId", required = false) ArrayList<Long> belongBuildingId,
Long belongFightingSystemId, Long sequenceNbr, @RequestParam(value = "belongFightingSystemId", required = false) Long belongFightingSystemId,
String resourceType, @RequestParam(value = "sequenceNbr", required = false) Long sequenceNbr,
String classifyId, @RequestParam(value = "resourceType", required = false) String resourceType,
String bizOrgCode, @RequestParam(value = "classifyId", required = false) String classifyId,
String equipCateGoryCode, @RequestParam(value = "bizOrgCode", required = false) String bizOrgCode,
List<String> ids) { @RequestParam(value = "equipCateGoryCode", required = false) String equipCateGoryCode,
@RequestParam(value = "ids", required = false) List<String> ids) {
Page<WaterResourceDto> page = new Page<>(); Page<WaterResourceDto> page = new Page<>();
page.setCurrent(pageNum); page.setCurrent(pageNum);
page.setSize(pageSize); page.setSize(pageSize);
......
...@@ -1745,11 +1745,13 @@ public class OrgUsrServiceImpl extends BaseService<OrgUsrDto, OrgUsr, OrgUsrMapp ...@@ -1745,11 +1745,13 @@ public class OrgUsrServiceImpl extends BaseService<OrgUsrDto, OrgUsr, OrgUsrMapp
if (StringUtils.isNotEmpty(type) && type.equals("COMPANY")){ if (StringUtils.isNotEmpty(type) && type.equals("COMPANY")){
//查询当前登录人所属单位/部门 //查询当前登录人所属单位/部门
OrgUsr orgUsr = orgUsrMapper.selectById(reginParams.getPersonIdentity().getCompanyId()); OrgUsr orgUsr = orgUsrMapper.selectById(reginParams.getPersonIdentity().getCompanyId());
//判断登陆人是否已经是顶级节点单位 if (!ObjectUtils.isEmpty(orgUsr)) {
if (orgUsr.getParentId() != null ){ //判断登陆人是否已经是顶级节点单位
orgUsr =this.selectParentOrgUsr(orgUsr); if (orgUsr.getParentId() != null ){
bizOrgCode = orgUsr.getBizOrgCode() != null? orgUsr.getBizOrgCode() : reginParams.getPersonIdentity().getBizOrgCode(); orgUsr =this.selectParentOrgUsr(orgUsr);
bizOrgCode = orgUsr.getBizOrgCode() != null? orgUsr.getBizOrgCode() : reginParams.getPersonIdentity().getBizOrgCode();
}
} }
} }
param.put("bizOrgCode", bizOrgCode); param.put("bizOrgCode", bizOrgCode);
......
...@@ -7,7 +7,6 @@ import com.yeejoin.amos.boot.biz.common.dto.OrgMenuDto; ...@@ -7,7 +7,6 @@ import com.yeejoin.amos.boot.biz.common.dto.OrgMenuDto;
import com.yeejoin.equipmanage.common.dto.AreaDto; import com.yeejoin.equipmanage.common.dto.AreaDto;
import com.yeejoin.equipmanage.common.entity.Area; import com.yeejoin.equipmanage.common.entity.Area;
import com.yeejoin.equipmanage.common.vo.AreaResquest; import com.yeejoin.equipmanage.common.vo.AreaResquest;
import com.yeejoin.equipmanage.common.vo.AreaTreeVo;
import com.yeejoin.equipmanage.common.vo.UnitAreaTreeVo; import com.yeejoin.equipmanage.common.vo.UnitAreaTreeVo;
import java.util.List; import java.util.List;
......
...@@ -2795,25 +2795,24 @@ ...@@ -2795,25 +2795,24 @@
</changeSet> </changeSet>
<changeSet author="tw" id="20220217-2" runAlways="true"> <changeSet author="gaojianqiang" id="202206301726-1" runAlways="true">
<comment>`getChildLstCode`</comment> <comment>`getChildLstCode`</comment>
<sql endDelimiter="#"> <sql endDelimiter="#">
DROP FUNCTION IF EXISTS `getChildLstCode`# DROP FUNCTION IF EXISTS `getChildLstCode`#
CREATE DEFINER=`root`@`%` FUNCTION `getChildLstCode`(rootId varchar(100)) RETURNS varchar(2000) CHARSET latin1 CREATE DEFINER=`root`@`%` FUNCTION `getChildLstCode`(`rootId` bigint) RETURNS varchar(1000) CHARSET utf8
BEGIN BEGIN
DECLARE i varchar(2000) default '';
DECLARE j varchar(1000) default rootId;
WHILE rootId is not null do DECLARE sTemp TEXT;
SET i =(SELECT group_concat(sequence_nbr) FROM cb_data_dictionary WHERE parent in ( rootId) ); DECLARE sTempChd VARCHAR(4000);
IF i is not null THEN
SET j = concat(i, ',', j); SET sTemp='$';
SET rootId = i; SET sTempChd = CAST(rootId AS CHAR);
ELSE
SET rootId = i; WHILE sTempChd IS NOT NULL DO
END IF; SET sTemp= CONCAT(sTemp,',',sTempChd);
SELECT GROUP_CONCAT(distinct sequence_nbr) INTO sTempChd FROM cb_data_dictionary WHERE FIND_IN_SET(parent,sTempChd)>0;
END WHILE; END WHILE;
return j; RETURN substring(sTemp,3);
END# END#
</sql> </sql>
</changeSet> </changeSet>
......
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