|
@@ -148,7 +148,11 @@ public class MaintenanceCompanyServiceImpl extends ServiceImpl<MaintenanceCompan
|
|
|
@Transactional
|
|
|
public RestResponse updateMaintenanceCompany(MaintenanceCompanyRequest maintenanceCompanyRequest) {
|
|
|
//获取公司id,前端传的字段是id
|
|
|
- Long companyId = maintenanceCompanyRequest.getCompanyId();
|
|
|
+ MtCompanyAttestation mtCompanyAttestation = mtCompanyAttestationService.getById(maintenanceCompanyRequest.getId());
|
|
|
+ if(mtCompanyAttestation == null){
|
|
|
+ return RestResponse.fail(ApiConstants.RESULT_ERROR, "用户申请信息不存在");
|
|
|
+ }
|
|
|
+ Long companyId = mtCompanyAttestation.getMtCompanyId();
|
|
|
MaintenanceCompany maintenanceCompany = this.getById(companyId);
|
|
|
//更新vip标识
|
|
|
maintenanceCompany.setVipFlag(maintenanceCompanyRequest.getVipFlag());
|