[frontend] Update openapi
This commit is contained in:
parent
55826cdef8
commit
52b6aa8a00
kibicara-frontend/src/app
|
@ -254,6 +254,55 @@ export class AdminService {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Admin Read
|
||||||
|
* Get a list of all hoods of a given admin.
|
||||||
|
* @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
|
||||||
|
* @param reportProgress flag to report request and response progress.
|
||||||
|
*/
|
||||||
|
public getAdmin(observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<any>;
|
||||||
|
public getAdmin(observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<any>>;
|
||||||
|
public getAdmin(observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<any>>;
|
||||||
|
public getAdmin(observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> {
|
||||||
|
|
||||||
|
let headers = this.defaultHeaders;
|
||||||
|
|
||||||
|
let credential: string | undefined;
|
||||||
|
// authentication (OAuth2PasswordBearer) required
|
||||||
|
credential = this.configuration.lookupCredential('OAuth2PasswordBearer');
|
||||||
|
if (credential) {
|
||||||
|
headers = headers.set('Authorization', 'Bearer ' + credential);
|
||||||
|
}
|
||||||
|
|
||||||
|
let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept;
|
||||||
|
if (httpHeaderAcceptSelected === undefined) {
|
||||||
|
// to determine the Accept header
|
||||||
|
const httpHeaderAccepts: string[] = [
|
||||||
|
'application/json'
|
||||||
|
];
|
||||||
|
httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts);
|
||||||
|
}
|
||||||
|
if (httpHeaderAcceptSelected !== undefined) {
|
||||||
|
headers = headers.set('Accept', httpHeaderAcceptSelected);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
let responseType: 'text' | 'json' = 'json';
|
||||||
|
if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) {
|
||||||
|
responseType = 'text';
|
||||||
|
}
|
||||||
|
|
||||||
|
return this.httpClient.get<any>(`${this.configuration.basePath}/api/admin/`,
|
||||||
|
{
|
||||||
|
responseType: <any>responseType,
|
||||||
|
withCredentials: this.configuration.withCredentials,
|
||||||
|
headers: headers,
|
||||||
|
observe: observe,
|
||||||
|
reportProgress: reportProgress
|
||||||
|
}
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Admin Hood Read All
|
* Admin Hood Read All
|
||||||
* Get a list of all hoods of a given admin.
|
* Get a list of all hoods of a given admin.
|
||||||
|
@ -504,66 +553,4 @@ export class AdminService {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Admin Update
|
|
||||||
* @param bodyAdmin
|
|
||||||
* @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
|
|
||||||
* @param reportProgress flag to report request and response progress.
|
|
||||||
*/
|
|
||||||
public updateAdmin(bodyAdmin: BodyAdmin, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<any>;
|
|
||||||
public updateAdmin(bodyAdmin: BodyAdmin, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<any>>;
|
|
||||||
public updateAdmin(bodyAdmin: BodyAdmin, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<any>>;
|
|
||||||
public updateAdmin(bodyAdmin: BodyAdmin, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> {
|
|
||||||
if (bodyAdmin === null || bodyAdmin === undefined) {
|
|
||||||
throw new Error('Required parameter bodyAdmin was null or undefined when calling updateAdmin.');
|
|
||||||
}
|
|
||||||
|
|
||||||
let headers = this.defaultHeaders;
|
|
||||||
|
|
||||||
let credential: string | undefined;
|
|
||||||
// authentication (OAuth2PasswordBearer) required
|
|
||||||
credential = this.configuration.lookupCredential('OAuth2PasswordBearer');
|
|
||||||
if (credential) {
|
|
||||||
headers = headers.set('Authorization', 'Bearer ' + credential);
|
|
||||||
}
|
|
||||||
|
|
||||||
let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept;
|
|
||||||
if (httpHeaderAcceptSelected === undefined) {
|
|
||||||
// to determine the Accept header
|
|
||||||
const httpHeaderAccepts: string[] = [
|
|
||||||
'application/json'
|
|
||||||
];
|
|
||||||
httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts);
|
|
||||||
}
|
|
||||||
if (httpHeaderAcceptSelected !== undefined) {
|
|
||||||
headers = headers.set('Accept', httpHeaderAcceptSelected);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// to determine the Content-Type header
|
|
||||||
const consumes: string[] = [
|
|
||||||
'application/json'
|
|
||||||
];
|
|
||||||
const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes);
|
|
||||||
if (httpContentTypeSelected !== undefined) {
|
|
||||||
headers = headers.set('Content-Type', httpContentTypeSelected);
|
|
||||||
}
|
|
||||||
|
|
||||||
let responseType: 'text' | 'json' = 'json';
|
|
||||||
if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) {
|
|
||||||
responseType = 'text';
|
|
||||||
}
|
|
||||||
|
|
||||||
return this.httpClient.put<any>(`${this.configuration.basePath}/api/admin/`,
|
|
||||||
bodyAdmin,
|
|
||||||
{
|
|
||||||
responseType: <any>responseType,
|
|
||||||
withCredentials: this.configuration.withCredentials,
|
|
||||||
headers: headers,
|
|
||||||
observe: observe,
|
|
||||||
reportProgress: reportProgress
|
|
||||||
}
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -59,7 +59,7 @@
|
||||||
New hood
|
New hood
|
||||||
</button>
|
</button>
|
||||||
<a mat-button color="primary" routerLink="/dashboard/settings">
|
<a mat-button color="primary" routerLink="/dashboard/settings">
|
||||||
User settings
|
Account settings
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
<div class="banner"></div>
|
<div class="banner"></div>
|
||||||
|
|
Loading…
Reference in a new issue