fix(03): namePrefix & fallback customer img
This commit is contained in:
parent
b6890330fb
commit
eb7d853788
2 changed files with 8 additions and 4 deletions
|
|
@ -123,7 +123,6 @@ async function init() {
|
||||||
router.push('/customer-management');
|
router.push('/customer-management');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
flowStore.rotate();
|
flowStore.rotate();
|
||||||
}
|
}
|
||||||
onMounted(init);
|
onMounted(init);
|
||||||
|
|
@ -845,6 +844,7 @@ const emptyCreateDialog = ref(false);
|
||||||
>
|
>
|
||||||
<q-tab
|
<q-tab
|
||||||
name="employer"
|
name="employer"
|
||||||
|
class="text-capitalize"
|
||||||
id="tab-employer"
|
id="tab-employer"
|
||||||
@click="
|
@click="
|
||||||
() => {
|
() => {
|
||||||
|
|
@ -867,6 +867,7 @@ const emptyCreateDialog = ref(false);
|
||||||
<q-tab
|
<q-tab
|
||||||
name="employee"
|
name="employee"
|
||||||
id="tab-employee"
|
id="tab-employee"
|
||||||
|
class="text-capitalize"
|
||||||
@click="
|
@click="
|
||||||
() => {
|
() => {
|
||||||
currentPageEmployee = 1;
|
currentPageEmployee = 1;
|
||||||
|
|
@ -1627,6 +1628,7 @@ const emptyCreateDialog = ref(false);
|
||||||
customerFormState.customerImageUrl ||
|
customerFormState.customerImageUrl ||
|
||||||
`/images/customer-${customerFormData.customerType}-avartar.png`
|
`/images/customer-${customerFormData.customerType}-avartar.png`
|
||||||
"
|
"
|
||||||
|
:fallbackImg="`/images/customer-${customerFormData.customerType}-avartar.png`"
|
||||||
color="hsla(var(--pink-6-hsl)/1)"
|
color="hsla(var(--pink-6-hsl)/1)"
|
||||||
bg-color="hsla(var(--pink-6-hsl)/0.15)"
|
bg-color="hsla(var(--pink-6-hsl)/0.15)"
|
||||||
@view="customerFormState.imageDialog = true"
|
@view="customerFormState.imageDialog = true"
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
<script lang="ts" setup>
|
<script lang="ts" setup>
|
||||||
import { ref, watch } from 'vue';
|
import { ref, watch, capitalize } from 'vue';
|
||||||
import { QSelect } from 'quasar';
|
import { QSelect } from 'quasar';
|
||||||
import { selectFilterOptionRefMod } from 'stores/utils';
|
import { selectFilterOptionRefMod } from 'stores/utils';
|
||||||
import { getRole } from 'src/services/keycloak';
|
import { getRole } from 'src/services/keycloak';
|
||||||
|
|
@ -311,13 +311,15 @@ function formatCode(input: string | undefined, type: 'code' | 'number') {
|
||||||
dense
|
dense
|
||||||
outlined
|
outlined
|
||||||
:disable="!readonly"
|
:disable="!readonly"
|
||||||
:readonly="readonly"
|
readonly
|
||||||
hide-bottom-space
|
hide-bottom-space
|
||||||
class="col-12 col-md-2"
|
class="col-12 col-md-2"
|
||||||
:label="$t('customer.form.prefixName')"
|
:label="$t('customer.form.prefixName')"
|
||||||
for="input-prefix-name"
|
for="input-prefix-name"
|
||||||
:model-value="
|
:model-value="
|
||||||
namePrefix ? $t(`customer.form.prefix.${namePrefix}`) : '-'
|
readonly
|
||||||
|
? capitalize(namePrefix || '') || '-'
|
||||||
|
: capitalize(namePrefix || '')
|
||||||
"
|
"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue