优化首页统计
This commit is contained in:
@@ -796,8 +796,8 @@ public class DepotHeadService {
|
||||
return depotHeadMapperEx.getBuyAndSaleStatistics(type, subType, hasSupplier, beginTime, endTime);
|
||||
}
|
||||
|
||||
public BigDecimal getBuyAndSaleRetailStatistics(String type, String subType, Integer hasSupplier, String beginTime, String endTime) {
|
||||
return depotHeadMapperEx.getBuyAndSaleRetailStatistics(type, subType, hasSupplier, beginTime, endTime);
|
||||
public BigDecimal getBuyAndSaleRetailStatistics(String type, String subType, String beginTime, String endTime) {
|
||||
return depotHeadMapperEx.getBuyAndSaleRetailStatistics(type, subType, beginTime, endTime).abs();
|
||||
}
|
||||
|
||||
public DepotHead getDepotHead(String number)throws Exception {
|
||||
|
||||
@@ -298,6 +298,27 @@ public class DepotItemService {
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* 统计零售的总金额
|
||||
* @param type
|
||||
* @param subType
|
||||
* @param month
|
||||
* @return
|
||||
* @throws Exception
|
||||
*/
|
||||
public BigDecimal inOrOutRetailPrice(String type, String subType, String month) throws Exception{
|
||||
BigDecimal result= BigDecimal.ZERO;
|
||||
try{
|
||||
String beginTime = Tools.firstDayOfMonth(month) + BusinessConstants.DAY_FIRST_TIME;
|
||||
String endTime = Tools.lastDayOfMonth(month) + BusinessConstants.DAY_LAST_TIME;
|
||||
result = depotItemMapperEx.inOrOutRetailPrice(type, subType, beginTime, endTime);
|
||||
result = result.abs();
|
||||
}catch(Exception e){
|
||||
JshException.readFail(logger, e);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@Transactional(value = "transactionManager", rollbackFor = Exception.class)
|
||||
public void saveDetials(String rows, Long headerId, HttpServletRequest request) throws Exception{
|
||||
//查询单据主表信息
|
||||
|
||||
Reference in New Issue
Block a user