New component DatePicker - SelectionMode (6.2.14)

UI Components for JSF
Post Reply
majulvez
Posts: 14
Joined: 26 Jan 2017, 17:16

11 Jan 2019, 15:05

Hi all,

is there a way to set up the new component datePicker in order to allow selectionMode="multiple" but only allow select two dates?

Thanks
Best regards

User avatar
Melloware
Posts: 1119
Joined: 22 Apr 2013, 15:48

12 Jan 2019, 15:51

Yes maxDateCount="2"

Code: Select all

<attribute>
            <description><![CDATA[Maximum number of selectable dates in multiple mode.]]></description>
            <name>maxDateCount</name>
            <required>false</required>
            <type>java.lang.Integer</type>
            <defaultValue>java.lang.Integer.MAX_VALUE</defaultValue>
        </attribute>
PrimeFaces Extensions Developer
GitHub Profile: https://github.com/melloware
PrimeFaces Elite 6.2.19 / PF Extensions 6.2.10

majulvez
Posts: 14
Joined: 26 Jan 2017, 17:16

14 Jan 2019, 22:53

Thanks!
Melloware wrote:
12 Jan 2019, 15:51
Yes maxDateCount="2"

Code: Select all

<attribute>
            <description><![CDATA[Maximum number of selectable dates in multiple mode.]]></description>
            <name>maxDateCount</name>
            <required>false</required>
            <type>java.lang.Integer</type>
            <defaultValue>java.lang.Integer.MAX_VALUE</defaultValue>
        </attribute>

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 5 guests