mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-20 05:16:07 +00:00
Add integration of publication
This commit is contained in:
@@ -104,6 +104,31 @@ export class PublicationsService {
|
||||
};
|
||||
return this.http.get<any>(`${geturl}`, options);
|
||||
}
|
||||
CreatePublication(folderId:any,body:any){
|
||||
const geturl = environment.apiURL + 'presidentialActions/'+folderId+'/posts';
|
||||
let params = new HttpParams();
|
||||
params = params.set("folderId", folderId);
|
||||
let options = {
|
||||
headers: this.headers,
|
||||
params: params
|
||||
};
|
||||
return this.http.post<any>(`${geturl}`, body, options).toPromise().then(res =>{
|
||||
console.log(res);
|
||||
});
|
||||
}
|
||||
|
||||
UpdatePublication(folderId:any,body:any){
|
||||
const geturl = environment.apiURL + 'presidentialActions/'+folderId+'/posts';
|
||||
let params = new HttpParams();
|
||||
params = params.set("folderId", folderId);
|
||||
let options = {
|
||||
headers: this.headers,
|
||||
params: params
|
||||
};
|
||||
return this.http.put<any>(`${geturl}`, body, options).toPromise().then(res =>{
|
||||
console.log(res);
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user