Commit b8f3a8df authored by TTS Kieu Tuan Anh's avatar TTS Kieu Tuan Anh

fix status

parent 4fb6a513
...@@ -59,7 +59,7 @@ ...@@ -59,7 +59,7 @@
> >
<v-select <v-select
v-model="sStatus" v-model="sStatus"
:items="statusDefaul" :items="statusDefault"
item-text="name" item-text="name"
item-value="id" item-value="id"
label="Status" label="Status"
...@@ -141,7 +141,7 @@ ...@@ -141,7 +141,7 @@
> >
<v-select <v-select
v-model="eStatus" v-model="eStatus"
:items="statusDefaul" :items="statusDefault"
item-text="name" item-text="name"
item-value="id" item-value="id"
label="Status" label="Status"
...@@ -271,7 +271,7 @@ ...@@ -271,7 +271,7 @@
> >
<v-select <v-select
v-model="status" v-model="status"
:items="statusDefaul" :items="statusDefault"
item-text="name" item-text="name"
item-value="id" item-value="id"
label="Status" label="Status"
...@@ -333,7 +333,7 @@ ...@@ -333,7 +333,7 @@
{{ categories.find(x => x.id === item.category_id)?.name }} {{ categories.find(x => x.id === item.category_id)?.name }}
</template> </template>
<template #[`item.status`]="{ item }"> <template #[`item.status`]="{ item }">
{{ statusDefaul.find(x => x.id == item.status)?.name }} {{ statusDefault.find(x => x.id == item.status)?.name }}
</template> </template>
<template #[`item.user_id`]="{ item }"> <template #[`item.user_id`]="{ item }">
{{ users.find(x => x.id === item.user_id)?.name }} {{ users.find(x => x.id === item.user_id)?.name }}
...@@ -403,18 +403,18 @@ export default { ...@@ -403,18 +403,18 @@ export default {
href: '/products' href: '/products'
} }
], ],
statusDefaul: [ statusDefault: [
{ {
name: 'Draft', name: 'Draft',
id: '1' id: 1
}, },
{ {
name: 'Publish', name: 'Publish',
id: '2' id: 2
}, },
{ {
name: 'Unpublish', name: 'Unpublish',
id: '3' id: 3
} }
], ],
posts: [], posts: [],
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment