first commit
This commit is contained in:
18
bin/WebRoot/JS/jquery-easyui-1.4.5/demo/datebox/basic.html
Normal file
18
bin/WebRoot/JS/jquery-easyui-1.4.5/demo/datebox/basic.html
Normal file
@ -0,0 +1,18 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Basic DateBox - jQuery EasyUI Demo</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/default/easyui.css">
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/icon.css">
|
||||
<link rel="stylesheet" type="text/css" href="../demo.css">
|
||||
<script type="text/javascript" src="../../jquery.min.js"></script>
|
||||
<script type="text/javascript" src="../../jquery.easyui.min.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<h2>Basic DateBox</h2>
|
||||
<p>Click the calendar image on the right side.</p>
|
||||
<div style="margin:20px 0;"></div>
|
||||
<input class="easyui-datebox"></input>
|
||||
</body>
|
||||
</html>
|
||||
28
bin/WebRoot/JS/jquery-easyui-1.4.5/demo/datebox/buttons.html
Normal file
28
bin/WebRoot/JS/jquery-easyui-1.4.5/demo/datebox/buttons.html
Normal file
@ -0,0 +1,28 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>DateBox Buttons - jQuery EasyUI Demo</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/default/easyui.css">
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/icon.css">
|
||||
<link rel="stylesheet" type="text/css" href="../demo.css">
|
||||
<script type="text/javascript" src="../../jquery.min.js"></script>
|
||||
<script type="text/javascript" src="../../jquery.easyui.min.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<h2>DateBox Buttons</h2>
|
||||
<p>This example shows how to customize the datebox buttons underneath the calendar.</p>
|
||||
<div style="margin:20px 0;"></div>
|
||||
<input class="easyui-datebox"></input>
|
||||
<input class="easyui-datebox" data-options="buttons:buttons"></input>
|
||||
<script>
|
||||
var buttons = $.extend([], $.fn.datebox.defaults.buttons);
|
||||
buttons.splice(1, 0, {
|
||||
text: 'MyBtn',
|
||||
handler: function(target){
|
||||
alert('click MyBtn');
|
||||
}
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
27
bin/WebRoot/JS/jquery-easyui-1.4.5/demo/datebox/clone.html
Normal file
27
bin/WebRoot/JS/jquery-easyui-1.4.5/demo/datebox/clone.html
Normal file
@ -0,0 +1,27 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Clone DateBox - jQuery EasyUI Demo</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/default/easyui.css">
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/icon.css">
|
||||
<link rel="stylesheet" type="text/css" href="../demo.css">
|
||||
<script type="text/javascript" src="../../jquery.min.js"></script>
|
||||
<script type="text/javascript" src="../../jquery.easyui.min.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<h2>Clone DateBox</h2>
|
||||
<p>Click the 'Clone' button to clone datebox components from the exiting datebox.</p>
|
||||
<div style="margin:20px 0;">
|
||||
<a href="javascript:void(0)" class="easyui-linkbutton" onclick="cloneDatebox()">Clone</a>
|
||||
</div>
|
||||
<input id="dt" class="easyui-datebox"></input>
|
||||
<div id="cc" style="margin-top:10px"></div>
|
||||
<script type="text/javascript">
|
||||
function cloneDatebox(){
|
||||
var dt = $('<input>').appendTo('#cc');
|
||||
dt.datebox('cloneFrom', '#dt');
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@ -0,0 +1,39 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Date Format - jQuery EasyUI Demo</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/default/easyui.css">
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/icon.css">
|
||||
<link rel="stylesheet" type="text/css" href="../demo.css">
|
||||
<script type="text/javascript" src="../../jquery.min.js"></script>
|
||||
<script type="text/javascript" src="../../jquery.easyui.min.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<h2>Date Format</h2>
|
||||
<p>Different date formats are applied to different DateBox components.</p>
|
||||
<div style="margin:20px 0;"></div>
|
||||
<input class="easyui-datebox"></input>
|
||||
<input class="easyui-datebox" data-options="formatter:myformatter,parser:myparser"></input>
|
||||
<script type="text/javascript">
|
||||
function myformatter(date){
|
||||
var y = date.getFullYear();
|
||||
var m = date.getMonth()+1;
|
||||
var d = date.getDate();
|
||||
return y+'-'+(m<10?('0'+m):m)+'-'+(d<10?('0'+d):d);
|
||||
}
|
||||
function myparser(s){
|
||||
if (!s) return new Date();
|
||||
var ss = (s.split('-'));
|
||||
var y = parseInt(ss[0],10);
|
||||
var m = parseInt(ss[1],10);
|
||||
var d = parseInt(ss[2],10);
|
||||
if (!isNaN(y) && !isNaN(m) && !isNaN(d)){
|
||||
return new Date(y,m-1,d);
|
||||
} else {
|
||||
return new Date();
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
27
bin/WebRoot/JS/jquery-easyui-1.4.5/demo/datebox/events.html
Normal file
27
bin/WebRoot/JS/jquery-easyui-1.4.5/demo/datebox/events.html
Normal file
@ -0,0 +1,27 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>DateBox Events - jQuery EasyUI Demo</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/default/easyui.css">
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/icon.css">
|
||||
<link rel="stylesheet" type="text/css" href="../demo.css">
|
||||
<script type="text/javascript" src="../../jquery.min.js"></script>
|
||||
<script type="text/javascript" src="../../jquery.easyui.min.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<h2>DateBox Events</h2>
|
||||
<p>Click the calendar image on the right side.</p>
|
||||
<div style="margin:20px 0;"></div>
|
||||
<input class="easyui-datebox" data-options="onSelect:onSelect"></input>
|
||||
<div style="margin:10px 0">
|
||||
<span>Selected Date: </span>
|
||||
<span id="result"></span>
|
||||
</div>
|
||||
<script>
|
||||
function onSelect(date){
|
||||
$('#result').text(date)
|
||||
}
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
21
bin/WebRoot/JS/jquery-easyui-1.4.5/demo/datebox/fluid.html
Normal file
21
bin/WebRoot/JS/jquery-easyui-1.4.5/demo/datebox/fluid.html
Normal file
@ -0,0 +1,21 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Fluid DateBox - jQuery EasyUI Demo</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/default/easyui.css">
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/icon.css">
|
||||
<link rel="stylesheet" type="text/css" href="../demo.css">
|
||||
<script type="text/javascript" src="../../jquery.min.js"></script>
|
||||
<script type="text/javascript" src="../../jquery.easyui.min.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<h2>Fluid DateBox</h2>
|
||||
<p>This example shows how to set the width of DateBox to a percentage of its parent container.</p>
|
||||
<div style="margin:20px 0;"></div>
|
||||
<p>width: 50%</p>
|
||||
<input class="easyui-datebox" style="width:50%"></input>
|
||||
<p>width: 30%</p>
|
||||
<input class="easyui-datebox" style="width:30%"></input>
|
||||
</body>
|
||||
</html>
|
||||
@ -0,0 +1,30 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Restrict Date Range in DateBox - jQuery EasyUI Demo</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/default/easyui.css">
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/icon.css">
|
||||
<link rel="stylesheet" type="text/css" href="../demo.css">
|
||||
<script type="text/javascript" src="../../jquery.min.js"></script>
|
||||
<script type="text/javascript" src="../../jquery.easyui.min.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<h2>Restrict Date Range in DateBox</h2>
|
||||
<p>This example shows how to restrict the user to select only ten days from now.</p>
|
||||
<div style="margin:20px 0;"></div>
|
||||
<input id="dd"></input>
|
||||
<script>
|
||||
$(function(){
|
||||
$('#dd').datebox().datebox('calendar').calendar({
|
||||
validator: function(date){
|
||||
var now = new Date();
|
||||
var d1 = new Date(now.getFullYear(), now.getMonth(), now.getDate());
|
||||
var d2 = new Date(now.getFullYear(), now.getMonth(), now.getDate()+10);
|
||||
return d1<=date && date<=d2;
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
@ -0,0 +1,30 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Shared Calendar in DateBox - jQuery EasyUI Demo</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/default/easyui.css">
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/icon.css">
|
||||
<link rel="stylesheet" type="text/css" href="../demo.css">
|
||||
<script type="text/javascript" src="../../jquery.min.js"></script>
|
||||
<script type="text/javascript" src="../../jquery.easyui.min.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<h2>Shared Calendar in DateBox</h2>
|
||||
<p>Multiple datebox components can share a calendar and use it to pick dates.</p>
|
||||
<div style="margin:20px 0;"></div>
|
||||
<table>
|
||||
<tr>
|
||||
<td>Start Date:</td>
|
||||
<td>
|
||||
<input class="easyui-datebox" data-options="sharedCalendar:'#cc'">
|
||||
</td>
|
||||
<td>End Date:</td>
|
||||
<td>
|
||||
<input class="easyui-datebox" data-options="sharedCalendar:'#cc'">
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<div id="cc" class="easyui-calendar"></div>
|
||||
</body>
|
||||
</html>
|
||||
@ -0,0 +1,30 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>Validate DateBox - jQuery EasyUI Demo</title>
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/default/easyui.css">
|
||||
<link rel="stylesheet" type="text/css" href="../../themes/icon.css">
|
||||
<link rel="stylesheet" type="text/css" href="../demo.css">
|
||||
<script type="text/javascript" src="../../jquery.min.js"></script>
|
||||
<script type="text/javascript" src="../../jquery.easyui.min.js"></script>
|
||||
</head>
|
||||
<body>
|
||||
<h2>Validate DateBox</h2>
|
||||
<p>When the selected date is greater than specified date. The field validator will raise an error.</p>
|
||||
<div style="margin:20px 0;"></div>
|
||||
<input class="easyui-datebox" required data-options="validType:'md[\'10/11/2012\']'"></input>
|
||||
<script>
|
||||
$.extend($.fn.validatebox.defaults.rules, {
|
||||
md: {
|
||||
validator: function(value, param){
|
||||
var d1 = $.fn.datebox.defaults.parser(param[0]);
|
||||
var d2 = $.fn.datebox.defaults.parser(value);
|
||||
return d2<=d1;
|
||||
},
|
||||
message: 'The date must be less than or equals to {0}.'
|
||||
}
|
||||
})
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user