feat: nodata product i18n

This commit is contained in:
puriphatt 2024-08-22 16:36:56 +07:00
parent 3f916bb4c3
commit 446015a795
3 changed files with 12 additions and 1 deletions

View file

@ -1,6 +1,7 @@
<script setup lang="ts"> <script setup lang="ts">
defineProps<{ defineProps<{
size?: number; size?: number;
text?: string;
useField?: boolean; useField?: boolean;
notFound?: boolean; notFound?: boolean;
}>(); }>();
@ -15,7 +16,15 @@ defineProps<{
}" }"
/> />
<div class="app-text-muted text-center"> <div class="app-text-muted text-center">
{{ notFound ? $t('notFound') : useField ? $t('noField') : $t('noData') }} {{
text
? text
: notFound
? $t('notFound')
: useField
? $t('noField')
: $t('noData')
}}
</div> </div>
</div> </div>
</template> </template>

View file

@ -219,6 +219,7 @@ export default {
showTotalPrice: 'Show Total Price', showTotalPrice: 'Show Total Price',
}, },
product: { product: {
noProduct: 'No Product',
allProduct: 'All Product', allProduct: 'All Product',
}, },
}, },

View file

@ -217,6 +217,7 @@ export default {
showTotalPrice: 'แสดงราคารวม', showTotalPrice: 'แสดงราคารวม',
}, },
product: { product: {
noProduct: 'ยังไม่มีสินค้า',
allProduct: 'สินค้าทั้งหมด', allProduct: 'สินค้าทั้งหมด',
}, },
}, },