Yes, we face the fact that stories often outlast over multiple sprints. The reason may vary, sometimes the story is not finished, code review or testing is not done yet. Altough it might not be best practice by theory, we move the same story to the next sprint and set remaining estimate with the value of the amount we think its needed to finish.
We do not bother developers by logging their work on story level, but as a project manager I want to know how much effort it took till the story is closed. Even the estimate is not the correct value, it's a good average I can use for my reports.
Now, if a story runs over multiple sprints I need the sum of all estimates. For example:
Sprint 1: Orig. Estimate = 3d
Sprint 2: Remaining = 1d
Total: 4d
Is there any (simple) approach, script or automation which I can use to calculate those values and save them best in the story itself (custom field) so I can export those values out of Jira?