refactor: debit note role check
Some checks failed
Spell Check / Spell Check with Typos (push) Failing after 6s
Some checks failed
Spell Check / Spell Check with Typos (push) Failing after 6s
This commit is contained in:
parent
8b933455d1
commit
963ed11073
2 changed files with 4 additions and 1 deletions
|
|
@ -22,7 +22,7 @@ import { useNavigator } from 'src/stores/navigator';
|
||||||
import useFlowStore from 'src/stores/flow';
|
import useFlowStore from 'src/stores/flow';
|
||||||
import { pageTabs, columns, hslaColors } from './constants';
|
import { pageTabs, columns, hslaColors } from './constants';
|
||||||
import { DebitNoteStatus, useDebitNote } from 'src/stores/debit-note';
|
import { DebitNoteStatus, useDebitNote } from 'src/stores/debit-note';
|
||||||
import { dialogWarningClose } from 'src/stores/utils';
|
import { canAccess, dialogWarningClose } from 'src/stores/utils';
|
||||||
import { useQuasar } from 'quasar';
|
import { useQuasar } from 'quasar';
|
||||||
import AdvanceSearch from 'src/components/shared/AdvanceSearch.vue';
|
import AdvanceSearch from 'src/components/shared/AdvanceSearch.vue';
|
||||||
|
|
||||||
|
|
@ -163,6 +163,7 @@ watch(
|
||||||
<FloatingActionButton
|
<FloatingActionButton
|
||||||
style="z-index: 999"
|
style="z-index: 999"
|
||||||
hide-icon
|
hide-icon
|
||||||
|
v-if="canAccess('related', 'edit')"
|
||||||
@click.stop="() => triggerCreateDebitNote()"
|
@click.stop="() => triggerCreateDebitNote()"
|
||||||
></FloatingActionButton>
|
></FloatingActionButton>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,7 @@ import { DebitNote, useDebitNote } from 'src/stores/debit-note';
|
||||||
|
|
||||||
import { columns } from './constants';
|
import { columns } from './constants';
|
||||||
import KebabAction from 'src/components/shared/KebabAction.vue';
|
import KebabAction from 'src/components/shared/KebabAction.vue';
|
||||||
|
import { canAccess } from 'src/stores/utils';
|
||||||
|
|
||||||
const debitNote = useDebitNote();
|
const debitNote = useDebitNote();
|
||||||
const { data, page, pageSize } = storeToRefs(debitNote);
|
const { data, page, pageSize } = storeToRefs(debitNote);
|
||||||
|
|
@ -80,6 +81,7 @@ const visible = computed(() =>
|
||||||
:id-name="`btn-kebab-${props.row.workName}`"
|
:id-name="`btn-kebab-${props.row.workName}`"
|
||||||
hide-toggle
|
hide-toggle
|
||||||
hide-edit
|
hide-edit
|
||||||
|
:hide-delete="!canAccess('related', 'edit')"
|
||||||
@edit="$emit('edit', props.row)"
|
@edit="$emit('edit', props.row)"
|
||||||
@delete="$emit('delete', props.row)"
|
@delete="$emit('delete', props.row)"
|
||||||
@view="$emit('view', props.row)"
|
@view="$emit('view', props.row)"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue