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 { pageTabs, columns, hslaColors } from './constants';
|
||||
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 AdvanceSearch from 'src/components/shared/AdvanceSearch.vue';
|
||||
|
||||
|
|
@ -163,6 +163,7 @@ watch(
|
|||
<FloatingActionButton
|
||||
style="z-index: 999"
|
||||
hide-icon
|
||||
v-if="canAccess('related', 'edit')"
|
||||
@click.stop="() => triggerCreateDebitNote()"
|
||||
></FloatingActionButton>
|
||||
|
||||
|
|
|
|||
|
|
@ -6,6 +6,7 @@ import { DebitNote, useDebitNote } from 'src/stores/debit-note';
|
|||
|
||||
import { columns } from './constants';
|
||||
import KebabAction from 'src/components/shared/KebabAction.vue';
|
||||
import { canAccess } from 'src/stores/utils';
|
||||
|
||||
const debitNote = useDebitNote();
|
||||
const { data, page, pageSize } = storeToRefs(debitNote);
|
||||
|
|
@ -80,6 +81,7 @@ const visible = computed(() =>
|
|||
:id-name="`btn-kebab-${props.row.workName}`"
|
||||
hide-toggle
|
||||
hide-edit
|
||||
:hide-delete="!canAccess('related', 'edit')"
|
||||
@edit="$emit('edit', props.row)"
|
||||
@delete="$emit('delete', props.row)"
|
||||
@view="$emit('view', props.row)"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue