don't show in hosted

This commit is contained in:
wh1te909
2024-07-01 19:47:08 +00:00
parent 739181a7ec
commit fd9f1bca8e
2 changed files with 11 additions and 3 deletions

View File

@@ -180,6 +180,7 @@
label="Edit Custom Fields"
/>
<q-checkbox
v-if="!hosted"
v-model="localRole.can_use_webterm"
label="Use TRMM Server Web Terminal"
/>
@@ -333,6 +334,7 @@
label="Manage Scripts"
/>
<q-checkbox
v-if="!hosted"
v-model="localRole.can_run_server_scripts"
label="Run Scripts on TRMM Server"
/>
@@ -417,7 +419,8 @@
<script>
// composition imports
import { ref, watch } from "vue";
import { computed, ref, watch } from "vue";
import { useStore } from "vuex";
import { useDialogPluginComponent } from "quasar";
import { saveRole, editRole } from "@/api/accounts";
import { useClientDropdown, useSiteDropdown } from "@/composables/clients";
@@ -435,6 +438,10 @@ export default {
// quasar setup
const { dialogRef, onDialogHide, onDialogOK } = useDialogPluginComponent();
// store
const store = useStore();
const hosted = computed(() => store.state.hosted);
// dropdown setup
const { clientOptions } = useClientDropdown(true);
const { siteOptions } = useSiteDropdown(true);
@@ -561,6 +568,7 @@ export default {
loading,
clientOptions,
siteOptions,
hosted,
onSubmit,

View File

@@ -42,7 +42,7 @@
<q-tooltip> Runs at 35mins past every hour </q-tooltip>
</q-checkbox>
</q-card-section>
<q-card-section class="row">
<q-card-section v-if="!hosted" class="row">
<q-checkbox
v-model="settings.enable_server_scripts"
label="Enable server scripts"
@@ -50,7 +50,7 @@
<q-tooltip>Allow running scripts on TRMM server</q-tooltip>
</q-checkbox>
</q-card-section>
<q-card-section class="row">
<q-card-section v-if="!hosted" class="row">
<q-checkbox
v-model="settings.enable_server_webterminal"
label="Enable web terminal"