EasyUI Forum
May 15, 2024, 08:11:08 AM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News:
 
   Home   Help Search Login Register  
Pages: [1]
  Print  
Author Topic: Implement restricted date  (Read 1121 times)
guruhyes
Newbie
*
Posts: 8


View Profile Email
« on: November 05, 2022, 07:31:06 AM »

I'm already success implement restricted date..
but my problem is, when i create restricted january only and now is already november,
the datebox view is showing november or current month,
my question in how can i set the datebox base on restricted date i choose , so when user click on datebox it will show january not november or current month ?

Thx for ur answer
Logged
jarry
Administrator
Hero Member
*****
Posts: 2264


View Profile Email
« Reply #1 on: November 06, 2022, 07:38:15 PM »

When the drop-down panel shows, you can set the calendar to the specified month days.
Code:
$('#dd').datebox({
    onShowPanel: function(){
        if (!$(this).datebox('getValue')){
            var c = $(this).datebox('calendar');
            c.calendar({
                year: 2023,
                month: 1
            })
        }
    }
})
Logged
guruhyes
Newbie
*
Posts: 8


View Profile Email
« Reply #2 on: November 10, 2022, 01:43:07 AM »

Its Works,
thx
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!