码迷,mamicode.com
首页 > 其他好文 > 详细

easyui 1

时间:2017-05-26 23:27:08      阅读:240      评论:0      收藏:0      [点我收藏+]

标签:ashx   query   utf-8   pts   efault   href   集合   text   基于   

jquwry-easyui:基于jquery库的一个页面集合插件 用来实现b/S结构富客户段
注意:一般用在企业级开发或者是互联网项目后台管理项目
不适合做网站前台页面

使用步骤
1.在外部文件中使用五个样式文件
三个js 两个css
<script src="webfie/jquery.min.js"></script>
<script src="webfie/jquery.easyui.min.js"></script>
<script src="locale/easyui-lang-zh_CN.js"></script>
<link href="themes/default/easyui.css" rel="stylesheet" />
2.要将一个普通的xhtml 标签渲染成easyui中的富标签
a 为要渲染的标签实施esayui中定义的class 样式 样式名:easyui-控件名
b 通过js代码选中要渲染的标签对象 并条用easyui中的方法
规律:方法名=控件名

layout 相关的属性

region:区域 north east south west center

sqlit:设定区域是否拖动

fit:布尔类型 设置是否适应父容器的属性

规律:如何在js代码中去调用easyui控件的方法

连接数据库进行增删改差的时候
data-options="fit:true,singleSelect:true,collapsible:true,url:‘Handler1.ashx‘,method:‘get‘">

将后台与前台进行链接绑定。

后台部分先在三层中查询将创建一个对象 然后再调用这个对象的方法查询到一个数据集合
用json将这个数据集合进行封装data,然后再把查询到的数据通过json序列化发送给前台

javascriptserializer JSS=NEW javascriptserializer();
var data=new{total=STUDEN.COUNT,ROWS=STUDEN};
string json=jss.serialize(data);


<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title></title>
</head>
<script src="webfie/jquery.min.js"></script>
<script src="webfie/jquery.easyui.min.js"></script>
<script src="locale/easyui-lang-zh_CN.js"></script>
<link href="themes/default/easyui.css" rel="stylesheet" />
<link href="themes/icon.css" rel="stylesheet" />
<body>

<div id="win" >
大家好,这是一个easyui 文件

</div>
<script type="text/javascript">

$("#win").window({

 

width: 400,
height: 300,
modal: true,

 

});

</script>
</body>
</html>

easyui 1

标签:ashx   query   utf-8   pts   efault   href   集合   text   基于   

原文地址:http://www.cnblogs.com/liyiyong/p/6910478.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!