UNPKG

calenstyle

Version:

CalenStyle is a Responsive Drag-and-Drop Event Calendar for Web, iOS, Android & Windows. CalenStyle is customizable plugin having multiple, clean-designed event calendar templates specially designed for web & mobile applications.

135 lines (99 loc) 3.55 kB
<!DOCTYPE html> <html> <head> <title>Task Planner View</title> <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"> <script type="text/javascript" src="../js/jquery-1.11.1.min.js"></script> <script type="text/javascript" src="../js/jquery-ui-custom-1.11.2.min.js"></script> <link rel="stylesheet" type="text/css" href="../css/jquery-ui-custom-1.11.2.min.css" /> <script type="text/javascript" src="../js/jquery.ui.touch-punch.js"></script> <script type="text/javascript" src="../js/hammer.min.js"></script> <script type="text/javascript" src="../js/fastclick.js"></script> <link rel="stylesheet" type="text/css" href="../../src/calenstyle.css" /> <link rel="stylesheet" type="text/css" href="../../src/calenstyle-jquery-ui-override.css" /> <link rel="stylesheet" type="text/css" href="../../src/calenstyle-iconfont.css" /> <script type="text/javascript" src="../../src/calenstyle.js"></script> <link rel="stylesheet" type="text/css" href="../css/CalEventList.css" /> <script type="text/javascript" src="../js/CalJsonGenerator.js"></script> <style type="text/css"> .calendarContOuter { position: absolute; left: 0px; right: 0px; top: 0px; bottom: 0px; font-size: 14px; text-shadow: none; } .cElemDatePicker { font-size: 14px; } .ctpvTableRowSummary { text-align: center; font-size: 80%; color: #777777; background: #F5F5F5; } .sum_amount { font-weight: bold; } </style> <script type="text/javascript"> $(function() { $(".calendarContOuter").CalenStyle( { visibleView: "TaskPlannerView", taskPlannerViewDuration: "CustomDays", daysInTaskPlannerView: 3, is24Hour: true, calDataSource: [ { sourceFetchType: "DateRange", sourceType: "FUNCTION", source: function(fetchStartDate, fetchEndDate, durationStartDate, durationEndDate, oConfig, loadViewCallback) { var calObj1 = this; calObj1.incrementDataLoadingCount(1); var oEventResponse = generateJsonEvents(fetchStartDate, fetchEndDate); if(oEventResponse != undefined) { if(oEventResponse[0]) { calObj1.parseDataSource("eventSource", oEventResponse[1], durationStartDate, durationEndDate, loadViewCallback, oConfig, false); } } } } ], addDaySummaryInTaskPlannerView: function(dThisDate, $oDaySummaryCell) { var oCS = this, iHours = getRandomInt(5, 10), iMinutes = getRandomInt(0, 60), iRate = 20, sTemplate = ""; sTemplate += "<span class='sum_time'>" + iHours + "h " + iMinutes + "m - </span>"; sTemplate += "<span class='sum_amount'>$" + ((iHours * 60 + iMinutes) * iRate) + ".00</span>"; $oDaySummaryCell.html(sTemplate); }, isTooltipInTaskPlannerView: false }); }); function getRandomInt(iMin, iMax) { return Math.floor(Math.random() * (iMax - iMin)) + iMin; } </script> </head> <body> <div class="calendarContOuterParent"> <div class="calendarContOuter"></div> </div> </body> </html>