|
@@ -1,12 +1,14 @@
|
|
package com.persagy.proxy.adm.controller;
|
|
package com.persagy.proxy.adm.controller;
|
|
|
|
|
|
import com.persagy.proxy.adm.constant.AdmCommonConstant;
|
|
import com.persagy.proxy.adm.constant.AdmCommonConstant;
|
|
|
|
+import com.persagy.proxy.adm.model.AdmManualRelationCalcDel;
|
|
import com.persagy.proxy.adm.model.AdmRelationAddRequest;
|
|
import com.persagy.proxy.adm.model.AdmRelationAddRequest;
|
|
import com.persagy.proxy.adm.request.AdmCreateResponse;
|
|
import com.persagy.proxy.adm.request.AdmCreateResponse;
|
|
import com.persagy.proxy.adm.service.AdmManualRelCalService;
|
|
import com.persagy.proxy.adm.service.AdmManualRelCalService;
|
|
import com.persagy.proxy.common.entity.InstanceUrlParam;
|
|
import com.persagy.proxy.common.entity.InstanceUrlParam;
|
|
import lombok.RequiredArgsConstructor;
|
|
import lombok.RequiredArgsConstructor;
|
|
import org.springframework.beans.factory.annotation.Value;
|
|
import org.springframework.beans.factory.annotation.Value;
|
|
|
|
+import org.springframework.validation.annotation.Validated;
|
|
import org.springframework.web.bind.annotation.PostMapping;
|
|
import org.springframework.web.bind.annotation.PostMapping;
|
|
import org.springframework.web.bind.annotation.RequestBody;
|
|
import org.springframework.web.bind.annotation.RequestBody;
|
|
import org.springframework.web.bind.annotation.RequestMapping;
|
|
import org.springframework.web.bind.annotation.RequestMapping;
|
|
@@ -44,6 +46,21 @@ public class AdmManualRelCalController {
|
|
InstanceUrlParam context = new InstanceUrlParam(groupCode, null, projectId, AdmCommonConstant.APP_ID);
|
|
InstanceUrlParam context = new InstanceUrlParam(groupCode, null, projectId, AdmCommonConstant.APP_ID);
|
|
return admManualRelationCalcService.addRels(context,request);
|
|
return admManualRelationCalcService.addRels(context,request);
|
|
}
|
|
}
|
|
|
|
+ /***
|
|
|
|
+ * Description: 删除关系
|
|
|
|
+ * @param admManualRelationCalcDel : 请求参数
|
|
|
|
+ * @return : com.persagy.proxy.adm.request.AdmCreateResponse
|
|
|
|
+ * @author : lijie
|
|
|
|
+ * @date :2021/8/31 12:10
|
|
|
|
+ * Update By lijie 2021/8/31 12:10
|
|
|
|
+ */
|
|
|
|
+ @PostMapping(value = "del")
|
|
|
|
+ public AdmCreateResponse delRels(@QueryParam("projectId") String projectId,
|
|
|
|
+ @Validated @RequestBody AdmManualRelationCalcDel admManualRelationCalcDel) throws Exception {
|
|
|
|
+ // 组装上下文条件
|
|
|
|
+ InstanceUrlParam context = new InstanceUrlParam(groupCode, null, projectId, AdmCommonConstant.APP_ID);
|
|
|
|
+ return admManualRelationCalcService.delRels(context,admManualRelationCalcDel);
|
|
|
|
+ }
|
|
|
|
|
|
|
|
|
|
|
|
|