mirror of
https://github.com/makeplane/plane.git
synced 2026-01-30 10:23:26 -06:00
[WEB-3839] fix: peek overview description version history (#6912)
* fix: handle undefined created_at * chore: add created_by, updated_by updated_at and created_at fields in relation apis * chore: handle undefined date * fix: project typo --------- Co-authored-by: pablohashescobar <nikhilschacko@gmail.com>
This commit is contained in:
committed by
GitHub
parent
0ae57b49d2
commit
20132e7544
@@ -352,8 +352,19 @@ class IssueRelationSerializer(BaseSerializer):
|
||||
"state_id",
|
||||
"priority",
|
||||
"assignee_ids",
|
||||
"created_by",
|
||||
"created_at",
|
||||
"updated_at",
|
||||
"updated_by",
|
||||
]
|
||||
read_only_fields = [
|
||||
"workspace",
|
||||
"project",
|
||||
"created_by",
|
||||
"created_at",
|
||||
"updated_by",
|
||||
"updated_at",
|
||||
]
|
||||
read_only_fields = ["workspace", "project"]
|
||||
|
||||
|
||||
class RelatedIssueSerializer(BaseSerializer):
|
||||
@@ -383,8 +394,19 @@ class RelatedIssueSerializer(BaseSerializer):
|
||||
"state_id",
|
||||
"priority",
|
||||
"assignee_ids",
|
||||
"created_by",
|
||||
"created_at",
|
||||
"updated_by",
|
||||
"updated_at",
|
||||
]
|
||||
read_only_fields = [
|
||||
"workspace",
|
||||
"project",
|
||||
"created_by",
|
||||
"created_at",
|
||||
"updated_by",
|
||||
"updated_at",
|
||||
]
|
||||
read_only_fields = ["workspace", "project"]
|
||||
|
||||
|
||||
class IssueAssigneeSerializer(BaseSerializer):
|
||||
|
||||
@@ -232,7 +232,7 @@ export const InboxIssueMainContent: React.FC<Props> = observer((props) => {
|
||||
<DescriptionVersionsRoot
|
||||
className="flex-shrink-0"
|
||||
entityInformation={{
|
||||
createdAt: new Date(issue.created_at ?? ""),
|
||||
createdAt: issue.created_at ? new Date(issue.created_at) : new Date(),
|
||||
createdByDisplayName:
|
||||
inboxIssue.source === EInboxIssueSource.FORMS
|
||||
? "Intake Form user"
|
||||
|
||||
@@ -155,7 +155,7 @@ export const IssueMainContent: React.FC<Props> = observer((props) => {
|
||||
<DescriptionVersionsRoot
|
||||
className="flex-shrink-0"
|
||||
entityInformation={{
|
||||
createdAt: new Date(issue.created_at),
|
||||
createdAt: issue.created_at ? new Date(issue.created_at) : new Date(),
|
||||
createdByDisplayName: getUserDetails(issue.created_by ?? "")?.display_name ?? "",
|
||||
id: issueId,
|
||||
isRestoreDisabled: !isEditable || isArchived,
|
||||
|
||||
@@ -147,7 +147,7 @@ export const PeekOverviewIssueDetails: FC<IPeekOverviewIssueDetails> = observer(
|
||||
<DescriptionVersionsRoot
|
||||
className="flex-shrink-0"
|
||||
entityInformation={{
|
||||
createdAt: new Date(issue.created_at),
|
||||
createdAt: issue.created_at ? new Date(issue.created_at) : new Date(),
|
||||
createdByDisplayName: getUserDetails(issue.created_by ?? "")?.display_name ?? "",
|
||||
id: issueId,
|
||||
isRestoreDisabled: disabled || isArchived,
|
||||
|
||||
Reference in New Issue
Block a user