The Atlassian Community Forums are currently in read-only mode. We will be relaunching on a new platform on September 22 (read more here). We apologize for the extended downtime. For concerns or questions, please email communitymanagers@atlassian.com. See you on the other side, on the new Atlassian Community Forums! :)

×

Forums

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

How to make Date field Readonly in confiform

Shah
January 30, 2024

Hi,

I have created 2 date fields similar to the date fields mentioned in the below link.

Need to make first date field set with current date and Read only so user may not be able to select the date. Is there a way to do it?

 

https://wiki.vertuna.com/display/TEST/Using+ConfiForms+Field+Definition+Rule+to+set+the+date+to+15+days+after+the+date+the+user+has+selected

 

1 answer

1 accepted

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

0 votes
Answer accepted
Alex Medved _ConfiForms_
Community Champion
January 30, 2024

Hi

May be to do something like this:

http://recordit.co/RCi7gnELna

Configuration:

<ac:structured-macro ac:macro-id="073af897-9a08-410e-a49a-d0fcf6eee6a8" ac:name="confiform" ac:schema-version="1">
<ac:parameter ac:name="formName">f</ac:parameter>
<ac:rich-text-body>
<ac:structured-macro ac:macro-id="691a7af9-9e03-49e2-aea5-bc8125359800" ac:name="confiform-entry-register" ac:schema-version="1">
<ac:parameter ac:name="presetValues">d=[entry._now]</ac:parameter>
<ac:parameter ac:name="type">Embedded</ac:parameter>
<ac:rich-text-body>
<p>
<br/>
</p>
</ac:rich-text-body>
</ac:structured-macro>
<p>
<ac:structured-macro ac:macro-id="c09d2978-3d36-4e75-9bf2-757141990229" ac:name="confiform-field-definition" ac:schema-version="1">
<ac:parameter ac:name="fieldName">d</ac:parameter>
<ac:parameter ac:name="fieldLabel">d</ac:parameter>
<ac:parameter ac:name="type">date</ac:parameter>
</ac:structured-macro>
</p>
<p>
<ac:structured-macro ac:macro-id="2ecfa27a-cb57-4705-9acb-e9460789536a" ac:name="confiform-field-definition-rules" ac:schema-version="1">
<ac:parameter ac:name="fieldName">d</ac:parameter>
<ac:parameter ac:name="action">Set field readonly</ac:parameter>
</ac:structured-macro>
</p>
</ac:rich-text-body>
</ac:structured-macro>
<p>
<br/>
</p>

 Alex

Shah
February 15, 2024

Thanks Alex for your usual support. 

TAGS
AUG Leaders

Atlassian Community Events