Commit 9d7b51c3 authored by chenzhao's avatar chenzhao

修改bug

parent c88f497f
...@@ -39,7 +39,7 @@ public class FireTeamDto extends BaseDto { ...@@ -39,7 +39,7 @@ public class FireTeamDto extends BaseDto {
@ApiModelProperty(value = "机构code") @ApiModelProperty(value = "机构code")
private String companyCode; private String companyCode;
@ExplicitConstraint(indexNum = 1, sourceClass = CommonExplicitConstraint.class,method="getFireTeam") //动态下拉内容 @ExplicitConstraint(indexNum = 1, sourceClass = CommonExplicitConstraint.class,method="getFireTeamList") //动态下拉内容
@ExcelProperty(value = "上级队伍", index = 1) @ExcelProperty(value = "上级队伍", index = 1)
@ApiModelProperty(value = "父级名称") @ApiModelProperty(value = "父级名称")
private String parentName; private String parentName;
......
...@@ -184,6 +184,10 @@ public class DataSourcesImpl implements DataSources { ...@@ -184,6 +184,10 @@ public class DataSourcesImpl implements DataSources {
case "getFireStationContactUser": case "getFireStationContactUser":
str = getFireStationContactUser(); str = getFireStationContactUser();
break; break;
case "getFireTeamList":
str = getFireTeamList();
break;
} }
} }
return str; return str;
...@@ -269,6 +273,23 @@ public class DataSourcesImpl implements DataSources { ...@@ -269,6 +273,23 @@ public class DataSourcesImpl implements DataSources {
return str; return str;
} }
private String[] getFireTeamList() {
// Page<FireTeamCardDto> pageBean = new Page<>(0, Integer.MAX_VALUE);
// IPage<FireTeamCardDto> fireTeamCardDtoIPage = fireTeamService.listFireTeamByPage(pageBean,
// new FireTeamListDto());
// List<FireTeamCardDto> records = fireTeamCardDtoIPage.getRecords();
// 导出模板增加权限
ReginParams reginParams = JSONObject.parseObject(redisUtils.get(RedisKey.buildReginKey(RequestContext.getExeUserId(), RequestContext.getToken())).toString(), ReginParams.class);
// 权限处理
PermissionInterceptorContext.setDataAuthRule("fire_team_info");
List<FireTeam> records = fireTeamService.getFireTeamList(reginParams.getPersonIdentity().getBizOrgCode());
List<String> names = records.stream().map(item -> {
return item.getName() + "@" + item.getSequenceNbr();
}).collect(Collectors.toList());
String[] str = names.toArray(new String[names.size()]);
return str;
}
private String[] getEquipFireTeam() { private String[] getEquipFireTeam() {
// Page<FireTeamCardDto> pageBean = new Page<>(0, Integer.MAX_VALUE); // Page<FireTeamCardDto> pageBean = new Page<>(0, Integer.MAX_VALUE);
// IPage<FireTeamCardDto> fireTeamCardDtoIPage = fireTeamService.listFireTeamByPage(pageBean, // IPage<FireTeamCardDto> fireTeamCardDtoIPage = fireTeamService.listFireTeamByPage(pageBean,
......
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