easyui入门

控件:

创建方法:

一、标签模式
<a href='#' class='easyui-linkbutton' data-options="iconCls:'icon-search'">easyui入门</a>

二、编程模式
<a href="#" class="hehe">第一个easyui</a>
$(function(){ $('.hehe').linkbutton({ iconCls:'icon-add' }) })

linkbutton按钮

创建:

方法一:
<a href='#' class='easyui-linkbutton' data-options="iconCls:'icon-search'">easyui入门</a>
方法二:
<a href="#" class="hehe">第一个easyui</a>
$(function(){ $('.hehe').linkbutton({ iconCls:'icon-add' }) })

属性:

名称 描述
id 组件的ID
disabled true禁用,false启用 boolean
plain 设置为简洁效果 boolean
text 按钮显示的文本 string
iconCls 按钮显示的图标 string
size 按钮显示的大小 large,small

事件:

名称 属性 描述
onClick none 点击事件
options none 返回属性对象
disabled none 禁用按钮
enable none 启用按钮

调用事件:
一、标签模式:
<a href="javascript:;" class="hehe easyui-linkbutton" data-options="onClick:test1">第一个easyui</a>

`
function test1() {
alert('easyui');
}

`

二、编程模式:
`
$(function(){
$('.hehe').linkbutton({
iconCls:'icon-add',
onClick:test1
});
});

$(function(){
$('.hehe').linkbutton({
iconCls:'icon-add',
onClick:function(){
alert(3333);
}
});
});
`

方法:

名称 属性 描述
resize json 设置按钮大小
disable boolean 禁用按钮

调用方法:

窗口插件window

windows

属性:

名称 属性 描述
title string 窗口的标题
collapsible boolean 定义是否显示折叠按钮
minimizable boolean 定义是否显示最小化按钮
maximizable boolean 定义是否显示最大化按钮
colsable boolean 定义是否显示关闭按钮
draggable boolean 定义窗口是否可以被拖放
resizable boolean 定义窗口是否可以被缩放
modal boolean 定义窗口是否有遮罩效果

事件(继承panel事件)

名称 属性 描述
onload none 控件在载入时触发
onOpen none 控件打开之后触发
onClose none 控件关闭时触发

方法(继承panel方法)

名称 属性 描述
window none 返回窗口对象
resize options 修改窗口尺寸width,height
onClose none 控件关闭时触发
posted @ 2023-02-18 21:58  哆啦阿梦  阅读(43)  评论(0编辑  收藏  举报