fix เลื่อนขั้นเงินเดือน
This commit is contained in:
parent
19fa1bb447
commit
bf29f6d058
2 changed files with 21 additions and 66 deletions
|
|
@ -166,6 +166,11 @@ function inputEdit(val: boolean) {
|
|||
};
|
||||
}
|
||||
|
||||
const pagination = ref({
|
||||
page: 1,
|
||||
rowsPerPage: 50,
|
||||
});
|
||||
|
||||
watch(
|
||||
() => modal.value,
|
||||
() => {
|
||||
|
|
@ -177,6 +182,8 @@ watch(
|
|||
keyword.value = "";
|
||||
type.value = "";
|
||||
selectedData.value = [];
|
||||
pagination.value.page = 1;
|
||||
pagination.value.rowsPerPage = 50;
|
||||
}
|
||||
}
|
||||
);
|
||||
|
|
@ -267,8 +274,7 @@ watch(
|
|||
<div class="row justify-end">ทั้งหมด {{ rows.length }} รายการ</div>
|
||||
|
||||
<div class="col-12 q-mt-sm">
|
||||
<q-table
|
||||
class="custom-header-table"
|
||||
<d-table
|
||||
ref="table"
|
||||
:columns="columns"
|
||||
:rows="rows"
|
||||
|
|
@ -276,11 +282,10 @@ watch(
|
|||
flat
|
||||
bordered
|
||||
dense
|
||||
hide-pagination
|
||||
:visible-columns="visibleColumns"
|
||||
selection="multiple"
|
||||
v-model:selected="selectedData"
|
||||
:pagination="{ page: 1, rowsPerPage: total }"
|
||||
v-model:pagination="pagination"
|
||||
>
|
||||
<template v-slot:header-selection="scope">
|
||||
<q-checkbox
|
||||
|
|
@ -336,7 +341,7 @@ watch(
|
|||
</q-td>
|
||||
</q-tr>
|
||||
</template>
|
||||
</q-table>
|
||||
</d-table>
|
||||
</div>
|
||||
</div>
|
||||
</q-card-section>
|
||||
|
|
@ -353,31 +358,4 @@ watch(
|
|||
</q-dialog>
|
||||
</template>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.custom-header-table {
|
||||
height: auto;
|
||||
.q-table tr:nth-child(odd) td {
|
||||
background: white;
|
||||
}
|
||||
.q-table tr:nth-child(even) td {
|
||||
background: #f8f8f8;
|
||||
}
|
||||
|
||||
.q-table thead tr {
|
||||
background: #ecebeb;
|
||||
}
|
||||
|
||||
.q-table thead tr th {
|
||||
position: sticky;
|
||||
z-index: 1;
|
||||
}
|
||||
/* this will be the loading indicator */
|
||||
.q-table thead tr:last-child th {
|
||||
/* height of all previous header rows */
|
||||
top: 48px;
|
||||
}
|
||||
.q-table thead tr:first-child th {
|
||||
top: 0;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
<style lang="scss" scoped></style>
|
||||
|
|
|
|||
|
|
@ -83,6 +83,10 @@ const typeRangeOps = computed(() => {
|
|||
});
|
||||
|
||||
const keyword = ref<string>("");
|
||||
const pagination = ref({
|
||||
page: 1,
|
||||
rowsPerPage: 50,
|
||||
});
|
||||
|
||||
/**
|
||||
* function เรียกข้อมูลรายชื่อ
|
||||
|
|
@ -177,6 +181,8 @@ watch(
|
|||
keyword.value = "";
|
||||
type.value = "";
|
||||
selectedData.value = [];
|
||||
pagination.value.page = 1;
|
||||
pagination.value.rowsPerPage = 50;
|
||||
}
|
||||
}
|
||||
);
|
||||
|
|
@ -267,8 +273,7 @@ watch(
|
|||
<div class="row justify-end">ทั้งหมด {{ rows.length }} รายการ</div>
|
||||
|
||||
<div class="col-12 q-mt-sm">
|
||||
<q-table
|
||||
class="custom-header-table"
|
||||
<d-table
|
||||
ref="table"
|
||||
:columns="columns"
|
||||
:rows="rows"
|
||||
|
|
@ -276,11 +281,10 @@ watch(
|
|||
flat
|
||||
bordered
|
||||
dense
|
||||
hide-pagination
|
||||
:visible-columns="visibleColumns"
|
||||
selection="multiple"
|
||||
v-model:selected="selectedData"
|
||||
:pagination="{ page: 1, rowsPerPage: total }"
|
||||
v-model:pagination="pagination"
|
||||
>
|
||||
<template v-slot:header-selection="scope">
|
||||
<q-checkbox
|
||||
|
|
@ -336,7 +340,7 @@ watch(
|
|||
</q-td>
|
||||
</q-tr>
|
||||
</template>
|
||||
</q-table>
|
||||
</d-table>
|
||||
</div>
|
||||
</div>
|
||||
</q-card-section>
|
||||
|
|
@ -353,31 +357,4 @@ watch(
|
|||
</q-dialog>
|
||||
</template>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.custom-header-table {
|
||||
height: auto;
|
||||
.q-table tr:nth-child(odd) td {
|
||||
background: white;
|
||||
}
|
||||
.q-table tr:nth-child(even) td {
|
||||
background: #f8f8f8;
|
||||
}
|
||||
|
||||
.q-table thead tr {
|
||||
background: #ecebeb;
|
||||
}
|
||||
|
||||
.q-table thead tr th {
|
||||
position: sticky;
|
||||
z-index: 1;
|
||||
}
|
||||
/* this will be the loading indicator */
|
||||
.q-table thead tr:last-child th {
|
||||
/* height of all previous header rows */
|
||||
top: 48px;
|
||||
}
|
||||
.q-table thead tr:first-child th {
|
||||
top: 0;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
<style lang="scss" scoped></style>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue