Edit D:\rfid\libsystem\page\application\js\bookcaseedit.js
$(function(){setBookGird();var a=[{key:"libcode",condition:"code",value:vLibcode}];commonSetParaInit(null,"record",null,a);enterEvent("keyword",serachBookList);$("#bookDataGridList").datagrid({onSelect:onSelectBookDataGridList});$("#keyword").textbox("textbox").focus();$(".easyui-panel").panel("resize")});function onSelectBookDataGridList(a,b){setJsonData(null,b)}function serachBookList(e){var b=0;var d=$("#bookDataGridList").datagrid("getSelected");if(d){b=$("#bookDataGridList").datagrid("getRowIndex",d)}var a=base_path+"acq/bookcase/page.do";var c={};if(getValue("keyword").length==0&&!e){return openMessageDlg("????????????")}cleanJsonData("record");clearGridData("bookDataGridList");c.rows=10;c.page=1;if(e){c.serno=e}else{c[""+getValue("index")+""]=getValue("keyword")}$("#bookDataGridList").datagrid({url:a,queryParams:c,onLoadSuccess:function(f){$("#bookDataGridList").datagrid("selectRow",b)},method:"post"})}function addBookRecord(){cleanJsonData("record");clearGridData("bookDataGridList");$("#title").textbox("textbox").focus()}function saveBookRecord(){var a=getJsonData(null,"record");if(!a){openMessageDlg("??????");return}if(!a.title){openMessageDlg("???????????");return}if(!a.price){openMessageDlg("???????????");return}if(!a.classno){openMessageDlg("????????????");return}if(!a.isbn){openMessageDlg("ISBN????????");return}if(!a.author){openMessageDlg("???????????");return}var c=getValue("serno");var b=base_path+"acq/bookcase/insert.do";if(c>0){b=base_path+"acq/bookcase/update.do"}$.post(b,a,function(d){if(d.status=="0"){openMessageDlg(d.message);var e=d.rows[0];serachBookList(e.serno)}else{openMessageDlg(d.message)}},"json")}function deleteBookRecord(){var a=$("#bookDataGridList").datagrid("getSelected");if(!a){return openMessageDlg("?????????¤???,??????")}openConfirmDlg("???????????????["+a.serno+"]????????",null,deleteBookRecordResult,null)}function deleteBookRecordResult(){var b=0;var d=$("#bookDataGridList").datagrid("getSelected");if(d){b=$("#bookDataGridList").datagrid("getRowIndex",d)}var a=base_path+"acq/bookcase/delete.do";var c={};c.pk=d.serno;$.post(a,c,function(e){if(e.status=="0"){cleanJsonData("record");$("#bookDataGridList").datagrid("deleteRow",b);openMessageDlg(e.message)}else{openMessageDlg(e.message)}},"json")}function setBookGird(){var a=$(window).height();var b=a-260;$(".datagrid-div").css("height",b+"px");$("#bookDataGridList").datagrid("resize")};
Ms-Dos/Windows
Unix
Write backup
jsp File Browser version 1.2 by
www.vonloesch.de