var initJson=[{code:"lib_bibliography.libcode",name:"文献馆"}];var handlecount=0;$(function(){initSrceenAndJson();$(".acceptTextTip").hide();var a=[{key:"sysid",condition:"type",value:sysid_type},];commonSetParaInit(null,"export_record",null,a)});function setFormatDesignFieldComBoxData(){}function onStartRebulid(a){var b=getJsonDataByTypeHandler();if(!b["limit[0].condition"]){return openMessageDlg("请设置你要重组数据的条件")}if(getValue("refetchType").length>0){b.refetchType=getValue("refetchType")}if(a){onBacthMianFun(a,b)}else{$.messager.confirm("提示消息","您确定要做数据重组操作吗?",function(c){if(c){onBacthMianFun(a,b)}})}}function onBacthMianFun(a,c){$(".error-msg-result").html("");if(!a){handlecount=0;$.messager.progress({title:"数据重组处理",msg:"正在处理数据,请稍等..."})}if(a){c=a}else{c.rows=500;c.page=1}var b=base_path+"lib/biblios/refetchBibIndex.do";$.post(b,c,function(d){$.messager.progress("close");if(d.status=="0"){var e=d.rows[0];if(e){if(e.nextpage&&e.nextpage>0){$.messager.progress({title:"数据重组处理",msg:"已处理["+e.count+"]条数据,请等待处理完成 ..."});c.page=e.nextpage;onStartRebulid(c)}else{$(".handlecount").html("已处理["+e.count+"]条数据");$(".successcount").html("成功["+e.count+"]条");$(".errorcount").html("失败[0]条");$("#checkerrorfile").show();$("#acceptFileResultDlg").dialog("open")}}else{openMessageDlg(d.message)}}else{openMessageDlg(d.message)}},"json").error(function(){$(".error-msg-result").html("处理数据中途错误,请查看错误文件!");$(".handlecount").html("已处理["+handlecount+"]条数据");$(".successcount").html("成功["+successcount+"]条");$(".errorcount").html("失败["+errorcount+"]条");$("#checkerrorfile").show();$("#acceptFileResultDlg").dialog("open");$.messager.progress("close")})};