mirror of
https://github.com/gotson/komga.git
synced 2026-05-09 05:10:19 +02:00
parent
7a176f2307
commit
acdea3daf1
4 changed files with 26 additions and 2 deletions
|
|
@ -52,6 +52,10 @@ export function readListThumbnailUrl (readListId: string): string {
|
||||||
return `${urls.originNoSlash}/api/v1/readlists/${readListId}/thumbnail`
|
return `${urls.originNoSlash}/api/v1/readlists/${readListId}/thumbnail`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export function readListFileUrl (readListId: string): string {
|
||||||
|
return `${urls.originNoSlash}/api/v1/readlists/${readListId}/file`
|
||||||
|
}
|
||||||
|
|
||||||
export function transientBookPageUrl (transientBookId: string, page: number): string {
|
export function transientBookPageUrl (transientBookId: string, page: number): string {
|
||||||
return `${urls.originNoSlash}/api/v1/transient-books/${transientBookId}/pages/${page}`
|
return `${urls.originNoSlash}/api/v1/transient-books/${transientBookId}/pages/${page}`
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -596,6 +596,7 @@
|
||||||
"bulk_edit_metadata": "Bulk edit metadata",
|
"bulk_edit_metadata": "Bulk edit metadata",
|
||||||
"delete": "Delete",
|
"delete": "Delete",
|
||||||
"deselect_all": "Deselect all",
|
"deselect_all": "Deselect all",
|
||||||
|
"download_readlist": "Download read list",
|
||||||
"download_series": "Download series",
|
"download_series": "Download series",
|
||||||
"edit": "Edit",
|
"edit": "Edit",
|
||||||
"edit_metadata": "Edit metadata",
|
"edit_metadata": "Edit metadata",
|
||||||
|
|
|
||||||
|
|
@ -94,7 +94,19 @@
|
||||||
</v-col>
|
</v-col>
|
||||||
</v-row>
|
</v-row>
|
||||||
|
|
||||||
<v-divider v-if="readList.summary" class="my-3"/>
|
<v-row class="px-2">
|
||||||
|
<v-col>
|
||||||
|
<v-btn :title="$t('menu.download_readlist')"
|
||||||
|
small
|
||||||
|
:disabled="!canDownload"
|
||||||
|
:href="fileUrl">
|
||||||
|
<v-icon left small>mdi-file-download</v-icon>
|
||||||
|
{{ $t('common.download') }}
|
||||||
|
</v-btn>
|
||||||
|
</v-col>
|
||||||
|
</v-row>
|
||||||
|
|
||||||
|
<v-divider class="my-3"/>
|
||||||
|
|
||||||
<item-browser
|
<item-browser
|
||||||
:items.sync="books"
|
:items.sync="books"
|
||||||
|
|
@ -136,6 +148,7 @@ import {authorRoles} from '@/types/author-roles'
|
||||||
import {LibraryDto} from '@/types/komga-libraries'
|
import {LibraryDto} from '@/types/komga-libraries'
|
||||||
import {mergeFilterParams, toNameValue} from '@/functions/filter'
|
import {mergeFilterParams, toNameValue} from '@/functions/filter'
|
||||||
import {Location} from 'vue-router'
|
import {Location} from 'vue-router'
|
||||||
|
import {readListFileUrl} from '@/functions/urls'
|
||||||
|
|
||||||
export default Vue.extend({
|
export default Vue.extend({
|
||||||
name: 'BrowseReadList',
|
name: 'BrowseReadList',
|
||||||
|
|
@ -242,6 +255,12 @@ export default Vue.extend({
|
||||||
isAdmin(): boolean {
|
isAdmin(): boolean {
|
||||||
return this.$store.getters.meAdmin
|
return this.$store.getters.meAdmin
|
||||||
},
|
},
|
||||||
|
canDownload(): boolean {
|
||||||
|
return this.$store.getters.meFileDownload
|
||||||
|
},
|
||||||
|
fileUrl(): string {
|
||||||
|
return readListFileUrl(this.readListId)
|
||||||
|
},
|
||||||
filterActive(): boolean {
|
filterActive(): boolean {
|
||||||
return Object.keys(this.filters).some(x => this.filters[x].length !== 0)
|
return Object.keys(this.filters).some(x => this.filters[x].length !== 0)
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -541,7 +541,7 @@ export default Vue.extend({
|
||||||
return this.$store.getters.meFileDownload && !this.unavailable
|
return this.$store.getters.meFileDownload && !this.unavailable
|
||||||
},
|
},
|
||||||
fileUrl(): string {
|
fileUrl(): string {
|
||||||
return seriesFileUrl(this.series.id)
|
return seriesFileUrl(this.seriesId)
|
||||||
},
|
},
|
||||||
thumbnailUrl(): string {
|
thumbnailUrl(): string {
|
||||||
return seriesThumbnailUrl(this.seriesId)
|
return seriesThumbnailUrl(this.seriesId)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue