fix: newLead/newDeal dialog was not working

This commit is contained in:
Shariq Ansari 2023-12-13 16:28:29 +05:30
parent 37538bd267
commit 25300bcf54
2 changed files with 18 additions and 40 deletions

View File

@ -8,12 +8,10 @@
v-if="field.type === 'select'"
type="select"
:options="field.options"
v-model="newDeal[field.name]"
v-model="field.value"
>
<template v-if="field.name == 'status'" #prefix>
<IndicatorIcon
:class="getDealStatus(newDeal[field.name]).iconColorClass"
/>
<template v-if="field.prefix" #prefix>
<IndicatorIcon :class="field.prefix" />
</template>
</FormControl>
<FormControl
@ -95,21 +93,10 @@ const allFields = [
{
label: 'Salutation',
name: 'salutation',
type: 'select',
options: [
{
label: 'Mr',
value: 'Mr',
},
{
label: 'Ms',
value: 'Ms',
},
{
label: 'Mrs',
value: 'Mrs',
},
],
type: 'link',
doctype: 'Salutation',
placeholder: 'Salutation',
change: (data) => (props.newDeal.salutation = data),
},
{
label: 'First Name',
@ -154,6 +141,8 @@ const allFields = [
name: 'status',
type: 'select',
options: statusOptions('deal'),
value: props.newDeal.status || getDealStatus(props.newDeal.status).name,
prefix: getDealStatus(props.newDeal.status).iconColorClass,
},
{
label: 'Deal Owner',

View File

@ -8,12 +8,10 @@
v-if="field.type === 'select'"
type="select"
:options="field.options"
v-model="newLead[field.name]"
v-model="field.value"
>
<template v-if="field.name == 'status'" #prefix>
<IndicatorIcon
:class="getLeadStatus(newLead[field.name]).iconColorClass"
/>
<template v-if="field.prefix" #prefix>
<IndicatorIcon :class="field.prefix" />
</template>
</FormControl>
<FormControl
@ -95,21 +93,10 @@ const allFields = [
{
label: 'Salutation',
name: 'salutation',
type: 'select',
options: [
{
label: 'Mr',
value: 'Mr',
},
{
label: 'Ms',
value: 'Ms',
},
{
label: 'Mrs',
value: 'Mrs',
},
],
type: 'link',
placeholder: 'Salutation',
doctype: 'Salutation',
change: (data) => (props.newLead.salutation = data),
},
{
label: 'First Name',
@ -154,6 +141,8 @@ const allFields = [
name: 'status',
type: 'select',
options: statusOptions('lead'),
value: props.newLead.status || getLeadStatus(props.newLead.status).name,
prefix: getLeadStatus(props.newLead.status).iconColorClass,
},
{
label: 'Lead Owner',