เอา tab restore ออก ให้อยู่หน้าเดียว
This commit is contained in:
parent
9d77be0646
commit
e20ddf985f
2 changed files with 8 additions and 10 deletions
|
|
@ -23,7 +23,7 @@ const { showLoader, hideLoader, date2Thai, dialogRemove, dialogConfirm } =
|
|||
useCounterMixin();
|
||||
const { fetchListBackup, createBackUp, restore, deleteBackUp } = useDataStore();
|
||||
const storeData = useDataStore();
|
||||
const { dataBackUp, backupRunTotal , restoreRunTotal } = storeToRefs(storeData);
|
||||
const { dataBackUp, backupRunTotal, restoreRunTotal } = storeToRefs(storeData);
|
||||
|
||||
/**
|
||||
* props
|
||||
|
|
@ -113,7 +113,6 @@ function onRestore(name: string) {
|
|||
|
||||
onMounted(async () => {
|
||||
setTimeout(() => {
|
||||
|
||||
fetchListBackup();
|
||||
}, 1000);
|
||||
});
|
||||
|
|
@ -171,16 +170,18 @@ onMounted(async () => {
|
|||
>
|
||||
<template v-slot:header="props">
|
||||
<q-tr :props="props">
|
||||
<q-th v-for="col, i in props.cols" :key="col.name" :props="props" >
|
||||
<span class="text-weight-medium" :class="{ 'q-ml-md': i === 2}" >{{ col.label }}</span>
|
||||
<q-th v-for="(col, i) in props.cols" :key="col.name" :props="props">
|
||||
<span class="text-weight-medium" :class="{ 'q-ml-md': i === 2 }">{{
|
||||
col.label
|
||||
}}</span>
|
||||
</q-th>
|
||||
<q-th auto-width></q-th>
|
||||
</q-tr>
|
||||
</template>
|
||||
<template v-slot:body="props">
|
||||
<q-tr :props="props">
|
||||
<q-td v-for="(col, i) in props.cols" :key="col.name" :props="props" >
|
||||
<div :class="{ 'text-center': i === 2}">
|
||||
<q-td v-for="(col, i) in props.cols" :key="col.name" :props="props">
|
||||
<div :class="{ 'text-center': i === 2 }">
|
||||
{{ i !== 2 ? col.value : col.value === "สำเร็จ" ? "สำเร็จ" : "" }}
|
||||
|
||||
<q-circular-progress
|
||||
|
|
@ -195,7 +196,6 @@ onMounted(async () => {
|
|||
</q-td>
|
||||
<q-td>
|
||||
<q-btn
|
||||
v-if="tab === 'backup'"
|
||||
dense
|
||||
flat
|
||||
round
|
||||
|
|
@ -208,11 +208,10 @@ onMounted(async () => {
|
|||
</q-btn>
|
||||
|
||||
<q-btn
|
||||
v-else
|
||||
dense
|
||||
flat
|
||||
round
|
||||
:disable="restoreRunTotal !== 0 "
|
||||
:disable="restoreRunTotal !== 0"
|
||||
icon="restore"
|
||||
color="primary"
|
||||
size="12px"
|
||||
|
|
|
|||
|
|
@ -17,7 +17,6 @@ import Card from "@/modules/04_system/components/cardBackupRestore.vue";
|
|||
const tab = ref<string>("backup");
|
||||
const tabItems = ref<ItemsTeb[]>([
|
||||
{ name: "backup", label: "Backup", icon: "mdi-database" },
|
||||
{ name: "restore", label: "Restore", icon: "restore" },
|
||||
]);
|
||||
</script>
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue