diff options
author | devega <ma.devega@globunet.com> | 2019-05-17 13:21:04 +0200 |
---|---|---|
committer | devega <ma.devega@globunet.com> | 2019-05-17 13:21:04 +0200 |
commit | 4a04b450f918e47fb0758cac47b3f0581d8db859 (patch) | |
tree | fb0b5aa897eb8e4f375fa7c10adf48229900ee2c /admin/WebConsole3/frontend/src/app/api/repository.service.ts | |
parent | 1dde16d74e66dd6699108bc17c03021e3ec96214 (diff) | |
parent | d34b00c51df4dcc5aa88e76361b22ef7c1ff72a8 (diff) |
Merge remote-tracking branch 'origin/webconsole3' into webconsole3
Diffstat (limited to 'admin/WebConsole3/frontend/src/app/api/repository.service.ts')
-rw-r--r-- | admin/WebConsole3/frontend/src/app/api/repository.service.ts | 54 |
1 files changed, 27 insertions, 27 deletions
diff --git a/admin/WebConsole3/frontend/src/app/api/repository.service.ts b/admin/WebConsole3/frontend/src/app/api/repository.service.ts index 1561f41a..55fd88a0 100644 --- a/admin/WebConsole3/frontend/src/app/api/repository.service.ts +++ b/admin/WebConsole3/frontend/src/app/api/repository.service.ts @@ -1,27 +1,27 @@ -import { Injectable } from '@angular/core';
-import { HttpClient} from '@angular/common/http';
-
-import { environment } from '../../environments/environment';
-import { Repository } from '../model/repository';
-import { RepositorySerializer } from '../serializer/repository.serializer';
-
-import {ResourceService} from 'globunet-angular/core/providers/api/resource.service';
-import {Observable} from 'rxjs';
-
-
-@Injectable({
- providedIn: 'root'
-})
-export class RepositoryService extends ResourceService<Repository> {
-
- constructor(http: HttpClient) {
- super(http, environment.API_URL, 'repositories', new RepositorySerializer());
- }
-
- getInfo(repository: Repository) {
- const url = 'https://' + repository.ip + '/' + environment.BASE_DIR + environment.API_BASE_URL;
- return this.httpClient.get(url, {headers: {
- Authorization: repository.password
- }});
- }
-}
+import { Injectable } from '@angular/core'; +import { HttpClient} from '@angular/common/http'; + +import { environment } from '../../environments/environment'; +import { Repository } from '../model/repository'; +import { RepositorySerializer } from '../serializer/repository.serializer'; + +import {ResourceService} from 'globunet-angular/core/providers/api/resource.service'; +import {Observable} from 'rxjs'; + + +@Injectable({ + providedIn: 'root' +}) +export class RepositoryService extends ResourceService<Repository> { + + constructor(http: HttpClient) { + super(http, environment.API_URL, 'repositories', new RepositorySerializer()); + } + + getInfo(repository: Repository) { + const url = 'https://' + repository.ip + '/' + environment.BASE_DIR + environment.API_BASE_URL; + return this.httpClient.get(url, {headers: { + Authorization: repository.randomId + }}); + } +} |