<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head id="Head1" runat="server">
  
    <title></title>
    <meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
 <link rel="stylesheet" type="text/css" href="../themes/default/easyui.css"/>
 <link rel="stylesheet" type="text/css" href="../themes/icon.css"/>
 <link rel="stylesheet" type="text/css" href="../demo.css"/>
 <script type="text/JavaScript" src="../jQuery-1.7.2.min.js"></script>
 <script type="text/javascript" src="../jquery.easyui.min.js"></script>

<link  rel="stylesheet" href="../css/mainFrom.css" type="text/css" />

<script>
        function resize() {
            $('#w').window({
                title: 'New Title',
                width: 600,
                modal: true,
                shadow: false,
                closed: false,
                height: 300
            });
        }
        function openW() {
            $('#w').window('open');
        }
        function closeW() {
            $('#w').window('close');
        }
        function test() {
            $('#test').window('open');
        }
       // Dialog
        function open1() {
            $('#d2').dialog('open');
        }
        function close1() {
            $('#d2').dialog('close');
        }
 </script>
</head>
<body>
<form id="form1" runat="server">
  <div id="incontent">
       <div id="contool">
       <div class="tool">工具栏</div>
            
            <a href="#"><span id="bj" runat="server">销售开单</span></a>
               <a href="#">历史单据</a>
        <div class="clear"></div>
        </div>
        <div class="contable">
          <div class="clear"></div>
           <div id="tb"> 
              <div style =" margin:5px;" >
                <div>
                 单号:<asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>  
                 开单时间:<asp:TextBox ID="TextBox2" runat="server"></asp:TextBox>---<asp:TextBox ID="TextBox3" runat="server"></asp:TextBox>
                 <asp:Button ID="Button1" runat="server" Text="查询" />
                 </div>                  
               </div> 
            </div> 
          <div id="UpdatePanel1">            
            <table  class="easyui-datagrid"  toolbar="#tb"  style="width:auto; height:auto;" data-options="idField:'itemid',showFooter:true,collapsible:true" title="销售单列表">
             <thead>
                 <tr>    
                    <th field="itemid" width="80" checkbox="true">行号</th>    
                    <th field="productid" width="120" sortable="true">单据日期</th>   
                    <th field="listprice" width="120" sortable="true">单据编号</th>   
                    <th field="unitcost" width="150"sortable="true" >客户名称</th>   
                    <th field="attr1" width="150" sortable="true">销售金额</th>    
                    <th field="status" width="150" sortable="true">折后金额</th>    
                    <th field="status1" width="150" sortable="true">收款金额</th>
                    <th field="status2" width="200">说明</th>
                    <th field="status3" width="130">操作</th>
                </tr>
             </thead>
             <tr >
              <td ></td>
               <td >123457645</td>
              <td >2013-06-02</td>
              <td >张三</td>
              <td >¥15000</td>
              <td >¥15000</td>
              <td >¥15000</td>
              <td >&nbsp;</td>
              <td >
                  <a href="javascript:void(0);" class="easyui-linkbutton" iconCls="icon-edit" plain="true" onclick="open1()" >修改</a>   
                 <a href="javascript:void(0);" class="easyui-linkbutton" iconCls="icon-cancel" plain="true" onclick="javascript:void(0);"  >删除</a>
              </td>
             </tr>
              <tr >
              <td ></td>
               <td >123457645</td>
              <td >2013-06-02</td>
              <td >张三</td>
              <td >¥15000</td>
              <td >¥15000</td>
              <td >¥15000</td>
              <td >&nbsp;</td>
              <td >
                  <a href="javascript:void(0);" class="easyui-linkbutton" iconCls="icon-edit" plain="true" onclick="openW()"  >修改</a>   
                 <a href="javascript:void(0);" class="easyui-linkbutton" iconCls="icon-cancel" plain="true" onclick="javascript:void(0);" >删除</a>
              </td>
             </tr>
           </table>
          </div>
        </div>
    </div> 
    <div id="d2" title="修改单据" class="easyui-dialog" closed="true"  modal="true" style="width:400px;height:200px;padding:10px;"
   toolbar="#dlg-toolbar" buttons="#dlg-buttons" resizable="true">
  Dialog toolbar and buttons are created from existing HTML nodes.
 </div>
 <div id="dlg-toolbar" style="padding:2px 0">
  <table cellpadding="0" cellspacing="0" style="width:100%">
   <tr>
    <td style="padding-left:2px">
     <a href="#" class="easyui-linkbutton" iconCls="icon-edit" plain="true">Edit</a>
     <a href="#" class="easyui-linkbutton" iconCls="icon-help" plain="true">Help</a>
    </td>
    <td style="text-align:right;padding-right:2px">
     <input class="easyui-searchbox"></input>
    </td>
   </tr>
  </table>
 </div>
    <div id="dlg-buttons">
  <a href="#" class="easyui-linkbutton" onclick="javascript:alert('save')">Save</a>
  <a href="#" class="easyui-linkbutton" onclick="javascript:$('#d2').dialog('close')">Close</a>
 </div>

<div id="w" class="easyui-window" title="My Window" closed="true"  modal="true" iconCls="icon-save" style="width:500px;height:200px;padding:5px;">
  <div class="easyui-layout" fit="true">
   <div region="center" border="false" style="padding:10px;background:#fff;border:1px solid #ccc;">
    jQuery EasyUI framework help you build your web page easily.
    <br/><br/>
    click <a href="#" onclick="test()">here</a> to popup another window.
   </div>
   <div region="south" border="false" style="text-align:right;padding:5px 0;">
    <a class="easyui-linkbutton" iconCls="icon-ok" href="javascript:void(0)" onclick="resize()">Ok</a>
    <a class="easyui-linkbutton" iconCls="icon-cancel" href="javascript:void(0)" onclick="resize()">Cancel</a>
   </div>
  </div>
 </div>
</form>
</body>
</html>

1、closed="true"//默认不显示

2 、modal="true"//是否有遮罩层

3、关闭窗口事件,无论点击取消还是窗口的关闭都会执行

$(function (){       
            $('#windowsMSG').window({ 
                 onClose:function(){ alert("dfsd");}
             });
              
        });

easyUI的Dialog和Windows框的应用的更多相关文章

  1. easyui打开dialog后给弹出框内输入框赋值问题

    在写一个弹出页面的时候,里面有一些输入框,需要在弹出的时候从数据库取值并且赋值,刚开始在弹出的时候使用$(id).val(value),结果赋值失败,为空当时纠结了一会,然后突然想到在easyui打开 ...

  2. Easyui的Dialog的toolbar的自定义添加

    最近一直在写快速定制Web表格,基于Easyui,整个过程使用了大量的Easyui的dialog,每个dialog的代码大部分都雷同,感觉代码出现了很大程度的重复,然后想写一个通用的dialog设置函 ...

  3. easyui的combobox下拉框初始化默认值以及保持该值一直显示的方法

    easyui的combobox下拉框默认初始值是空,下面是实现从远程加载数据之后初始化默认值,以及让该值一直排在下拉框的最顶部的方式. 目前的需求是需要在初始化的时候添加"全部数据库&quo ...

  4. Android 代码库(自定义一套 Dialog通用提示框 )

          做Android开发五年了,期间做做停停(去做后台开发,服务器管理),当回来做Android的时候,发现很生疏,好些控件以前写得很顺手,现在好像忘记些什么了,总要打开这个项目,打开那个项目 ...

  5. vue--vant组件库Dialog弹出框

    安装vant UI框架: cnpm install vant –-save-dev 导入组件-在main.js里: import Vant from 'vant'; import'vant/lib/v ...

  6. ASP.NET页面使用JQuery EasyUI生成Dialog后台取值为空

    原因: JQuery EasyUI生成Dialog后原来的文档结构发生了变化,原本在form里的内容被移动form外面,提交到后台后就没有办法取值了. 解决办法: 在生成Dialog后将它append ...

  7. 第二百零四节,jQuery EasyUI,Dialog(对话框)组件

    jQuery EasyUI,Dialog(对话框)组件 学习要点: 1.加载方式 2.属性列表 3.事件列表 4.方法列表 本节课重点了解EasyUI中Dialog(窗口)组件的使用方法,这个组件依赖 ...

  8. jQuery EasyUI/TopJUI创建文本验证框(不写js,纯HTML实现!!!)

    jQuery EasyUI/TopJUI创建文本验证框(不写js,纯HTML实现!!!) validatebox(验证框)的设计目的是为了验证输入的表单字段是否有效.如果用户输入了无效的值,它将会更改 ...

  9. JQuery EasyUI dialog弹出框的 close 和 destroy

    开发项目中(使用JQuery EasyUI),根据业务需要重叠弹出多个提示框的情况,会出现如下情况:页面出现两个div模块调用同一个弹出页面,页面的数据接受框元素不能实时存储数据解决方案: 使用$(t ...

随机推荐

  1. 视觉机器学习笔记------CNN学习

    卷积神经网络是第一个被成功训练的多层神经网络结构,具有较强的容错.自学习及并行处理能力. 一.基本原理 1.CNN算法思想 卷积神经网络可以看作为前馈网络的特例,主要在网络结构上对前馈网络进行简化和改 ...

  2. java 使用map返回多个对象组装

    Object json=JSONObject.fromObject("{}"); List<Object> list = new ArrayList<Object ...

  3. android 生命周期

    引入android生命周期概念来做前端的hash切换页面的思路: 1. page manager来管理多个page(一对多的关系); 2. route:URL <-> Page; 3. P ...

  4. 快速将一个表的数据生成SQL插入语句

    将一个表中的数据生成SQL插入语句,方便系统快速初始化,在数据库中执行创建以下过程就可以了. ) Drop Procedure GenerateData go CREATE PROCEDURE Gen ...

  5. ACM集训的Day3 B。。。盲目搜索之DFS。。。

    milk 一.题目描述: gzp有三个容量分别是A,B,C升的桶,A,B,C分别是三个从1到20的整数, 最初,A和B桶都是空的,而C桶是装满牛奶的.有时,农民把牛奶从一个桶倒到 另一个桶中,直到被灌 ...

  6. web前端开发和后端开发有什么区别?

    web前端分为网页设计师.网页美工.web前端开发工程师 首先网页设计师是对网页的架构.色彩以及网站的整体页面代码负责 网页美工只针对UI这块儿的东西,比如网站是否做的漂亮 web前端开发工程师是负责 ...

  7. RDIFramework.NET -.NET快速信息化系统开发整合框架 【开发实例 EasyUI】之产品管理(WebForm版)

    RDIFramework.NET—.NET快速开发整合框架 [开发实例]之产品管理(WebForm版) 接上篇:RDIFramework.NET (.NET快速信息化系统开发整合框架) [开发实例]之 ...

  8. 用Canvas制作剪纸效果

    在做剪纸效果之前,先介绍剪纸效果运用到的一些知识: 1.阴影: 在Canvas之中进行绘制时,可以通过修改绘图环境中的如下4个属性值来指定阴影效果: shadowColor:CSS格式的颜色字串.默认 ...

  9. DIY PIXHAWK APM等飞控用的声纳

    代码: SR04 + ApmSonar.ino 打包下载 注意,使用到了SR04的类库. ApmSonar.ino // sr04 to apm I2c sonar // by panxu mail: ...

  10. nginx 配置https

    firewall-cmd --zone=public --add-port=80/tcp --permanent firewall-cmd --zone=public --add-port=3306/ ...