var vTitle="约";var vMsg="借出";var vArea;$(function(){if(vType=="1"){vTitle="借";vMsg="在馆"}setTabsGridGird();var a=[{key:"libcode",condition:"code",value:vLibcode}];commonSetParaInit(null,"record",null,a);$("#barcode").textbox("textbox").focus().select();enterEvent("barcode",searchHoldRecord);$(".easyui-panel").panel("resize")});function onCloseMessageFun(){$("#barcode").textbox("textbox").focus().select()}function searchHoldRecord(){var a=base_path+"hld/holding/getHoldingWithBib.do";var b={};if(getValue("barcode").length==0){return openMessageDlg("条码号不能为空")}b.barcode=getValue("barcode");$.post(a,b,function(c){if(c.status=="0"){var d=c.rows[0];setJsonData(null,d);getReserveDataGridList(d.bibid)}else{openMessageDlg(c.message)}},"json")}function setTabsGridGird(){var a=$(window).height();var b=a-(324);$(".datagrid-div").css("height",b+"px");$("#tabsGrid").tabs("resize")}function backReserveRecord(){var b=$("#reserveDataGridList").datagrid("getSelected");if(!b){return openMessageDlg("请先选择一条预"+vTitle+"信息,进行操作")}var a=b.bibid;$.messager.confirm("提示消息","您确定要对此条预"+vTitle+"信息,进行回车处理吗?",function(d){if(d){var c=base_path+"cir/reserve/cancelReserve.do";var e={};e.id=b.id;e.resstatus="3";e.barcode=getValue("barcode");$.post(c,e,function(f){if(f.status=="0"){openMessageDlg(f.message);getReserveDataGridList(a)}else{openMessageDlg(f.message)}},"json")}})}function getReserveDataGridList(c){if(c>0){deleteGridData("reserveDataGridList");var a=base_path+"cir/reserve/unionPage.do";var b={};b.bibid=c;b.restype=vType;$("#reserveDataGridList").datagrid({url:a,queryParams:b,onLoadSuccess:function(d){},method:"post"})}else{deleteGridData("reserveDataGridList")}}function setPara(){};