mirror of
https://github.com/gotson/komga.git
synced 2026-05-08 21:00:16 +02:00
feat:(webui): Add scan all libraries button in server settings
* Add scan all libraries button * refactor: remove error color, adjust spacing for RTL Co-authored-by: Gauthier Roebroeck <gauthier.roebroeck@gmail.com>
This commit is contained in:
parent
1eb16b4c2a
commit
62a885417c
2 changed files with 11 additions and 2 deletions
|
|
@ -632,6 +632,7 @@
|
|||
},
|
||||
"server": {
|
||||
"server_management": {
|
||||
"button_scan_libraries": "Scan all libraries",
|
||||
"button_empty_trash": "Empty trash for all libraries",
|
||||
"button_shutdown": "Shut down",
|
||||
"section_title": "Server Management"
|
||||
|
|
|
|||
|
|
@ -5,9 +5,12 @@
|
|||
</v-row>
|
||||
<v-row>
|
||||
<v-col>
|
||||
<v-btn @click="scanAllLibraries"
|
||||
:class="$vuetify.rtl ? 'ml-4' : 'mr-4'"
|
||||
>{{ $t('server.server_management.button_scan_libraries') }}
|
||||
</v-btn>
|
||||
<v-btn @click="confirmEmptyTrash = true"
|
||||
style="margin-right: 15px"
|
||||
color="error"
|
||||
:class="$vuetify.rtl ? 'ml-4' : 'mr-4'"
|
||||
>{{ $t('server.server_management.button_empty_trash') }}
|
||||
</v-btn>
|
||||
<v-btn @click="modalStopServer = true"
|
||||
|
|
@ -61,6 +64,11 @@ export default Vue.extend({
|
|||
this.$komgaLibraries.emptyTrash(library)
|
||||
})
|
||||
},
|
||||
scanAllLibraries() {
|
||||
this.libraries.forEach(library => {
|
||||
this.$komgaLibraries.scanLibrary(library)
|
||||
})
|
||||
},
|
||||
async stopServer() {
|
||||
try {
|
||||
await this.$actuator.shutdown()
|
||||
|
|
|
|||
Loading…
Reference in a new issue