Fix created at view format
This commit is contained in:
@@ -1,8 +1,4 @@
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
// imports
|
|
||||||
|
|
||||||
import { usePersianTimeAgo } from "~/composables/global/usePersianTimeAgo";
|
|
||||||
|
|
||||||
// types
|
// types
|
||||||
|
|
||||||
type Props = {
|
type Props = {
|
||||||
@@ -15,9 +11,6 @@ const props = defineProps<Props>();
|
|||||||
|
|
||||||
const { data } = toRefs(props);
|
const { data } = toRefs(props);
|
||||||
|
|
||||||
// computed
|
|
||||||
|
|
||||||
const createdTimeAgo = usePersianTimeAgo(new Date(data.value.created_at));
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
@@ -34,7 +27,7 @@ const createdTimeAgo = usePersianTimeAgo(new Date(data.value.created_at));
|
|||||||
<td
|
<td
|
||||||
class="w-3/12 px-6 py-6 text-xs lg:text-sm font-medium whitespace-pre shrink-0"
|
class="w-3/12 px-6 py-6 text-xs lg:text-sm font-medium whitespace-pre shrink-0"
|
||||||
>
|
>
|
||||||
{{ data.created_at ? createdTimeAgo : "--" }}
|
{{ data.created_at ?? "--" }}
|
||||||
</td>
|
</td>
|
||||||
<td class="w-2/12 px-6 py-6 text-xs lg:text-sm whitespace-pre shrink-0">
|
<td class="w-2/12 px-6 py-6 text-xs lg:text-sm whitespace-pre shrink-0">
|
||||||
{{ data.count ? data.count : "--" }}
|
{{ data.count ? data.count : "--" }}
|
||||||
|
|||||||
Reference in New Issue
Block a user