[英]Kendo UI - Scheduler - Add Event
我正在使用Kendo UI的Scheduler小部件。 我需要修改單擊日歷日時觸發的“添加事件”窗口。
我無法確定從何處調用此窗口,或從何處定義這些字段。 我需要更新。 誰能指出我正確的方向?
我用來生成Sceduler小部件的代碼如下:
<div id="example">
<div id="team-schedule">
<div id="People">
<input checked type="checkbox" id="Country" value="1" disabled="disabled">
<input checked type="checkbox" id="Region" value="2">
<input type="checkbox" id="District" value="3">
<input type="checkbox" id="WorkUnit" value="4">
<input type="checkbox" id="Classifier" value="5">
</div>
</div>
<div id="Schedule" class="calendars"></div>
</div>
<script>
$("#Schedule").kendoScheduler({
date: new Date("2013/6/6"), // The current date of the scheduler
views: [
"month",
{ type: "month", selected: true },
"week",
"day"
],
dataSource: [ // The kendo.data.SchedulerDataSource configuration
// First scheduler event
{
id: 1, // Unique identifier. Needed for editing.
start: new Date("2013/6/6 08:00 AM"), // Start of the event
end: new Date("2013/6/6 09:00 AM"), // End of the event
title: "Classification" // Title of the event
}
]
});
</script>
您將要研究Scheduler Editor模板。 這是一個詳細的版本(盡管它是MVC包裝器版本,但是Kendo模板是通過<script type =“ text / x-kendo-template” id =“ schedulerTemplate”>塊類似地定義的,而沒有Razor代碼。) / JS版本,您只需像通常使用<input>字段那樣定義字段即可。
在HTML5 / JS的Schema中定義了傳遞給“事件”窗口的字段
以下是指向Kendo UI(Telerik的代碼庫)的Scheduler自定義編輯器的鏈接:
有一個完整的博客文章供您使用Scheduler,但是它是ASP.NET MVC版本。 您仍可以繼續,因為它在演練中與HTML5 / JS版本具有相關性。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.