refactor: ตรวจสอบเงื่อนไขการกด
This commit is contained in:
parent
015673032b
commit
99e26e4ad2
1 changed files with 7 additions and 21 deletions
|
|
@ -987,11 +987,12 @@ watch(locale, () => {
|
||||||
<q-tr
|
<q-tr
|
||||||
:class="{
|
:class="{
|
||||||
'app-text-muted': props.row.status === 'INACTIVE',
|
'app-text-muted': props.row.status === 'INACTIVE',
|
||||||
|
'cursor-pointer': props.row._count.branch !== 0,
|
||||||
}"
|
}"
|
||||||
:props="props"
|
:props="props"
|
||||||
@click="
|
@click="
|
||||||
() => {
|
() => {
|
||||||
if (props.row.isHeadOffice) {
|
if (props.row.isHeadOffice && props.row._count.branch !==0) {
|
||||||
fieldSelectedBranch.value = '';
|
fieldSelectedBranch.value = '';
|
||||||
inputSearch = '';
|
inputSearch = '';
|
||||||
currentHq = {
|
currentHq = {
|
||||||
|
|
@ -1059,25 +1060,7 @@ watch(locale, () => {
|
||||||
}}
|
}}
|
||||||
</q-td>
|
</q-td>
|
||||||
<q-td>
|
<q-td>
|
||||||
<q-btn
|
|
||||||
icon="mdi-eye-outline"
|
|
||||||
size="sm"
|
|
||||||
dense
|
|
||||||
round
|
|
||||||
flat
|
|
||||||
@click.stop="
|
|
||||||
() => {
|
|
||||||
triggerEdit(
|
|
||||||
'drawer',
|
|
||||||
props.row.id,
|
|
||||||
props.row.isHeadOffice
|
|
||||||
? 'headOffice'
|
|
||||||
: 'subBranch',
|
|
||||||
props.row.code,
|
|
||||||
);
|
|
||||||
}
|
|
||||||
"
|
|
||||||
/>
|
|
||||||
|
|
||||||
<q-btn
|
<q-btn
|
||||||
icon="mdi-dots-vertical"
|
icon="mdi-dots-vertical"
|
||||||
|
|
@ -1240,9 +1223,12 @@ watch(locale, () => {
|
||||||
<div class="col-12 col-md-6">
|
<div class="col-12 col-md-6">
|
||||||
<BranchCard
|
<BranchCard
|
||||||
:id="`branch-card-${props.row.name}`"
|
:id="`branch-card-${props.row.name}`"
|
||||||
|
:class="{
|
||||||
|
'cursor-pointer': props.row._count.branch !== 0,
|
||||||
|
}"
|
||||||
@click="
|
@click="
|
||||||
() => {
|
() => {
|
||||||
if (props.row.isHeadOffice) {
|
if (props.row.isHeadOffice && props.row._count.branch !==0) {
|
||||||
fieldSelectedBranch.value = '';
|
fieldSelectedBranch.value = '';
|
||||||
inputSearch = '';
|
inputSearch = '';
|
||||||
currentHq = {
|
currentHq = {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue