Commit 458a69f7 authored by suhuiguang's avatar suhuiguang

Merge branch 'develop_tzs_register' of…

Merge branch 'develop_tzs_register' of http://36.40.66.175:5000/moa/amos-boot-biz into develop_tzs_register
parents fd3910a8 23c0761d
......@@ -539,5 +539,11 @@ public class CommonController extends BaseController {
return ResponseHelper.buildResponse("succese");
}
@TycloudOperation(ApiLevel = UserType.AGENCY)
@PutMapping(value = "/unitType/selected")
@ApiOperation(httpMethod = "PUT", value = "更新缓存中单位类型", notes = "更新缓存中单位类型")
public ResponseModel<String> updateUnitTypeCache(@ApiParam("单位类型") @RequestParam String unitType){
commonService.updateUnitTypeCache(getSelectedOrgInfo(), unitType);
return ResponseHelper.buildResponse("success");
}
}
......@@ -187,4 +187,11 @@ public interface ICommonService {
CompanyBo getOneCompany(String companyCode);
Integer checkFactoryNumUniquenessForVehicleCylinder(String factoryNum,String sequenceNbr);
/**
* 更新单位类型缓存
*
* @param unitType 单位类型
*/
void updateUnitTypeCache(ReginParams reginParams, String unitType);
}
......@@ -159,6 +159,10 @@ public class CommonServiceImpl implements ICommonService {
private static final String SBZX_PAGE_ID = "jgScrapCancelAdd";
// 业务通用发起——更名变更表单key
private static final String GMBG_PAGE_ID = "jgRegistrationInfo";
@Value("${redis.cache.failure.time}")
private Long redisRegionTimeSecond;
@Autowired
EquipmentCategoryMapper equipmentCategoryMapper;
@Autowired
......@@ -1800,4 +1804,10 @@ public class CommonServiceImpl implements ICommonService {
return "templates/use-flag-model-other.pdf";
}
}
@Override
public void updateUnitTypeCache(ReginParams reginParams, String unitType) {
reginParams.getCompany().setCompanyType(unitType);
redisUtils.set(RedisKey.buildReginKey(RequestContext.getExeUserId(), RequestContext.getToken()), JSONObject.toJSONString(reginParams), redisRegionTimeSecond);
}
}
\ No newline at end of file
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