cancel
Showing results for 
Search instead for 
Did you mean: 

Aikau DateBoxControl

muralidharand
Star Contributor
Star Contributor
Hi experts,
I would like to disable the previous date selection in the Aikau DateBox Control.
Can someone please guide on this?

https://dojotoolkit.org/reference-guide/1.8/dijit/form/DateTextBox.html

Dojo date control support constraint.min and constraint.max properties to control the date selection, but I am not sure, how we can add this in Aikau DateTextBox controls.



    {
      name : "alfresco/forms/controls/DateTextBox",
      config : {
      
         label : "Completion Date",      
         name : "prop_expectedCompletionDate",
         requirementConfig : {
            initialValue : true
         },
         constraints
         {
             min: new Date()
         },
         value : currentDate
      }
    }


1 REPLY 1

ddraper
World-Class Innovator
World-Class Innovator
At the moment it doesn't look like the alfresco/forms/controls/DateTextBox widget is exposing that underlying Dojo form control configuration therefore it will not be possible for you to configure it as is on the latest release of Aikau (1.0.43 at the time of writing).

You have the following options:
1) Create a custom date control
2) Clone the Aikau GitHub repository, make the necessary changes yourself (ensuring that you also update the unit tests to test the new configuration options) and make a pull request to merge the changes
3) Raise a feature request on the Aikau JIRA project (https://issues.alfresco.com/jira/secure/RapidBoard.jspa?rapidView=187&projectKey=AKU&view=planning.n...) wait for the Aikau team to implement the feature request.