Is there any way we can restrict entering the time in parent issue ? I would like to time spent restrict, if subTask available.
We can use in workflow by entering the below property value but it will disable completely. It will not check for subTask available or not.
We need to allow if there is no subTask for issue.
Hi @Peter-Dave Sheehan Thanks you for the reply.
I tried with the following condition. I am specifying the project and issue type to narrow down the condition but it is not working. Log work is still visible and accepted logging the hours even subTask available or not.
If the user story has subtasks then log hours shouldn't be accepted at user story.
(jiraHelper.project?.key == "JIRAPOJ" && issue.issueType.name == "User Story" && issue.subTaskObjects.size() > 0)
The condition block in the "hide system or plugin ui" does not specify when you want to hide the item. It specifies when you want to show it. So you want to return True most of the time and False, when you want the item to be hidden.
Right now, you are returning True on a specific project when the issue has subtask.
It will be hidden for all other projects and situations. So you should put a ! before your parenthesis.
But also, I missed one item in the "Hide waht" (because it was disabled in my environment)... you need the following 2:
The first hides the menu item in the issue More menu.
The second hides the + sign on the time tracking panel on the right
Hi @Peter-Dave Sheehan I agree to keep ! before the condition and I have added log-work to disable from more menu. Even though it is not hiding log work option
!(jiraHelper.project?.key == "OP" && issue.issueType.name == "User Story" && issue.subTaskObjects.size() == 0)
Is anything wrong in my condition?
Look like I figured it out the condition. I used following condition to make it work. Thank you so much Peter for your help on this.
!(jiraHelper.project?.key == "OP" && issue.issueType.name == "User Story") && !(jiraHelper.project?.key == "OP" && issue.subTaskObjects.size() == 0)
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events