<%@ page language="java" pageEncoding="UTF-8" %>
<script type="text/javascript">
Ext.onReady(function(){
function blurSubmit(pnlBlur) {
pnlBlur.getForm().submit();
}
var pnlBlur = new Ext.FormPanel({
//renderTo: 'aaa',
labelWidth: 75,
url:'/search/customer.do',
frame:true,
//title: '',
bodyStyle:'padding:1px 1px 0',
width: 500,
defaults: {width: 230},
//defaultType: 'textfield',
waitMsgTarget: true,
layout: 'column',
items: [
{
name: 'imgBlur',
width:100,
html: "<img width='100' height='30' src='/xxx.jpg' alt='模糊查找' />"
},{
//fieldLabel: '模糊查找',
xtype: 'textfield',
name: 'txtBlur',
emptyText:'可输入多名车友姓名,用逗号隔开……',
//allowBlank:false
},{
name: 'btnBlurSearch',
width:20,
html:"<a href='#' onclick='blurSubmit(pnlBlur);return false;'>go!</a>"
},{
xtype:"hidden",
name:"searchType",
hidden:true,
//hiddenLabel:true,
value:"blur"
}
]/*,
buttons: [{
text: 'go!',
disabled: false,
handler: function(){
pnlBlur.getForm().submit({
url:'testBlur.do',
waitMsg:'Loading',
submitEmptyText: false});
}
}] */
});
pnlBlur.render('inputArea');
var starProxy = new Ext.data.HttpProxy({
url: '${pageContext.request.contextPath}/constants.do?category=star',
method: 'GET'
});
var bloodTypeProxy = new Ext.data.HttpProxy({
url: '${pageContext.request.contextPath}/constants.do?category=blood_type',
method: 'GET'
});
var genderProxy = new Ext.data.HttpProxy({
url: '${pageContext.request.contextPath}/constants.do?category=gender',
method: 'GET'
});
var districtProxy = new Ext.data.HttpProxy({
url: '${pageContext.request.contextPath}/constants.do?category=district',
method: 'GET'
});
var starStore = new Ext.data.JsonStore({
proxy: starProxy,
//url: '${pageContext.request.contextPath}/constants.do',
//root: 'stars',
idProperty: 'constantId',
fields: ['constantId','name']
});
var bloodTypeStore = new Ext.data.JsonStore({
proxy: bloodTypeProxy,
//url: '${pageContext.request.contextPath}/constants.do',
//root: 'stars',
idProperty: 'constantId',
fields: ['constantId','name']
});
var genderStore = new Ext.data.JsonStore({
proxy: genderProxy,
//url: '${pageContext.request.contextPath}/constants.do',
//root: 'stars',
idProperty: 'constantId',
fields: ['constantId','name']
});
var districtStore = new Ext.data.JsonStore({
proxy: districtProxy,
//url: '${pageContext.request.contextPath}/constants.do',
//root: 'stars',
idProperty: 'constantId',
fields: ['constantId','name']
});
var pnlPara = new Ext.FormPanel({
//renderTo: 'inputArea',
labelWidth: 75,
url:'save-form.php',
frame:true,
//title: ' ',
bodyStyle:'padding:1px 1px 0',
width: 1000,
defaults: {width: 150},
//defaultType: 'combo',
waitMsgTarget: true,
layout: 'column',
items: [{
name: 'imgCriteria',
width:100,
html: "<img width='100' height='30' src='/xxx.jpg' alt='参数查找' />"
},{
xtype: 'combo',
name: 'cboGroup',
emptyText:'所在车组',
selectOnFocus:true,
mode: 'local'
},{
xtype: 'combo',
name: 'cboDistrict',
emptyText:'区域',
store: districtStore,
mode: 'remote',
editable: false,
triggerAction: 'all',
valueField: 'constantId',
displayField: 'name'
},{
xtype: 'combo',
name: 'cboGender',
emptyText:'性别',
store: genderStore,
mode: 'remote',
editable: false,
triggerAction: 'all',
valueField: 'constantId',
displayField: 'name'
},{
xtype: 'combo',
name: 'cboBlood',
emptyText:'血型',
store: bloodTypeStore,
mode: 'remote',
editable: false,
triggerAction: 'all',
valueField: 'constantId',
displayField: 'name'
},{
xtype: 'combo',
name: 'cboStar',
emptyText: '星座',
store: starStore,
mode: 'remote',
editable: false,
triggerAction: 'all',
valueField: 'constantId',
displayField: 'name'
//autoLoad: false
},{
name: 'btnCriteriaSearch',
width:20,
html:"<a href='#'>go!</a>"
}
]
/*,
buttons: [{
text: 'go!'
}] */
});
pnlPara.render(document.getElementById('inputArea'));
});
</script>
<div id="inputArea"></div>
prompt PL/SQL Developer import file
prompt Created on 2011年1月10日 by Administrator
set feedback off
set define off
prompt Dropping STAR_DETAIL...
drop table STAR_DETAIL cascade constraints;
prompt Creating STAR_DETAIL...
create table STAR_DETAIL
(
CONSTANT_ID NUMBER(10) not null,
BEGIN_DT VARCHAR2(20),
END_DT VARCHAR2(20)
)
tablespace USERS
pctfree 10
initrans 1
maxtrans 255
storage
(
initial 64K
minextents 1
maxextents unlimited
);
alter table STAR_DETAIL
add constraint STAR_DETAIL_PK primary key (CONSTANT_ID)
using index
tablespace USERS
pctfree 10
initrans 2
maxtrans 255
storage
(
initial 64K
minextents 1
maxextents unlimited
);
alter table STAR_DETAIL
add constraint STAR_DETAIL_FK foreign key (CONSTANT_ID)
references CONSTANTS (CONSTANT_ID);
prompt Disabling triggers for STAR_DETAIL...
alter table STAR_DETAIL disable all triggers;
prompt Loading STAR_DETAIL...
insert into STAR_DETAIL (CONSTANT_ID, BEGIN_DT, END_DT)
values (1001, '03-21', '04-20');
insert into STAR_DETAIL (CONSTANT_ID, BEGIN_DT, END_DT)
values (1002, '04-21', '05-21');
insert into STAR_DETAIL (CONSTANT_ID, BEGIN_DT, END_DT)
values (1003, '05-22', '06-21');
insert into STAR_DETAIL (CONSTANT_ID, BEGIN_DT, END_DT)
values (1004, '06-22', '07-22');
insert into STAR_DETAIL (CONSTANT_ID, BEGIN_DT, END_DT)
values (1005, '07-23', '08-23');
insert into STAR_DETAIL (CONSTANT_ID, BEGIN_DT, END_DT)
values (1006, '08-24', '09-23');
insert into STAR_DETAIL (CONSTANT_ID, BEGIN_DT, END_DT)
values (1007, '09-24', '10-23');
insert into STAR_DETAIL (CONSTANT_ID, BEGIN_DT, END_DT)
values (1008, '10-24', '11-22');
insert into STAR_DETAIL (CONSTANT_ID, BEGIN_DT, END_DT)
values (1009, '11-23', '12-21');
insert into STAR_DETAIL (CONSTANT_ID, BEGIN_DT, END_DT)
values (1010, '12-22', '01-20');
insert into STAR_DETAIL (CONSTANT_ID, BEGIN_DT, END_DT)
values (1011, '01-21', '02-19');
insert into STAR_DETAIL (CONSTANT_ID, BEGIN_DT, END_DT)
values (1012, '02-20', '03-20');
commit;
prompt 12 records loaded
prompt Enabling triggers for STAR_DETAIL...
alter table STAR_DETAIL enable all triggers;
set feedback on
set define on
prompt Done.