|
|
|
@ -104,14 +104,16 @@ public class OpenApiController { |
|
|
|
|
@RequestMapping(value = "/base/{interfaceVersion}/queryOrgInfoByCode",method = RequestMethod.POST) |
|
|
|
|
@ApiOperation(value = "查询用户数据权限") |
|
|
|
|
public com.dxhy.itax.result.Result queryOrgInfoByCode(@RequestBody DeptTaskQueryDto deptTaskQueryDto, @PathVariable("interfaceVersion") String interfaceVersion) { |
|
|
|
|
log.info("查询组织信息入参{}",JSONObject.toJSONString(deptTaskQueryDto)); |
|
|
|
|
String SysDeptEntity = (String) redisTemplate.opsForValue().get(CommonConstant.DEFAULT_DEPT_DATA_KEY+ deptTaskQueryDto.getTaxpayerCode()+deptTaskQueryDto.getEnterpriseNumbers()); |
|
|
|
|
com.dxhy.itax.result.Result result1 = com.dxhy.itax.result.Result.ok(); |
|
|
|
|
if (StringUtil.isBlank(SysDeptEntity)) { |
|
|
|
|
SysDeptEntityDto result = sysDeptService.queryOrgInfoByCode(deptTaskQueryDto); |
|
|
|
|
if(result!=null){ |
|
|
|
|
SysDeptEntityV2Dto sysDeptEntityV2Dto = ItaxBeanTransition.toSysDeptEntityV2Dto(result); |
|
|
|
|
log.info("查询组织信息为{}",JSONObject.toJSONString(sysDeptEntityV2Dto)); |
|
|
|
|
result1.put(ItaxConstant.STR_DATA,sysDeptEntityV2Dto); |
|
|
|
|
redisTemplate.opsForValue().set(CommonConstant.DEFAULT_DEPT_DATA_KEY+ deptTaskQueryDto.getTaxpayerCode()+deptTaskQueryDto.getEnterpriseNumbers(),JSONObject.toJSONString(sysDeptEntityV2Dto),12, TimeUnit.HOURS); |
|
|
|
|
// redisTemplate.opsForValue().set(CommonConstant.DEFAULT_DEPT_DATA_KEY+ deptTaskQueryDto.getTaxpayerCode()+deptTaskQueryDto.getEnterpriseNumbers(),JSONObject.toJSONString(sysDeptEntityV2Dto),12, TimeUnit.HOURS);
|
|
|
|
|
return result1; |
|
|
|
|
} |
|
|
|
|
}else{ |
|
|
|
|