Hi
I currently have 2 projects. Project A is a Service Project and project B is a Business project.
I have a couple of basic automation rules in place.
I need to copy the worklog from project B to project A using Automation.
I need some assistance with this as I am new to Automation and can cope with the basiscs.
Any assistance would be appreciated.
Hello @Otto Van Straaten ,
Using the work logged or field changed to trigger with the values for the work log, the entries for work logs are independently stored item are not tracked in Jira as a field change history item due to how the work log is stored as a specialized item apposed to a direct field value.
So to get the time log entered into the rule you need to create a variable to store the value you want to pass to the other issues.
This can be achieved with a global automation rule, and inputting a {{Create Variable}} action to store the work log item to be reused for the follow-up actions within the linked issues. and you can use an automation rule like this:
Regards,
Earl
Hi Earl
This works great thank you.
The only issue that I have picked up is that whenever the time is logged against the linked issue the time spent is not correct.
When time is logged the first time both issues have the exact same time spent.
When time is logged a second time it adds the original value plus the new time logged, e.g. I logged 5 mins of work in project B and the time logged is 5 mins in project A.
When I log another 5 mins in project B (total time logged 10 mins) the time logged in project A is 15min.
Is there a way around this?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
HI @Otto Van Straaten ,
I was not able to get this behavior to trigger in my test instance, so i'm wondering how do you have the rule configured, and what are the link types on the two issues used for the trigger?
I am wondering if the rule is getting triggered on multiple issue link types between the two issues, i.e. if you have both "blocks" and "related to" the rule might be triggering for each link.
Alternatively, if the rule might be getting triggered on the issue by the rule editing the worklog, so it does a double edit, check the rule details and make sure that the option for "Allow rule Trigger: Check to allow other rule actions to trigger this rule. Only enable this if you need this rule to execute in response to another rule." is unchecked so that rule does not trigger itself reciprocally.
Let me know what you find.
Regards,
Earl
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Earl McCutcheon Thank you for providing such a simplistic solution, I've been racking my brain for days trying to get this automation to function properly. However, I'm getting the same issue as @Otto Van Straaten stated. I checked all the items you recommended and I'm only using 'relates to' and I've had the 'Allow other rule...' unselected. I also tried only using the automation for updated work logged operations and that disabled the automation completely. I'm SO close to getting this automation to work the way I need, do you have any other suggestions to make the aggregate calculation on the linked issue correct?
Use Case: 1 Issue in Project A has many issues linked from Project B. The original estimate is entered in Project A for contractual hours. Original estimates in project B are from estimates for completion of issue. We would like work logged for all issues in Project B to aggregate into logged work for Project A.
Thank you,
Christine
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Try {{worklog.timespent}} as a smartvalue, rather than {{issue.worklog.timespent}}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Otto Van Straaten
It is possible to set worklogs on an issue using automation, by using smart values and setting the JSON values in an issues 'Additional Fields' section (see https://support.atlassian.com/jira-software-cloud/docs/advanced-field-editing-json/#field-syntax-examples for some examples of this). However, I am not sure how this automation would work, as it is expecting a trigger from an event related to an issue. What event would you be expecting to fire off your rule?
Cheers
Sam
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Sam Harding
Thank you for the advice.
I finally got it working using Edit issue fields.
I am now struggling to get the worklog comments moved over to the linked issue.
Do you have any advise?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello.
This works when time is logged the first time, but if I edit the time in the original issue, in the linked issue duplicate the time.
Any idea how to control that? Thks,
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.