Okay
  Public Ticket #867250
angularjs datepicker on modal
Closed

Comments

  •  2
    Zulfy started the conversation

    Hi

    Currently I am developing an application using xenon with angularjs. I have problem to show date picker on modal. Do you have an example for it ?

    Yours sincerely

    Zulfy Adi Haryanto

  •  2
    Rodolfo replied

    Up.

    Have solution?

  • [deleted] replied

    Hi Rodolfo,

    Please execute this code when you open modal (callback):

    $(".datepicker").each(function(i, el)
    {
    var $this = $(el),
    opts = {
    format : attrDefault($this, 'format', 'mm/dd/yyyy'),
    startDate : attrDefault($this, 'startDate', ''),
    endDate : attrDefault($this, 'endDate', ''),
    daysOfWeekDisabled : attrDefault($this, 'disabledDays', ''),
    startView : attrDefault($this, 'startView', 0),
    },
    $n = $this.next(),
    $p = $this.prev();

    $this.datepicker(opts);
    });

    This should work for you.