Fix the URL for the DELETE operation 11/14211/1
authorGuangrong Fu <fu.guangrong@zte.com.cn>
Thu, 21 Sep 2017 11:04:23 +0000 (19:04 +0800)
committerGuangrong Fu <fu.guangrong@zte.com.cn>
Thu, 21 Sep 2017 11:04:23 +0000 (19:04 +0800)
Change-Id: I0010f65aa41469913f1f3f551f6d71ebb0869eaf
Issue-ID: HOLMES-64
Signed-off-by: Guangrong Fu <fu.guangrong@zte.com.cn>
usecaseui-holmes/src/main/webapp/alarm/app/correlation-ruleList/alarmRule.service.ts

index 076c951..c0ca2ad 100644 (file)
@@ -112,9 +112,8 @@ export class AlarmRuleService {
     }
 
     public delete(ruleid: string): Promise<void> {
-        let ru = { 'ruleid': ruleid };
-        const url = `${this.ruleUrl}`;
-        return this.http.delete(url, { body: JSON.stringify(ru), headers: this.headers })
+        const url = `${this.ruleUrl}` + '/' + ruleid;
+        return this.http.delete(url, { headers: this.headers })
             .toPromise()
             .then(res => {