fix: made due date in task datetime
This commit is contained in:
parent
76be5729b8
commit
f8114cd633
@ -59,7 +59,7 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"fieldname": "due_date",
|
"fieldname": "due_date",
|
||||||
"fieldtype": "Date",
|
"fieldtype": "Datetime",
|
||||||
"label": "Due Date"
|
"label": "Due Date"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@ -87,7 +87,7 @@
|
|||||||
],
|
],
|
||||||
"index_web_pages_for_search": 1,
|
"index_web_pages_for_search": 1,
|
||||||
"links": [],
|
"links": [],
|
||||||
"modified": "2024-01-19 21:55:42.654547",
|
"modified": "2024-02-08 12:04:00.955984",
|
||||||
"modified_by": "Administrator",
|
"modified_by": "Administrator",
|
||||||
"module": "FCRM",
|
"module": "FCRM",
|
||||||
"name": "CRM Task",
|
"name": "CRM Task",
|
||||||
|
|||||||
@ -154,8 +154,12 @@
|
|||||||
</div>
|
</div>
|
||||||
<div v-if="task.due_date" class="flex gap-2">
|
<div v-if="task.due_date" class="flex gap-2">
|
||||||
<CalendarIcon />
|
<CalendarIcon />
|
||||||
<Tooltip :text="dateFormat(task.due_date, 'ddd, MMM D, YYYY')">
|
<Tooltip
|
||||||
{{ dateFormat(task.due_date, 'D MMM') }}
|
:text="
|
||||||
|
dateFormat(task.due_date, 'ddd, MMM D, YYYY | hh:mm a')
|
||||||
|
"
|
||||||
|
>
|
||||||
|
{{ dateFormat(task.due_date, 'D MMM, hh:mm a') }}
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
</div>
|
</div>
|
||||||
<div class="flex items-center justify-center">
|
<div class="flex items-center justify-center">
|
||||||
@ -367,24 +371,24 @@
|
|||||||
</Tooltip>
|
</Tooltip>
|
||||||
</div>
|
</div>
|
||||||
<div class="flex gap-0.5">
|
<div class="flex gap-0.5">
|
||||||
<Tooltip text="Reply">
|
<Tooltip text="Reply">
|
||||||
<Button
|
<Button
|
||||||
variant="ghost"
|
variant="ghost"
|
||||||
class="text-gray-700"
|
class="text-gray-700"
|
||||||
@click="reply(activity.data)"
|
@click="reply(activity.data)"
|
||||||
>
|
>
|
||||||
<ReplyIcon class="h-4 w-4" />
|
<ReplyIcon class="h-4 w-4" />
|
||||||
</Button>
|
</Button>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
<Tooltip text="Reply All">
|
<Tooltip text="Reply All">
|
||||||
<Button
|
<Button
|
||||||
variant="ghost"
|
variant="ghost"
|
||||||
class="text-gray-700"
|
class="text-gray-700"
|
||||||
@click="reply(activity.data, true)"
|
@click="reply(activity.data, true)"
|
||||||
>
|
>
|
||||||
<ReplyAllIcon class="h-4 w-4" />
|
<ReplyAllIcon class="h-4 w-4" />
|
||||||
</Button>
|
</Button>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="text-sm leading-5 text-gray-600">
|
<div class="text-sm leading-5 text-gray-600">
|
||||||
|
|||||||
@ -4,16 +4,14 @@
|
|||||||
class="flex w-full [&>div:first-child]:w-full"
|
class="flex w-full [&>div:first-child]:w-full"
|
||||||
>
|
>
|
||||||
<template #target="{ togglePopover }">
|
<template #target="{ togglePopover }">
|
||||||
<input
|
<Input
|
||||||
readonly
|
readonly
|
||||||
type="text"
|
type="text"
|
||||||
:placeholder="placeholder"
|
:placeholder="placeholder"
|
||||||
:value="value && formatter ? formatter(value) : value"
|
:value="value && formatter ? formatter(value) : value"
|
||||||
@focus="!readonly ? togglePopover() : null"
|
@focus="!readonly ? togglePopover() : null"
|
||||||
:class="[
|
:class="inputClass"
|
||||||
'form-input block h-7 w-full cursor-pointer select-none rounded border-gray-400 text-sm placeholder-gray-500',
|
v-bind="$attrs"
|
||||||
inputClass,
|
|
||||||
]"
|
|
||||||
/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
<template #body="{ togglePopover }">
|
<template #body="{ togglePopover }">
|
||||||
|
|||||||
@ -17,17 +17,18 @@
|
|||||||
v-slot="{ column, item }"
|
v-slot="{ column, item }"
|
||||||
:row="row"
|
:row="row"
|
||||||
>
|
>
|
||||||
<div
|
<Tooltip
|
||||||
v-if="column.key === 'due_date'"
|
v-if="column.key === 'due_date'"
|
||||||
class="flex items-center gap-2 text-base"
|
class="flex items-center gap-2 truncate text-base"
|
||||||
|
:text="dateFormat(item, 'ddd, MMM D, YYYY | hh:mm a')"
|
||||||
>
|
>
|
||||||
<CalendarIcon />
|
<div>
|
||||||
<div v-if="item">
|
<CalendarIcon />
|
||||||
<Tooltip :text="dateFormat(item, 'ddd, MMM D, YYYY')">
|
|
||||||
{{ dateFormat(item, 'D MMM') }}
|
|
||||||
</Tooltip>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
<div v-if="item" class="truncate">
|
||||||
|
{{ dateFormat(item, 'D MMM, hh:mm a') }}
|
||||||
|
</div>
|
||||||
|
</Tooltip>
|
||||||
<ListRowItem v-else :item="item">
|
<ListRowItem v-else :item="item">
|
||||||
<template #prefix>
|
<template #prefix>
|
||||||
<div v-if="column.key === 'status'">
|
<div v-if="column.key === 'status'">
|
||||||
|
|||||||
@ -80,12 +80,13 @@
|
|||||||
</Tooltip>
|
</Tooltip>
|
||||||
</template>
|
</template>
|
||||||
</Link>
|
</Link>
|
||||||
<DatePicker
|
<DatetimePicker
|
||||||
class="datepicker w-36"
|
class="datepicker w-36"
|
||||||
v-model="_task.due_date"
|
icon-left="calendar"
|
||||||
|
:value="_task.due_date"
|
||||||
|
@change="(val) => (_task.due_date = val)"
|
||||||
placeholder="Due Date"
|
placeholder="Due Date"
|
||||||
input-class="border-none"
|
input-class="border-none"
|
||||||
:formatValue="(val) => val.split('-').reverse().join('-')"
|
|
||||||
/>
|
/>
|
||||||
<Dropdown :options="taskPriorityOptions(updateTaskPriority)">
|
<Dropdown :options="taskPriorityOptions(updateTaskPriority)">
|
||||||
<Button :label="_task.priority" class="w-full justify-between">
|
<Button :label="_task.priority" class="w-full justify-between">
|
||||||
@ -108,7 +109,8 @@ import UserAvatar from '@/components/UserAvatar.vue'
|
|||||||
import Link from '@/components/Controls/Link.vue'
|
import Link from '@/components/Controls/Link.vue'
|
||||||
import { taskStatusOptions, taskPriorityOptions } from '@/utils'
|
import { taskStatusOptions, taskPriorityOptions } from '@/utils'
|
||||||
import { usersStore } from '@/stores/users'
|
import { usersStore } from '@/stores/users'
|
||||||
import { TextEditor, Dropdown, Tooltip, DatePicker, call } from 'frappe-ui'
|
import DatetimePicker from '@/components/Controls/DatetimePicker.vue'
|
||||||
|
import { TextEditor, Dropdown, Tooltip, call } from 'frappe-ui'
|
||||||
import { ref, defineModel, watch, nextTick } from 'vue'
|
import { ref, defineModel, watch, nextTick } from 'vue'
|
||||||
import { useRouter } from 'vue-router'
|
import { useRouter } from 'vue-router'
|
||||||
|
|
||||||
|
|||||||
@ -1,5 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="flex items-center justify-between px-5 pb-4 pt-3">
|
<div class="flex items-center justify-between px-5 py-4">
|
||||||
<div class="flex items-center gap-2">
|
<div class="flex items-center gap-2">
|
||||||
<Dropdown :options="viewsDropdownOptions">
|
<Dropdown :options="viewsDropdownOptions">
|
||||||
<template #default="{ open }">
|
<template #default="{ open }">
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user