jquery ezUI 雙擊行記錄彈窗查看明細(xì)的實(shí)現(xiàn)方法
第一步:給DataGrid綁定onDblClickRow事件;
<table title="" id="dataTable" class="easyui-datagrid" style="height: 500px;" data-options=" url: '/ajaxget.aspx?_t='+new Date().getTime()+'&_action=SVNGetHandler.GetSearchPageData&searchType=&keyword=*', method: 'get', rownumbers: true, singleSelect:true, border:0, idField: 'Id', columns:[[ {field:'ProjectId',title:'項(xiàng)目Id',width:30,align:'left'}, {field:'ProjectName',title:'項(xiàng)目名稱',width:150,align:'left'}, {field:'ProjectNum',title:'項(xiàng)目編號(hào)',width:100,align:'left'} ]], toolbar:'#myToolbar', pagination:true, fitColumns: true, pageSize:20, onDblClickRow:onDblClickRow "> </table>
第二步:編寫行雙擊事件
//行雙擊事件 function onDblClickRow() { var item = $('#dataTable').datagrid("getSelected"); if (item != null) { editId = item.Id; var html = ""; html += "項(xiàng)目名稱:" + item.ProjectName + "<br/>"; html += "項(xiàng)目編號(hào):" + item.ProjectNum + "<br/>"; html += "<br/>"; show(item.ProjectName + " 項(xiàng)目詳情", html); } }
第三步:彈出窗口顯示詳細(xì)信息:
<div id="details" style="padding: 10px;line-height:20px;font-size:12px"></div> function show(title, msg) { $('#details').html("<div id=\"output\" style=\"width:99%;height:96%;border:0\">" + msg + "</div>"); $('#details').dialog({ title: title, width: 800, height: 400, iconCls: 'icon-custom-eye', closed: false, cache: false, modal: true }); }
以上這篇jquery ezUI 雙擊行記錄彈窗查看明細(xì)的實(shí)現(xiàn)方法就是小編分享給大家的全部內(nèi)容了,希望能給大家一個(gè)參考,也希望大家多多支持腳本之家。
- Jquery實(shí)現(xiàn)自定義彈窗示例
- 小巧強(qiáng)大的jquery layer彈窗彈層插件
- jQuery實(shí)現(xiàn)彈窗居中效果類似alert()
- 運(yùn)用JQuery的toggle實(shí)現(xiàn)網(wǎng)頁加載完成自動(dòng)彈窗
- jquery模擬alert的彈窗插件
- jquery彈窗插件colorbox綁定動(dòng)態(tài)生成元素的方法
- jQuery實(shí)現(xiàn)簡(jiǎn)單彈窗遮罩效果
- jquery實(shí)現(xiàn)彈出窗口效果的實(shí)例代碼
- Jquery彈出窗口插件 LeanModal的使用方法
- jQuery+jqmodal彈出窗口實(shí)現(xiàn)代碼分明
- jQuery Mobile彈出窗、彈出層知識(shí)匯總
- jQuery實(shí)現(xiàn)的兩種簡(jiǎn)單彈窗效果示例
相關(guān)文章
基于jquery+thickbox仿校內(nèi)登錄注冊(cè)框
近日,客戶說他想要個(gè)類似于人人網(wǎng)(以前為校內(nèi))的登錄框效果,于是上網(wǎng)搜了下,發(fā)現(xiàn)有一個(gè)仿得比較好的,于是就拿過來用了用。2010-06-06基于Jquery的仿Windows Aero彈出窗(漂亮的關(guān)閉按鈕)
目前市面上已經(jīng)有很多成熟好用的jquery彈出窗插件,像模態(tài)窗口插件(Modal Dialog Plugins)以及數(shù)不勝數(shù)的燈箱插件(lightbox plugins)。2010-09-09jQuery實(shí)現(xiàn)html雙向綁定功能示例
這篇文章主要介紹了jQuery實(shí)現(xiàn)html雙向綁定功能,涉及jQuery針對(duì)HTML頁面元素事件綁定相關(guān)操作技巧,需要的朋友可以參考下2017-10-10jQuery實(shí)現(xiàn)下拉框左右選擇的簡(jiǎn)單實(shí)例
本篇文章主要是對(duì)jQuery實(shí)現(xiàn)下拉框左右選擇的簡(jiǎn)單實(shí)例進(jìn)行了介紹,需要的朋友可以過來參考下,希望對(duì)大家有所幫助2014-02-02jquery實(shí)現(xiàn)input輸入框?qū)崟r(shí)輸入觸發(fā)事件代碼
如何實(shí)現(xiàn)input輸入框?qū)崟r(shí)輸入觸發(fā)事件,下面有個(gè)不不錯(cuò)的示例使用jquery實(shí)現(xiàn)的,感興趣的朋友可以參考下2014-01-01