Index: ssts-web/src/main/webapp/disinfectsystem/config/blxrmyy/config.js =================================================================== diff -u -r23310 -r23315 --- ssts-web/src/main/webapp/disinfectsystem/config/blxrmyy/config.js (.../config.js) (revision 23310) +++ ssts-web/src/main/webapp/disinfectsystem/config/blxrmyy/config.js (.../config.js) (revision 23315) @@ -72,5 +72,7 @@ //是否启用聚合包功能 enableComboTousse: true, //如果配置为不需要在单位前加上最小申请数量时,则用原单位,否则加上最小申请数量与斜杠 - notNeedMinApplyAmountBeforeUnit : true + notNeedMinApplyAmountBeforeUnit : true, + //科室申领列表自动刷新间隔时间(单位:秒) + autoRefreshApplicationDataIntervalSeconds : 30 } \ No newline at end of file Index: ssts-web/src/main/webapp/disinfectsystem/recyclingApplication/goodsApplicationView.js =================================================================== diff -u -r23306 -r23315 --- ssts-web/src/main/webapp/disinfectsystem/recyclingApplication/goodsApplicationView.js (.../goodsApplicationView.js) (revision 23306) +++ ssts-web/src/main/webapp/disinfectsystem/recyclingApplication/goodsApplicationView.js (.../goodsApplicationView.js) (revision 23315) @@ -1801,6 +1801,23 @@ return "
" + v + "
"; } +/** + * 渲染汇总状态的颜色 + * @param v + * @param p + * @param record + * @returns {String} + */ +function renderGatherStatusColor(v, p, record){ + var color = ""; + if(v == gatherStatusYes){//未汇总 黄色 + color = "red"; + }else if(statusArr[1] == gatherStatusNo){ //已汇总 绿色 + color = "green"; + } + return "" + v + "
"; +} + function renderColor2(v, p, record){ var status = record.data['recyclingStatus']; var color = ""; @@ -2882,7 +2899,7 @@ {header : "类型",width : 105 * fontSizeScale,dataIndex : 'type'}, {header : "已提交",width : 45 * fontSizeScale,dataIndex : 'committedStatus', renderer : renderStatus}, {header : "已打印",width : 45 * fontSizeScale,dataIndex : 'printed', renderer : renderPrintStatu}, - {header : "汇总状态",width : 65 * fontSizeScale,dataIndex : 'gatherStatus', renderer : renderColor}, + {header : "汇总状态",width : 65 * fontSizeScale,dataIndex : 'gatherStatus',hidden : !sstsConfig.enableGatherRecyclingApplication, renderer : renderGatherStatusColor}, {header : "回收状态",width : 65 * fontSizeScale,dataIndex : 'recyclingStatus', renderer : renderColor2}, {header : "发货状态",width : 65 * fontSizeScale,dataIndex : 'deliverStatus', renderer : renderColor}, {header : "住院号",width : 65 * fontSizeScale,dataIndex : 'hospitalNumber',hidden : isHideHospitalNumber}, @@ -3169,6 +3186,26 @@ null ); + //如果设置了定时自动刷新,则定时刷新(单位为秒) + var autoRefreshApplicationDataIntervalSeconds = sstsConfig.autoRefreshApplicationDataIntervalSeconds; + if(autoRefreshApplicationDataIntervalSeconds){ + try{ + if(isNaN(autoRefreshApplicationDataIntervalSeconds)){ + showResult('定时自动刷新时长的参数设置有误,只能设置为正整数,请检查,当前参数设置为:' + autoRefreshApplicationDataIntervalSeconds); + }else{ + var seconds = parseInt(autoRefreshApplicationDataIntervalSeconds); + grid.getStore().on('load',function(store){ + window.setTimeout(function(){ + //showResult('申请单列表数据已更新'); + grid.dwrReload(); + },seconds * 1000); + }); + } + }catch(e){ + showResult('定时自动刷新时长的参数设置有误,只能设置为正整数,请检查,当前参数设置为:' + autoRefreshApplicationDataIntervalSeconds); + } + } + //如果开始日期为当天则设置开始时间为当天,否则设置开始时间为服务器当天当月第一天 sstsConfig.startDateIsToday ? getServerTime('yyyy-MM-dd', Ext, 'startDate') : getServerTime('yyyy-MM-dd', Ext, 'startDate', null, WWWROOT + '/system/serverTimeAction!getFirstDay.do'); //设置结束时间为服务器当天时间 @@ -3234,7 +3271,7 @@ content += voItems[i].delivered === false ? "style='background-color: palevioletred'>" : ">"; //如果是未完全发货的话背景色显示为红色 content += ForeignContent + - "