complete Complete User Request Submission section RAD-1

This commit is contained in:
2026-01-03 19:14:30 +03:30
commit 7137ec5792
393 changed files with 152602 additions and 0 deletions
@@ -0,0 +1,70 @@
<script setup>
import { Link } from '@inertiajs/inertia-vue3';
import { watch, onMounted, ref } from 'vue';
import { usePage } from '@inertiajs/inertia-vue3';
import { toast } from 'vue3-toastify';
const page = usePage();
const lastFlash = ref(null);
const showToast = (type, message) => {
if (message) {
const toastOptions = {
position: 'top-right',
rtl: true,
theme: 'colored',
autoClose: 3000,
};
if (type === 'success') {
toast.success(message, toastOptions);
} else if (type === 'error') {
toast.error(message, toastOptions);
}
}
};
onMounted(() => {
const flash = page.props.value?.flash;
if (flash?.success || flash?.error) {
lastFlash.value = JSON.stringify(flash);
if (flash.success) {
showToast('success', flash.success);
}
if (flash.error) {
showToast('error', flash.error);
}
}
});
watch(() => page.props.value?.flash, (newFlash) => {
if (newFlash) {
const newFlashStr = JSON.stringify(newFlash);
if (newFlashStr !== lastFlash.value) {
lastFlash.value = newFlashStr;
if (newFlash.success) {
showToast('success', newFlash.success);
}
if (newFlash.error) {
showToast('error', newFlash.error);
}
}
}
}, { deep: true });
</script>
<template>
<div class="grid grid-cols-a relative grid-rows-[auto] items-center justify-center h-[100svh] w-full bg-dominant-50 content-center">
<Link href="/">
<figure class="flex justify-center mb-8">
<img src="@/images/radical_logo.png" alt="logo" class="w-[125px] h-auto object-cover"></img>
</figure>
</Link>
<slot />
<slot name="footer" class=""></slot>
<div class="absolute w-full text-center bottom-5 right-0 left-0 m-auto">
<p class="text-center text-[13px] max-sm:px-4 max-sm:leading-8 text-dominant-700 font-normal">تمامی حقوق این وب‌سایت برای مجموعه <span class="font-semibold">تله‌رادیولوژی رادیکال</span> محفوظ می‌باشد.</p>
</div>
</div>
</template>
@@ -0,0 +1,41 @@
<script setup>
import DialogsProvider from "./DialogsProvider.vue";
import SidebarComponent from "../components/sidebar/SidebarComponent.vue";
import HeaderComponent from "../components/header/HeaderComponent.vue";
import { Transition, onMounted } from 'vue';
import { usePage } from '@inertiajs/inertia-vue3';
import { useGlobalStore } from "../store/Global";
const globalStore = useGlobalStore();
const {props} = usePage();
onMounted(() => {
globalStore.current_user = props.value.auth.User;
});
</script>
<template>
<sidebar-component />
<header-component />
<div class="!bg-white">
<section class="">
<main class="overflow-hidden !ps-[16rem] max-sm:!ps-4 pt-20 min-h-[calc(100svh)] p-4 grid grid-cols-1">
<section class="!rounded-2xl border-[1px] border-dominant-50 !bg-dominant-50/50 content-start p-4 grid grid-cols-1">
<div v-if="$page.props.flash.success" class="w-full mb-4">
<Message size="small" closable class="!text-xs py-1.5" severity="success">{{$page.props.flash.success}}</Message>
</div>
<Transition
name="page-transition"
mode="out-in"
appear
>
<section class="grid grid-cols-1">
<slot></slot>
</section>
</Transition>
</section>
</main>
<dialogs-provider />
</section>
</div>
</template>
@@ -0,0 +1,16 @@
<script setup>
</script>
<template>
<ConfirmDialog group="deleteTemplate">
<template #message="slotProps">
<div class="flex flex-col items-center w-full gap-4">
<i :class="slotProps.message.icon" class="!text-6xl text-primary-500"></i>
<p class="leading-7 text-sm font-normal">{{ slotProps.message.message }}</p>
</div>
</template>
</ConfirmDialog>
<Toast />
</template>