给采购销售统计和出入库汇总接口增加数据角色类型参数
This commit is contained in:
@@ -472,20 +472,23 @@ public class DepotHeadService {
|
||||
}
|
||||
|
||||
public List<DepotHeadVo4InOutMCount> findInOutMaterialCount(String beginTime, String endTime, String type, String materialParam,
|
||||
List<Long> depotList, Integer oId, Integer offset, Integer rows)throws Exception {
|
||||
List<Long> depotList, Integer oId, String roleType, Integer offset, Integer rows)throws Exception {
|
||||
List<DepotHeadVo4InOutMCount> list = null;
|
||||
try{
|
||||
list =depotHeadMapperEx.findInOutMaterialCount(beginTime, endTime, type, materialParam, depotList, oId, offset, rows);
|
||||
String [] creatorArray = getCreatorArray(roleType);
|
||||
list =depotHeadMapperEx.findInOutMaterialCount(beginTime, endTime, type, materialParam, depotList, oId, creatorArray, offset, rows);
|
||||
}catch(Exception e){
|
||||
JshException.readFail(logger, e);
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
public int findInOutMaterialCountTotal(String beginTime, String endTime, String type, String materialParam, List<Long> depotList, Integer oId)throws Exception {
|
||||
public int findInOutMaterialCountTotal(String beginTime, String endTime, String type, String materialParam,
|
||||
List<Long> depotList, Integer oId, String roleType)throws Exception {
|
||||
int result = 0;
|
||||
try{
|
||||
result =depotHeadMapperEx.findInOutMaterialCountTotal(beginTime, endTime, type, materialParam, depotList, oId);
|
||||
String [] creatorArray = getCreatorArray(roleType);
|
||||
result =depotHeadMapperEx.findInOutMaterialCountTotal(beginTime, endTime, type, materialParam, depotList, oId, creatorArray);
|
||||
}catch(Exception e){
|
||||
JshException.readFail(logger, e);
|
||||
}
|
||||
|
||||
@@ -305,33 +305,36 @@ public class DepotItemService {
|
||||
return result;
|
||||
}
|
||||
|
||||
public List<DepotItemVo4WithInfoEx> getListWithBugOrSale(String materialParam, String billType, String beginTime, String endTime, Integer offset, Integer rows)throws Exception {
|
||||
public List<DepotItemVo4WithInfoEx> getListWithBugOrSale(String materialParam, String billType,
|
||||
String beginTime, String endTime, String[] creatorArray, Integer offset, Integer rows)throws Exception {
|
||||
List<DepotItemVo4WithInfoEx> list =null;
|
||||
try{
|
||||
list = depotItemMapperEx.getListWithBugOrSale(materialParam, billType, beginTime, endTime, offset, rows);
|
||||
list = depotItemMapperEx.getListWithBugOrSale(materialParam, billType, beginTime, endTime, creatorArray, offset, rows);
|
||||
}catch(Exception e){
|
||||
JshException.readFail(logger, e);
|
||||
}
|
||||
return list;
|
||||
}
|
||||
|
||||
public int getListWithBugOrSaleCount(String materialParam, String billType, String beginTime, String endTime)throws Exception {
|
||||
public int getListWithBugOrSaleCount(String materialParam, String billType,
|
||||
String beginTime, String endTime, String[] creatorArray)throws Exception {
|
||||
int result=0;
|
||||
try{
|
||||
result = depotItemMapperEx.getListWithBugOrSaleCount(materialParam, billType, beginTime, endTime);
|
||||
result = depotItemMapperEx.getListWithBugOrSaleCount(materialParam, billType, beginTime, endTime, creatorArray);
|
||||
}catch(Exception e){
|
||||
JshException.readFail(logger, e);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public BigDecimal buyOrSale(String type, String subType, Long MId, String beginTime, String endTime, String sumType) throws Exception{
|
||||
public BigDecimal buyOrSale(String type, String subType, Long MId, String beginTime, String endTime,
|
||||
String[] creatorArray, String sumType) throws Exception{
|
||||
BigDecimal result= BigDecimal.ZERO;
|
||||
try{
|
||||
if (SUM_TYPE.equals(sumType)) {
|
||||
result= depotItemMapperEx.buyOrSaleNumber(type, subType, MId, beginTime, endTime, sumType);
|
||||
result= depotItemMapperEx.buyOrSaleNumber(type, subType, MId, beginTime, endTime, creatorArray, sumType);
|
||||
} else {
|
||||
result= depotItemMapperEx.buyOrSalePrice(type, subType, MId, beginTime, endTime, sumType);
|
||||
result= depotItemMapperEx.buyOrSalePrice(type, subType, MId, beginTime, endTime, creatorArray, sumType);
|
||||
}
|
||||
}catch(Exception e){
|
||||
JshException.readFail(logger, e);
|
||||
|
||||
Reference in New Issue
Block a user