mirror of
https://github.com/owntone/owntone-server.git
synced 2025-01-24 13:13:17 -05:00
[web-src] forced meta rescan
This commit is contained in:
parent
e9c1a59ad2
commit
bf7c96d23f
@ -97,6 +97,8 @@
|
||||
<div class="column is-7 content">
|
||||
<a class="button" v-on:click="update" v-show="!library.updating">Update library</a>
|
||||
<p v-show="library.updating">Update in progress ...</p>
|
||||
<a class="button" v-on:click="update_meta" v-show="!library.updating">Rescan library meta</a>
|
||||
<p v-show="library.updating">Rescan in progress ...</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
@ -56,6 +56,11 @@ var app = new Vue({
|
||||
axios.get('/api/update').then(console.log('Library is updating'));
|
||||
},
|
||||
|
||||
update_meta: function() {
|
||||
this.library.updating = true;
|
||||
axios.get('/api/update/meta').then(console.log('Library is rescanning meta'));
|
||||
},
|
||||
|
||||
kickoffPairing: function() {
|
||||
axios.post('/api/pairing', this.pairing_req).then(response => {
|
||||
console.log('Kicked off pairing');
|
||||
|
@ -24,8 +24,9 @@
|
||||
</div>
|
||||
|
||||
<!-- Right side -->
|
||||
<div class="level-right">
|
||||
<div class="level-right buttons">
|
||||
<a class="button is-small is-outlined is-link" :class="{ 'is-loading': library.updating }" @click="update">Update</a>
|
||||
<a class="button is-small is-outlined is-link" :class="{ 'is-loading': library.updating }" @click="update_meta">Force Meta Rescan</a>
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
@ -95,6 +96,10 @@ export default {
|
||||
methods: {
|
||||
update: function () {
|
||||
webapi.library_update()
|
||||
},
|
||||
|
||||
update_meta: function () {
|
||||
webapi.library_update_meta()
|
||||
}
|
||||
},
|
||||
|
||||
|
@ -21,6 +21,10 @@ export default {
|
||||
return axios.get('/api/update')
|
||||
},
|
||||
|
||||
library_update_meta () {
|
||||
return axios.get('/api/update/meta')
|
||||
},
|
||||
|
||||
library_count (expression) {
|
||||
return axios.get('/api/library/count?expression=' + expression)
|
||||
},
|
||||
|
Loading…
x
Reference in New Issue
Block a user