fix: set lead_owner & deal_owner as default field in lead/deal detail section
This commit is contained in:
parent
da406b4e01
commit
fc0b19ff0a
@ -14,6 +14,7 @@
|
|||||||
"close_date",
|
"close_date",
|
||||||
"probability",
|
"probability",
|
||||||
"next_step",
|
"next_step",
|
||||||
|
"deal_owner",
|
||||||
"contacts_tab",
|
"contacts_tab",
|
||||||
"email",
|
"email",
|
||||||
"mobile_no",
|
"mobile_no",
|
||||||
@ -21,7 +22,6 @@
|
|||||||
"others_tab",
|
"others_tab",
|
||||||
"naming_series",
|
"naming_series",
|
||||||
"status",
|
"status",
|
||||||
"deal_owner",
|
|
||||||
"section_break_eepu",
|
"section_break_eepu",
|
||||||
"lead",
|
"lead",
|
||||||
"column_break_bqvs",
|
"column_break_bqvs",
|
||||||
@ -212,7 +212,7 @@
|
|||||||
],
|
],
|
||||||
"index_web_pages_for_search": 1,
|
"index_web_pages_for_search": 1,
|
||||||
"links": [],
|
"links": [],
|
||||||
"modified": "2023-12-26 15:49:52.597014",
|
"modified": "2023-12-28 11:40:16.934256",
|
||||||
"modified_by": "Administrator",
|
"modified_by": "Administrator",
|
||||||
"module": "FCRM",
|
"module": "FCRM",
|
||||||
"name": "CRM Deal",
|
"name": "CRM Deal",
|
||||||
|
|||||||
@ -15,6 +15,7 @@
|
|||||||
"industry",
|
"industry",
|
||||||
"job_title",
|
"job_title",
|
||||||
"source",
|
"source",
|
||||||
|
"lead_owner",
|
||||||
"person_tab",
|
"person_tab",
|
||||||
"salutation",
|
"salutation",
|
||||||
"first_name",
|
"first_name",
|
||||||
@ -30,7 +31,6 @@
|
|||||||
"phone",
|
"phone",
|
||||||
"column_break_dbsv",
|
"column_break_dbsv",
|
||||||
"status",
|
"status",
|
||||||
"lead_owner",
|
|
||||||
"no_of_employees",
|
"no_of_employees",
|
||||||
"annual_revenue",
|
"annual_revenue",
|
||||||
"image",
|
"image",
|
||||||
@ -275,7 +275,7 @@
|
|||||||
"image_field": "image",
|
"image_field": "image",
|
||||||
"index_web_pages_for_search": 1,
|
"index_web_pages_for_search": 1,
|
||||||
"links": [],
|
"links": [],
|
||||||
"modified": "2023-12-26 15:45:43.715140",
|
"modified": "2023-12-28 11:39:47.573673",
|
||||||
"modified_by": "Administrator",
|
"modified_by": "Administrator",
|
||||||
"module": "FCRM",
|
"module": "FCRM",
|
||||||
"name": "CRM Lead",
|
"name": "CRM Lead",
|
||||||
|
|||||||
@ -8,7 +8,9 @@
|
|||||||
<div class="w-[106px] shrink-0 text-sm text-gray-600">
|
<div class="w-[106px] shrink-0 text-sm text-gray-600">
|
||||||
{{ field.label }}
|
{{ field.label }}
|
||||||
</div>
|
</div>
|
||||||
<div class="grid min-h-[28px] flex-1 text-base items-center overflow-hidden">
|
<div
|
||||||
|
class="grid min-h-[28px] flex-1 items-center overflow-hidden text-base"
|
||||||
|
>
|
||||||
<FormControl
|
<FormControl
|
||||||
v-if="
|
v-if="
|
||||||
[
|
[
|
||||||
@ -40,6 +42,25 @@
|
|||||||
:debounce="500"
|
:debounce="500"
|
||||||
@change.stop="emit('update', field.name, $event.target.value)"
|
@change.stop="emit('update', field.name, $event.target.value)"
|
||||||
/>
|
/>
|
||||||
|
<Link
|
||||||
|
v-else-if="['lead_owner', 'deal_owner'].includes(field.name)"
|
||||||
|
class="form-control"
|
||||||
|
:value="getUser(data[field.name]).full_name"
|
||||||
|
doctype="User"
|
||||||
|
@change="(data) => emit('update', field.name, data)"
|
||||||
|
>
|
||||||
|
<template #prefix>
|
||||||
|
<UserAvatar class="mr-1.5" :user="data[field.name]" size="sm" />
|
||||||
|
</template>
|
||||||
|
<template #item-prefix="{ option }">
|
||||||
|
<UserAvatar class="mr-1.5" :user="option.value" size="sm" />
|
||||||
|
</template>
|
||||||
|
<template #item-label="{ option }">
|
||||||
|
<Tooltip :text="option.value">
|
||||||
|
{{ getUser(option.value).full_name }}
|
||||||
|
</Tooltip>
|
||||||
|
</template>
|
||||||
|
</Link>
|
||||||
<Link
|
<Link
|
||||||
v-else-if="field.type === 'link'"
|
v-else-if="field.type === 'link'"
|
||||||
class="form-control"
|
class="form-control"
|
||||||
@ -78,6 +99,8 @@
|
|||||||
<script setup>
|
<script setup>
|
||||||
import ArrowUpRightIcon from '@/components/Icons/ArrowUpRightIcon.vue'
|
import ArrowUpRightIcon from '@/components/Icons/ArrowUpRightIcon.vue'
|
||||||
import Link from '@/components/Controls/Link.vue'
|
import Link from '@/components/Controls/Link.vue'
|
||||||
|
import UserAvatar from '@/components/UserAvatar.vue'
|
||||||
|
import { usersStore } from '@/stores/users'
|
||||||
import { FormControl, Tooltip } from 'frappe-ui'
|
import { FormControl, Tooltip } from 'frappe-ui'
|
||||||
import { defineModel } from 'vue'
|
import { defineModel } from 'vue'
|
||||||
|
|
||||||
@ -88,6 +111,8 @@ const props = defineProps({
|
|||||||
},
|
},
|
||||||
})
|
})
|
||||||
|
|
||||||
|
const { getUser } = usersStore()
|
||||||
|
|
||||||
const emit = defineEmits(['update'])
|
const emit = defineEmits(['update'])
|
||||||
|
|
||||||
const data = defineModel()
|
const data = defineModel()
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user