Giter Site home page Giter Site logo

Comments (16)

KennethanCeyer avatar KennethanCeyer commented on August 21, 2024

Hello @feldmarv!

Thank you for asking.

No we have not allowed date range picker features yet.

But i can update within this week.

Could you please tell me specific specs that you want to use?

Sorry about the sentence!

And if you have any questions, please send me any format. I will reply as soon as possible.

Thank you

from pg-calendar.

feldmarv avatar feldmarv commented on August 21, 2024

@KennethanCeyer
Thanks for your fast answer.
What we need is not exactely a date range picker. We just want to disable all days by a default (should be a setting). Disabled means its not clickable on UI and is marked as disabled. Then we load an array of dates (days). This dates should then be clickable.

Thanks in advance

from pg-calendar.

KennethanCeyer avatar KennethanCeyer commented on August 21, 2024

Hi @feldmarv,

I think i can make for your needs.

The update may will be on Oct 21 or 22.

I am sorry but, Please waiting few days for updating.

Thank you for your time 👍

from pg-calendar.

feldmarv avatar feldmarv commented on August 21, 2024

@KennethanCeyer
Thanks this sounds nice! Can you assure that its ready by the end of the week? Because i need to create some implementation.

from pg-calendar.

KennethanCeyer avatar KennethanCeyer commented on August 21, 2024

@feldmarv

Yes sure, maybe i will be working on next day.

from pg-calendar.

KennethanCeyer avatar KennethanCeyer commented on August 21, 2024

Hi @feldmarv

I have updated for your feature disabled dates.

disabled dates means you can give none selectable date by 'YYYY-MM-DD' format strings array.

If you start all dates inactive status on toggle type calendar,

Give reverse option to true.

You can check the feature on Demo site

You can use this feature by download v1.2.10 version.

Thank you.

from pg-calendar.

feldmarv avatar feldmarv commented on August 21, 2024

@KennethanCeyer
Wow thanks that looks cool!
So how to disable all dates by default. Is there an option called: disabledDates: true, and then enableDates: [2016-01-03, 2016-01-04] that will for example only enable this two dates?

from pg-calendar.

feldmarv avatar feldmarv commented on August 21, 2024

As I see the options
toggle: true,
reverse: true,
does disable the whole calendar which is great, but dates are still clickable. And how to enable now an array of dates?

thanks in advance

from pg-calendar.

KennethanCeyer avatar KennethanCeyer commented on August 21, 2024

@feldmarv

OMG I think i don't understand your needs.

I will make displayDates and readonly specs today.

I think you want to display only readable dates, is it correct?

Thank you for your time :)

from pg-calendar.

feldmarv avatar feldmarv commented on August 21, 2024

@KennethanCeyer
Thanks a lot for your answer.
Yes, on the calendar disabled dates are visible but not accessible (grey font). Enables dates are accessible and font is green.

from pg-calendar.

KennethanCeyer avatar KennethanCeyer commented on August 21, 2024

Hi @feldmarv

I have updated 1.2.11 version

enabledDates option is date array format like disabledDates.

This option makes all dates to disabled state and

only declared item in enabledDates will be enabled state (clickable date).

Thank you

from pg-calendar.

feldmarv avatar feldmarv commented on August 21, 2024

GREAT! This really is our Usecase!

One question: I load activeDays via ajax. Then the calendar just is empty. If I try to load the exact data without ajax directly hardcoded its working. Do we need a setter method maybe setEnabledDay. Or is there just an issue with loading order?

var activeDays = [];
$.ajax({
url: 'xyz',
dataType: 'json',
method: "get",
async: false,
cache: false,
success: function (data) {
$.each(data.dates, function (i, d) {
var date = new Date(d).toISOString().slice(0, 10);
activeDays.push(date);
});
}
});

$('#datetimepicker').pignoseCalendar({
select: getFreeAppointments,
enabledDates: [activeDays]
});

from pg-calendar.

KennethanCeyer avatar KennethanCeyer commented on August 21, 2024

I think you must to use like the snippet.

$('#datetimepicker').pignoseCalendar({
    select: getFreeAppointments,
    enabledDates: activeDays // It be changed. 
});

from pg-calendar.

feldmarv avatar feldmarv commented on August 21, 2024

true thanks! just this small typo.
Thanks for your GREAT work!

from pg-calendar.

abbu1 avatar abbu1 commented on August 21, 2024

I want to pass array of collection of dates to disabled when i press button how we can do in ngxbootstrap?

Thanks in advance

from pg-calendar.

mprince2k18 avatar mprince2k18 commented on August 21, 2024

here I solved in this way:

$init_date = new Date();

$current_date = $init_date.getFullYear() + '-' + ($init_date.getMonth() + 1) + '-' + $init_date.getDate();

$('.pig_calendar').pignoseCalendar({ minDate: $current_date });

from pg-calendar.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.