Skip to content

Commit

Permalink
Merge pull request #6098 from deNBI/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
dweinholz authored Jun 17, 2024
2 parents 0ae1eb1 + f7271dd commit 425d09f
Show file tree
Hide file tree
Showing 58 changed files with 3,989 additions and 3,894 deletions.
Binary file added .nx/cache/18.3.4-nx.linux-x64-gnu.node
Binary file not shown.
Binary file added .nx/cache/nx_files.nxt
Binary file not shown.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ COPY . .
RUN $(npm bin)/ng build --configuration=custom --build-optimizer

### STAGE 2: Setup ###
FROM nginx:1.26.0-alpine
FROM nginx:1.26.1-alpine

## Copy our default nginx config
COPY nginx/default.conf /etc/nginx/conf.d/
Expand Down
112 changes: 36 additions & 76 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@denbi/cloud-portal-webapp",
"version": "4.846.0",
"version": "4.847.0",
"description": "de.NBI Cloud Portal",
"scripts": {
"ng": "ng serve",
Expand Down Expand Up @@ -87,7 +87,7 @@
"@angular/compiler-cli": "17.3.10",
"@playwright/test": "1.43.1",
"@types/jasmine": "5.1.4",
"@types/node": "20.12.12",
"@types/node": "20.12.14",
"@typescript-eslint/eslint-plugin": "^7.2.0",
"@typescript-eslint/parser": "^7.2.0",
"async": "3.2.5",
Expand All @@ -96,7 +96,7 @@
"eslint": "^8.57.0",
"eslint-config-airbnb-base": "15.0.0",
"eslint-plugin-import": "^2.29.0",
"eslint-plugin-jsdoc": "48.2.5",
"eslint-plugin-jsdoc": "48.2.7",
"eslint-plugin-no-null": "latest",
"eslint-plugin-prefer-arrow": "1.2.3",
"exports-loader": "5.0.0",
Expand All @@ -107,7 +107,7 @@
"karma": "6.4.3",
"karma-chrome-launcher": "3.2.0",
"less-loader": "12.2.0",
"lint-staged": "15.2.4",
"lint-staged": "15.2.5",
"ngx-spec": "2.1.6",
"npm-run-all2": "6.1.2",
"prettier": "3.2.5",
Expand All @@ -124,7 +124,7 @@
},
"overrides": {
"undici": "6.15.0",
"vite": "5.2.11"
"vite": "5.2.12"
},
"lint-staged": {
"*.{js,jsx,ts}": [
Expand Down
34 changes: 29 additions & 5 deletions src/app/api-connector/applications.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import { Application } from '../applications/application.model/application.model
import { ApplicationLifetimeExtension } from '../applications/application_extension.model';
import { ApplicationModification } from '../applications/application_modification.model';
import { ApplicationCreditRequest } from '../applications/application_credit_request';
import { User } from '../applications/application.model/user.model';

/**
* Service which provides methods for creating application.
Expand Down Expand Up @@ -44,6 +45,29 @@ export class ApplicationsService {
);
}

getApplicationPI(application_id: string | number): Observable<User> {
return this.http.get<User>(`${ApiSettings.getApiBaseURL()}project_applications/${application_id}/pi/`, {
withCredentials: true,
});
}

getApplicationUser(application_id: string | number): Observable<User> {
return this.http.get<User>(`${ApiSettings.getApiBaseURL()}project_applications/${application_id}/user/`, {
withCredentials: true,
});
}

getLifetimeExtensionUser(lifetimeextension_id: string | number): Observable<User> {
return this.http.get<User>(`${ApiSettings.getApiBaseURL()}project_applications/lifetime/extensions/${lifetimeextension_id}/user/`, {
withCredentials: true,
});
}

getModificationUser(project_id: string | number): Observable<User> {
return this.http.get<User>(`${ApiSettings.getApiBaseURL()}project_applications/modifications/${project_id}/user/`, {
withCredentials: true,
});
}
getApplicationValidationByHash(hash: string): Observable<Application> {
return this.http.get<Application>(`${ApiSettings.getApiBaseURL()}project_applications/validation/${hash}/`, {
withCredentials: true,
Expand Down Expand Up @@ -124,11 +148,11 @@ export class ApplicationsService {
}

/**
* Checks if some client has the resource available for an application.
*
* @param app_id
* @returns
*/
* Checks if some client has the resource available for an application.
*
* @param app_id
* @returns
*/
getApplicationClientAvaiable(app_id: string): Observable<any> {
return this.http.get(`${ApiSettings.getApiBaseURL()}project_applications/${app_id}/clients/resource/`, {
withCredentials: true,
Expand Down
2 changes: 1 addition & 1 deletion src/app/api-connector/credits.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { ResourceWeight, IResourceWeight } from '../credits-calculator/resource-
/**
* Service which delivers functions for services related to the credit service.
*/
@Injectable()
@Injectable({ providedIn: 'root' })
export class CreditsService {
constructor(private http: HttpClient) {
this.http = http;
Expand Down
6 changes: 3 additions & 3 deletions src/app/api-connector/facility.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -683,7 +683,7 @@ export class FacilityService {
* @param application_id
* @returns
*/
declineFacilityApplication(facility: number, application_id: number): Observable<any> {
declineFacilityApplication(facility: string|number, application_id: number|string): Observable<any> {
const params: HttpParams = new HttpParams().set('action', 'decline');

return this.http.post(
Expand Down Expand Up @@ -760,13 +760,13 @@ export class FacilityService {
});
}

approveTerminationByFM(groupId: number | string, facility: number): Observable<object> {
approveTerminationByFM(groupId: number | string, facility: number|string): Observable<object> {
return this.http.delete(`${ApiSettings.getApiBaseURL()}computecenters/${facility}/projects/${groupId}/`, {
withCredentials: true,
});
}

declineTerminationByFM(groupId: number | string, facility: number): Observable<object> {
declineTerminationByFM(groupId: number | string, facility: number|string): Observable<object> {
return this.http.get(`${ApiSettings.getApiBaseURL()}computecenters/${facility}/projects/${groupId}/`, {
withCredentials: true,
});
Expand Down
2 changes: 1 addition & 1 deletion src/app/api-connector/flavor.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { FlavorType } from '../virtualmachines/virtualmachinemodels/flavorType';
/**
* Service which provides methods for Flavors.
*/
@Injectable()
@Injectable({ providedIn: 'root' })
export class FlavorService {
constructor(private http: HttpClient) {
this.http = http;
Expand Down
2 changes: 1 addition & 1 deletion src/app/api-connector/group.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ export class GroupService {
}
}

assignGroupToResource(groupid: string, computecenter: string): Observable<any> {
assignGroupToResource(groupid: number, computecenter: string): Observable<any> {
const params: HttpParams = new HttpParams().set('compute_center', computecenter);

return this.http.post(`${ApiSettings.getApiBaseURL()}projects/${groupid}/resource/`, params, {
Expand Down
Loading

0 comments on commit 425d09f

Please sign in to comment.