ย้ายไอคอน
This commit is contained in:
parent
900d308f81
commit
dfa66f3a98
28 changed files with 730 additions and 702 deletions
|
|
@ -236,6 +236,7 @@ watch(
|
|||
>
|
||||
<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"
|
||||
|
|
@ -243,11 +244,19 @@ watch(
|
|||
>
|
||||
<span class="text-weight-medium">{{ col.label }}</span>
|
||||
</q-th>
|
||||
<q-th auto-width></q-th>
|
||||
|
||||
</q-tr>
|
||||
</template>
|
||||
<template v-slot:body="props">
|
||||
<q-tr :props="props" class="cursor-pointer">
|
||||
<q-td>
|
||||
<q-btn
|
||||
outline
|
||||
color="primary"
|
||||
label="เพิ่ม"
|
||||
@click="onClickAddPerson(props.row)"
|
||||
/>
|
||||
</q-td>
|
||||
<q-td
|
||||
v-for="col in props.cols"
|
||||
:key="col.name"
|
||||
|
|
@ -269,14 +278,7 @@ watch(
|
|||
{{ col.value ? col.value : "-" }}
|
||||
</div>
|
||||
</q-td>
|
||||
<q-td>
|
||||
<q-btn
|
||||
outline
|
||||
color="primary"
|
||||
label="เพิ่ม"
|
||||
@click="onClickAddPerson(props.row)"
|
||||
/>
|
||||
</q-td>
|
||||
|
||||
</q-tr>
|
||||
</template>
|
||||
<template v-slot:pagination="scope">
|
||||
|
|
|
|||
|
|
@ -357,14 +357,63 @@ watch(
|
|||
>
|
||||
<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" :props="props">
|
||||
<span class="text-weight-medium">{{ col.label }}</span>
|
||||
</q-th>
|
||||
<q-th auto-width></q-th>
|
||||
</q-tr>
|
||||
</template>
|
||||
<template v-slot:body="props">
|
||||
<q-tr :props="props" class="cursor-pointer">
|
||||
<q-td>
|
||||
<q-btn
|
||||
v-if="!store.isClosedRound"
|
||||
flat
|
||||
dense
|
||||
icon="mdi-dots-vertical"
|
||||
class="q-pa-none q-ml-xs"
|
||||
color="grey-13"
|
||||
size="12px"
|
||||
>
|
||||
<q-menu>
|
||||
<q-list dense style="min-width: 150px">
|
||||
<q-item
|
||||
v-for="(item, index) in store.roundCode !== 'SPECIAL' ? store.itemMenu.filter((x:any)=>x.type !== 'properties') :store.itemMenu.filter((x:any)=>x.type !== 'moveGroup' && x.type !== 'properties')"
|
||||
:key="index"
|
||||
clickable
|
||||
v-close-popup
|
||||
@click="
|
||||
item.type === 'edit'
|
||||
? onClickEdit(props.row.id, props.row.amount)
|
||||
: item.type === 'moveGroup'
|
||||
? onClickMovieGroup(props.row.id)
|
||||
: item.type === 'moveLevel'
|
||||
? onClickMoveLevel(
|
||||
props.row.id,
|
||||
props.row.type,
|
||||
props.row.isReserve,
|
||||
props.row.remark
|
||||
)
|
||||
: item.type === 'delete'
|
||||
? onClickDelete(props.row.id)
|
||||
: null
|
||||
"
|
||||
>
|
||||
<q-item-section>
|
||||
<div class="row items-center">
|
||||
<q-icon
|
||||
:color="item.color"
|
||||
size="17px"
|
||||
:name="item.icon"
|
||||
/>
|
||||
<div class="q-pl-md">{{ item.label }}</div>
|
||||
</div>
|
||||
</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-menu>
|
||||
</q-btn>
|
||||
</q-td>
|
||||
<q-td
|
||||
v-for="col in props.cols"
|
||||
:key="col.name"
|
||||
|
|
@ -438,55 +487,7 @@ watch(
|
|||
{{ col.value ? col.value : "-" }}
|
||||
</div>
|
||||
</q-td>
|
||||
<q-td>
|
||||
<q-btn
|
||||
v-if="!store.isClosedRound"
|
||||
flat
|
||||
dense
|
||||
icon="mdi-dots-vertical"
|
||||
class="q-pa-none q-ml-xs"
|
||||
color="grey-13"
|
||||
size="12px"
|
||||
>
|
||||
<q-menu>
|
||||
<q-list dense style="min-width: 150px">
|
||||
<q-item
|
||||
v-for="(item, index) in store.roundCode !== 'SPECIAL' ? store.itemMenu.filter((x:any)=>x.type !== 'properties') :store.itemMenu.filter((x:any)=>x.type !== 'moveGroup' && x.type !== 'properties')"
|
||||
:key="index"
|
||||
clickable
|
||||
v-close-popup
|
||||
@click="
|
||||
item.type === 'edit'
|
||||
? onClickEdit(props.row.id, props.row.amount)
|
||||
: item.type === 'moveGroup'
|
||||
? onClickMovieGroup(props.row.id)
|
||||
: item.type === 'moveLevel'
|
||||
? onClickMoveLevel(
|
||||
props.row.id,
|
||||
props.row.type,
|
||||
props.row.isReserve,
|
||||
props.row.remark
|
||||
)
|
||||
: item.type === 'delete'
|
||||
? onClickDelete(props.row.id)
|
||||
: null
|
||||
"
|
||||
>
|
||||
<q-item-section>
|
||||
<div class="row items-center">
|
||||
<q-icon
|
||||
:color="item.color"
|
||||
size="17px"
|
||||
:name="item.icon"
|
||||
/>
|
||||
<div class="q-pl-md">{{ item.label }}</div>
|
||||
</div>
|
||||
</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-menu>
|
||||
</q-btn>
|
||||
</q-td>
|
||||
|
||||
</q-tr>
|
||||
</template>
|
||||
<template v-slot:pagination="scope">
|
||||
|
|
|
|||
|
|
@ -45,6 +45,33 @@ const props = defineProps({
|
|||
|
||||
/** ข้อมูล Table*/
|
||||
const columns = ref<QTableProps["columns"]>([
|
||||
{
|
||||
name: "posSalary",
|
||||
align: "center",
|
||||
label: "ประวัติตำแหน่ง/เงินเดือน",
|
||||
sortable: false,
|
||||
field: "posSalary",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
},
|
||||
{
|
||||
name: "discipline",
|
||||
align: "center",
|
||||
label: "วินัย",
|
||||
sortable: false,
|
||||
field: "discipline",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
},
|
||||
{
|
||||
name: "leave",
|
||||
align: "center",
|
||||
label: "การลา",
|
||||
sortable: false,
|
||||
field: "leave",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
},
|
||||
{
|
||||
name: "no",
|
||||
align: "left",
|
||||
|
|
@ -136,35 +163,12 @@ const columns = ref<QTableProps["columns"]>([
|
|||
style: "font-size: 14px",
|
||||
},
|
||||
|
||||
{
|
||||
name: "posSalary",
|
||||
align: "center",
|
||||
label: "ประวัติตำแหน่ง/เงินเดือน",
|
||||
sortable: false,
|
||||
field: "posSalary",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
},
|
||||
{
|
||||
name: "discipline",
|
||||
align: "center",
|
||||
label: "วินัย",
|
||||
sortable: false,
|
||||
field: "discipline",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
},
|
||||
{
|
||||
name: "leave",
|
||||
align: "center",
|
||||
label: "การลา",
|
||||
sortable: false,
|
||||
field: "leave",
|
||||
headerStyle: "font-size: 14px",
|
||||
style: "font-size: 14px",
|
||||
},
|
||||
|
||||
]);
|
||||
const visibleColumns = ref<string[]>([
|
||||
"discipline",
|
||||
"leave",
|
||||
"isSuspension",
|
||||
"no",
|
||||
"fullName",
|
||||
"posType",
|
||||
|
|
@ -175,9 +179,7 @@ const visibleColumns = ref<string[]>([
|
|||
"organization",
|
||||
"result",
|
||||
"posSalary",
|
||||
"discipline",
|
||||
"leave",
|
||||
"isSuspension",
|
||||
|
||||
]);
|
||||
|
||||
/** modalDialog*/
|
||||
|
|
@ -359,14 +361,64 @@ function onClickViewInfo(type: string, id: string) {
|
|||
>
|
||||
<template v-slot:header="props">
|
||||
<q-tr :props="props">
|
||||
<q-th auto-width />
|
||||
<q-th v-for="col in props.cols" :key="col.name" :props="props">
|
||||
<span class="text-weight-medium">{{ col.label }}</span>
|
||||
</q-th>
|
||||
<q-th auto-width />
|
||||
</q-tr>
|
||||
</template>
|
||||
<template v-slot:body="props">
|
||||
<q-tr :props="props" class="cursor-pointer">
|
||||
<q-td>
|
||||
<q-btn
|
||||
v-if="!store.isClosedRound"
|
||||
flat
|
||||
dense
|
||||
icon="mdi-dots-vertical"
|
||||
class="q-pa-none q-ml-xs"
|
||||
color="grey-13"
|
||||
size="12px"
|
||||
>
|
||||
<q-menu>
|
||||
<q-list dense style="min-width: 150px">
|
||||
<q-item
|
||||
v-for="(item, index) in store.roundCode !== 'SPECIAL'? store.itemMenu :store.itemMenu.filter((x:any)=>x.type !== 'moveGroup')"
|
||||
:key="index"
|
||||
clickable
|
||||
v-close-popup
|
||||
@click="
|
||||
item.type === 'edit'
|
||||
? onClickEdit(props.row.id, props.row.amount)
|
||||
: item.type === 'moveGroup'
|
||||
? onClickMovieGroup(props.row.id)
|
||||
: item.type === 'moveLevel'
|
||||
? onClickMoveLevel(
|
||||
props.row.id,
|
||||
props.row.type,
|
||||
props.row.isReserve
|
||||
)
|
||||
: item.type === 'delete'
|
||||
? onClickDelete(props.row.id)
|
||||
: item.type === 'properties'
|
||||
? onProperties(props.row)
|
||||
: null
|
||||
"
|
||||
>
|
||||
<q-item-section>
|
||||
<div class="row items-center">
|
||||
<q-icon
|
||||
:color="item.color"
|
||||
size="17px"
|
||||
:name="item.icon"
|
||||
/>
|
||||
<div class="q-pl-md">{{ item.label }}</div>
|
||||
</div>
|
||||
</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-menu>
|
||||
</q-btn>
|
||||
</q-td>
|
||||
<q-td v-for="col in props.cols" :key="col.name" :props="props">
|
||||
<div v-if="col.name === 'no'">
|
||||
{{
|
||||
|
|
@ -435,56 +487,7 @@ function onClickViewInfo(type: string, id: string) {
|
|||
{{ col.value ? col.value : "-" }}
|
||||
</div>
|
||||
</q-td>
|
||||
<q-td>
|
||||
<q-btn
|
||||
v-if="!store.isClosedRound"
|
||||
flat
|
||||
dense
|
||||
icon="mdi-dots-vertical"
|
||||
class="q-pa-none q-ml-xs"
|
||||
color="grey-13"
|
||||
size="12px"
|
||||
>
|
||||
<q-menu>
|
||||
<q-list dense style="min-width: 150px">
|
||||
<q-item
|
||||
v-for="(item, index) in store.roundCode !== 'SPECIAL'? store.itemMenu :store.itemMenu.filter((x:any)=>x.type !== 'moveGroup')"
|
||||
:key="index"
|
||||
clickable
|
||||
v-close-popup
|
||||
@click="
|
||||
item.type === 'edit'
|
||||
? onClickEdit(props.row.id, props.row.amount)
|
||||
: item.type === 'moveGroup'
|
||||
? onClickMovieGroup(props.row.id)
|
||||
: item.type === 'moveLevel'
|
||||
? onClickMoveLevel(
|
||||
props.row.id,
|
||||
props.row.type,
|
||||
props.row.isReserve
|
||||
)
|
||||
: item.type === 'delete'
|
||||
? onClickDelete(props.row.id)
|
||||
: item.type === 'properties'
|
||||
? onProperties(props.row)
|
||||
: null
|
||||
"
|
||||
>
|
||||
<q-item-section>
|
||||
<div class="row items-center">
|
||||
<q-icon
|
||||
:color="item.color"
|
||||
size="17px"
|
||||
:name="item.icon"
|
||||
/>
|
||||
<div class="q-pl-md">{{ item.label }}</div>
|
||||
</div>
|
||||
</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-menu>
|
||||
</q-btn>
|
||||
</q-td>
|
||||
|
||||
</q-tr>
|
||||
</template>
|
||||
<template v-slot:pagination="scope">
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue