forked from verdnatura/salix-front
fix: customer Risk icon color
This commit is contained in:
parent
0a239e8c43
commit
d52a0fdc7f
|
@ -37,6 +37,9 @@ const entityId = computed(() => {
|
||||||
|
|
||||||
const data = ref(useCardDescription());
|
const data = ref(useCardDescription());
|
||||||
const setData = (entity) => (data.value = useCardDescription(entity?.name, entity?.id));
|
const setData = (entity) => (data.value = useCardDescription(entity?.name, entity?.id));
|
||||||
|
const debtWarning = computed(() => {
|
||||||
|
return customer.value?.debt > customer.value?.credit ? 'negative' : 'primary';
|
||||||
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
|
@ -123,6 +126,14 @@ const setData = (entity) => (data.value = useCardDescription(entity?.name, entit
|
||||||
>
|
>
|
||||||
<QTooltip>{{ t('customer.card.notChecked') }}</QTooltip>
|
<QTooltip>{{ t('customer.card.notChecked') }}</QTooltip>
|
||||||
</QIcon>
|
</QIcon>
|
||||||
|
<QIcon
|
||||||
|
v-if="customer.debt > customer.credit"
|
||||||
|
name="vn:risk"
|
||||||
|
size="xs"
|
||||||
|
:color="debtWarning"
|
||||||
|
>
|
||||||
|
<QTooltip>{{ t('customer.card.hasDebt') }}</QTooltip>
|
||||||
|
</QIcon>
|
||||||
<QBtn
|
<QBtn
|
||||||
v-if="customer.unpaid"
|
v-if="customer.unpaid"
|
||||||
flat
|
flat
|
||||||
|
|
Loading…
Reference in New Issue