diff --git a/src/pages/ProductVersionsPage.vue b/src/pages/ProductVersionsPage.vue index 52e3b61..c42daa4 100644 --- a/src/pages/ProductVersionsPage.vue +++ b/src/pages/ProductVersionsPage.vue @@ -5,6 +5,7 @@ import { message, Modal } from 'ant-design-vue' import { ArrowRightOutlined, PlusOutlined, SearchOutlined } from '@ant-design/icons-vue' import api from '@/api/http' import { useAuthStore } from '@/stores/auth' +import { formatIranDateTime } from '@/utils/datetime' type Tenant = { id: string @@ -20,6 +21,7 @@ type Tenant = { notes?: string | null hasAppUiConfig?: boolean uiVariant?: 'modular' | 'newTheme' + createdAt?: string } const route = useRoute() @@ -141,6 +143,7 @@ onMounted(load)

{{ item.nameFa }}

{{ item.domain }}
+
ایجاد: {{ formatIranDateTime(item.createdAt) }}
{{ item.slug }} {{ item.nameEn }} diff --git a/src/pages/TenantFormPage.vue b/src/pages/TenantFormPage.vue index 33c8744..0d4de2b 100644 --- a/src/pages/TenantFormPage.vue +++ b/src/pages/TenantFormPage.vue @@ -5,6 +5,7 @@ import { message } from 'ant-design-vue' import { ArrowRightOutlined, PlusOutlined, DeleteOutlined } from '@ant-design/icons-vue' import api from '@/api/http' import { useAuthStore } from '@/stores/auth' +import { formatIranDateTime } from '@/utils/datetime' const route = useRoute() const router = useRouter() @@ -12,6 +13,7 @@ const auth = useAuthStore() const loading = ref(false) const saving = ref(false) const uploading = ref(false) +const createdAt = ref(null) const isEdit = computed(() => Boolean(route.params.id)) @@ -49,12 +51,14 @@ async function load() { if (!isEdit.value) { const q = String(route.query.product || '') form.product = q === 'khanegi' ? 'khanegi' : 'hamkar' + createdAt.value = null return } loading.value = true try { const { data } = await api.get(`/tenants/${route.params.id}`) + createdAt.value = data.createdAt || null Object.assign(form, { product: data.product, slug: data.slug, @@ -185,6 +189,9 @@ onMounted(load) + + +
diff --git a/src/styles.css b/src/styles.css index a747414..fb7cc8d 100644 --- a/src/styles.css +++ b/src/styles.css @@ -298,6 +298,12 @@ button, input, textarea, select, word-break: break-all; } +.version-meta .created-at { + margin-top: 4px; + color: #94a3b8; + font-size: 0.8rem; +} + .version-actions { display: flex; flex-wrap: wrap;