Compare commits
4 Commits
fd85567f30
...
120ae1bd24
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
120ae1bd24 | ||
|
|
6e757ae650 | ||
|
|
099c3109f7 | ||
|
|
25873076c6 |
@@ -4,7 +4,7 @@ import cn.hutool.core.bean.BeanUtil;
|
||||
import com.github.pagehelper.Page;
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
||||
import com.lideeyunji.core.framework.enhance.example.report.xtsy.zhxsqkPlugin;
|
||||
import com.lideeyunji.core.framework.enhance.example.report.xtsy.ZhxsqkPlugin;
|
||||
import com.lideeyunji.core.framework.entity.NewGrBiSaAgg;
|
||||
import com.lideeyunji.core.framework.entity.NewGrBiSaAggMonthCount;
|
||||
import com.lideeyunji.core.framework.entity.NewGrBiSaAggYearCount;
|
||||
@@ -123,7 +123,7 @@ public class NewGrBiSaAggMonthCountController extends BaseController
|
||||
{
|
||||
Map<String, Object> params = FuncWeb.getParameterBodyMap(req);
|
||||
Page<Object> page = PageHelper.startPage(Integer.parseInt(params.get("pageNo").toString()), Integer.parseInt(params.get("pageSize").toString()));
|
||||
zhxsqkPlugin.setMonthOrderBy(params, page);
|
||||
ZhxsqkPlugin.setMonthOrderBy(params, page);
|
||||
List<NewGrBiSaAgg> newGrBiSaAggList = newGrBiSaAggService.selectNewGrBiSaAggList(params);
|
||||
PageInfo<NewGrBiSaAgg> pageInfo = new PageInfo<>(newGrBiSaAggList);
|
||||
List<Map<String, Object>> list = newGrBiSaAggList.stream().map(BeanUtil::beanToMap).collect(Collectors.toList());
|
||||
|
||||
@@ -0,0 +1,55 @@
|
||||
|
||||
package com.lideeyunji.core.framework.enhance.example.report.xtsy;
|
||||
|
||||
import com.lideeyunji.core.framework.config.aspect.enhancereport.model.EnhanceReportContext;
|
||||
import com.lideeyunji.core.framework.config.aspect.enhancereport.plugin.ReportAfterAdvicePlugin;
|
||||
import com.lideeyunji.core.framework.utils.Func;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 报表-库存全品种统计表-插件
|
||||
*/
|
||||
@Slf4j
|
||||
@Component("kcqmltjPlugin")
|
||||
public class KcqmltjPlugin implements ReportAfterAdvicePlugin {
|
||||
|
||||
@Override
|
||||
public void execute(EnhanceReportContext enhanceContext) {
|
||||
List<Map<String, Object>> records = enhanceContext.getResult().getRecords();
|
||||
if (Func.isEmpty(records)) {
|
||||
return;
|
||||
}
|
||||
|
||||
for(Map<String, Object> record : records){
|
||||
if(!record.containsKey("remmoney")){
|
||||
record.put("remmoney","-");
|
||||
}
|
||||
if(!record.containsKey("monthsamoney")){
|
||||
record.put("monthsamoney","-");
|
||||
}
|
||||
if(!record.containsKey("sksa")){
|
||||
record.put("sksa","-");
|
||||
}
|
||||
if(!record.containsKey("thissamoney")){
|
||||
record.put("thissamoney","-");
|
||||
}
|
||||
if(!record.containsKey("thisprofit")){
|
||||
record.put("thisprofit","-");
|
||||
}
|
||||
if(!record.containsKey("thisprofitrate")){
|
||||
record.put("thisprofitrate","-");
|
||||
}
|
||||
if(!record.containsKey("maxage")){
|
||||
record.put("maxage","-");
|
||||
}
|
||||
if(!record.containsKey("goodsid")){
|
||||
record.put("goodsid","-");
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
|
||||
package com.lideeyunji.core.framework.enhance.example.report.xtsy;
|
||||
|
||||
import com.lideeyunji.core.framework.config.aspect.enhancereport.model.EnhanceReportContext;
|
||||
import com.lideeyunji.core.framework.config.aspect.enhancereport.plugin.ReportAfterAdvicePlugin;
|
||||
import com.lideeyunji.core.framework.utils.Func;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 产品可销库存表- 增强
|
||||
*/
|
||||
@Component("prouctAvlPlugin")
|
||||
public class ProuctAvlPlugin implements ReportAfterAdvicePlugin {
|
||||
|
||||
@Override
|
||||
public void execute(EnhanceReportContext enhanceContext) {
|
||||
List<Map<String, Object>> records = enhanceContext.getResult().getRecords();
|
||||
if (Func.isEmpty(records)) {
|
||||
return;
|
||||
}
|
||||
|
||||
for(Map<String, Object> record : records){
|
||||
if(!record.containsKey("rem")){
|
||||
record.put("rem","-");
|
||||
}
|
||||
if(!record.containsKey("thismonthout")){
|
||||
record.put("thismonthout","-");
|
||||
}
|
||||
if(!record.containsKey("lastmonthout")){
|
||||
record.put("lastmonthout","-");
|
||||
}
|
||||
if(!record.containsKey("thisyearout")){
|
||||
record.put("thisyearout","-");
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,41 @@
|
||||
|
||||
package com.lideeyunji.core.framework.enhance.example.report.xtsy;
|
||||
|
||||
import com.lideeyunji.core.framework.config.aspect.enhancereport.model.EnhanceReportContext;
|
||||
import com.lideeyunji.core.framework.config.aspect.enhancereport.plugin.ReportAfterAdvicePlugin;
|
||||
import com.lideeyunji.core.framework.utils.Func;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 库存产品占比表- 增强
|
||||
*/
|
||||
@Component("prouctPlugin")
|
||||
public class ProuctPlugin implements ReportAfterAdvicePlugin {
|
||||
|
||||
@Override
|
||||
public void execute(EnhanceReportContext enhanceContext) {
|
||||
List<Map<String, Object>> records = enhanceContext.getResult().getRecords();
|
||||
if (Func.isEmpty(records)) {
|
||||
return;
|
||||
}
|
||||
|
||||
for(Map<String, Object> record : records){
|
||||
if(!record.containsKey("money_prop")){
|
||||
record.put("money_prop","-");
|
||||
}
|
||||
if(!record.containsKey("money")){
|
||||
record.put("money","-");
|
||||
}
|
||||
if(!record.containsKey("qty")){
|
||||
record.put("qty","-");
|
||||
}
|
||||
if(!record.containsKey("qty_prop")){
|
||||
record.put("qty_prop","-");
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -2,12 +2,15 @@
|
||||
package com.lideeyunji.core.framework.enhance.example.report.xtsy;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import cn.hutool.core.collection.ListUtil;
|
||||
import com.github.pagehelper.Page;
|
||||
import com.github.pagehelper.PageHelper;
|
||||
import com.github.pagehelper.PageInfo;
|
||||
import com.lideeyunji.core.framework.config.aspect.enhancereport.model.EnhanceReportContext;
|
||||
import com.lideeyunji.core.framework.config.aspect.enhancereport.plugin.ReportAroundAdvicePlugin;
|
||||
import com.lideeyunji.core.framework.entity.NewGrBiSaAggMonthCount;
|
||||
import com.lideeyunji.core.framework.entity.NewGrBiSaAggYearCount;
|
||||
import com.lideeyunji.core.framework.service.INewGrBiSaAggMonthCountService;
|
||||
import com.lideeyunji.core.framework.service.INewGrBiSaAggYearCountService;
|
||||
import com.lideeyunji.tool.framework.yunji.model.ResultDataModel;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
@@ -20,6 +23,8 @@ import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
import static com.lideeyunji.core.framework.enhance.example.report.xtsy.ZhxsqkPlugin.setMonthOrderBy;
|
||||
|
||||
/**
|
||||
* 报表-综合销售表_剂型-插件
|
||||
*/
|
||||
@@ -30,54 +35,75 @@ public class ZhxsqkPluginJx implements ReportAroundAdvicePlugin {
|
||||
@Resource
|
||||
INewGrBiSaAggYearCountService newGrBiSaAggYearCountService;
|
||||
|
||||
@Resource
|
||||
INewGrBiSaAggMonthCountService newGrBiSaAggMonthCountService;
|
||||
|
||||
@Override
|
||||
public ResultDataModel executeAround(EnhanceReportContext enhanceContext) {
|
||||
log.info("进入=======>zhxsqkPluginJx=======>execute");
|
||||
List<String> groupFieldList = Arrays.asList("useYear","dosageName");
|
||||
return zhxsqkFun(enhanceContext, groupFieldList, newGrBiSaAggYearCountService);
|
||||
List<String> groupFieldList = ListUtil.toList("useYear","dosageName");
|
||||
return zhxsqkFun(enhanceContext, groupFieldList, newGrBiSaAggYearCountService, newGrBiSaAggMonthCountService);
|
||||
}
|
||||
|
||||
@NotNull
|
||||
static ResultDataModel zhxsqkFun(EnhanceReportContext enhanceContext, List<String> groupFieldList, INewGrBiSaAggYearCountService newGrBiSaAggYearCountService) {
|
||||
static ResultDataModel zhxsqkFun(EnhanceReportContext enhanceContext, List<String> groupFieldList, INewGrBiSaAggYearCountService newGrBiSaAggYearCountService, INewGrBiSaAggMonthCountService newGrBiSaAggMonthCountService) {
|
||||
Map<String, Object> params = enhanceContext.getParam().getParams();
|
||||
Page<Object> page = PageHelper.startPage(Integer.parseInt(params.get("pageNo").toString()), Integer.parseInt(params.get("pageSize").toString()));
|
||||
if(params.containsKey("column")){
|
||||
String orderBy = "";
|
||||
if ("thisYearSaQty".equals(params.get("column"))) {
|
||||
orderBy = "this_year_sa_qty " + params.get("order").toString();
|
||||
}
|
||||
if ("saqty_yoy".equals(params.get("column"))) {
|
||||
orderBy = "CAST(TRIM(REGEXP_SUBSTR(saqty_yoy, '-?([0-9]+\\.?[0-9]*|[0-9]*\\.?[0-9]+)')) AS DECIMAL(10,2)) " + params.get("order").toString();
|
||||
}
|
||||
if ("thisYearSaMoney".equals(params.get("column"))) {
|
||||
orderBy = "this_year_sa_money " + params.get("order").toString();
|
||||
}
|
||||
if ("samoney_yoy".equals(params.get("column"))) {
|
||||
orderBy = "CAST(TRIM(REGEXP_SUBSTR(samoney_yoy, '-?([0-9]+\\.?[0-9]*|[0-9]*\\.?[0-9]+)')) AS DECIMAL(10,2)) " + params.get("order").toString();
|
||||
}
|
||||
if ("thisYearProfit".equals(params.get("column"))) {
|
||||
orderBy = "this_year_profit " + params.get("order").toString();
|
||||
}
|
||||
if ("profit_yoy".equals(params.get("column"))) {
|
||||
orderBy = "CAST(TRIM(REGEXP_SUBSTR(profit_yoy, '-?([0-9]+\\.?[0-9]*|[0-9]*\\.?[0-9]+)')) AS DECIMAL(10,2)) " + params.get("order").toString();
|
||||
}
|
||||
if ("thisYearCost".equals(params.get("column"))) {
|
||||
orderBy = "this_year_cost " + params.get("order").toString();
|
||||
}
|
||||
if ("thisYearSaMoneyShare".equals(params.get("column"))) {
|
||||
orderBy = "this_year_sa_money_share " + params.get("order").toString();
|
||||
}
|
||||
if ("thisprofitshare".equals(params.get("column"))) {
|
||||
orderBy = "thisprofitshare " + params.get("order").toString();
|
||||
}
|
||||
if ("thisYearSaMoneyGrowth".equals(params.get("column"))) {
|
||||
orderBy = "CAST(TRIM(REGEXP_SUBSTR(this_year_sa_money_growth, '-?([0-9]+\\.?[0-9]*|[0-9]*\\.?[0-9]+)')) AS DECIMAL(10,2)) " + params.get("order").toString();
|
||||
}
|
||||
page.setUnsafeOrderBy(orderBy);
|
||||
if(params.containsKey("useMonth")){
|
||||
groupFieldList.add("useMonth");
|
||||
params.put("useMonthStart", params.get("useMonth"));
|
||||
params.put("useMonthEnd", params.get("useMonth"));
|
||||
}
|
||||
List<NewGrBiSaAggYearCount> newGrBiSaAggList = newGrBiSaAggYearCountService.selectNewGrBiSaAggGroupYearList(params, groupFieldList);
|
||||
PageInfo<NewGrBiSaAggYearCount> pageInfo = new PageInfo<>(newGrBiSaAggList);
|
||||
List<Map<String, Object>> list = newGrBiSaAggList.stream().map(BeanUtil::beanToMap).collect(Collectors.toList());
|
||||
return ResultDataModel.fomat(pageInfo.getTotal(),list);
|
||||
if(params.containsKey("useYear")){
|
||||
params.put("useYearStart", params.get("useYear"));
|
||||
params.put("useYearEnd", params.get("useYear"));
|
||||
}
|
||||
Page<Object> page = PageHelper.startPage(Integer.parseInt(params.get("pageNo").toString()), Integer.parseInt(params.get("pageSize").toString()));
|
||||
if(groupFieldList.contains("useMonth") || params.containsKey("useMonth")){
|
||||
setMonthOrderBy(params, page);
|
||||
List<NewGrBiSaAggMonthCount> newGrBiSaAggList = newGrBiSaAggMonthCountService.selectNewGrBiSaAggGroupMonthList(params, groupFieldList);
|
||||
PageInfo<NewGrBiSaAggMonthCount> pageInfo = new PageInfo<>(newGrBiSaAggList);
|
||||
List<Map<String, Object>> list = newGrBiSaAggList.stream().map(BeanUtil::beanToMap).collect(Collectors.toList());
|
||||
return ResultDataModel.fomat(pageInfo.getTotal(),list);
|
||||
}else{
|
||||
if(params.containsKey("column")){
|
||||
String orderBy = "";
|
||||
if ("thisYearSaQty".equals(params.get("column"))) {
|
||||
orderBy = "this_year_sa_qty " + params.get("order").toString();
|
||||
}
|
||||
if ("saqty_yoy".equals(params.get("column"))) {
|
||||
orderBy = "CAST(TRIM(REGEXP_SUBSTR(saqty_yoy, '-?([0-9]+\\.?[0-9]*|[0-9]*\\.?[0-9]+)')) AS DECIMAL(10,2)) " + params.get("order").toString();
|
||||
}
|
||||
if ("thisYearSaMoney".equals(params.get("column"))) {
|
||||
orderBy = "this_year_sa_money " + params.get("order").toString();
|
||||
}
|
||||
if ("samoney_yoy".equals(params.get("column"))) {
|
||||
orderBy = "CAST(TRIM(REGEXP_SUBSTR(samoney_yoy, '-?([0-9]+\\.?[0-9]*|[0-9]*\\.?[0-9]+)')) AS DECIMAL(10,2)) " + params.get("order").toString();
|
||||
}
|
||||
if ("thisYearProfit".equals(params.get("column"))) {
|
||||
orderBy = "this_year_profit " + params.get("order").toString();
|
||||
}
|
||||
if ("profit_yoy".equals(params.get("column"))) {
|
||||
orderBy = "CAST(TRIM(REGEXP_SUBSTR(profit_yoy, '-?([0-9]+\\.?[0-9]*|[0-9]*\\.?[0-9]+)')) AS DECIMAL(10,2)) " + params.get("order").toString();
|
||||
}
|
||||
if ("thisYearCost".equals(params.get("column"))) {
|
||||
orderBy = "this_year_cost " + params.get("order").toString();
|
||||
}
|
||||
if ("thisYearSaMoneyShare".equals(params.get("column"))) {
|
||||
orderBy = "this_year_sa_money_share " + params.get("order").toString();
|
||||
}
|
||||
if ("thisprofitshare".equals(params.get("column"))) {
|
||||
orderBy = "thisprofitshare " + params.get("order").toString();
|
||||
}
|
||||
if ("thisYearSaMoneyGrowth".equals(params.get("column"))) {
|
||||
orderBy = "CAST(TRIM(REGEXP_SUBSTR(this_year_sa_money_growth, '-?([0-9]+\\.?[0-9]*|[0-9]*\\.?[0-9]+)')) AS DECIMAL(10,2)) " + params.get("order").toString();
|
||||
}
|
||||
page.setUnsafeOrderBy(orderBy);
|
||||
}
|
||||
List<NewGrBiSaAggYearCount> newGrBiSaAggList = newGrBiSaAggYearCountService.selectNewGrBiSaAggGroupYearList(params, groupFieldList);
|
||||
PageInfo<NewGrBiSaAggYearCount> pageInfo = new PageInfo<>(newGrBiSaAggList);
|
||||
List<Map<String, Object>> list = newGrBiSaAggList.stream().map(BeanUtil::beanToMap).collect(Collectors.toList());
|
||||
return ResultDataModel.fomat(pageInfo.getTotal(),list);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,15 +1,16 @@
|
||||
|
||||
package com.lideeyunji.core.framework.enhance.example.report.xtsy;
|
||||
|
||||
import cn.hutool.core.collection.ListUtil;
|
||||
import com.lideeyunji.core.framework.config.aspect.enhancereport.model.EnhanceReportContext;
|
||||
import com.lideeyunji.core.framework.config.aspect.enhancereport.plugin.ReportAroundAdvicePlugin;
|
||||
import com.lideeyunji.core.framework.service.INewGrBiSaAggMonthCountService;
|
||||
import com.lideeyunji.core.framework.service.INewGrBiSaAggYearCountService;
|
||||
import com.lideeyunji.tool.framework.yunji.model.ResultDataModel;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
import static com.lideeyunji.core.framework.enhance.example.report.xtsy.ZhxsqkPluginJx.zhxsqkFun;
|
||||
@@ -24,10 +25,14 @@ public class ZhxsqkPluginLxfl implements ReportAroundAdvicePlugin {
|
||||
@Resource
|
||||
INewGrBiSaAggYearCountService newGrBiSaAggYearCountService;
|
||||
|
||||
@Resource
|
||||
INewGrBiSaAggMonthCountService newGrBiSaAggMonthCountService;
|
||||
|
||||
|
||||
@Override
|
||||
public ResultDataModel executeAround(EnhanceReportContext enhanceContext) {
|
||||
log.info("进入=======>zhxsqkPluginLxfl=======>execute");
|
||||
List<String> groupFieldList = Arrays.asList("useYear","effectName");
|
||||
return zhxsqkFun(enhanceContext, groupFieldList, newGrBiSaAggYearCountService);
|
||||
List<String> groupFieldList = ListUtil.toList("useYear","effectName");
|
||||
return zhxsqkFun(enhanceContext, groupFieldList, newGrBiSaAggYearCountService, newGrBiSaAggMonthCountService);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,15 +1,16 @@
|
||||
|
||||
package com.lideeyunji.core.framework.enhance.example.report.xtsy;
|
||||
|
||||
import cn.hutool.core.collection.ListUtil;
|
||||
import com.lideeyunji.core.framework.config.aspect.enhancereport.model.EnhanceReportContext;
|
||||
import com.lideeyunji.core.framework.config.aspect.enhancereport.plugin.ReportAroundAdvicePlugin;
|
||||
import com.lideeyunji.core.framework.service.INewGrBiSaAggMonthCountService;
|
||||
import com.lideeyunji.core.framework.service.INewGrBiSaAggYearCountService;
|
||||
import com.lideeyunji.tool.framework.yunji.model.ResultDataModel;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
import static com.lideeyunji.core.framework.enhance.example.report.xtsy.ZhxsqkPluginJx.zhxsqkFun;
|
||||
@@ -24,10 +25,14 @@ public class ZhxsqkPluginXslx implements ReportAroundAdvicePlugin {
|
||||
@Resource
|
||||
INewGrBiSaAggYearCountService newGrBiSaAggYearCountService;
|
||||
|
||||
@Resource
|
||||
INewGrBiSaAggMonthCountService newGrBiSaAggMonthCountService;
|
||||
|
||||
|
||||
@Override
|
||||
public ResultDataModel executeAround(EnhanceReportContext enhanceContext) {
|
||||
log.info("进入=======>zhxsqkPluginXslx=======>execute");
|
||||
List<String> groupFieldList = Arrays.asList("useYear","saleTypeName");
|
||||
return zhxsqkFun(enhanceContext, groupFieldList, newGrBiSaAggYearCountService);
|
||||
List<String> groupFieldList = ListUtil.toList("useYear","saleTypeName");
|
||||
return zhxsqkFun(enhanceContext, groupFieldList, newGrBiSaAggYearCountService, newGrBiSaAggMonthCountService);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package com.lideeyunji.core.framework.service.impl;
|
||||
|
||||
import cn.hutool.core.collection.CollUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.baomidou.dynamic.datasource.annotation.DS;
|
||||
import com.baomidou.dynamic.datasource.annotation.DSTransactional;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
@@ -100,6 +101,24 @@ public class NewGrBiSaAggServiceImpl extends ServiceImpl<NewGrBiSaAggMapper, New
|
||||
log.info("删除数量:{}", reNum);
|
||||
int result = 0;
|
||||
for (NewGrBiSaAgg grBiSaSetdtl : grBiSaSetdtlList) {
|
||||
if(StrUtil.isBlank(grBiSaSetdtl.getStdGoodsName())){
|
||||
grBiSaSetdtl.setStdGoodsName("其他");
|
||||
}
|
||||
if(StrUtil.isBlank(grBiSaSetdtl.getCustomName())){
|
||||
grBiSaSetdtl.setCustomName("-");
|
||||
}
|
||||
if(StrUtil.isBlank(grBiSaSetdtl.getSalerName())){
|
||||
grBiSaSetdtl.setSalerName("-");
|
||||
}
|
||||
if(StrUtil.isBlank(grBiSaSetdtl.getZoneName())){
|
||||
grBiSaSetdtl.setZoneName("-");
|
||||
}
|
||||
if(StrUtil.isBlank(grBiSaSetdtl.getDosageName())){
|
||||
grBiSaSetdtl.setDosageName("-");
|
||||
}
|
||||
if(StrUtil.isBlank(grBiSaSetdtl.getSaleTypeName())){
|
||||
grBiSaSetdtl.setSaleTypeName("-");
|
||||
}
|
||||
int re = this.baseMapper.insert(grBiSaSetdtl);
|
||||
if (re < 1) {
|
||||
throw new RuntimeException("批量新增异常");
|
||||
|
||||
@@ -658,6 +658,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
current_month.dosage_id,
|
||||
current_month.dosage_name,
|
||||
</if>
|
||||
<if test="groupFieldList.contains('effectName') || params.containsKey('effectName')">
|
||||
current_month.effect_id,
|
||||
current_month.effect_name,
|
||||
</if>
|
||||
<if test="groupFieldList.contains('stdGoodsName') || params.containsKey('stdGoodsName')">
|
||||
current_month.std_goods_name,
|
||||
</if>
|
||||
@@ -756,7 +760,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
dosage_id,
|
||||
dosage_name,
|
||||
</if>
|
||||
|
||||
<if test="groupFieldList.contains('effectName') || params.containsKey('effectName')">
|
||||
effect_id,
|
||||
effect_name,
|
||||
</if>
|
||||
<if test="groupFieldList.contains('salerName') || params.containsKey('salerName')">
|
||||
saler_id,
|
||||
saler_name,
|
||||
@@ -799,6 +806,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
#{name}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="saAggParam.effectName != null and saAggParam.effectName != ''"> and effect_name in
|
||||
<foreach collection="saAggParam.effectName" item="name" open="(" separator="," close=")">
|
||||
#{name}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="saAggParam.goodsName != null and saAggParam.goodsName != ''"> and goods_name in
|
||||
<foreach collection="saAggParam.goodsName" item="name" open="(" separator="," close=")">
|
||||
#{name}
|
||||
@@ -846,6 +858,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
dosage_id,
|
||||
dosage_name,
|
||||
</if>
|
||||
<if test="groupFieldList.contains('effectName') || params.containsKey('effectName')">
|
||||
effect_id,
|
||||
effect_name,
|
||||
</if>
|
||||
<if test="groupFieldList.contains('salerName') || params.containsKey('salerName')">
|
||||
saler_id,
|
||||
saler_name,
|
||||
@@ -873,6 +889,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="groupFieldList.contains('dosageName') || params.containsKey('dosageName')">
|
||||
dosage_id,
|
||||
</if>
|
||||
<if test="groupFieldList.contains('effectName') || params.containsKey('effectName')">
|
||||
effect_id,
|
||||
</if>
|
||||
<if test="groupFieldList.contains('salerName') || params.containsKey('salerName')">
|
||||
saler_id,
|
||||
</if>
|
||||
@@ -902,6 +921,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="groupFieldList.contains('dosageName') || params.containsKey('dosageName')">
|
||||
dosage_id,
|
||||
</if>
|
||||
<if test="groupFieldList.contains('effectName') || params.containsKey('effectName')">
|
||||
effect_id,
|
||||
</if>
|
||||
<if test="groupFieldList.contains('salerName') || params.containsKey('salerName')">
|
||||
saler_id,
|
||||
</if>
|
||||
@@ -926,6 +948,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="groupFieldList.contains('dosageName') || params.containsKey('dosageName')">
|
||||
AND current_month.dosage_id = last_month_data.dosage_id
|
||||
</if>
|
||||
<if test="groupFieldList.contains('effectName') || params.containsKey('effectName')">
|
||||
AND current_month.effect_id = last_month_data.effect_id
|
||||
</if>
|
||||
<if test="groupFieldList.contains('salerName') || params.containsKey('salerName')">
|
||||
AND current_month.saler_id = last_month_data.saler_id
|
||||
</if>
|
||||
@@ -950,6 +975,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="groupFieldList.contains('dosageName') || params.containsKey('dosageName')">
|
||||
dosage_id,
|
||||
</if>
|
||||
<if test="groupFieldList.contains('effectName') || params.containsKey('effectName')">
|
||||
effect_id,
|
||||
</if>
|
||||
<if test="groupFieldList.contains('salerName') || params.containsKey('salerName')">
|
||||
saler_id,
|
||||
</if>
|
||||
@@ -981,6 +1009,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
#{name}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="saAggParam.effectName != null and saAggParam.effectName != ''"> and effect_name in
|
||||
<foreach collection="saAggParam.effectName" item="name" open="(" separator="," close=")">
|
||||
#{name}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="saAggParam.goodsName != null and saAggParam.goodsName != ''"> and goods_name in
|
||||
<foreach collection="saAggParam.goodsName" item="name" open="(" separator="," close=")">
|
||||
#{name}
|
||||
@@ -1024,6 +1057,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="groupFieldList.contains('dosageName') || params.containsKey('dosageName')">
|
||||
dosage_id,
|
||||
</if>
|
||||
<if test="groupFieldList.contains('effectName') || params.containsKey('effectName')">
|
||||
effect_id,
|
||||
</if>
|
||||
<if test="groupFieldList.contains('salerName') || params.containsKey('salerName')">
|
||||
saler_id,
|
||||
</if>
|
||||
@@ -1050,6 +1086,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="groupFieldList.contains('dosageName') || params.containsKey('dosageName')">
|
||||
AND yoy_month.dosage_id = current_month.dosage_id
|
||||
</if>
|
||||
<if test="groupFieldList.contains('effectName') || params.containsKey('effectName')">
|
||||
AND yoy_month.effect_id = current_month.effect_id
|
||||
</if>
|
||||
<if test="groupFieldList.contains('salerName') || params.containsKey('salerName')">
|
||||
AND yoy_month.saler_id = current_month.saler_id
|
||||
</if>
|
||||
@@ -1091,6 +1130,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
#{name}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="saAggParam.effectName != null and saAggParam.effectName != ''"> and current_month.effect_name in
|
||||
<foreach collection="saAggParam.effectName" item="name" open="(" separator="," close=")">
|
||||
#{name}
|
||||
</foreach>
|
||||
</if>
|
||||
<if test="saAggParam.goodsName != null and saAggParam.goodsName != ''"> and current_month.goods_name in
|
||||
<foreach collection="saAggParam.goodsName" item="name" open="(" separator="," close=")">
|
||||
#{name}
|
||||
|
||||
Reference in New Issue
Block a user