This commit is contained in:
setthawutttty 2024-01-05 11:05:49 +07:00
parent c2e0e5cb59
commit bc8a03139d
4 changed files with 51 additions and 48 deletions

View file

@ -240,6 +240,7 @@ function openDetial(id: string) {
function closeDetail() {
modalHistory.value = false;
personalId.value = "";
}
</script>
<template>
@ -337,6 +338,7 @@ function closeDetail() {
>
<template v-slot:header="props">
<q-tr :props="props">
<q-th auto-width></q-th>
<q-th
v-for="col in props.cols"
:key="col.name"
@ -347,40 +349,37 @@ function closeDetail() {
col.label
}}</span>
</q-th>
</q-tr>
</template>
<template v-slot:body="props">
<q-tr :props="props" class="cursor-pointer">
<td>
<router-link
target="_blank"
:to="`/registry/${props.row.personId}`"
><q-icon name="info" color="info" size="sm"
><q-tooltip>อมลในทะเบยนประว</q-tooltip>
</q-icon></router-link
>
</td>
<q-td
v-for="col in props.cols"
:key="col.name"
:props="props"
@click="openDetial(props.row.personId)"
>
<div
v-if="col.name == 'no'"
@click="openDetial(props.row.id)"
>
<div v-if="col.name == 'no'">
{{ props.rowIndex + 1 }}
</div>
<div v-else-if="col.name == 'info'">
<router-link
target="_blank"
:to="`/registry/${props.row.personId}`"
><q-icon name="info" color="info" size="sm"
><q-tooltip
>อมลในทะเบยนประว</q-tooltip
>
</q-icon></router-link
>
</div>
<div
v-else-if="col.name === 'organization'"
class="table_ellipsis"
@click="openDetial(props.row.id)"
>
{{ props.row.organization }}
</div>
<div v-else @click="openDetial(props.row.id)">
<div v-else>
{{ col.value }}
</div>
</q-td>