Skip to content

Commit 6c9059d

Browse files
include type of resource in member permission level label to better convey the scope
1 parent 8f15c4d commit 6c9059d

File tree

1 file changed

+18
-7
lines changed

1 file changed

+18
-7
lines changed

src/views/ResourceSettings.vue

Lines changed: 18 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -44,13 +44,6 @@ const resource = ref(null);
4444
const loading = ref(false);
4545
const resourceActiveLoading = ref(false);
4646
47-
const memberPermissionLevelOptions = [
48-
// TRANSLATORS This a permission level of members of organization folders and resources
49-
{ label: t("organization_folders", "Member"), value: 1 },
50-
// TRANSLATORS This a permission level of members of organization folders and resources
51-
{ label: t("organization_folders", "Manager"), value: 2 },
52-
];
53-
5447
const currentResourceName = ref(false);
5548
5649
const resourceNameValid = computed(() => {
@@ -177,6 +170,24 @@ const title = computed(() =>{
177170
}
178171
});
179172
173+
const memberPermissionLevelOptions = computed(() => {
174+
if(resource.value?.type === api.ResourceTypes.FOLDER) {
175+
return [
176+
// TRANSLATORS This a permission level of members of folder resources
177+
{ label: t("organization_folders", "Folder member"), value: 1 },
178+
// TRANSLATORS This a permission level of members of folder resources
179+
{ label: t("organization_folders", "Folder manager"), value: 2 },
180+
];
181+
} else {
182+
return [
183+
// TRANSLATORS This a permission level of members of organization folders and resources
184+
{ label: t("organization_folders", "Member"), value: 1 },
185+
// TRANSLATORS This a permission level of members of organization folders and resources
186+
{ label: t("organization_folders", "Manager"), value: 2 },
187+
];
188+
}
189+
});
190+
180191
const permissionLevelExplanation = computed(() => {
181192
if(resource.value?.type === api.ResourceTypes.FOLDER) {
182193
return t("organization_folders", "Managers have access to the settings of this folder");

0 commit comments

Comments
 (0)