Revision 50977
Added by Myrto Koukouli about 6 years ago
sr-literature.component.ts | ||
---|---|---|
3 | 3 |
*/ |
4 | 4 |
|
5 | 5 |
import { Component, OnInit, Type, ViewChild } from '@angular/core'; |
6 |
import { RepositoryInterface } from '../../../domain/typeScriptClasses'; |
|
6 |
import { Repository, RepositoryInterface } from '../../../domain/typeScriptClasses';
|
|
7 | 7 |
import { DatasourceInfoFormComponent } from '../sources-forms/datasource-info-form.component'; |
8 | 8 |
import { RegisterDatasourceShareableComponent } from './register-datasource-shareable.component'; |
9 | 9 |
import { DatasourceInterfaceFormComponent } from '../sources-forms/datasource-interface-form.component'; |
... | ... | |
26 | 26 |
step4: string = ''; |
27 | 27 |
|
28 | 28 |
datasourceId: string; |
29 |
repo: Repository; |
|
29 | 30 |
|
30 | 31 |
@ViewChild('datasourcesByCountry') |
31 | 32 |
public datasourcesByCountry: RegisterDatasourceShareableComponent; |
... | ... | |
37 | 38 |
interfaceFormDesc: Description = interfaceFormDesc; |
38 | 39 |
updateDatasourceInterfaces: Type<any> = DatasourceInterfaceFormComponent; |
39 | 40 |
repoInterfaces: RepositoryInterface[] = []; |
40 |
exportedData: string[] = []; |
|
41 | 41 |
|
42 | 42 |
|
43 | 43 |
constructor( |
... | ... | |
60 | 60 |
} else if(this.showForm) { |
61 | 61 |
if (this.updateDatasource.updateRepo()){ |
62 | 62 |
setTimeout( () => { |
63 |
this.exportedData.push(this.datasourceId); |
|
64 |
this.exportedData.push('opendoar'); |
|
65 | 63 |
this.getRepoInterfaces(); |
66 | 64 |
this.group = this.fb.group({}); |
67 | 65 |
}, 500 ); |
... | ... | |
93 | 91 |
this.datasourceId = emitedId; |
94 | 92 |
} |
95 | 93 |
|
94 |
getCurrentRepo(repo: Repository) { |
|
95 |
this.repo = repo; |
|
96 |
} |
|
97 |
|
|
96 | 98 |
getRepoInterfaces() { |
97 | 99 |
this.repoService.getRepositoryInterface(this.datasourceId).subscribe( |
98 | 100 |
interfaces => { |
Also available in: Unified diff
finalized sources register and update