[WEB-848] fix: issue with parent child relation not being removed parent select dropwdown. (#4120)

This commit is contained in:
Prateek Shourya 2024-04-04 14:24:01 +05:30 committed by GitHub
parent 840bc51537
commit 4cba7ff2f5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -684,15 +684,21 @@ export const IssueFormRoot: FC<IssueFormProps> = observer((props) => {
<CustomMenu.MenuItem className="!p-1" onClick={() => setParentIssueListModalOpen(true)}> <CustomMenu.MenuItem className="!p-1" onClick={() => setParentIssueListModalOpen(true)}>
Change parent issue Change parent issue
</CustomMenu.MenuItem> </CustomMenu.MenuItem>
<Controller
control={control}
name="parent_id"
render={({ field: { onChange } }) => (
<CustomMenu.MenuItem <CustomMenu.MenuItem
className="!p-1" className="!p-1"
onClick={() => { onClick={() => {
setValue("parent_id", null); onChange(null);
handleFormChange(); handleFormChange();
}} }}
> >
Remove parent issue Remove parent issue
</CustomMenu.MenuItem> </CustomMenu.MenuItem>
)}
/>
</> </>
</CustomMenu> </CustomMenu>
) : ( ) : (