Commit c87b1f79 authored by suhuiguang's avatar suhuiguang

监管新增接口:

1.工作台设备种类 2.工作套设备类型
parent ee0e76d9
...@@ -8,6 +8,8 @@ import com.yeejoin.amos.boot.module.jg.biz.service.ICommonService; ...@@ -8,6 +8,8 @@ import com.yeejoin.amos.boot.module.jg.biz.service.ICommonService;
import com.yeejoin.amos.boot.module.jg.biz.service.IPdfService; import com.yeejoin.amos.boot.module.jg.biz.service.IPdfService;
import com.yeejoin.amos.boot.module.ymt.api.entity.EquipmentCategory; import com.yeejoin.amos.boot.module.ymt.api.entity.EquipmentCategory;
import com.yeejoin.amos.boot.module.ymt.api.enums.FlowStatusEnum; import com.yeejoin.amos.boot.module.ymt.api.enums.FlowStatusEnum;
import com.yeejoin.amos.feign.systemctl.Systemctl;
import com.yeejoin.amos.feign.systemctl.model.DictionarieValueModel;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
...@@ -18,119 +20,120 @@ import org.typroject.tyboot.core.foundation.enumeration.UserType; ...@@ -18,119 +20,120 @@ import org.typroject.tyboot.core.foundation.enumeration.UserType;
import org.typroject.tyboot.core.restful.doc.TycloudOperation; import org.typroject.tyboot.core.restful.doc.TycloudOperation;
import org.typroject.tyboot.core.restful.utils.ResponseHelper; import org.typroject.tyboot.core.restful.utils.ResponseHelper;
import org.typroject.tyboot.core.restful.utils.ResponseModel; import org.typroject.tyboot.core.restful.utils.ResponseModel;
import java.util.*; import java.util.*;
import java.util.stream.Collectors; import java.util.stream.Collectors;
/** /**
* 装备分类 * 监管公共Api
* *
* @author system_generator * @author system_generator
* @date 2021-10-20 * @date 2021-10-20
*/ */
@RestController @RestController
@Api(tags = "装备分类Api") @Api(tags = "监管公共Api")
@RequestMapping(value = "/common") @RequestMapping(value = "/common")
public class CommonController extends BaseController { public class CommonController extends BaseController {
@Autowired @Autowired
ICommonService commonService; ICommonService commonService;
@Autowired @Autowired
IPdfService pdfService; IPdfService pdfService;
@TycloudOperation(ApiLevel = UserType.AGENCY) @TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/getChildren") @GetMapping(value = "/getChildren")
@ApiOperation(httpMethod = "GET", value = "通过设备种类code获取设备类别", notes = "通过设备种类code获取设备类别") @ApiOperation(httpMethod = "GET", value = "通过设备种类code获取设备类别", notes = "通过设备种类code获取设备类别")
public ResponseModel<List<EquipmentCategory>> getChildren(@RequestParam(value = "code") String code, public ResponseModel<List<EquipmentCategory>> getChildren(@RequestParam(value = "code") String code,
@RequestParam(value = "type", required = false) String type) { @RequestParam(value = "type", required = false) String type) {
return ResponseHelper.buildResponse(commonService.getEquipmentCategoryList(code, type)); return ResponseHelper.buildResponse(commonService.getEquipmentCategoryList(code, type));
} }
@TycloudOperation(ApiLevel = UserType.AGENCY) @TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/getRegion") @GetMapping(value = "/getRegion")
@ApiOperation(httpMethod = "GET", value = "获取行政区划", notes = "获取行政区划") @ApiOperation(httpMethod = "GET", value = "获取行政区划", notes = "获取行政区划")
public ResponseModel<Object> getRegion(@RequestParam(value = "level", required = false) String level, public ResponseModel<Object> getRegion(@RequestParam(value = "level", required = false) String level,
@RequestParam(value = "parentId", required = false) String parentId) { @RequestParam(value = "parentId", required = false) String parentId) {
return ResponseHelper.buildResponse(commonService.getRegion(level, parentId)); return ResponseHelper.buildResponse(commonService.getRegion(level, parentId));
} }
/** /**
* 获取管辖分局树 * 获取管辖分局树
* *
* @return * @return
*/ */
@TycloudOperation(ApiLevel = UserType.AGENCY) @TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/creatTree") @GetMapping(value = "/creatTree")
@ApiOperation(httpMethod = "GET", value = "获取管辖分局树", notes = "获取管辖分局树") @ApiOperation(httpMethod = "GET", value = "获取管辖分局树", notes = "获取管辖分局树")
public ResponseModel<Object> creatTree() { public ResponseModel<Object> creatTree() {
return ResponseHelper.buildResponse(commonService.getTree(getSelectedOrgInfo())); return ResponseHelper.buildResponse(commonService.getTree(getSelectedOrgInfo()));
} }
/** /**
* 工作台接收机构树 * 工作台接收机构树
* @param bizType 业务类型:notice-告知类, register-登记类 *
* @return 树 * @param bizType 业务类型:notice-告知类, register-登记类
*/ * @return 树
@TycloudOperation(ApiLevel = UserType.AGENCY) */
@GetMapping(value = "/{bizType}/receive-unit/tree") @TycloudOperation(ApiLevel = UserType.AGENCY)
@ApiOperation(httpMethod = "GET", value = "接收机构树", notes = "接收机构树") @GetMapping(value = "/{bizType}/receive-unit/tree")
public ResponseModel<Object> getNoticeReceiveTree(@PathVariable String bizType) { @ApiOperation(httpMethod = "GET", value = "接收机构树", notes = "接收机构树")
return ResponseHelper.buildResponse(commonService.getReceiveUnitTree(bizType)); public ResponseModel<Object> getNoticeReceiveTree(@PathVariable String bizType) {
} return ResponseHelper.buildResponse(commonService.getReceiveUnitTree(bizType));
}
/**
/** * 获取行政审批局树
* 获取行政审批局树 *
* * @return
* @return */
*/ @TycloudOperation(ApiLevel = UserType.AGENCY)
@TycloudOperation(ApiLevel = UserType.AGENCY) @GetMapping(value = "/getApproveTree")
@GetMapping(value = "/getApproveTree") @ApiOperation(httpMethod = "GET", value = "获取行政审批局树", notes = "获取行政审批局树")
@ApiOperation(httpMethod = "GET", value = "获取行政审批局树", notes = "获取行政审批局树") public ResponseModel<Object> getApproveTree() {
public ResponseModel<Object> getApproveTree() { ReginParams reginParams = getSelectedOrgInfo();
ReginParams reginParams = getSelectedOrgInfo(); return ResponseHelper.buildResponse(commonService.getApproveTree(reginParams));
return ResponseHelper.buildResponse(commonService.getApproveTree(reginParams)); }
}
/**
/** * 通过单位类型获取单位列表
* 通过单位类型获取单位列表 *
* * @return
* @return */
*/ @TycloudOperation(ApiLevel = UserType.AGENCY)
@TycloudOperation(ApiLevel = UserType.AGENCY) @GetMapping(value = "/getUnitList")
@GetMapping(value = "/getUnitList") @ApiOperation(httpMethod = "GET", value = "通过单位类型获取单位列表", notes = "通过单位类型获取单位列表")
@ApiOperation(httpMethod = "GET", value = "通过单位类型获取单位列表", notes = "通过单位类型获取单位列表") public ResponseModel<List<Map<String, Object>>> getUnitList(@RequestParam(value = "type") String type) {
public ResponseModel<List<Map<String,Object>>> getUnitList(@RequestParam(value = "type") String type) { return ResponseHelper.buildResponse(commonService.getUnitListByType(type));
return ResponseHelper.buildResponse(commonService.getUnitListByType(type)); }
}
/**
/** * 查找当前公司下所属的安全管理员
* 查找当前公司下所属的安全管理员 *
* * @return
* @return */
*/ @TycloudOperation(ApiLevel = UserType.AGENCY)
@TycloudOperation(ApiLevel = UserType.AGENCY) @GetMapping(value = "/getSecurityAdmin")
@GetMapping(value = "/getSecurityAdmin") @ApiOperation(httpMethod = "GET", value = "查找当前公司下所属的安全管理员", notes = "查找当前公司下所属的安全管理员")
@ApiOperation(httpMethod = "GET", value = "查找当前公司下所属的安全管理员", notes = "查找当前公司下所属的安全管理员") public ResponseModel<List<Map<String, Object>>> getSecurityAdmin(@RequestParam(value = "type") String type,
public ResponseModel<List<Map<String, Object>>> getSecurityAdmin(@RequestParam(value = "type") String type, @RequestParam(value = "useUnitCode", required = false) String useUnitCode) {
@RequestParam(value = "useUnitCode",required = false)String useUnitCode) { return ResponseHelper.buildResponse(commonService.getSecurityAdmin(type, useUnitCode));
return ResponseHelper.buildResponse(commonService.getSecurityAdmin(type,useUnitCode)); }
}
/**
/** * 查询安全管理员的基本信息
* 查询安全管理员的基本信息 *
* * @return
* @return */
*/ @TycloudOperation(ApiLevel = UserType.AGENCY)
@TycloudOperation(ApiLevel = UserType.AGENCY) @GetMapping(value = "/getUserPhone")
@GetMapping(value = "/getUserPhone") @ApiOperation(httpMethod = "GET", value = "查询用户对应联系方式", notes = "查询用户对应联系方式")
@ApiOperation(httpMethod = "GET", value = "查询用户对应联系方式", notes = "查询用户对应联系方式") public ResponseModel<Map<String, Object>> getUserInfo(@RequestParam(value = "sequenceNbr") String sequenceNbr) {
public ResponseModel<Map<String,Object>> getUserInfo(@RequestParam(value = "sequenceNbr") String sequenceNbr) { return ResponseHelper.buildResponse(commonService.getUserInfo(sequenceNbr));
return ResponseHelper.buildResponse(commonService.getUserInfo(sequenceNbr)); }
}
@TycloudOperation(ApiLevel = UserType.AGENCY) @TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/getUserInfoSplit") @GetMapping(value = "/getUserInfoSplit")
@ApiOperation(httpMethod = "GET", value = "查询安全管理员的基本信息", notes = "查询安全管理员的基本信息") @ApiOperation(httpMethod = "GET", value = "查询安全管理员的基本信息", notes = "查询安全管理员的基本信息")
...@@ -140,188 +143,211 @@ public class CommonController extends BaseController { ...@@ -140,188 +143,211 @@ public class CommonController extends BaseController {
} }
return ResponseHelper.buildResponse(commonService.getUserInfo(sequenceNbr)); return ResponseHelper.buildResponse(commonService.getUserInfo(sequenceNbr));
} }
/**
* 查询企业的基本信息 /**
* * 查询企业的基本信息
* @return *
*/ * @return
@TycloudOperation(ApiLevel = UserType.AGENCY) */
@GetMapping(value = "/getEnterpriseInfo") @TycloudOperation(ApiLevel = UserType.AGENCY)
@ApiOperation(httpMethod = "GET", value = "查询企业的基本信息", notes = "查询企业的基本信息") @GetMapping(value = "/getEnterpriseInfo")
public ResponseModel<Map<String,Object>> getEnterpriseInfo(@RequestParam(value = "sequenceNbr") String sequenceNbr) { @ApiOperation(httpMethod = "GET", value = "查询企业的基本信息", notes = "查询企业的基本信息")
return ResponseHelper.buildResponse(commonService.getEnterpriseInfo(sequenceNbr)); public ResponseModel<Map<String, Object>> getEnterpriseInfo(@RequestParam(value = "sequenceNbr") String sequenceNbr) {
} return ResponseHelper.buildResponse(commonService.getEnterpriseInfo(sequenceNbr));
}
/**
* 查询企业的下面的人员 /**
* * 查询企业的下面的人员
* @return *
*/ * @return
@TycloudOperation(ApiLevel = UserType.AGENCY) */
@GetMapping(value = "/getEnterpriseEmployee") @TycloudOperation(ApiLevel = UserType.AGENCY)
@ApiOperation(httpMethod = "GET", value = "查询企业的下面的人员", notes = "查询企业的下面的人员") @GetMapping(value = "/getEnterpriseEmployee")
public ResponseModel<List<Map<String,Object>>> getEnterpriseEmployee(@RequestParam String unitCode) { @ApiOperation(httpMethod = "GET", value = "查询企业的下面的人员", notes = "查询企业的下面的人员")
String companyCode = unitCode.split("_")[0]; public ResponseModel<List<Map<String, Object>>> getEnterpriseEmployee(@RequestParam String unitCode) {
return ResponseHelper.buildResponse(commonService.getEnterpriseEmployee(companyCode)); String companyCode = unitCode.split("_")[0];
} return ResponseHelper.buildResponse(commonService.getEnterpriseEmployee(companyCode));
}
@TycloudOperation (ApiLevel = UserType.AGENCY)
@ApiOperation (httpMethod = "GET", value = "流程状态枚举列表", notes = "流程状态枚举列表") @TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping (value = "/flow-status/list") @ApiOperation(httpMethod = "GET", value = "流程状态枚举列表", notes = "流程状态枚举列表")
public ResponseModel<List<Map<String, Object>>> selectForFlowStatusList() { @GetMapping(value = "/flow-status/list")
return ResponseHelper.buildResponse(Arrays.stream(FlowStatusEnum.values()).map(this::mapPointTypeToMap).filter(Objects::nonNull).collect(Collectors.toList())); public ResponseModel<List<Map<String, Object>>> selectForFlowStatusList() {
} return ResponseHelper.buildResponse(Arrays.stream(FlowStatusEnum.values()).map(this::mapPointTypeToMap).filter(Objects::nonNull).collect(Collectors.toList()));
}
private Map<String, Object> mapPointTypeToMap(FlowStatusEnum e) {
if (FlowStatusEnum.TO_SUBMITTED.getCode() == e.getCode() || FlowStatusEnum.TO_BE_DISCARD.getCode() == e.getCode()) { private Map<String, Object> mapPointTypeToMap(FlowStatusEnum e) {
return null; if (FlowStatusEnum.TO_SUBMITTED.getCode() == e.getCode() || FlowStatusEnum.TO_BE_DISCARD.getCode() == e.getCode()) {
} return null;
Map<String, Object> record = new HashMap<>(); }
record.put("key", e.getCode()); Map<String, Object> record = new HashMap<>();
record.put("label", e.getName()); record.put("key", e.getCode());
return record; record.put("label", e.getName());
} return record;
}
/**
* 查询监管业务名称列表 /**
* * 查询监管业务名称列表
* @return *
*/ * @return
@TycloudOperation(ApiLevel = UserType.AGENCY) */
@ApiOperation(httpMethod = "GET", value = "查询监管业务名称列表", notes = "查询监管业务名称列表") @TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/superviseBusinessCategory") @ApiOperation(httpMethod = "GET", value = "查询监管业务名称列表", notes = "查询监管业务名称列表")
public ResponseModel<Object> equipTree(String type) { @GetMapping(value = "/superviseBusinessCategory")
return ResponseHelper.buildResponse(commonService.superviseBusinessCategory(type)); public ResponseModel<Object> equipTree(String type) {
} return ResponseHelper.buildResponse(commonService.superviseBusinessCategory(type));
}
@Autowired
private IJgInstallationNoticeService iJgInstallationNoticeService; @Autowired
private IJgInstallationNoticeService iJgInstallationNoticeService;
/**
* 业务发起公共接口 /**
* /jg/jg-installation-notice/save * 业务发起公共接口
*/ * /jg/jg-installation-notice/save
@TycloudOperation(ApiLevel = UserType.AGENCY) */
@PostMapping(value = "/saveOrSubmit") @TycloudOperation(ApiLevel = UserType.AGENCY)
@ApiOperation(httpMethod = "POST", value = "业务发起公共接口", notes = "业务发起公共接口") @PostMapping(value = "/saveOrSubmit")
public ResponseModel<Object> save(@RequestParam(value = "submitType", required = false) String submitType, @ApiOperation(httpMethod = "POST", value = "业务发起公共接口", notes = "业务发起公共接口")
@RequestBody Map<String, Object> map) { public ResponseModel<Object> save(@RequestParam(value = "submitType", required = false) String submitType,
ReginParams reginParams = getSelectedOrgInfo(); @RequestBody Map<String, Object> map) {
Object result = commonService.invokeBusinessProcess(submitType, map, reginParams); ReginParams reginParams = getSelectedOrgInfo();
return ResponseHelper.buildResponse(result); Object result = commonService.invokeBusinessProcess(submitType, map, reginParams);
} return ResponseHelper.buildResponse(result);
}
/**
* 根据公司id获取公司下人员 /**
* * 根据公司id获取公司下人员
*/ */
@TycloudOperation(ApiLevel = UserType.AGENCY) @TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/getCompanyUser") @GetMapping(value = "/getCompanyUser")
@ApiOperation(httpMethod = "get", value = "根据公司id获取公司下人员", notes = "根据公司id获取公司下人员") @ApiOperation(httpMethod = "get", value = "根据公司id获取公司下人员", notes = "根据公司id获取公司下人员")
public ResponseModel<Object> getCompanyUser(@RequestParam(value = "companyId",required = false) Long companyId) { public ResponseModel<Object> getCompanyUser(@RequestParam(value = "companyId", required = false) Long companyId) {
if(ObjectUtils.isEmpty(companyId)){ if (ObjectUtils.isEmpty(companyId)) {
return null; return null;
} }
Object result = commonService.getCompanyUser(companyId); Object result = commonService.getCompanyUser(companyId);
return ResponseHelper.buildResponse(result); return ResponseHelper.buildResponse(result);
} }
/** /**
* 获取当前登录人企业类型 * 获取当前登录人企业类型
*/ */
@TycloudOperation(ApiLevel = UserType.AGENCY) @TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/getCompanyType") @GetMapping(value = "/getCompanyType")
@ApiOperation(httpMethod = "GET", value = "获取当前登录人企业类型", notes = "获取当前登录人企业类型") @ApiOperation(httpMethod = "GET", value = "获取当前登录人企业类型", notes = "获取当前登录人企业类型")
public ResponseModel<Object> getCompanyType() { public ResponseModel<Object> getCompanyType() {
return ResponseHelper.buildResponse(iJgInstallationNoticeService.getCompanyType()); return ResponseHelper.buildResponse(iJgInstallationNoticeService.getCompanyType());
} }
/**
* 获取管辖分局树 /**
* * 获取管辖分局树
* @return *
*/ * @return
@TycloudOperation(ApiLevel = UserType.AGENCY) */
@GetMapping(value = "/getCreatTree") @TycloudOperation(ApiLevel = UserType.AGENCY)
@ApiOperation(httpMethod = "GET", value = "获取管辖分局树", notes = "获取管辖分局树") @GetMapping(value = "/getCreatTree")
public ResponseModel<Object> getCreatTree() { @ApiOperation(httpMethod = "GET", value = "获取管辖分局树", notes = "获取管辖分局树")
return ResponseHelper.buildResponse(commonService.getCreatTree()); public ResponseModel<Object> getCreatTree() {
} return ResponseHelper.buildResponse(commonService.getCreatTree());
}
/**
* 获取管辖分局树 /**
* * 获取管辖分局树
* @return *
*/ * @return
@TycloudOperation(ApiLevel = UserType.AGENCY) */
@GetMapping(value = "/getCreatTreeByInstallation") @TycloudOperation(ApiLevel = UserType.AGENCY)
@ApiOperation(httpMethod = "GET", value = "获取管辖分局树安装告知使用", notes = "获取管辖分局树安装告知使用") @GetMapping(value = "/getCreatTreeByInstallation")
public ResponseModel<Object> getCreatTreeByInstallation(String county) { @ApiOperation(httpMethod = "GET", value = "获取管辖分局树安装告知使用", notes = "获取管辖分局树安装告知使用")
List<LinkedHashMap> creatTree = commonService.getCreatTreeByInstallation(); public ResponseModel<Object> getCreatTreeByInstallation(String county) {
String code = county.split("_")[0]; List<LinkedHashMap> creatTree = commonService.getCreatTreeByInstallation();
List<LinkedHashMap> infoByCounty = getInfoByCounty(code, creatTree); String code = county.split("_")[0];
return ResponseHelper.buildResponse(infoByCounty); List<LinkedHashMap> infoByCounty = getInfoByCounty(code, creatTree);
} return ResponseHelper.buildResponse(infoByCounty);
}
private List<LinkedHashMap> getInfoByCounty(String county, List<LinkedHashMap> children) {
for (LinkedHashMap item : children) { private List<LinkedHashMap> getInfoByCounty(String county, List<LinkedHashMap> children) {
if (item.get("companyCode").toString().equals(county)) { for (LinkedHashMap item : children) {
return (List<LinkedHashMap>) item.get("children"); if (item.get("companyCode").toString().equals(county)) {
} else { return (List<LinkedHashMap>) item.get("children");
if (!ObjectUtils.isEmpty(item.get("children"))) { } else {
List<LinkedHashMap> children1 = getInfoByCounty(county, (List<LinkedHashMap>) item.get("children")); if (!ObjectUtils.isEmpty(item.get("children"))) {
if (!CollectionUtils.isEmpty(children1)) { List<LinkedHashMap> children1 = getInfoByCounty(county, (List<LinkedHashMap>) item.get("children"));
return children1; if (!CollectionUtils.isEmpty(children1)) {
} return children1;
} }
} }
} }
return new ArrayList<>(); }
} return new ArrayList<>();
}
/**
* 公共转办接口 /**
* /jg/common/transfer * 公共转办接口
*/ * /jg/common/transfer
@TycloudOperation(ApiLevel = UserType.AGENCY) */
@PostMapping(value = "/transfer") @TycloudOperation(ApiLevel = UserType.AGENCY)
@ApiOperation(httpMethod = "POST", value = "公共转办接口", notes = "公共转办接口") @PostMapping(value = "/transfer")
public ResponseModel<Object> transfer(@RequestBody Map<String, Object> map) { @ApiOperation(httpMethod = "POST", value = "公共转办接口", notes = "公共转办接口")
Object result = commonService.transfer(map); public ResponseModel<Object> transfer(@RequestBody Map<String, Object> map) {
return ResponseHelper.buildResponse(result); Object result = commonService.transfer(map);
} return ResponseHelper.buildResponse(result);
}
/**
* 校验EQUCODE的唯一性 /**
* @param equCode EQUCODE * 校验EQUCODE的唯一性
* @return *
*/ * @param equCode EQUCODE
@TycloudOperation(ApiLevel = UserType.AGENCY,needAuth = false) * @return
@GetMapping(value = "/checkUniquenessOfEQUCODE") */
@ApiOperation(httpMethod = "GET", value = "校验EQUCODE的唯一性", notes = "校验EQUCODE的唯一性") @TycloudOperation(ApiLevel = UserType.AGENCY, needAuth = false)
public ResponseModel<Object> checkUniquenessOfEQUCODE(String equCode) { @GetMapping(value = "/checkUniquenessOfEQUCODE")
Boolean bool = commonService.checkUniquenessOfEQUCODE(equCode); @ApiOperation(httpMethod = "GET", value = "校验EQUCODE的唯一性", notes = "校验EQUCODE的唯一性")
return ResponseHelper.buildResponse(bool); public ResponseModel<Object> checkUniquenessOfEQUCODE(String equCode) {
} Boolean bool = commonService.checkUniquenessOfEQUCODE(equCode);
return ResponseHelper.buildResponse(bool);
}
@TycloudOperation(ApiLevel = UserType.AGENCY,needAuth = false)
@GetMapping(value = "/test-file")
@ApiOperation(httpMethod = "GET", value = "文件测试", notes = "文件测试") @TycloudOperation(ApiLevel = UserType.AGENCY, needAuth = false)
public ResponseModel<String> testFile() { @GetMapping(value = "/test-file")
return ResponseHelper.buildResponse(pdfService.signToPdf("upload/tzs/pdf/1708911268708_temp.pdf", "已作废")); @ApiOperation(httpMethod = "GET", value = "文件测试", notes = "文件测试")
} public ResponseModel<String> testFile() {
return ResponseHelper.buildResponse(pdfService.signToPdf("upload/tzs/pdf/1708911268708_temp.pdf", "已作废"));
@TycloudOperation(ApiLevel = UserType.AGENCY,needAuth = false) }
@GetMapping(value = "/water-print")
@ApiOperation(httpMethod = "GET", value = "文件测试", notes = "文件测试") @TycloudOperation(ApiLevel = UserType.AGENCY, needAuth = false)
public ResponseModel<String> signToPdfWaterPrint() { @GetMapping(value = "/water-print")
return ResponseHelper.buildResponse(pdfService.signToPdfWaterPrint("upload/tzs/pdf/1708911268708_temp.pdf", "已作废")); @ApiOperation(httpMethod = "GET", value = "文件测试", notes = "文件测试")
} public ResponseModel<String> signToPdfWaterPrint() {
return ResponseHelper.buildResponse(pdfService.signToPdfWaterPrint("upload/tzs/pdf/1708911268708_temp.pdf", "已作废"));
}
@TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/equList")
@ApiOperation(httpMethod = "GET", value = "按照业务类型查询设备种类,工作台使用", notes = "按照业务类型查询设备种类,工作台使用")
public ResponseModel<List<DictionarieValueModel>> equList(@RequestParam(value = "type") String bizType) {
// 在平台字典配置的自定义业务的设备种类:格式{bizType}_SBZL,如BF_YZ_SBZL==》移装注销-设备种类
String suffix = "_SBZL";
String dictCode = bizType + suffix;
return ResponseHelper.buildResponse(Systemctl.dictionarieClient.dictValues(dictCode).getResult());
}
@TycloudOperation(ApiLevel = UserType.AGENCY)
@GetMapping(value = "/equ-category/{categoryCode}/list")
@ApiOperation(httpMethod = "GET", value = "按照业务类型、设备种类查询设备类别", notes = "按照业务类型、设备种类查询设备类别")
public ResponseModel<List<DictionarieValueModel>> equCategoryList(@RequestParam(value = "type") String bizType,
@PathVariable String categoryCode) {
// 在平台字典配置的自定义业务的设备种类:格式{bizType}_{categoryCode},如BF_YZ_1000==》移装注销-锅炉
String dictCode = String.format("%s_%s", bizType, categoryCode);
return ResponseHelper.buildResponse(Systemctl.dictionarieClient.dictValues(dictCode).getResult());
}
} }
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