【问题标题】:Is it possible to have two gridviews for dhtmlx scheduler?dhtmlx调度程序是否可以有两个gridviews?
【发布时间】:2015-05-05 15:00:40
【问题描述】:

我正在尝试使用 dhtmlx 调度程序库显示两个网格视图。我们使用调度程序的方式是让员工可以退出。现在,我们可以将其视为月视图,但我们也希望拥有日视图。

我能够创建网格,但是当我尝试单击按钮时,它不会显示当日报告。

这是一个代码sn-p

                    scheduler.locale.labels.grid_tab = "Month";

                    scheduler.createGridView({
                       name:"grid",
                       fields:[     // defines columns of the grid
                             {id:"date", label:'Date', sort:'date', width:300, align:"left"},
                             {id:"employee",   label:'Employee',   sort:'str',  width:400, align: "*"},
                             {id:"room_description", label:'Destination', sort:'str',  width:600, align:'left'}
                       ],
                        paging:true,
                        unit:"month",
                        step:1




                });


                    scheduler.locale.labels.grid_tab2 = "Day Report";   
                scheduler.createGridView({
                       name:"day_grid",
                       fields:[     // defines columns of the grid
                             {id:"date", label:'Date', sort:'date', width:300, align:"left"},
                             {id:"employee",   label:'Employee',   sort:'str',  width:400, align: "*"},
                             {id:"room_description", label:'Destination', sort:'str',  width:600, align:'left'}
                       ],
                        paging:true,
                        unit:"day",
                        step:1

                });

【问题讨论】:

    标签: html gridview scheduler dhtml


    【解决方案1】:

    您的代码似乎适用于调度程序演示 http://docs.dhtmlx.com/scheduler/snippet/b9320394

    唯一需要为 day_grid 视图正确定义标签,变量应命名为“day_grid_tab”而不是“grid_tab2” scheduler.locale.labels.day_grid_tab = "日报告";

    【讨论】:

    • 谢谢,就是这样。这么小的事情可以忽略。
    猜你喜欢
    • 1970-01-01
    • 2017-01-07
    • 2015-03-30
    • 2017-03-21
    • 1970-01-01
    • 2012-11-20
    • 2019-07-27
    • 2020-03-29
    • 2018-05-25
    相关资源
    最近更新 更多