[webapp] 批量处理eslint格式告警
This commit is contained in:
@@ -1,8 +1,9 @@
|
||||
import { HttpClient } from '@angular/common/http';
|
||||
import { Injectable } from '@angular/core';
|
||||
import {HttpClient} from "@angular/common/http";
|
||||
import {Observable} from "rxjs";
|
||||
import {Message} from "../pojo/Message";
|
||||
import {NoticeReceiver} from "../pojo/NoticeReceiver";
|
||||
import { Observable } from 'rxjs';
|
||||
|
||||
import { Message } from '../pojo/Message';
|
||||
import { NoticeReceiver } from '../pojo/NoticeReceiver';
|
||||
|
||||
const notice_receiver_uri = '/notice/receiver';
|
||||
const notice_receivers_uri = '/notice/receivers';
|
||||
@@ -11,22 +12,20 @@ const notice_receivers_uri = '/notice/receivers';
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class NoticeReceiverService {
|
||||
constructor(private http: HttpClient) {}
|
||||
|
||||
constructor(private http : HttpClient) { }
|
||||
|
||||
public newReceiver(body: NoticeReceiver) : Observable<Message<any>> {
|
||||
public newReceiver(body: NoticeReceiver): Observable<Message<any>> {
|
||||
return this.http.post<Message<any>>(notice_receiver_uri, body);
|
||||
}
|
||||
|
||||
public editReceiver(body: NoticeReceiver) : Observable<Message<any>> {
|
||||
public editReceiver(body: NoticeReceiver): Observable<Message<any>> {
|
||||
return this.http.put<Message<any>>(notice_receiver_uri, body);
|
||||
}
|
||||
public deleteReceiver(receiverId: number) : Observable<Message<any>> {
|
||||
public deleteReceiver(receiverId: number): Observable<Message<any>> {
|
||||
return this.http.delete<Message<any>>(`${notice_receiver_uri}/${receiverId}`);
|
||||
}
|
||||
|
||||
public getReceivers() : Observable<Message<NoticeReceiver[]>> {
|
||||
public getReceivers(): Observable<Message<NoticeReceiver[]>> {
|
||||
return this.http.get<Message<NoticeReceiver[]>>(notice_receivers_uri);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user