diff --git a/models/tracker/src/index.ts b/models/tracker/src/index.ts index 8659aa81c5..17d0b72751 100644 --- a/models/tracker/src/index.ts +++ b/models/tracker/src/index.ts @@ -168,7 +168,7 @@ export class TIssue extends TDoc implements Issue { declare space: Ref - @Prop(TypeDate(true), tracker.string.Number) + @Prop(TypeDate(true), tracker.string.DueDate) dueDate!: Timestamp | null @Prop(TypeString(), tracker.string.Rank) diff --git a/plugins/tracker-resources/src/components/issues/EditIssue.svelte b/plugins/tracker-resources/src/components/issues/EditIssue.svelte index 51924c0ef4..0982d1e221 100644 --- a/plugins/tracker-resources/src/components/issues/EditIssue.svelte +++ b/plugins/tracker-resources/src/components/issues/EditIssue.svelte @@ -20,7 +20,16 @@ import { createQuery, getClient, UserBox } from '@anticrm/presentation' import { StyledTextBox } from '@anticrm/text-editor' import type { Issue, IssueStatus, Team } from '@anticrm/tracker' - import { Button, EditBox, IconDownOutline, IconEdit, IconMoreH, IconUpOutline, Label } from '@anticrm/ui' + import { + Button, + DatePresenter, + EditBox, + IconDownOutline, + IconEdit, + IconMoreH, + IconUpOutline, + Label + } from '@anticrm/ui' import { createEventDispatcher, onMount } from 'svelte' import tracker from '../../plugin' import IssuePresenter from './IssuePresenter.svelte' @@ -136,7 +145,7 @@ alwaysEdit bind:content={issue.description} placeholder={tracker.string.IssueDescriptionPlaceholder} - on:value={(evt) => change('description', evt.detail)} + on:value={(evt) => evt.detail !== issue?.description && change('description', evt.detail)} /> @@ -221,6 +230,21 @@ kind="link" /> + + {#if issue.dueDate !== null} +
+ +
+ + + change('dueDate', detail)} + /> +
+ {/if}
{:else}