fix: remove unused link reference fields from EventModal component
This commit is contained in:
parent
abec857dd2
commit
0eb07f0242
@ -115,36 +115,6 @@
|
|||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="flex items-center">
|
|
||||||
<div class="text-base text-ink-gray-7 w-3/12">
|
|
||||||
{{ __('Link') }}
|
|
||||||
</div>
|
|
||||||
<div class="flex gap-2 w-9/12">
|
|
||||||
<FormControl
|
|
||||||
:class="_event.referenceDoctype ? 'w-20' : 'w-full'"
|
|
||||||
type="select"
|
|
||||||
:options="linkDoctypeOptions"
|
|
||||||
v-model="_event.referenceDoctype"
|
|
||||||
variant="outline"
|
|
||||||
:placeholder="__('Add Lead or Deal')"
|
|
||||||
@change="() => (_event.referenceDocname = '')"
|
|
||||||
/>
|
|
||||||
<Link
|
|
||||||
v-if="_event.referenceDoctype"
|
|
||||||
class="w-full"
|
|
||||||
v-model="_event.referenceDocname"
|
|
||||||
:doctype="_event.referenceDoctype"
|
|
||||||
variant="outline"
|
|
||||||
:placeholder="
|
|
||||||
__('Select {0}', [
|
|
||||||
_event.referenceDoctype == 'CRM Lead'
|
|
||||||
? __('Lead')
|
|
||||||
: __('Deal'),
|
|
||||||
])
|
|
||||||
"
|
|
||||||
/>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="flex items-start">
|
<div class="flex items-start">
|
||||||
<div class="text-base text-ink-gray-7 mt-1.5 w-3/12">
|
<div class="text-base text-ink-gray-7 mt-1.5 w-3/12">
|
||||||
{{ __('Attendees') }}
|
{{ __('Attendees') }}
|
||||||
@ -200,7 +170,6 @@
|
|||||||
</Dialog>
|
</Dialog>
|
||||||
</template>
|
</template>
|
||||||
<script setup>
|
<script setup>
|
||||||
import Link from '@/components/Controls/Link.vue'
|
|
||||||
import Attendee from '@/components/Calendar/Attendee.vue'
|
import Attendee from '@/components/Calendar/Attendee.vue'
|
||||||
import {
|
import {
|
||||||
Switch,
|
Switch,
|
||||||
@ -211,7 +180,6 @@ import {
|
|||||||
TimePicker,
|
TimePicker,
|
||||||
dayjs,
|
dayjs,
|
||||||
Dropdown,
|
Dropdown,
|
||||||
FormControl,
|
|
||||||
} from 'frappe-ui'
|
} from 'frappe-ui'
|
||||||
import { globalStore } from '@/stores/global'
|
import { globalStore } from '@/stores/global'
|
||||||
import { validateEmail } from '@/utils'
|
import { validateEmail } from '@/utils'
|
||||||
@ -376,8 +344,6 @@ function createEvent() {
|
|||||||
color: _event.value.color,
|
color: _event.value.color,
|
||||||
reference_doctype: props.doctype,
|
reference_doctype: props.doctype,
|
||||||
reference_docname: props.docname,
|
reference_docname: props.docname,
|
||||||
reference_doctype: _event.value.referenceDoctype || props.doctype,
|
|
||||||
reference_docname: _event.value.referenceDocname || props.docname,
|
|
||||||
event_participants: _event.value.event_participants,
|
event_participants: _event.value.event_participants,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -407,8 +373,6 @@ function updateEvent() {
|
|||||||
color: _event.value.color,
|
color: _event.value.color,
|
||||||
reference_doctype: props.doctype,
|
reference_doctype: props.doctype,
|
||||||
reference_docname: props.docname,
|
reference_docname: props.docname,
|
||||||
reference_doctype: _event.value.referenceDoctype || props.doctype,
|
|
||||||
reference_docname: _event.value.referenceDocname || props.docname,
|
|
||||||
event_participants: _event.value.event_participants,
|
event_participants: _event.value.event_participants,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -455,12 +419,6 @@ function deleteEvent() {
|
|||||||
|
|
||||||
const toOptions = computed(() => buildEndTimeOptions(_event.value.fromTime))
|
const toOptions = computed(() => buildEndTimeOptions(_event.value.fromTime))
|
||||||
|
|
||||||
const linkDoctypeOptions = [
|
|
||||||
{ label: '', value: '' },
|
|
||||||
{ label: __('Lead'), value: 'CRM Lead' },
|
|
||||||
{ label: __('Deal'), value: 'CRM Deal' },
|
|
||||||
]
|
|
||||||
|
|
||||||
const colors = Object.keys(colorMap).map((c) => ({
|
const colors = Object.keys(colorMap).map((c) => ({
|
||||||
label: c.charAt(0).toUpperCase() + c.slice(1),
|
label: c.charAt(0).toUpperCase() + c.slice(1),
|
||||||
value: colorMap[c].color,
|
value: colorMap[c].color,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user