How to find out the Date CustomField value has changed in Jira Postscript function.

SRIDHAR March 20, 2013

I have a custom field of type Date Picker. This date picker decides to which platform the issue is moved to. we have 4 platforms (dev, test, uat, prod). If the DatePicker value is not null i have a post script to create subtask for the platform On Create Transition. I want to check if the DatePicker value is changed/updated on CustomEdit Screen to write a post-function.

We can move the issue directly to 2 platforms and it creates 2 subtasks. Each platform has datepicker field. We are restricted to create only 1 subtask per platform and this should be generated based on the value of the Datepicker Field on create Transition or CustomEditTransition. So each issue can have any number of subtasks but limited to only 1 subtask per platform that are created from postfunction.

My edit screen has only comment box. where as the CustomEdit screen has the DatePicker Field and both the screens are part of same issue type using same workflow.

I just want to find out if the Datepicker value is same on Create and while Editing the issue on CustomEdit Screen. If the Datepicker is same then i don't want to create a subtask however if there is a change then i want to decide whether to use the existing subtask or create a new subtask.

2 answers

0 votes
Yossi Zinger May 1, 2013

You can try using the Behavior plugin, which lets you run a server-side script if when the field value is changed.

0 votes
RambanamP
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 20, 2013

you can't add postfunction to edit screen, if you want to edit the date picker field then add new intermediate workflow action(some thing like "Update target date") with the date field and configure postfunction to this transition.

remove the date field from edit screen.

I think it should work for you..

SRIDHAR March 20, 2013

we cannot remove the date from edit screen. we give always user to change the date and it is part of our requirements.

RambanamP
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 21, 2013

you need to remove from edit screen but you are providing option to edit through workflow action in all states

SRIDHAR March 21, 2013

My edit screen has only comment box. where as the CustomEdit screen has the DatePicker Field and both the screens are part of same issue type using same workflow.

Suggest an answer

Log in or Sign up to answer