|
@@ -64,7 +64,7 @@ public class ReportFormServiceImpl implements IReportFormService {
|
|
|
private IGoodsMapper iGoodsMapper;
|
|
private IGoodsMapper iGoodsMapper;
|
|
|
|
|
|
|
|
@Override
|
|
@Override
|
|
|
- public PageResult<ShareAmountQueryResult> selectShareAmount(ShareAmountQueryParam param, HttpServletRequest request) {
|
|
|
|
|
|
|
+ public AjaxResult<ShareAmountQueryResult> selectShareAmount(ShareAmountQueryParam param, HttpServletRequest request) {
|
|
|
Systemmanager systemmanager = iSystemmanagerMapper.selectOne(new QueryWrapper<Systemmanager>().eq("LOGINCODE", iCommonService.getUserLoginCode(request)));
|
|
Systemmanager systemmanager = iSystemmanagerMapper.selectOne(new QueryWrapper<Systemmanager>().eq("LOGINCODE", iCommonService.getUserLoginCode(request)));
|
|
|
Object devidetype = redisServiceUtil.getCacheMapValue(Constants.REDIS_HEADER_SYSPARAM, SysConstants.SYSPARAM_CODE_DIVIDE);
|
|
Object devidetype = redisServiceUtil.getCacheMapValue(Constants.REDIS_HEADER_SYSPARAM, SysConstants.SYSPARAM_CODE_DIVIDE);
|
|
|
if (devidetype == null || "1".equals(devidetype.toString())) {
|
|
if (devidetype == null || "1".equals(devidetype.toString())) {
|
|
@@ -81,11 +81,9 @@ public class ReportFormServiceImpl implements IReportFormService {
|
|
|
param.setAreaid(systemmanager.getAreauserid());
|
|
param.setAreaid(systemmanager.getAreauserid());
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
- IPage<ShareAmountQueryResult> page = new Page<>(param.getPageNum(), param.getPageSize());
|
|
|
|
|
- IPage<ShareAmountQueryResult> resultIPage;
|
|
|
|
|
-
|
|
|
|
|
|
|
+ List<ShareAmountQueryResult> resultIPage;
|
|
|
if (param.getCycletype() == null || param.getCycletype() == 0) {
|
|
if (param.getCycletype() == null || param.getCycletype() == 0) {
|
|
|
- resultIPage = detailMapper.queryDayDivide(page, param);
|
|
|
|
|
|
|
+ resultIPage = detailMapper.queryDayDivide(param);
|
|
|
} else {
|
|
} else {
|
|
|
if (param.getCycletype() == 2 && param.getQuarter() != null) {
|
|
if (param.getCycletype() == 2 && param.getQuarter() != null) {
|
|
|
param.setTradedate(param.getTradedate() + param.getQuarter());
|
|
param.setTradedate(param.getTradedate() + param.getQuarter());
|
|
@@ -94,22 +92,13 @@ public class ReportFormServiceImpl implements IReportFormService {
|
|
|
param.setCycletime(param.getTradedate());
|
|
param.setCycletime(param.getTradedate());
|
|
|
param.setTradedate(null);
|
|
param.setTradedate(null);
|
|
|
}
|
|
}
|
|
|
- resultIPage = detailMapper.queryReportDivide(page, param);
|
|
|
|
|
|
|
+ resultIPage = detailMapper.queryReportDivide(param);
|
|
|
}
|
|
}
|
|
|
- PageResult<ShareAmountQueryResult> pageResult = new PageResult<>();
|
|
|
|
|
- pageResult.setCode(Constants.Success_Code_Design);
|
|
|
|
|
- pageResult.setMessage(AjaxResult.dealMsg(MessageType.MESSAGE_CODE_SYSTEM001.getCode(), request.getHeader("Accept-Language")));
|
|
|
|
|
- pageResult.setPages(resultIPage.getPages());
|
|
|
|
|
- pageResult.setCurrent(resultIPage.getCurrent());
|
|
|
|
|
- pageResult.setTotal(resultIPage.getTotal());
|
|
|
|
|
- pageResult.setPageSize(resultIPage.getSize());
|
|
|
|
|
- pageResult.setData(resultIPage.getRecords());
|
|
|
|
|
- return pageResult;
|
|
|
|
|
-
|
|
|
|
|
|
|
+ return AjaxResult.success(Constants.Success_Code_Design, MessageType.MESSAGE_CODE_SYSTEM001.getCode(), request.getHeader("Accept-Language"), resultIPage);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@Override
|
|
@Override
|
|
|
- public PageResult<ShareAmountQueryResult> shareAmountQueryPlat(ShareAmountQueryParam param, HttpServletRequest request) {
|
|
|
|
|
|
|
+ public AjaxResult<ShareAmountQueryResult> shareAmountQueryPlat(ShareAmountQueryParam param, HttpServletRequest request) {
|
|
|
//只能查询自己和下一级的
|
|
//只能查询自己和下一级的
|
|
|
Systemmanager systemmanager = iSystemmanagerMapper.selectOne(new QueryWrapper<Systemmanager>().eq("LOGINCODE", iCommonService.getUserLoginCode(request)));
|
|
Systemmanager systemmanager = iSystemmanagerMapper.selectOne(new QueryWrapper<Systemmanager>().eq("LOGINCODE", iCommonService.getUserLoginCode(request)));
|
|
|
if (systemmanager.getReletype() != 1) {
|
|
if (systemmanager.getReletype() != 1) {
|
|
@@ -119,29 +108,18 @@ public class ReportFormServiceImpl implements IReportFormService {
|
|
|
param.setParentuserid(systemmanager.getAreauserid());
|
|
param.setParentuserid(systemmanager.getAreauserid());
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
- IPage<ShareAmountQueryResult> page = new Page<>(param.getPageNum(), param.getPageSize());
|
|
|
|
|
- IPage<ShareAmountQueryResult> resultIPage;
|
|
|
|
|
-
|
|
|
|
|
|
|
+ List<ShareAmountQueryResult> resultIPage;
|
|
|
if (param.getCycletype() == 0) {
|
|
if (param.getCycletype() == 0) {
|
|
|
- resultIPage = detailMapper.queryByDate(page, param);
|
|
|
|
|
|
|
+ resultIPage = detailMapper.queryByDate(param);
|
|
|
} else {
|
|
} else {
|
|
|
//周、月、季、年、全
|
|
//周、月、季、年、全
|
|
|
if (param.getCycletype() == 2) {
|
|
if (param.getCycletype() == 2) {
|
|
|
//季报表
|
|
//季报表
|
|
|
param.setTradedate(param.getTradedate() + param.getQuarter());
|
|
param.setTradedate(param.getTradedate() + param.getQuarter());
|
|
|
}
|
|
}
|
|
|
- resultIPage = detailMapper.queryByOther(page, param);
|
|
|
|
|
|
|
+ resultIPage = detailMapper.queryByOther(param);
|
|
|
}
|
|
}
|
|
|
- PageResult<ShareAmountQueryResult> pageResult = new PageResult<>();
|
|
|
|
|
- pageResult.setCode(Constants.Success_Code_Design);
|
|
|
|
|
- pageResult.setMessage(AjaxResult.dealMsg(MessageType.MESSAGE_CODE_SYSTEM001.getCode(), request.getHeader("Accept-Language")));
|
|
|
|
|
- pageResult.setPages(resultIPage.getPages());
|
|
|
|
|
- pageResult.setCurrent(resultIPage.getCurrent());
|
|
|
|
|
- pageResult.setTotal(resultIPage.getTotal());
|
|
|
|
|
- pageResult.setPageSize(resultIPage.getSize());
|
|
|
|
|
- pageResult.setData(resultIPage.getRecords());
|
|
|
|
|
- return pageResult;
|
|
|
|
|
|
|
+ return AjaxResult.success(Constants.Success_Code_Design, MessageType.MESSAGE_CODE_SYSTEM001.getCode(), request.getHeader("Accept-Language"), resultIPage);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
|