Index: ssts-basedata/src/main/java/com/forgon/disinfectsystem/vo/ApplicationItemVO.java =================================================================== diff -u -r18435 -r21392 --- ssts-basedata/src/main/java/com/forgon/disinfectsystem/vo/ApplicationItemVO.java (.../ApplicationItemVO.java) (revision 18435) +++ ssts-basedata/src/main/java/com/forgon/disinfectsystem/vo/ApplicationItemVO.java (.../ApplicationItemVO.java) (revision 21392) @@ -12,7 +12,10 @@ private int amount;//申请的数量 - private int invoiceAmount;//已发货的数量 + /** + * 已发货的数量 + */ + private int invoiceAmount = 0; private int recyclingAmount;//回收数量 @@ -39,8 +42,33 @@ * 该物品是否已发货 */ private boolean delivered; + + /** + * 拆分数量 + */ + private Integer splitAmount = 0; + + /** + * 已装配数量 + */ + private Integer packedAmount = 0; + + /** + * 已灭菌数量 + */ + private Integer sterilizationAmount = 0; + + /** + * 医生名称 + */ + private String doctor; + + /** + * 供应商名称 + */ + private String supplierName; + - public String getName() { return name; } @@ -145,6 +173,46 @@ this.delivered = delivered; } + public Integer getPackedAmount() { + return packedAmount; + } + + public void setPackedAmount(Integer packedAmount) { + this.packedAmount = packedAmount; + } + + public Integer getSterilizationAmount() { + return sterilizationAmount; + } + + public void setSterilizationAmount(Integer sterilizationAmount) { + this.sterilizationAmount = sterilizationAmount; + } + + public Integer getSplitAmount() { + return splitAmount; + } + + public void setSplitAmount(Integer splitAmount) { + this.splitAmount = splitAmount; + } + + public String getDoctor() { + return doctor; + } + + public void setDoctor(String doctor) { + this.doctor = doctor; + } + + public String getSupplierName() { + return supplierName; + } + + public void setSupplierName(String supplierName) { + this.supplierName = supplierName; + } + @Override public String toString() { return "ApplicationItemVO{" + @@ -160,6 +228,11 @@ ", material='" + material + '\'' + ", amountDisplay='" + amountDisplay + '\'' + ", delivered=" + delivered + + ", splitAmount=" + splitAmount + + ", packedAmount=" + packedAmount + + ", sterilizationAmount=" + sterilizationAmount + + ", doctor='" + doctor + '\'' + + ", supplierName='" + supplierName + '\'' + '}'; } } Index: ssts-recyclingapplication/src/main/java/com/forgon/disinfectsystem/recyclingapplication/service/InvoicePlanManagerImpl.java =================================================================== diff -u -r21390 -r21392 --- ssts-recyclingapplication/src/main/java/com/forgon/disinfectsystem/recyclingapplication/service/InvoicePlanManagerImpl.java (.../InvoicePlanManagerImpl.java) (revision 21390) +++ ssts-recyclingapplication/src/main/java/com/forgon/disinfectsystem/recyclingapplication/service/InvoicePlanManagerImpl.java (.../InvoicePlanManagerImpl.java) (revision 21392) @@ -706,6 +706,36 @@ if (applicationItems != null) { for (TousseItem item : applicationItems) { ApplicationItemVO vo = new ApplicationItemVO(); + vo.setInvoiceAmount(item.getSendOutAmount()); + + List tousseInstances = objectDao.findBySql( + TousseInstance.class.getSimpleName(), String.format("where invoicePlanID=%s ", re.getId())); + + //设置“供应商名称”、“医生名称”、“拆分数量”、“已装配数量”、“已灭菌数量”、“已发货数量” + if (item.isForeignTousse() && re instanceof ForeignTousseApplication && DatabaseUtil.isPoIdValid(item.getTousseDefinitionId())) { + ForeignTousseApplication fta = (ForeignTousseApplication) re; + vo.setSupplierName(fta.getSupplierName()); + vo.setDoctor(fta.getDoctor()); + int splitAmount = objectDao.countBySql( + String.format("select count(0) from ClassifiedItem where tousseDefinitionID=%s", item.getTousseDefinitionId())); + vo.setSplitAmount(splitAmount); + } + if (CollectionUtils.isNotEmpty(tousseInstances)) { + vo.setPackedAmount(tousseInstances.size()); //已装配数量 + Integer sterilizationAmount = 0; //已灭菌数量 + Integer invoiceAmount = 0; //已发货数量 + for (TousseInstance tousseInstance : tousseInstances) { + if (DatabaseUtil.isPoIdValid(tousseInstance.getSterilizationRecord_id())) { + ++sterilizationAmount; + } + if (DatabaseUtil.isPoIdValid(tousseInstance.getInvoice_id())) { + ++invoiceAmount; + } + } + vo.setSterilizationAmount(sterilizationAmount); + vo.setInvoiceAmount(invoiceAmount); + } + vo.setName(item.getTousseName()); vo.setAmount(MathTools.object2Integer(item.getAmount())); vo.setAmountDisplay(String.valueOf(vo.getAmount())); @@ -714,7 +744,7 @@ recyclingAmount = 0; } vo.setRecyclingAmount(recyclingAmount); - vo.setInvoiceAmount(item.getSendOutAmount()); +// vo.setInvoiceAmount(item.getSendOutAmount()); //设置是否已发货状态 vo.setDelivered(deliverManager.calculateIsDelivered(item)); Index: ssts-web/src/main/webapp/disinfectsystem/recyclingApplication/goodsApplicationView.js =================================================================== diff -u -r21380 -r21392 --- ssts-web/src/main/webapp/disinfectsystem/recyclingApplication/goodsApplicationView.js (.../goodsApplicationView.js) (revision 21380) +++ ssts-web/src/main/webapp/disinfectsystem/recyclingApplication/goodsApplicationView.js (.../goodsApplicationView.js) (revision 21392) @@ -2490,7 +2490,9 @@ Ext4.tip.QuickTipManager.init(); Ext4.apply(Ext4.tip.QuickTipManager.getQuickTip(), { - dismissDelay: 0, + maxWidth: 1200, + minWidth: 100, + dismissDelay: 0, showDelay: 0 }); top.Ext4.tip.QuickTipManager.init(); @@ -2866,26 +2868,68 @@ var index = grid.getView().findRowIndex(e.getTarget());// 根据mouse所在的target可以取到列的位置 if (index !== false) {// 当取到了正确的列时,(因为如果传入的target列没有取到的时候会返回false) var record = this.getStore().getAt(index); + //1、借物单特有的 var BorrowName = ''; var BorrowAmount = ''; - var isDiposableApplicationForm = (record.data['type']==diposableGoodsApplicationForm); + //2、外来器械包申请单特有的 + var ForeignName = ''; + var ForeignContent = ''; + //3、装配数量和灭菌数量 + var PackAndSterileName = ''; + var PackAndSterileContent = ''; + + var isForeignTousseApplicationForm = record.data['type'] == '外来器械包申请单'; //是否外来器械包申请单 + var isDiposableApplicationForm = (record.data['type']==diposableGoodsApplicationForm); //是否外来器械包申请单 tableContent = record.data['htmlContent'];// if(!tableContent){ var content = ""; DWREngine.setAsync(false); InvoicePlanTableManager.findApplicationItemVOListByInvoicePlanId(record.data['id'],function(voItems){ for(var i=0;i"; } - var recyclingAmount = voItems[i].recyclingAmount; + if(isForeignTousseApplicationForm){ + ForeignName = + "

供应商

" + + "

医生名称

" + + "

拆包数量

"; + ForeignContent = + "" + voItems[i].supplierName+"" + + "" + voItems[i].doctor+"" + + "" + voItems[i].splitAmount+""; + } + + if (!isDiposableApplicationForm) { + PackAndSterileName = + "

装配数量

" + + "

灭菌数量

"; + PackAndSterileContent = + "" + packedAmount+"" + + "" + sterilizationAmount+""; + } content += "" : ">"; - content +=" " + tousseName +"" + voItems[i].amountDisplay+"" + recyclingAmount+"" + voItems[i].invoiceAmount+"" + BorrowAmount; - // content +=" " + tousseName +"" + voItems[i].amount+"" + recyclingAmount+"" + voItems[i].invoiceAmount+""+BorrowAmount; + content += + ForeignContent + + " " + tousseName +"" + + "" + voItems[i].amountDisplay+"" + + "" + recyclingAmount+"" + + PackAndSterileContent + + "" + invoiceAmount+"" + + BorrowAmount; + + + //一次性物品加编号 if(isDiposableApplicationForm){ var code = voItems[i].externalCode; @@ -2908,15 +2952,23 @@ } }); DWREngine.setAsync(true); - tableContent = (""+BorrowName); + tableContent = ("

物品名称

申请数量

回收数量

已发货数量

" + + "" + + ForeignName + + "" + + "" + + "" + + PackAndSterileName + + "" + + BorrowName); if(isDiposableApplicationForm){ tableContent += ""; } tableContent += "" + content + "

物品名称

申请数量

回收数量

发货数量

编码


"; record.set("htmlContent",tableContent); } e.getTarget().setAttribute('data-qtip', tableContent); - e.getTarget().setAttribute('data-qwidth', 450); +// e.getTarget().setAttribute('data-qwidth', 1000); e.getTarget().setAttribute('data-qtitle', ' 申请物品列表:'); } });