"projects": [
{
"name": "Sample data",
"key": "SUPPORT",
"issues": [
{
"status" : "Closed",
"reporter" : "admin",
"summary" : "Imported Request 3",
"comments": [
{
"body": "This is a comment from admin 5 days ago",
"author": "admin",
"created": "2012-08-31T17:59:02.161+0100"
},
{
"body": "Internal",
"author": "admin",
"properties":{"key":"sd.public.comment","value":{"internal":true}},
"visibility": {
"type": "role",
"value": "Administrators"
},
"created": "2012-08-31T17:59:02.161+0100"
}
]
}
]
}
]
}
How to import comments properties or visibility with Jira Json import tool?
Now this data ignored and create public comment.
Who can help with this.
The JSON importer does not support setting the comment visibility: https://jira.atlassian.com/browse/JRASERVER-64584
You will probably need to resort to database manipulation unless you can find another third party import tool that supports this.
Whether a comment is internal is determined by two properties "CommentProperty" & "sd.comment.property", if you run the following SQL query (entity_id is the comment ID):
SELECT * FROM entity_property where entity_id = 11111 AND property_key = 'sd.public.comment'
You should get two entries if it is an internal comment:
10000;"sd.comment.property";11111;"sd.public.comment";"2018-03-10 09:26:57.44+08";"2018-03-10 09:45:35.307+08";"{"internal":true}"
10001;"CommentProperty";11111;"sd.public.comment";"2018-03-10 09:26:57.351+08";"2018-03-10 09:56:33.188+08";"{"internal":true}"
As far as I am aware, "sd.comment.property" can be set via REST API http://<baseurl.com>/rest/api/2/comment/<comment_id>/properties/sd.public.comment/, but unfortunately not "CommentProperty".
so how do you set CommentProperty?! toggling the sd.public.comment doesn't actually work without both being set, so this is not helpful as an answer
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.