Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DSP-700 Fix broken link to project #306

Merged
merged 1 commit into from Sep 25, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/app/workspace/resource/resource.component.html
Expand Up @@ -3,5 +3,5 @@
Back
</button>
<div class="content large middle">
<dsp-resource-view [iri]="resourceIri"></dsp-resource-view>
<dsp-resource-view [iri]="resourceIri" (openProject)="openProject($event)"></dsp-resource-view>
</div>
6 changes: 6 additions & 0 deletions src/app/workspace/resource/resource.component.ts
Expand Up @@ -8,6 +8,7 @@ import {
Params,
Router
} from '@angular/router';
import { ReadProject } from '@dasch-swiss/dsp-js';
import { Subscription } from 'rxjs';

@Component({
Expand Down Expand Up @@ -75,4 +76,9 @@ export class ResourceComponent implements OnInit, OnDestroy {
goBack() {
this._location.back();
}

// open project in new tab
openProject(project: ReadProject){
window.open('/project/' + project.shortcode, "_blank");
}
}