เพิ่ม head table Drop&drop
This commit is contained in:
parent
6941a6e4d6
commit
7e768afdb3
2 changed files with 9 additions and 12 deletions
|
|
@ -227,7 +227,7 @@ const columns = ref<QTableProps["columns"]>([
|
|||
* @param to ตำแหน่งที่จะย้ายไป
|
||||
*/
|
||||
function onDrop(from: number, to: number) {
|
||||
rows.value.splice(to, 0, rows.value.splice(from, 1)[0]);
|
||||
rows.value.splice(to - 1, 0, rows.value.splice(from - 1, 1)[0]);
|
||||
selected.value.push(rows.value[0]);
|
||||
}
|
||||
|
||||
|
|
@ -296,18 +296,11 @@ watch(modal, async () => {
|
|||
row-key="id"
|
||||
hide-bottom
|
||||
hide-pagination
|
||||
hide-header
|
||||
selection="multiple"
|
||||
class="custom-header-table"
|
||||
v-model:selected="selected"
|
||||
>
|
||||
<template v-slot:header-selection="scope">
|
||||
<q-checkbox
|
||||
keep-color
|
||||
color="primary"
|
||||
dense
|
||||
v-model="scope.checkBox"
|
||||
/>
|
||||
</template>
|
||||
<template v-slot:header-selection="scope"> </template>
|
||||
<template v-slot:body="props">
|
||||
<q-tr :props="props">
|
||||
<q-td>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue