Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

How to hide the comment field only in the Edit screen and not the View screen

Tom L
June 11, 2018

I have a requirement to hide the comment field in the Edit screen.  I was able to hide it using the following Behaviours script:

def commentField = getFieldById(getFieldChanged())

if (getFieldScreen().name == "My Edit Screen" && !getActionName())

{ // check if on edit screen
commentField.setHidden(true)
}

But, the problem is that it is also hiding the comment field in the View screen, which I do not want.

For example, after I open/dismiss the Edit screen and clicked on the "Comment" button in the "Comments" tab in the View screen, the "Comment" button disappeared.  Also clicking on the "Comment" button under the Summary in the View screen has no affect.

If I refresh the browser, the "Comment" button appears again in the "Comments" tab, and clicking on it will display the comment field.

Anyone knows how to hide the comment field in the Edit screen without affecting the comment field in the View screen?

 

1 answer

1 accepted

0 votes
Answer accepted
Bahar Çağlar
Contributor
September 10, 2012

The Soulwing CAS client is officially deprecated. I will continue to provide minimal support for it for existing users. Those interested in CAS integration for Confluence, Jira, and Tomcat are strongly encouraged to use the official Jasig CAS client. The official client supports all of the functionality provided by the Soulwing CAS client, and many new features -- support for SAML, single sign-out, etc...

Here is the jasig documentation:

https://wiki.jasig.org/display/CASC/Configuring+Jira+with+JASIG+CAS+Client+for+Java+3.1?focusedCommentId=52953493#comment-52953493

Hope you will find it useful :)

Bahar Çağlar
Contributor
October 14, 2012

This question is related to that one.

https://answers.atlassian.com/questions/85715/cas-jira-5-1-integration?page=1#95424

"If you download their 3.3-SNAPSHOT of the code and build it yourself it works in jira 5.1"

Suggest an answer

Log in or Sign up to answer