This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
|
post_functions [2018/04/12 08:15] root |
post_functions [2018/06/27 13:03] (current) root |
||
|---|---|---|---|
| Line 104: | Line 104: | ||
| issue.setCustomFieldValue(cfApprovalStatus," | issue.setCustomFieldValue(cfApprovalStatus," | ||
| } | } | ||
| + | </ | ||
| + | |||
| + | === Additional actions performed on Issue Clone post function === | ||
| + | |||
| + | <code java> | ||
| + | def cfD = customFieldManager.getCustomFieldObjects(issue).find {it.name == ' | ||
| + | def cfS = customFieldManager.getCustomFieldObjects(issue).find {it.name == 'Start Date'} | ||
| + | def cfE = customFieldManager.getCustomFieldObjects(issue).find {it.name == 'End Date'} | ||
| + | |||
| + | issue.setCustomFieldValue(cfD, | ||
| + | issue.setCustomFieldValue(cfS, | ||
| + | issue.setCustomFieldValue(cfE, | ||
| + | |||
| + | issue.summary = ' | ||
| + | |||
| + | import com.onresolve.scriptrunner.runner.util.UserMessageUtil | ||
| + | |||
| + | UserMessageUtil.success(' | ||
| + | </ | ||
| + | |||
| + | === Update Select List (Drop Down) field Status with value Waiting Approval === | ||
| + | |||
| + | <code java> | ||
| + | import com.atlassian.jira.component.ComponentAccessor | ||
| + | def cfSelect = ComponentAccessor.customFieldManager.getCustomFieldObjectByName(" | ||
| + | def cfConfig = cfSelect.getRelevantConfig(issue) | ||
| + | def value = ComponentAccessor.optionsManager.getOptions(cfConfig)? | ||
| + | it.toString() == ' | ||
| + | } | ||
| + | issue.setCustomFieldValue(cfSelect, | ||
| </ | </ | ||