简体   繁体   English

bootstrap full calender不适用于day tab

[英]bootstrap full calender not working for day tab

My calendar is working properly. 我的日历工作正常。 But in day section it's not showing the events from start time to end time its showing on full day only. 但是在白天部分,它没有显示从开始时间到结束时间仅在全天显示的事件。

I am newbie here, help me in this, thanks in advance. 我是新手,请帮助我,提前谢谢。

<div id="fullCalModal"  class="modal fade">
        <div class="modal-dialog">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal"><span aria-hidden="true">×</span> <span class="sr-only">close</span></button>
                    <h4 id="modalTitle" style="text-align: center;" class="modal-title"></h4>
                </div>
               <h6>Description: </h6> <div id="modalBody" class="modal-body"></div><hr>
               <h6>Start Time: </h6><div id="starttime" class="modal-body"></div>
               <h6>End Time: </h6><div id="endtime" class="modal-body"></div>
                <div class="modal-footer">
                    <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
                </div>
            </div>
        </div>
    </div>                
    <script type="text/javascript">

                $(document).ready(function()
                {
                    var currentDate = '<?php echo date('Y-m-d'); ?>';
                    $('#custom-calendar').fullCalendar(
                      {
                        header:
                        {
                            left: 'prev,next today',
                            center: 'title',
                            right: 'month,agendaWeek,agendaDay',
                        },
                        defaultDate: currentDate,
                        businessHours: true, 
                        editable: true,
                        events: <?= $response ?>,
                        eventClick:  function(events) {
                        $('#fullCalModal').modal('show');
                        $('#modalTitle').html(events.title);
                        $('#modalBody').html(events.details);
                        $('#starttime').html(events.stime);
                        $('#endtime').html(events.etime);

                  }
                    });
                });
    </script>

Output 产量

In this image not showing start time to end time selection in day tab of my calendar. 在此图像中,未在我日历的日期选项卡中显示结束时间选择的开始时间。 I want a selection if start date is from 2 O'clock and end date is 5 O'clock. 如果开始日期是从2点开始,结束日期是5点,我想要一个选择。

不工作一天

need to set the allDay attribute to false , that it's usually true as configuration default; 需要将allDay属性设置为false ,它通常是配置默认值; from the docs: See Answer Here 来自文档:请参阅此处的答案

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM