Edit D:\rfid\libsystem\page\iframe\js\iframe_holdgrid.js
var eidtorGridObject=undefined;var eidtorGridIndex=undefined;var holdToolbar=[{text:"???",iconCls:"e-icon fa fa-plus",handler:function(){_checkBibObj.prototype.addHoldRecord()}},"-",{text:"???",iconCls:"e-icon fa fa-remove",handler:function(){removeitEidtorGridRow()}}];var _checkBibObj=function(){};var _initdata,_configData;$(function(){eidtorGridObject=$("#checkhold_eidtorgrid");_initdata=mystorage.get("cat_init_data");_configData=mystorage.get("cat_config");$(".easyui-panel").panel("resize");_myPage.prototype.getOperatorParam()});function checkRepeatHoldGrid(e){_copies=e;_initdata=mystorage.get("cat_init_data");_configData=mystorage.get("cat_config");var c=mystorage.get("cat_holdlist");if(mystorage.get("set_grid_holdlist")){c=mystorage.get("set_grid_holdlist");mystorage.remove("cat_holdlist")}eidtorGridIndex=undefined;clearGridData("checkhold_eidtorgrid");if(c&&c.length>0){var d=JSON.parse(c);for(var b=0;b<d.length;b++){var a=d[b];appendEidtorGridRow(a)}}$(".checkbib_tip").html("???:???????"+_copies+"??")}_myPage.prototype.initComboxByOperatorParm=function(f){if(f.showacqloccode){var b=_initdata.rows[0].location;var e=[];for(var c=0;c<b.length;c++){var d=b[c].code+",";if(f.showacqloccode.indexOf(d)>-1){e.push(b[c])}}var g={};g["limit[0].condition"]="code";g["limit[0].typeHandler"]="3";g["limit[0].value"]=getSqlConditionLimitIn(f.showacqloccode);var a=base_path+"par/location/list.do";$.post(a,g,function(n){var r=n.rows;_myLocationData=r;var l=_initdata.rows[0].libcode;var q=[];for(var o=0;o<l.length;o++){for(var m=0;m<r.length;m++){if(r[m].libcode.split("|")[0]==l[o].code){q.push(l[o]);break}}}var p=_initdata.rows[0].doctype;var h=[];for(var o=0;o<p.length;o++){for(var m=0;m<r.length;m++){if(r[m].defdoctype==p[o].code){h.push(p[o]);break}}}var j={};j.libcode=q;j.location=e;j.doctype=h;_checkBibObj.prototype.initGrid(true,j)},"json")}else{_checkBibObj.prototype.initGrid(false)}};_checkBibObj.prototype.initGrid=function(a,e){var b=_initdata.rows[0].libcode;var d=_initdata.rows[0].location;var c=_initdata.rows[0].doctype;if(e){b=e.libcode;d=e.location;c=e.doctype}eidtorGridObject.datagrid({iconCls:"e-icon fa fa-table",title:"?????????",toolbar:holdToolbar,fit:true,fitColumns:true,singleSelect:true,border:true,nowrap:false,striped:true,onClickRow:onClickEditorRow,columns:[[{field:"id",title:"?????",hidden:true},{field:"libcode",title:"??????",width:"25%",formatter:onShowLibNameByMyStorage,editor:{type:"combobox",options:{valueField:"code",textField:"name",panelHeight:"200px",required:true,editable:false,data:b,onChange:function(j,g){if(j!=undefined&&j!=g){if(eidtorGridIndex!=undefined){var o=eidtorGridObject.datagrid("getEditor",{index:eidtorGridIndex,field:"curlocation"});var t=eidtorGridObject.datagrid("getEditor",{index:eidtorGridIndex,field:"doctype"});if(!a){if(o&&$(o.target)){var p={key:"location",condition:"libcode",value:j};var h=base_path+"par/common/getInitData.do";$.post(h,p,function(i){try{$(o.target).combobox("loadData",i.rows)}catch(k){}},"json")}if(t&&$(t.target)){p={key:"doctype",condition:"libcode",value:j};var h=base_path+"par/common/getInitData.do";$.post(h,p,function(i){try{$(t.target).combobox("loadData",i.rows)}catch(k){}},"json")}}else{var n="";for(var l=0;l<_myLocationData.length;l++){if(_myLocationData[l].libcode.split("|")[0]==j){var s=_myLocationData[l].code;if(s){n+=s+","}}}var r=_initdata.rows[0].location;var q=[];for(var m=0;m<r.length;m++){var u=r[m].code+",";if(n.indexOf(u)>-1){q.push(r[m])}}if(o&&$(o.target)){$(o.target).combobox("loadData",q);$(o.target).combobox("setValue",q[0].code)}}}}}}}},{field:"curlocation",title:"??????",width:"25%",formatter:onShowLocationNameByMyStorage,editor:{type:"combobox",options:{valueField:"code",textField:"name",panelHeight:"200px",groupField:"group",required:true,editable:false,data:d,onChange:function(l,i){if(l!=undefined&&l!=i){if(eidtorGridIndex!=undefined){if(a){var g=eidtorGridObject.datagrid("getEditor",{index:eidtorGridIndex,field:"doctype"});for(var h=0;h<_myLocationData.length;h++){if(_myLocationData[h].code==l){var j=_myLocationData[h].defdoctype;$(g.target).combobox("setValue",j);break}}}}}}}}},{field:"doctype",title:"??????",width:"25%",formatter:onShowDocTypeNameByMyStorage,editor:{type:"combobox",options:{valueField:"code",textField:"name",panelHeight:"200px",groupField:"group",required:true,editable:false,data:c}}},{field:"copies",title:"???",width:"25%",editor:{type:"numberbox",options:{required:true}}}]]});var f=_copies;checkRepeatHoldGrid(f)};_checkBibObj.prototype.saveCheck=function(){acceptEidtorGrid();var a=eidtorGridObject.datagrid("getRows");var c=0;for(var b=0;b<a.length;b++){c+=parseInt(a[b].copies)}if(c!=_copies){$.messager.confirm("??????","?????????????????????,????????????",function(d){if(d){parent.setCheckHoldSaveResult(a,c)}else{parent.setCheckHoldSaveResult(a)}})}else{parent.setCheckHoldSaveResult(a)}};_checkBibObj.prototype.addHoldRecord=function(){acceptEidtorGrid();var b=eidtorGridObject.datagrid("getRows");if(b.length>0){var d=0;for(var c=0;c<b.length;c++){d+=parseInt(b[c].copies)}if(d>=_copies){return openMessageDlg("??????????????????????????!")}}var a={};appendEidtorGridRow(a)};function colseParentDlg(){parent.colseIframeDlg("holdgrid_dlg",null,null)}function onShowLibNameByMyStorage(b,c){var d=_initdata.rows[0].libcode;if(b){for(var a=0;a<d.length;a++){if(b==d[a].code){return d[a].name}}return b}else{return b}}function onShowLocationNameByMyStorage(b,c){var d=_initdata.rows[0].location;if(b){for(var a=0;a<d.length;a++){if(b==d[a].code){return d[a].name}}return b}else{return b}}function onShowDocTypeNameByMyStorage(b,c){var d=_initdata.rows[0].doctype;if(b){for(var a=0;a<d.length;a++){if(b==d[a].code){return d[a].name}}return b}else{return b}};
Ms-Dos/Windows
Unix
Write backup
jsp File Browser version 1.2 by
www.vonloesch.de