...
Here is some SQL that does the job, including fixing the issuelinktype
if you hadn't already done so above.
Code Block |
---|
-- https://www.redradishtech.com/pages/viewpage.action?pageId=14483457 begin; create temp sequence issuelink_seq start with 99999; -- https://stackoverflow.com/questions/37057643/postgresql-starting-a-sequence-at-maxthe-column1 select setval('issuelink_seq', (select max(id::bigint)+1 from issuelink)); WITH jpolinks AS ( select entity_id AS child_id, (json_value::json->>'parent_id')::numeric AS parent_id from entity_property where entity_name='IssueProperty' and property_key='jpo-issue-properties') , newissuelinks AS ( select nextval('issuelink_seq') AS id , jpolinktype.id AS linktype , parent_id AS source , child_id as destination , null::numeric AS sequence from jpolinks CROSS JOIN (select id from issuelinktype where linkname='Parent-Child Link') jpolinktype where parent_id is not null -- the parent_id JSON is sometimes empty and not exists (select * From issuelink where source=parent_id and destination=child_id and issuelinktypelinktype=jpolinktype.id) -- don't double-insert ) insert into issuelink select * from newissuelinks; update sequence_value_item set seq_id=nextval('issuelink_seq') where seq_name='IssueLink'; update issuelinktype set pstyle=null where pstyle='jira_jpos_parent_child'; commit; |
After running the above, you will have to restart Jira for the changes to take effect.
...
then when you disable Portfolio, the Child issues section disappears, and you are where you want to be.
Addendum: post-uninstall log errors
After uninstalling Portfolio, you might find your atlassian-jira.log
file being filled with errors on each page load:
Code Block |
---|
2019-11-11 00:59:59,234 ajp-nio-127.0.0.100-8009-exec-4059 WARN jturner 59x3059696x3 56p7sr 10.36.2.100 /browse/CC-5353 [c.a.r.j.p.w.children.condition.ChildIssuesPanelVisibilityCondition] Exception when evaluating if child issues panel should be displayed.
com.atlassian.rm.common.env.EnvironmentPortfolio1NotAvailableException: com.atlassian.rm.common.bridges.api.plugins.PluginNotAvailableException
at com.atlassian.rm.common.env.license.JiraLicenseService.getLicenseInformation(JiraLicenseService.java:36)
at com.atlassian.rm.common.env.license.JiraLicenseService.isLicensed(JiraLicenseService.java:45)
at com.atlassian.rm.jpo.plugin.webpanels.children.condition.ChildIssuesPanelVisibilityCondition.isLicensed(ChildIssuesPanelVisibilityCondition.java:81)
at com.atlassian.rm.jpo.plugin.webpanels.children.condition.ChildIssuesPanelVisibilityCondition.shouldChildrenBeVisible(ChildIssuesPanelVisibilityCondition.java:68) at com.atlassian.rm.jpo.plugin.webpanels.children.condition.ChildIssuesPanelVisibilityCondition.shouldDisplay(ChildIssuesPanelVisibilityCondition.java:54)
at com.atlassian.plugin.web.DefaultWebInterfaceManager.filterFragmentsByCondition(DefaultWebInterfaceManager.java:154)
at com.atlassian.plugin.web.DefaultWebInterfaceManager.getDisplayableWebPanelDescriptors(DefaultWebInterfaceManager.java:117)
... 2 filtered
at java.lang.reflect.Method.invoke(Method.java:498) ... |
In Jira's Manage apps admin page you will find these two vestigial plugins:
Uninstall them and your Jira should be back to normal. Jira's plugin system lets plugin authors package reusable parts as separate plugins, but isn't smart enough to uninstall them when the parent plugin is uninstalled.