Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/server.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulius Härtl <jus@bitgrid.net>2019-12-23 12:31:28 +0300
committerJulius Härtl <jus@bitgrid.net>2019-12-27 10:45:39 +0300
commitdca861de942282d8536d52a785ae464237bd0d81 (patch)
treeee3f87b36e40972a79be9ea18b6ae8fa5514f725 /apps/workflowengine/src
parentb8779eed3680be88155750e2564465c462007f54 (diff)
Fix app store link and hide it for users (fix #18495 #18500)
Signed-off-by: Julius Härtl <jus@bitgrid.net>
Diffstat (limited to 'apps/workflowengine/src')
-rw-r--r--apps/workflowengine/src/components/Workflow.vue11
1 files changed, 9 insertions, 2 deletions
diff --git a/apps/workflowengine/src/components/Workflow.vue b/apps/workflowengine/src/components/Workflow.vue
index d94d2bf90a5..29ca2f44ed0 100644
--- a/apps/workflowengine/src/components/Workflow.vue
+++ b/apps/workflowengine/src/components/Workflow.vue
@@ -13,7 +13,10 @@
:operation="operation"
@click.native="createNewRule(operation)" />
- <a :key="'add'" :href="appstoreUrl" class="actions__item colored more">
+ <a v-if="showAppStoreHint"
+ :key="'add'"
+ :href="appstoreUrl"
+ class="actions__item colored more">
<div class="icon icon-add" />
<div class="actions__item__description">
<h3>{{ t('workflowengine', 'More flows') }}</h3>
@@ -49,6 +52,7 @@ import Rule from './Rule'
import Operation from './Operation'
import { mapGetters, mapState } from 'vuex'
import { loadState } from '@nextcloud/initial-state'
+import { generateUrl } from '@nextcloud/router'
const ACTION_LIMIT = 3
@@ -61,7 +65,7 @@ export default {
data() {
return {
showMoreOperations: false,
- appstoreUrl: '/index.php/settings/apps/workflow',
+ appstoreUrl: generateUrl('settings/apps/workflow'),
scope: loadState('workflowengine', 'scope'),
}
},
@@ -81,6 +85,9 @@ export default {
}
return Object.values(this.operations).slice(0, ACTION_LIMIT)
},
+ showAppStoreHint() {
+ return this.scope === 0 && OC.isUserAdmin()
+ },
},
mounted() {
this.$store.dispatch('fetchRules')