mirror of
https://github.com/Tzahi12345/YoutubeDL-Material.git
synced 2026-03-16 09:40:56 +03:00
Added two new API calls, to update the server to a particular version and to get the updater status You can now update through the UI, and a status dialog displays after
34 lines
985 B
TypeScript
34 lines
985 B
TypeScript
import { Component, OnInit } from '@angular/core';
|
|
import { PostsService } from 'app/posts.services';
|
|
import { CURRENT_VERSION } from 'app/consts';
|
|
|
|
@Component({
|
|
selector: 'app-about-dialog',
|
|
templateUrl: './about-dialog.component.html',
|
|
styleUrls: ['./about-dialog.component.scss']
|
|
})
|
|
export class AboutDialogComponent implements OnInit {
|
|
|
|
projectLink = 'https://github.com/Tzahi12345/YoutubeDL-Material';
|
|
issuesLink = 'https://github.com/Tzahi12345/YoutubeDL-Material/issues';
|
|
latestUpdateLink = 'https://github.com/Tzahi12345/YoutubeDL-Material/releases/latest'
|
|
latestGithubRelease = null;
|
|
checking_for_updates = true;
|
|
|
|
current_version_tag = CURRENT_VERSION;
|
|
|
|
constructor(private postsService: PostsService) { }
|
|
|
|
ngOnInit(): void {
|
|
this.getLatestGithubRelease()
|
|
}
|
|
|
|
getLatestGithubRelease() {
|
|
this.postsService.getLatestGithubRelease().subscribe(res => {
|
|
this.checking_for_updates = false;
|
|
this.latestGithubRelease = res;
|
|
});
|
|
}
|
|
|
|
}
|