|
|
@ -424,37 +424,66 @@ const onFormItemClick = (element: any) => { |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</template> |
|
|
|
</template> |
|
|
|
<template v-else> |
|
|
|
<template v-else> |
|
|
|
<a-row v-if="submitted" class="h-full" data-testid="nc-form-wrapper-submit"> |
|
|
|
<div |
|
|
|
<a-col :span="24"> |
|
|
|
v-if="submitted" |
|
|
|
|
|
|
|
class="h-full p-6" |
|
|
|
|
|
|
|
:style="{background:(formViewData?.meta as Record<string,any>).theme_color || '#F9F9FA'}" |
|
|
|
|
|
|
|
data-testid="nc-form-wrapper-submit" |
|
|
|
|
|
|
|
> |
|
|
|
|
|
|
|
<GeneralFormBanner :banner-image-url="formViewData?.banner_image_url" /> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div |
|
|
|
|
|
|
|
class="transition-all duration-300 ease-in relative max-w-[max(33%,688px)] mx-auto my-6 bg-white rounded-3xl border-1 border-gray-200 px-4 py-8 lg:p-12 md:(p-8 dark:bg-slate-700)" |
|
|
|
|
|
|
|
> |
|
|
|
<div v-if="formViewData" class="items-center justify-center text-center mt-2"> |
|
|
|
<div v-if="formViewData" class="items-center justify-center text-center mt-2"> |
|
|
|
<a-alert type="success"> |
|
|
|
<div class="text-left"> |
|
|
|
<template #message> |
|
|
|
<h1 class="prose-2xl font-bold mb-4" style="word-break: break-all"> |
|
|
|
<div class="text-center"> |
|
|
|
{{ formViewData.heading }} |
|
|
|
{{ formViewData.success_msg || $t('msg.successfullySubmittedFormData') }} |
|
|
|
</h1> |
|
|
|
</div> |
|
|
|
|
|
|
|
</template> |
|
|
|
<h2 |
|
|
|
</a-alert> |
|
|
|
v-if="formViewData.subheading" |
|
|
|
|
|
|
|
class="prose-lg text-slate-500 dark:text-slate-300 mb-4 leading-6" |
|
|
|
<div v-if="formViewData.show_blank_form" class="text-gray-400 mt-4"> |
|
|
|
style="word-break: break-all" |
|
|
|
{{ |
|
|
|
> |
|
|
|
$t('msg.newFormWillBeLoaded', { |
|
|
|
{{ formViewData.subheading }} |
|
|
|
seconds: secondsRemain, |
|
|
|
</h2> |
|
|
|
}) |
|
|
|
|
|
|
|
}} |
|
|
|
|
|
|
|
</div> |
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
<div v-if="formViewData.submit_another_form || !isPublic" class="text-center mt-4"> |
|
|
|
<div class="flex justify-center"> |
|
|
|
<a-button type="primary" size="large" @click="submitted = false"> {{ $t('activity.submitAnotherForm') }}</a-button> |
|
|
|
<div class="w-full lg:w-[95%]"> |
|
|
|
|
|
|
|
<a-alert type="success" class="!my-4 text-center !rounded-lg"> |
|
|
|
|
|
|
|
<template #message> |
|
|
|
|
|
|
|
<div class="text-center"> |
|
|
|
|
|
|
|
{{ formViewData.success_msg || $t('msg.successfullySubmittedFormData') }} |
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
</template> |
|
|
|
|
|
|
|
</a-alert> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div v-if="formViewData.show_blank_form" class="text-gray-400 mt-4"> |
|
|
|
|
|
|
|
{{ |
|
|
|
|
|
|
|
$t('msg.newFormWillBeLoaded', { |
|
|
|
|
|
|
|
seconds: secondsRemain, |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
}} |
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<div v-if="formViewData.submit_another_form || !isPublic" class="text-center mt-4"> |
|
|
|
|
|
|
|
<a-button type="primary" size="large" @click="submitted = false"> |
|
|
|
|
|
|
|
{{ $t('activity.submitAnotherForm') }}</a-button |
|
|
|
|
|
|
|
> |
|
|
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
</a-col> |
|
|
|
</div> |
|
|
|
</a-row> |
|
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
<div v-else class="h-full w-full flex" data-testid="nc-form-wrapper"> |
|
|
|
<div v-else class="h-full w-full flex" data-testid="nc-form-wrapper"> |
|
|
|
<div |
|
|
|
<div |
|
|
|
v-if="formViewData" |
|
|
|
v-if="formViewData" |
|
|
|
class="flex-1 h-full overflow-auto nc-form-scrollbar p-6 bg-gray-50" |
|
|
|
class="flex-1 h-full overflow-auto nc-form-scrollbar p-6" |
|
|
|
:style="{background:(formViewData?.meta as Record<string,any>).theme_color}" |
|
|
|
:style="{background:(formViewData?.meta as Record<string,any>).theme_color || '#F9F9FA'}" |
|
|
|
> |
|
|
|
> |
|
|
|
<div :class="isEditable ? 'min-w-[616px] overflow-x-auto nc-form-scrollbar' : ''"> |
|
|
|
<div :class="isEditable ? 'min-w-[616px] overflow-x-auto nc-form-scrollbar' : ''"> |
|
|
|
<!-- for future implementation of cover image --> |
|
|
|
<!-- for future implementation of cover image --> |
|
|
|