Code

Discussion on Caleran - Date Range Picker

Discussion on Caleran - Date Range Picker

By
Cart 627 sales

tpaksu supports this item

Supported

This author's response time can be up to 5 business days.

287 comments found.

I need to use this component with Angular2 “angular-cli” can help me

I didn’t use angular before but here it says you can use it by doing this:

http://stackoverflow.com/questions/30623825/how-to-use-jquery-with-angular2

Hi . I’m recently purchased your product. this is a great product but i have problem in mobile version about showing more than 1 calendar.

As per your offer in documentation at this point “Mobile versions only show 1 calendar. If you want it to support multiple calendars on mobile or inline support, let me know how it should be designed, and I’ll try to put it on the next release.”

I suggest to use display like at agoda.com on mobile view. it’s used scroll down display calendar.

Hello ginharja, thanks for your comment and your rating to the plugin. I’ll take it into account for the next release. But I can’t give you a date right now because I have other plugins in development.

Hi ginharja, can you check the latest version (1.2), I tried to implement the multiple calendar thing, can you check it?

Hi, great work on the script!

Is there an easy way to change the month/year?

Thank you, if you mean quick switching, no it doesn’t support that.

Hi munett, I’ve implemented the quick switching thing. Click on the month name or year in the new version (1.2). Can you try it?

great work! already purchased! many thanks!

hi tpaksu,

By default the value in field is today, it is possible to make only the calendar appear without having a default range selected and the value of the input is empty until the range is selected?

oninit: function(element) {
  var valueInput = $(".caleran-global").val();
  alert(valueInput);
  element.config.target.val('');
},

alert say Today-today rangue by default :(, if neccesary?

check like budgetplaces.com range calendar without default range

Can you try this:

$("#caleran-ex-1").caleran({ oninit: function(elem){ elem.config.target.val(""); }, onaftershow: function(elem){ if(elem.config.startDate.isSame(moment().startOf("day")) && elem.config.startDate.isSame(moment().startOf("day"))) elem.config.target.val(""); } });

Looks good! But when I change the language the calendar still shows Spanish strings btw;)

Is possible to set the input text value in blank by default, only placeholder?

Thanks

Yeah! but Override CSS -> .caleran-container .caleran-header { display: none !important; }

Ok, brilliant! CSS media query is one way to do it too.

Thanks for giving a rating to this plugin. I appreciate it.

How can Disable Header or Footer only in Desktop version?

Hi,

You need to use some javascript:

var options = {}; if(!is_mobile_check_here){ options.showHeader = false; } $(”.input”).caleran(options);

You can find the mobile checker here:

http://stackoverflow.com/questions/11381673/detecting-a-mobile-browser

Thanks!

Did you get it to work?

HI, your item is great!

We have some questions:

1. How can prevent select the same day in range, like budgetplaces.com range calendar.

2. We have a autocomplete input text, after you select item in suggest, we need calenran show.

I try this

$("#destiny").catcomplete({
  delay: 0,
  minLength: 3,
  source: autocomplete_url,
  select: function (e, ui) {
    //$("#checkin").datepicker('show'); // Open JqueryDatepicker IT'S OK
    var caleran = $("#caleran-ex-3").data("caleran"); // :( NO SHOW
    caleran.showDropdown();  // :( NO SHOW
  }
});

3. How can disable the months before today?

For days use: minDate: moment().subtract(0, “day”),

Yes, disable past months, that’s ok, but prevent select the same day in range is not posible with validation and return false;

Sorry, the event should be onbeforeselect. Here’s a working code

$("#caleran-ex-1").caleran({ onbeforeselect: function(elem,start,end){ if(end.isSame(start,"day")){ return false; } return true; } });

Did you try the code? what happened?

Rated 5 stars! great product and great support! Any chance you are adding a time picker? We are thinking of using this for another project but this one requires a date and time picker.

Thank you :) Do you want the time picker on this plugin or another seperate time picker plugin?

Hello all Caleran users, if you like the plugin, can you please rate it? Or give me some feedback about it? I wonder how it’s working out in the wild.

Hi I’m just bought your plugin and i have question – is there posibility to disable specific date ranges ? like in reservation calendars reserved periods of time which are not selectable

i need pass to calendar array of ranges to disable from selection, specific dates. and second question – is it moblie friendly ? responsive ? I have a feeling it is not

Hi, I was away for 5 days, I’m now back. How come that you decided it’s not responsive? I shared the landscape and portrait mobile views of the plugin? I’ll add the disabledRanges option to the next release.

I updated the code. You can check the documentation.

Keywords, disabledRanges and continuous option.

Examples included.

For all customers, I’ve pushed an approval request (v1.1.2) to envato, with a major fix on ranges. Thanks to @katspate most of the bugs were fixed. You’ll all be notified when the update is approved.

I’ll be away for 5 days, and I won’t be able to answer your questions until then. Sorry for that.

And don’t forget to review the plugin ;)

Hi tpaksu,

It seems the new update not fixing the “stopPropagation of undefined” issue, it still exist

Uncaught TypeError: Cannot read property ‘stopPropagation’ of undefined at e.cellClicked (..\..\js\caleran.js:526) at HTMLDivElement.dispatch (jquery.min.js:3) at Object.trigger (jquery.min.js:4) at HTMLDivElement.<anonymous> (jquery.min.js:4) at Function.each (jquery.min.js:2) at uikit.min.js:2 cellClicked @ ..\..\js\caleran.js:526 dispatch @ jquery.min.js:3 trigger @ jquery.min.js:4 (anonymous) @ jquery.min.js:4 each @ jquery.min.js:2 (anonymous) @ uikit.min.js:2

for locale: ‘id’ (indonesia) first show it works, but when clicking the range link (today. tomorrow) it shows incorrect date and day, ok I think I will use my own version

Cheers

hi tpaksu,

do you know how can I download the previous version of this plugin? I accidentally replaced the files with the new one. you can email it to me to erwin.yusrizal@gmail.com

I will merge the new methods showDropdown and hideDropdown and init by my self

Cheers Thanks

I’ve sent you a new version with the old version. Please try the new one first.

Hi,

I have purchased and implemented the calendar on my site. Its working nicely apart from the date selecting. Every date select sets both from and to dates to the same and no selecting hover state or classes being set.

You can see it here:

http://kea.webflow.io

Any ideas?

Not necessary now, can you download the latest update from here? It contains the latest fixes.

Thank you. It is working 100%. Great service!

Can you rate the plugin?

Are there turkish version? April = Nisan

Türkçe olarak kullanabiliyormuyuz kardeşim? Ocak şubat vs.

Ayrıca aşağıdaki ön tanımlı zamanlarda sorun var sanırım.Sorun= dil değişince bunların dili değişmiyor.

onları da configde değiştirebiliyorsunuz. O örnekte ben kullanıcının browser dilini al dediğim için öyle görünüyor. yoksa çoklu dil göstermek için genel kullanılan bir javascript dil kütüphanesine ihtiyaç olabilir.

http://rettica.com/caleran/docs/readme.html#custom-ranges

burada istediğiniz string’i ön tanımlı range olarak verebilirsiniz.

http://rettica.com/caleran/docs/readme.html#options

burada da applyLabel, cancelLabel, rangeLabel şeklinde 3 ayar var, onları türkçe yapabilirsiniz.

startOnMonday: true yaparsanız pazartesi günü ilk gün olur.

Hi tpaksu,

Sorry I don’t mean to be impatient but may I know how many days usually it’s approved by envato? because until today I don’t get any email from envato about the new update

Cheers

Usually it says up to 2 days. It’ll get approved soon I guess.

The plugin & the documentation is now updated.

Hi, where can I find onInitiate function or something like that which I will need to fire any action from the initiate ?

The new version includes an [oninit] event. FYI.

Great to hear that, you are a genius :)

You’re welcome ;)

Hi I’m just bought your plugin

It has bug with jQuery v3, line 200

this.container.find(”.caleran-title”).size() > 0

$.size() is removed since v3, my temp fix I replace with .length

Thanks

In the upcoming version there will be a showDropdown() and hideDropdown() methods, you can bind the element’s focus & blur events.

Can you review the plugin please?

Can you try the uikit problem and the locale problem with the new version? They should be fixed in this release.

Is it possible to disable all days other than Wednesday’s within the calendar so that only Wednesday’s can be selected?

Hi again,

The feature you want needs an event binding in code, will be added in next release, but with some hacking, you can do it like this:

https://gist.github.com/tpaksu/854aa96e6506509a6b7b5077e200d5bf

The new version includes an example in the documentation. You can convert the workaround to that. keyword: “disabledDays” option.

If you want any feature to be added, ask me and I’ll put it in the next version.

Hi, $(”#caleran”).caleran({format:moment().format(“DD MMM YYYY”)}); returns a garbage value for the month. Please check.

Also, please send a sample to retrieve both dates separately. Thank you. Jay

Hi,

You need to use the format like this:

$(”#caleran”).caleran({ format: “DD MMM YYYY” });

And for seperate values:

var caleranInstance = $(”#caleran”).data(“caleran”); var startDate = caleranInstance.config.startDate; var endDate = caleranInstance.config.endDate;

They will return as momentjs instances, and you can format them any way you want.

Is your problem solved? Can you give some feedback?

by
by
by
by
by
by

Tell us what you think!

We'd like to ask you a few questions to help improve CodeCanyon.

Sure, take me to the survey