This worked in JIRA 4.1.1, but not after upgrading to JIRA 5.2.10. In 4.1.1, I would go to the field configuration of a specific project. Within it, I would go to the Description field, click on edit, and type my java script. Then, whenever a new issue is created in this specific project, a default text would appear within the description box.
However, this is no longer working in JIRA 5.2.10. Any suggestions? Keep in mind, I want the description field to be populated with default text only for a particular project, not all projects. Thanks.
He need it in the specific project so it need to be in the field configuration of all the issue type wanted for that project, its easier that way.
yes i know that, we need to add condition, that can be done!!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello, in your specific field configuration just put this and it will work with jira 5.2
<script type="text/javascript">
AJS.$("#description").val("default value");
</script>
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.
Hi, this sounds like something I need too.
I have JIRA 6.4.12.
I don't understand what to do with that piece of code. Can you help me?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi guys,
There is Default Values plugin available for JIRA. It allows to define default value for description and number of other fields (per project and issue type):
https://marketplace.atlassian.com/plugins/com.gebsun.plugins.jira.defaultvalues
Regards,
Gebsun
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
try with this script by adding it in announcement banner for testing purpose
<script type="text/javascript"> function addDefaultValue() {
//need to add condition here
AJS.$("#description").val("default value"); } (function($) { AJS.toInit(function(){ // init on load addDefaultValue() }); JIRA.bind(JIRA.Events.NEW_CONTENT_ADDED, function (e, context) { // init on refresh addDefaultValue() }); })(AJS.$); </script>
i suggest to load it as webresource module in plugin, check this
https://answers.atlassian.com/questions/47843/strange-javascript-problem-in-create-screen
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.