calendar控件使用 extjs_Calendar 日历控件使用

这篇博客介绍了如何在HTML页面中使用ExtJS的Calendar控件,展示了一个配置示例,包括设置输入字段`J_time_start`和`J_time_end`的日期格式,以及如何调用预览和分类联动功能。
摘要由CSDN通过智能技术生成

在HTML 的body 标签下

1

2 -3

4

5

6 Calendar.setup({7 inputField :"J_time_start",8 ifFormat :"%Y-%m-%d",9 showsTime :false,10 timeFormat :"24"

11 });12 Calendar.setup({13 inputField :"J_time_end",14 ifFormat :"%Y-%m-%d",15 showsTime :false,16 timeFormat :"24"

17 });18 $('.J_preview').preview();//查看大图

19 $('.J_cate_select').cate_select({top_option:lang.all});//分类联动

20 $('.J_tooltip[title]').tooltip({offset:[10,2], effect:'slide'}).dynamic({bottom:{direction:'down', bounce:true}});21

运行一下吧

Insert title here

-

inputField :"J_time_start",

ifFormat :"%Y-%m-%d",

showsTime :false,

timeFormat :"24"});

Calendar.setup({

inputField :"J_time_end",

ifFormat :"%Y-%m-%d",

showsTime :false,

timeFormat :"24"});

$('.J_preview').preview();//查看大图

$('.J_cate_select').cate_select({top_option:lang.all});//分类联动

$('.J_tooltip[title]').tooltip({offset:[10,2], effect:'slide'}).dynamic({bottom:{direction:'down', bounce:true}});

效果图如下:

a1cceaed04e497ca43aedd584dada75a.png

如果想要在input 标签右侧出现小图标:看下面

Insert title here

input.date,input.endDate{background: #fff url(__STATIC__/css/admin/bgimg/input_date.png) no-repeat right 3px; padding-right:18px;font-size:12px;}

-

Calendar.setup({

inputField : "J_time_start",

ifFormat : "%Y-%m-%d",

showsTime : false,

timeFormat : "24"

});

Calendar.setup({

inputField : "J_time_end",

ifFormat : "%Y-%m-%d",

showsTime : false,

timeFormat : "24"

});

$('.J_preview').preview(); //查看大图

$('.J_cate_select').cate_select({top_option:lang.all}); //分类联动

$('.J_tooltip[title]').tooltip({offset:[10, 2], effect:'slide'}).dynamic({bottom:{direction:'down', bounce:true}});

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值