| 
					
				 | 
			
			
				@@ -3,7 +3,6 @@ package com.ruoyi.reportManagement.service.impl; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 import com.baomidou.mybatisplus.core.toolkit.CollectionUtils; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 import com.ruoyi.basicData.domain.TCustomerContact; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-import com.ruoyi.basicData.mapper.TCorpsMapper; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 import com.ruoyi.basicData.mapper.TCustomerContactMapper; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 import com.ruoyi.basicData.mapper.TWarehouseMapper; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 import com.ruoyi.common.core.domain.entity.TWarehouse; 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -18,7 +17,6 @@ import com.ruoyi.reportManagement.excel.Whgenleg; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 import com.ruoyi.reportManagement.mapper.TWhgenlegMapper; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 import com.ruoyi.reportManagement.service.ITWhgenlegService; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 import com.ruoyi.warehouseBusiness.domain.TWarehouseBills; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-import com.ruoyi.warehouseBusiness.excel.ListMapToBeanUtils; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 import com.ruoyi.warehouseBusiness.mapper.TWarehouseBillsMapper; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 import org.springframework.beans.factory.annotation.Autowired; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				 import org.springframework.stereotype.Service; 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -42,7 +40,7 @@ public class TWhgenlegServiceImpl implements ITWhgenlegService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     private TWarehouseBillsMapper tWarehouseBillsMapper; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     @Autowired 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-    private TWarehouseMapper  tWarehouseMapper; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    private TWarehouseMapper tWarehouseMapper; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     @Autowired 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     private TCustomerContactMapper customerContactMapper; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -80,16 +78,16 @@ public class TWhgenlegServiceImpl implements ITWhgenlegService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * 出库、调拨、货转查询库存总账列表 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * @param tWhgenleg 库存总账 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-     *      * @return 库存总账集合 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+     *                  * @return 库存总账集合 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     @Override 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     public List<Map<String, Object>> selectInventoryList(TWhgenleg tWhgenleg) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        if(StringUtils.isNotNull(tWhgenleg.getfWarehouseLocationid())){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        if (StringUtils.isNotNull(tWhgenleg.getfWarehouseLocationid())) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             // 获取仓库信息 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            TWarehouse tWarehouse =  tWarehouseMapper.selectTWarehouseById(tWhgenleg.getfWarehouseLocationid()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            if(tWarehouse.getfLocation()==1){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            TWarehouse tWarehouse = tWarehouseMapper.selectTWarehouseById(tWhgenleg.getfWarehouseLocationid()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            if (tWarehouse.getfLocation() == 1) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 tWhgenleg.setfLocation(1L); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            }else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 tWhgenleg.setfLocation(0L); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -104,12 +102,12 @@ public class TWhgenlegServiceImpl implements ITWhgenlegService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     @Override 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     public List<Map<String, Object>> selectInventoryMapList(TWhgenleg tWhgenleg) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        if(StringUtils.isNotNull(tWhgenleg.getfWarehouseLocationid())){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        if (StringUtils.isNotNull(tWhgenleg.getfWarehouseLocationid())) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             // 获取仓库信息 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            TWarehouse tWarehouse =  tWarehouseMapper.selectTWarehouseById(tWhgenleg.getfWarehouseLocationid()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            if(tWarehouse.getfLocation()==1){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            TWarehouse tWarehouse = tWarehouseMapper.selectTWarehouseById(tWhgenleg.getfWarehouseLocationid()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            if (tWarehouse.getfLocation() == 1) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 tWhgenleg.setfLocation(1L); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            }else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 tWhgenleg.setfLocation(0L); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -118,12 +116,12 @@ public class TWhgenlegServiceImpl implements ITWhgenlegService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     @Override 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     public List<Map<String, Object>> selectWhgenlegList(TWhgenleg tWhgenleg) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        if(StringUtils.isNotNull(tWhgenleg.getfWarehouseLocationid())){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        if (StringUtils.isNotNull(tWhgenleg.getfWarehouseLocationid())) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             // 获取仓库信息 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            TWarehouse tWarehouse =  tWarehouseMapper.selectTWarehouseById(tWhgenleg.getfWarehouseLocationid()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            if(tWarehouse.getfLocation()==1){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            TWarehouse tWarehouse = tWarehouseMapper.selectTWarehouseById(tWhgenleg.getfWarehouseLocationid()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            if (tWarehouse.getfLocation() == 1) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 tWhgenleg.setfLocation(1L); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            }else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 tWhgenleg.setfLocation(0L); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -182,61 +180,61 @@ public class TWhgenlegServiceImpl implements ITWhgenlegService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         Map<String, Object> map = new HashMap<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         // 查询仓库 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         List<Map<String, Object>> whouseList; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        if(null!= fId &&  fId!=0){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            whouseList= tWhgenlegMapper.selectWareHouseListWhouse(fId); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        }else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            whouseList= tWhgenlegMapper.selectWareHouseList(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        if (null != fId && fId != 0) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            whouseList = tWhgenlegMapper.selectWareHouseListWhouse(fId); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            whouseList = tWhgenlegMapper.selectWareHouseList(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        if(null!=whouseList && whouseList.size()>0){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        if (null != whouseList && whouseList.size() > 0) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             String fid = null; //获取 第一个 仓库ID 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            for(Map<String, Object> m : whouseList){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            for (Map<String, Object> m : whouseList) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 String fGrossweightblc = null; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                for (String k : m.keySet()){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    if(k.equals("fWarehouseid")){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        fid= m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                for (String k : m.keySet()) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    if (k.equals("fWarehouseid")) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        fid = m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    if(k.equals("fGrossweightD")){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        fGrossweightblc=  m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    if (k.equals("fGrossweightD")) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        fGrossweightblc = m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                m.put("fGrossweightD",calculation2(fGrossweightblc,"1000")); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                m.put("fGrossweightD", calculation2(fGrossweightblc, "1000")); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 break; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             //通过ID 查询仓库下 所有的 商品 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            List<Map<String, Object>> goodslistWhouse=tWhgenlegMapper.selectGoodsListWhouse(Long.parseLong(fid)); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            for (Map<String, Object> m : goodslistWhouse){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                String  fTotalgross = null; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            List<Map<String, Object>> goodslistWhouse = tWhgenlegMapper.selectGoodsListWhouse(Long.parseLong(fid)); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            for (Map<String, Object> m : goodslistWhouse) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                String fTotalgross = null; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 String fGrossweightblc = null; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                for (String k : m.keySet()){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                for (String k : m.keySet()) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     // 获取毛重库容 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    if(k.equals("fTotalgross")){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        fTotalgross= m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    if (k.equals("fTotalgross")) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        fTotalgross = m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    if(k.equals("fGrossweightD")){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        fGrossweightblc=  m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    if (k.equals("fGrossweightD")) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        fGrossweightblc = m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                m.put("balance",calculation1(fTotalgross,fGrossweightblc)); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                m.put("fGrossweightD",calculation2(fGrossweightblc,"1000")); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                m.put("balance", calculation1(fTotalgross, fGrossweightblc)); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                m.put("fGrossweightD", calculation2(fGrossweightblc, "1000")); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             map.put("goodslistWhouse", goodslistWhouse); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             // 查询仓库下 所有的 客户 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            List<Map<String, Object>> corpsListWhouse=tWhgenlegMapper.selectCorpsListWhouse(Long.parseLong(fid)); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            List<Map<String, Object>> corpsListWhouse = tWhgenlegMapper.selectCorpsListWhouse(Long.parseLong(fid)); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             // 计算库容 总剩余 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            for (Map<String, Object> m : corpsListWhouse){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                String  fTotalgross = null; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            for (Map<String, Object> m : corpsListWhouse) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                String fTotalgross = null; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 String fGrossweightblc = null; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                for (String k : m.keySet()){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                for (String k : m.keySet()) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     // 获取毛重库容 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    if(k.equals("fTotalgross")){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        fTotalgross= m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    if (k.equals("fTotalgross")) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        fTotalgross = m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    if(k.equals("fGrossweightD")){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        fGrossweightblc=  m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    if (k.equals("fGrossweightD")) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        fGrossweightblc = m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                m.put("balance",calculation1(fTotalgross,fGrossweightblc)); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                m.put("fGrossweightD",calculation2(fGrossweightblc,"1000")); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                m.put("balance", calculation1(fTotalgross, fGrossweightblc)); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                m.put("fGrossweightD", calculation2(fGrossweightblc, "1000")); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             map.put("corpsListWhouse", corpsListWhouse); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } else { 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -260,24 +258,24 @@ public class TWhgenlegServiceImpl implements ITWhgenlegService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     public List<Map<String, Object>> selectWareHouseList() { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         List<Map<String, Object>> list = new ArrayList<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         list = tWhgenlegMapper.selectWareHouseList(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        if(list!=null && list.size()>0){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            for (Map<String, Object> m : list){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                String  fTotalgross = null; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        if (list != null && list.size() > 0) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            for (Map<String, Object> m : list) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                String fTotalgross = null; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 String fGrossweightblc = null; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                for (String k : m.keySet()){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                for (String k : m.keySet()) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     // 获取毛重库容 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    if(k.equals("fTotalgross")){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        fTotalgross= m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    if (k.equals("fTotalgross")) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        fTotalgross = m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    if(k.equals("fGrossweightD")){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        fGrossweightblc=  m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    if (k.equals("fGrossweightD")) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        fGrossweightblc = m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                m.put("percentage",calculation(fGrossweightblc,fTotalgross)); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                m.put("fGrossweightD",calculation2(fGrossweightblc,"1000")); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                m.put("percentage", calculation(fGrossweightblc, fTotalgross)); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                m.put("fGrossweightD", calculation2(fGrossweightblc, "1000")); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            List<TWarehouse> tWarehouses= tWarehouseMapper.selectTWarehouseList(new TWarehouse()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            List<TWarehouse> tWarehouses = tWarehouseMapper.selectTWarehouseList(new TWarehouse()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             for (TWarehouse tWarehouse : tWarehouses) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 Map<String, Object> maps = new HashMap<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 maps.put("fName", tWarehouse.getfName()); 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -294,7 +292,7 @@ public class TWhgenlegServiceImpl implements ITWhgenlegService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     @Override 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     public List<Map<String, Object>> selectWareHouseLists() { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         List<Map<String, Object>> list = new ArrayList<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        List<TWarehouse> tWarehouses= tWarehouseMapper.selectTWarehouseLists(new TWarehouse()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        List<TWarehouse> tWarehouses = tWarehouseMapper.selectTWarehouseLists(new TWarehouse()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         for (TWarehouse tWarehouse : tWarehouses) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             Map<String, Object> maps = new HashMap<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             maps.put("fName", tWarehouse.getfName()); 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -311,37 +309,37 @@ public class TWhgenlegServiceImpl implements ITWhgenlegService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     public Map<String, Object> selectCorpsList(Long fId) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         Map<String, Object> map = new HashMap<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         // 查询所有 客户 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        List<Map<String, Object>> corpsList=tWhgenlegMapper.selectCorpsList(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        List<Map<String, Object>> corpsList = tWhgenlegMapper.selectCorpsList(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         map.put("corpsList", corpsList); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        if(corpsList!=null){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        if (corpsList != null) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             Long fid = null; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            for(Map<String, Object> m : corpsList){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                for (String k : m.keySet()){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    if(k.equals("fCorpid")){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        fid= (Long) m.get(k); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            for (Map<String, Object> m : corpsList) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                for (String k : m.keySet()) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    if (k.equals("fCorpid")) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        fid = (Long) m.get(k); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     break; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             List<Map<String, Object>> corpsListWhouse; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            if(null!= fId ){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                corpsListWhouse=tWhgenlegMapper.selectCorpsListWhouse(fId); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            }else{ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                corpsListWhouse=tWhgenlegMapper.selectCorpsListWhouse(fid); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            if (null != fId) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                corpsListWhouse = tWhgenlegMapper.selectCorpsListWhouse(fId); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                corpsListWhouse = tWhgenlegMapper.selectCorpsListWhouse(fid); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            for (Map<String, Object> m : corpsListWhouse){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                String  fTotalgross = null; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            for (Map<String, Object> m : corpsListWhouse) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                String fTotalgross = null; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 String fGrossweightblc = null; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                for (String k : m.keySet()){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                for (String k : m.keySet()) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     // 获取毛重库容 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    if(k.equals("fTotalgross")){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        fTotalgross= m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    if (k.equals("fTotalgross")) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        fTotalgross = m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                    if(k.equals("fGrossweightD")){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                        fGrossweightblc=  m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                    if (k.equals("fGrossweightD")) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                        fGrossweightblc = m.get(k).toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                m.put("percentage",calculation(fGrossweightblc,fTotalgross)); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                m.put("percentage", calculation(fGrossweightblc, fTotalgross)); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             map.put("corpsListWhouse", corpsListWhouse); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -353,41 +351,41 @@ public class TWhgenlegServiceImpl implements ITWhgenlegService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         // 当天往前推 一周 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         SimpleDateFormat format = new SimpleDateFormat("yyyy-MM-dd "); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         Calendar c = Calendar.getInstance(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        c.add(Calendar.DATE, - 8); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        c.add(Calendar.DATE, -8); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         String frontday = format.format(c.getTime()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         // 当前日期 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        String nowadays=DateUtils.getDate(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        String nowadays = DateUtils.getDate(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         Map<String, Object> map = new HashMap<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         map.put("frontday", frontday); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         map.put("nowadays", nowadays); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        List<Map<String, Object>>  list= tWhgenlegMapper.selectDateFQtyblcListList(map); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        List<Map<String, Object>> list = tWhgenlegMapper.selectDateFQtyblcListList(map); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         // 对比 日期 为空入库赋值0 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        ArrayList<String> pastDaysList=dayList(8); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        for(String day:pastDaysList){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            if(!day.equals(nowadays)){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        ArrayList<String> pastDaysList = dayList(8); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        for (String day : pastDaysList) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            if (!day.equals(nowadays)) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 Map<String, Object> map1 = new HashMap<String, Object>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                map1.put("fOriginalbilldate",day); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                map1.put("fQtyblc",0); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                map1.put("fOriginalbilldate", day); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                map1.put("fQtyblc", 0); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 list.add(map1); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        List<Map<String,Object>> countList = combineMap("fOriginalbilldate", list); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        List<Map<String, Object>> countList = combineMap("fOriginalbilldate", list); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         return countList; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     @Override 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     public List<Whgenleg> whgenlegExport(TWhgenleg tWhgenleg) throws Exception { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        if(StringUtils.isNotNull(tWhgenleg.getfWarehouseLocationid())){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        if (StringUtils.isNotNull(tWhgenleg.getfWarehouseLocationid())) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             // 获取仓库信息 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            TWarehouse tWarehouse =  tWarehouseMapper.selectTWarehouseById(tWhgenleg.getfWarehouseLocationid()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            if(tWarehouse.getfLocation()==1){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            TWarehouse tWarehouse = tWarehouseMapper.selectTWarehouseById(tWhgenleg.getfWarehouseLocationid()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            if (tWarehouse.getfLocation() == 1) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 tWhgenleg.setfLocation(1L); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            }else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 tWhgenleg.setfLocation(0L); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        List<Whgenleg> list =  tWhgenlegMapper.selectWhgenlegMessage(tWhgenleg); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        List<Whgenleg> list = tWhgenlegMapper.selectWhgenlegMessage(tWhgenleg); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         //List<Whgenleg> list1 = ListMapToBeanUtils.castMapToBean(list,Whgenleg.class); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         return list; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     } 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -400,9 +398,10 @@ public class TWhgenlegServiceImpl implements ITWhgenlegService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     /** 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-     *  查询单票分析信息 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+     * 查询单票分析信息 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+     * 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * @param singleAnalysisExcel 查询条件 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-     * @return  结果 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+     * @return 结果 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     @Override 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     public List<SingleAnalysisExcel> selectSingleAnalysis(SingleAnalysisExcel singleAnalysisExcel) { 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -410,7 +409,8 @@ public class TWhgenlegServiceImpl implements ITWhgenlegService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     /** 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-     *  查询单票分析费用信息 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+     * 查询单票分析费用信息 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+     * 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * @param singleAnalysisExcel 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * @return 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      */ 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -426,38 +426,37 @@ public class TWhgenlegServiceImpl implements ITWhgenlegService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     @Override 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     public List<Map<String, Object>> appWhGenLegList(TWhgenleg tWhgenleg) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        List<Map<String,Object>> list = new ArrayList<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        List<Map<String, Object>> list = new ArrayList<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         TCustomerContact customerContact = new TCustomerContact(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         customerContact.setfTel(SecurityUtils.getLoginUser().getUser().getPhonenumber()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         List<TCustomerContact> tCustomerContacts = customerContactMapper.selectTCustomerContactList(customerContact); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        if (CollectionUtils.isNotEmpty(tCustomerContacts)){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        if (CollectionUtils.isNotEmpty(tCustomerContacts)) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             tWhgenleg.setfCorpid(tCustomerContacts.get(0).getfPid()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-            if(StringUtils.isNotNull(tWhgenleg.getfWarehouseLocationid())){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+            if (StringUtils.isNotNull(tWhgenleg.getfWarehouseLocationid())) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 // 获取仓库信息 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                TWarehouse tWarehouse =  tWarehouseMapper.selectTWarehouseById(tWhgenleg.getfWarehouseLocationid()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                if(tWarehouse.getfLocation()==1){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                TWarehouse tWarehouse = tWarehouseMapper.selectTWarehouseById(tWhgenleg.getfWarehouseLocationid()); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                if (tWarehouse.getfLocation() == 1) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     tWhgenleg.setfLocation(1L); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-                }else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+                } else { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                     tWhgenleg.setfLocation(0L); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				                 } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             list = tWhgenlegMapper.selectInventoryMapList(tWhgenleg); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        if (SecurityUtils.getUsername().equals("admin")){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        if (SecurityUtils.getUsername().equals("admin")) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             list = tWhgenlegMapper.selectInventoryMapList(tWhgenleg); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         return list; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     /** 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-     * 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * @param fOriginalbilldate 根据该字段进行合并 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-     * @param dataList 原始数据 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+     * @param dataList          原始数据 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * @return 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-    public static List<Map<String, Object>> combineMap(String fOriginalbilldate, List<Map<String, Object>> dataList){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    public static List<Map<String, Object>> combineMap(String fOriginalbilldate, List<Map<String, Object>> dataList) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         //用于存放最后的结果 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        List<Map<String, Object>> countList = new ArrayList<Map<String,Object>>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        List<Map<String, Object>> countList = new ArrayList<Map<String, Object>>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         for (int i = 0; i < dataList.size(); i++) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             String oldCombineField = String.valueOf(dataList.get(i).get(fOriginalbilldate)); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -482,16 +481,18 @@ public class TWhgenlegServiceImpl implements ITWhgenlegService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     /** 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * 获取过去 任意天内的日期数组 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-     * @param intervals      intervals天内 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-     * @return              日期数组 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+     * 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+     * @param intervals intervals天内 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+     * @return 日期数组 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-    public static ArrayList<String> dayList(int intervals ) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    public static ArrayList<String> dayList(int intervals) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         ArrayList<String> pastDaysList = new ArrayList<>(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        for (int i = 0; i <intervals; i++) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        for (int i = 0; i < intervals; i++) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				             pastDaysList.add(getPastDate(i)); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         return pastDaysList; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     /** 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * 获取过去第几天的日期 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * 
			 | 
		
	
	
		
			
				| 
					
				 | 
			
			
				@@ -508,44 +509,47 @@ public class TWhgenlegServiceImpl implements ITWhgenlegService { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     /** 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-     *    返回百分比 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+     * 返回百分比 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+     * 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * @param fTotalgross 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * @param fGrossweightblc 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * @return 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-    public static String  calculation(String  fTotalgross, String fGrossweightblc){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    public static String calculation(String fTotalgross, String fGrossweightblc) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         BigDecimal num1 = new BigDecimal(fTotalgross); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         BigDecimal num2 = new BigDecimal(fGrossweightblc); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        BigDecimal result = num1.divide(num2,2,BigDecimal.ROUND_HALF_UP); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        int i = new Double(result.doubleValue()*100).intValue(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        String str = i +  "%"; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        BigDecimal result = num1.divide(num2, 2, BigDecimal.ROUND_HALF_UP); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        int i = new Double(result.doubleValue() * 100).intValue(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        String str = i + "%"; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         return str; 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     /** 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-     *   结余数/1000 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+     * 结余数/1000 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+     * 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * @param fTotalgross 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * @param fGrossweightblc 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * @return 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-    public static String  calculation2(String  fTotalgross, String fGrossweightblc){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    public static String calculation2(String fTotalgross, String fGrossweightblc) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         BigDecimal num1 = new BigDecimal(fTotalgross); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         BigDecimal num2 = new BigDecimal(fGrossweightblc); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        BigDecimal result = num1.divide(num2,2,BigDecimal.ROUND_HALF_UP); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        BigDecimal result = num1.divide(num2, 2, BigDecimal.ROUND_HALF_UP); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         return result.toString(); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     /** 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-     *   库容-结余毛重 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+     * 库容-结余毛重 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+     * 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * @param fTotalgross 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * @param fGrossweightblc 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      * @return 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				      */ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-    public static BigDecimal  calculation1(String  fTotalgross, String fGrossweightblc){ 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+    public static BigDecimal calculation1(String fTotalgross, String fGrossweightblc) { 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         BigDecimal num1 = new BigDecimal(fTotalgross); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         BigDecimal num2 = new BigDecimal(fGrossweightblc); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				         BigDecimal result = num1.subtract(num2); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				-        return result.setScale(2,BigDecimal.ROUND_HALF_UP); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				+        return result.setScale(2, BigDecimal.ROUND_HALF_UP); 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				     } 
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 | 
		
	
		
			
				 | 
				 | 
			
			
				  
			 |