jQuery EasyUI Window Plugin - Dialog
jQuery EasyUI Plugins
Extends $.fn.window.defaults. Override the defaults through $.fn.dialog.defaults.
A dialog is a special type of window that has a toolbar at the top and a button bar at the bottom. By default, a dialog has only a close tool shown on the right of the header. Users can configure dialog behavior to show other tools (such as collapsible, minimizable, maximizable, and so on).
Depends on
- window
- linkbutton
Usage
Create a dialog from existing DOM nodes through markup. The example below demonstrates a modal dialog with resizable capability.
Dialog Content.
Create a dialog using JavaScript. Now let's create a modal dialog and then call the 'refresh' method to load its content via ajax.
Dialog Content.
$('#dd').dialog({
title: 'My Dialog',
width: 400,
height: 200,
closed: false,
cache: false,
href: 'get_content.php',
modal: true
});
$('#dd').dialog('refresh', 'new_content.php');
property
This property extends the window; the following are properties overridden for the dialog.
| Name | Type | Description | Default value |
|---|---|---|---|
| title | string | The title text of the dialog. | New Dialog |
| collapsible | boolean | Defines whether to show the collapse button. | false |
| minimizable | boolean | Defines whether to show the minimize button. | false |
| maximizable | boolean | Defines whether to show the maximize button. | false |
| resizable | boolean | Defines whether the dialog is resizable. | false |
| toolbar | array,selector | The top toolbar of the dialog. Possible values: |
1、数组,每个工具的选项都与链接按钮(linkbutton)一样。
2、选择器,指示工具栏。
对话框工具栏可以在 标签中声明:
Dialog Content. The dialog toolbar can also be defined by an array:
Dialog Content.
| null| onSelect | event | buttons | array,selector | The bottom buttons of the dialog, possible values:
1. an array, with each button having the same options as a linkbutton.
2. A selector indicating the button bar.
按钮可以在 Label中声明:
Dialog Content. Buttons can also be defined by an array:
Dialog Content.
| null |
Events
This event extends from Panel (panel).
Method
This method extends from Window (window), below are the methods added for the dialog (dialog).
Name
Parameters
Description
dialog
none
Return the outer dialog (dialog) object.
jQuery EasyUI Plugins