<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="stylesheet" type="text/css" href="../../resources/css/ext-all.css" />
<title>例子工程</title>
<script type="text/javascript" src="../../adapter/ext/ext-base.js"></script>
<script type="text/javascript" src="../../ext-all.js"></script>
<script type="text/javascript" src="../../build/locale/ext-lang-zh_CN.js"></script>
<script type="text/javascript">
Ext.onReady(function(){
var _loginWindow = new Ext.Window({
title : "添加人员",
width : 500,
height : 400,
plain : true,
layout : "form",
defaultType : "textfield",
labelWidth : 59,
items : [{
xtype : "panel",
baseCls : "x-plain", //相当于plain 与外面的背景色一样
layout : "column", //当前布局是一个列布局
style : "padding:5px",
items :[{
columnWidth : .5,
layout : "form",
defaultType : "textfield",
defaults : {width : 160},
baseCls : "x-plain",
labelWidth : 55,
items : [{
fieldLabel : "姓名"
},{
fieldLabel : "年龄"
},{
fieldLabel : "出生日期"
},{
fieldLabel : "联系电话"
},{
fieldLabel : "手机号码"
},{
fieldLabel : "电子邮件"
},{
fieldLabel : "性别"
}]
},{
columnWidth : .5,
layout : "form",
baseCls : "x-plain",
labelWidth : 55,
items : {
xtype : "textfield",
fieldLabel : "个人照片",
width : 160,
height : 173,
inputType : "image"
}
}]
},{
fieldLabel : "身份证号",
width : 490
},{
fieldLabel : "具体地址",
width : 490
},{
fieldLabel : "职位",
width : 150
}],
showLock:false,
listeners :{
"show":function(_window){
//alert(_window.title); 验证是否能够访问
if(!_window["showLock"])
{
_window.findByType("textfield")[7].getEl().dom.src = "addPeople.png";
_window["showLock"] = true;
}
}
},
buttons : [{
text : "确定"
},{
text : "取消"
}]
});
_loginWindow.show();
});
</script>
</head>
<body>
</body>
</html>
Extjs学习----注册用
于 2018-08-21 15:10:10 首次发布