diff options
author | Julius Härtl <jus@bitgrid.net> | 2018-06-02 08:49:30 +0200 |
---|---|---|
committer | Julius Härtl <jus@bitgrid.net> | 2018-06-06 11:40:09 +0200 |
commit | 64c2e946f4d17e877105116ddc6e02f9c2aa042b (patch) | |
tree | 370cd51990d5e4ab6fea6860bb146acc0e85e319 /settings/src/components/appList.vue | |
parent | b4a7be20c8837d2ce74b082a6668b8896cf3318f (diff) | |
download | nextcloud-server-64c2e946f4d17e877105116ddc6e02f9c2aa042b.tar.gz nextcloud-server-64c2e946f4d17e877105116ddc6e02f9c2aa042b.zip |
Some code cleanup
Signed-off-by: Julius Härtl <jus@bitgrid.net>
Diffstat (limited to 'settings/src/components/appList.vue')
-rw-r--r-- | settings/src/components/appList.vue | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/settings/src/components/appList.vue b/settings/src/components/appList.vue index 36980f57085..ab8d30b1227 100644 --- a/settings/src/components/appList.vue +++ b/settings/src/components/appList.vue @@ -21,8 +21,7 @@ --> <template> - <div id="app-content" class="app-settings-content" :class="{ 'with-app-sidebar': app, 'icon-loading': loading }"> - + <div id="app-content-inner"> <div id="apps-list" :class="{installed: (useBundleView || useListView), store: useAppStoreView}"> <template v-if="useListView"> <app-item v-for="app in apps" :key="app.id" :app="app" :category="category" /> @@ -115,14 +114,15 @@ export default { return (this.category === 'app-bundles'); }, allBundlesEnabled() { + let self = this; return function(id) { - console.log(this.bundleApps(id).filter(app => !app.active)); - return this.bundleApps(id).filter(app => !app.active).length === 0; + return self.bundleApps(id).filter(app => !app.active).length === 0; } }, bundleToggleText() { + let self = this; return function(id) { - if (this.allBundlesEnabled(id)) { + if (self.allBundlesEnabled(id)) { return t('settings', 'Disable all'); } return t('settings', 'Enable all'); @@ -131,14 +131,13 @@ export default { }, methods: { toggleBundle(id) { - if (this.allBundlesEnabled) { + if (this.allBundlesEnabled(id)) { return this.disableBundle(id); } return this.enableBundle(id); }, enableBundle(id) { let apps = this.bundleApps(id).map(app => app.id); - console.log(apps); this.$store.dispatch('enableApp', { appId: apps, groups: [] }) .catch((error) => { console.log(error); OC.Notification.show(error)}); }, |