Browse Source

chore(nc-gui): lint

Ramesh Mane 2 days ago
parent
commit
8767ffad3f
  1. 2
      packages/nc-gui/components/dlg/share-and-collaborate/CustomUrl.vue
  2. 21
      packages/nc-gui/components/dlg/share-and-collaborate/SharePage.vue

2
packages/nc-gui/components/dlg/share-and-collaborate/CustomUrl.vue

@ -6,7 +6,7 @@ interface Props {
dashboardUrl: string
}
const emits = defineEmits(['updateSharedView', 'copyCustomUrl'])
defineProps<Props>()
</script>
<template>

21
packages/nc-gui/components/dlg/share-and-collaborate/SharePage.vue

@ -54,10 +54,6 @@ const url = computed(() => {
return sharedViewUrl() ?? ''
})
const preFillFormSearchParams = computed(() => {
return viewStore.preFillFormSearchParams && formPreFill.value.preFillEnabled ? viewStore.preFillFormSearchParams : ''
})
const passwordProtectedLocal = ref(false)
const passwordProtected = computed(() => {
@ -69,7 +65,10 @@ const password = computed({
set: async (value) => {
if (!activeView.value) return
activeView.value = { ...(activeView.value as any), password: passwordProtected.value ? value : null }
activeView.value = {
...(activeView.value as any),
password: passwordProtected.value ? value : null,
}
updateSharedView()
},
@ -179,6 +178,10 @@ const formPreFill = computed({
},
})
const preFillFormSearchParams = computed(() => {
return viewStore.preFillFormSearchParams && formPreFill.value.preFillEnabled ? viewStore.preFillFormSearchParams : ''
})
const handleChangeFormPreFill = (value: { preFillEnabled?: boolean; preFilledMode?: PreFilledMode }) => {
formPreFill.value = {
...formPreFill.value,
@ -330,7 +333,9 @@ const copyCustomUrl = async (custUrl = '') => {
<div class="flex flex-col py-2 px-3 mb-1">
<div class="flex flex-col w-full mt-2.5 px-3 py-2.5 border-gray-200 border-1 rounded-md gap-y-2">
<div class="flex flex-row w-full justify-between py-0.5">
<div class="text-gray-900 font-medium">{{ $t('activity.enabledPublicViewing') }}</div>
<div class="text-gray-900 font-medium">
{{ $t('activity.enabledPublicViewing') }}
</div>
<a-switch
v-e="['c:share:view:enable:toggle']"
:checked="isPublicShared"
@ -355,7 +360,9 @@ const copyCustomUrl = async (custUrl = '') => {
/>
<div class="flex flex-col justify-between mt-1 py-2 px-3 bg-gray-50 rounded-md">
<div class="flex flex-row items-center justify-between">
<div class="flex text-black">{{ $t('activity.restrictAccessWithPassword') }}</div>
<div class="flex text-black">
{{ $t('activity.restrictAccessWithPassword') }}
</div>
<a-switch
v-e="['c:share:view:password:toggle']"
:checked="passwordProtected"

Loading…
Cancel
Save