ext Formpanel 使用方法

var searchForm = new Ext.FormPanel({
buttonAlign : 'right',
labelWidth : 70,
region : 'north',
bodyStyle:"border:none;",
height:125,
//width:750,
frame :true,
title : '',
layout : 'column',
monitorResize:true,
items : [
{columnWidth : 0.25,layout : 'form',bodyStyle:"border:none;",
items : [
{xtype : 'datefield',format : 'Y-m-d', fieldLabel : '起始日期', id : 'date_start',
name : 'date_start',anchor : '90%',allowBlank : false},
{xtype : 'datefield',format : 'Y-m-d',fieldLabel : '终止日期',id : 'date_end',name : 'date_end',anchor : '90%',allowBlank : false}]
}, 
{columnWidth : 0.25,bodyStyle:"border:none;",layout : 'form',
items : [
{xtype : 'timefield',fieldLabel : '起始时间',format: 'H:i:s',name : 'time_start',
id : 'time_start',anchor : '90%'},
{xtype : 'timefield',fieldLabel : '终止时间',format: 'H:i:s',name : 'time_end', id : 'time_end',anchor : '90%'}]
},
{columnWidth : 0.25,layout : 'form',bodyStyle:"border:none;",
items : [
{xtype : 'trigger',fieldLabel : '用户', onTriggerClick: trigger_sub_select, name : 'sub_name',
id : 'sub_name',anchor : '90%'},
{xtype:'combo', store: new Ext.data.SimpleStore({
fields: ["retrunValue", "displayText"],
data: [['全部','全部'],['允许','允许'],['阻断','阻断']]
}),
valueField :"retrunValue",
displayField:"displayText",
mode:'local',
editable: false,                
forceSelection: true,
triggerAction: 'all',
hiddenName:'imtype',
fieldLabel:'访问控制',
emptyText:'全部',
name :'access_control',
id : 'access_control',
value:'',
anchor:'90%',
width:250
}]
},
{columnWidth : 0.25,layout : 'form',bodyStyle:"border:none;",
items : [
{xtype : 'textfield',fieldLabel : '网址',name : 'website',id : 'website',anchor : '90%'},
{xtype : 'textfield',fieldLabel : '网址类别',name : 'websiteType',id : 'websiteType',
value :'', anchor : '90%'}
]
}],
buttons : [
{text : '开始过滤',
  handler : function tijiao() {
l.load({
params : {
start : 0,
limit : 100,
sub_name : Ext.get('sub_name').dom.value,
websiteType : Ext.get('websiteType').dom.value,
website : Ext.get('website').dom.value,
time_start : Ext.get('time_start').dom.value,
time_end : Ext.get('time_end').dom.value,
date_start : Ext.get('date_start').dom.value,
date_end : Ext.get('date_end').dom.value,
access_control:Ext.get('access_control').dom.value
}
});
}
},
{ref: '../exportBtn', iconCls: 'icon-export',  text: '数据管理',  disabled: false,
handler: function () {
listDate();
}
},
{ref: '../importBtn', iconCls: 'icon-import',  text: '导入', disabled: false,
handler: function () {
ImportUrl()
}
}
]
});
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值