|
@@ -33,6 +33,7 @@ import org.springframework.data.domain.Page;
|
|
|
import org.springframework.data.domain.Pageable;
|
|
import org.springframework.data.domain.Pageable;
|
|
|
import org.springframework.data.domain.Sort;
|
|
import org.springframework.data.domain.Sort;
|
|
|
import org.springframework.data.web.PageableDefault;
|
|
import org.springframework.data.web.PageableDefault;
|
|
|
|
|
+import org.springframework.format.annotation.DateTimeFormat;
|
|
|
import org.springframework.ui.ModelMap;
|
|
import org.springframework.ui.ModelMap;
|
|
|
import org.springframework.util.StringUtils;
|
|
import org.springframework.util.StringUtils;
|
|
|
import org.springframework.web.bind.annotation.PathVariable;
|
|
import org.springframework.web.bind.annotation.PathVariable;
|
|
@@ -50,6 +51,7 @@ import javax.servlet.http.HttpSession;
|
|
|
import java.io.*;
|
|
import java.io.*;
|
|
|
import java.text.SimpleDateFormat;
|
|
import java.text.SimpleDateFormat;
|
|
|
import java.util.ArrayList;
|
|
import java.util.ArrayList;
|
|
|
|
|
+import java.util.Date;
|
|
|
import java.util.HashMap;
|
|
import java.util.HashMap;
|
|
|
import java.util.List;
|
|
import java.util.List;
|
|
|
import java.util.Map;
|
|
import java.util.Map;
|
|
@@ -854,27 +856,29 @@ public class GoodsController {
|
|
|
* 通过分页参数获取品牌数量
|
|
* 通过分页参数获取品牌数量
|
|
|
*
|
|
*
|
|
|
* @param params 分页信息
|
|
* @param params 分页信息
|
|
|
- * @param filter 过滤条件
|
|
|
|
|
|
|
+ * @param endTime 截止时间
|
|
|
|
|
+ * @param startTime 开始时间
|
|
|
* @return Page<BrandCount>
|
|
* @return Page<BrandCount>
|
|
|
*/
|
|
*/
|
|
|
- @RequestMapping(value = "/brandProductsCount/page", method = RequestMethod.POST)
|
|
|
|
|
- public com.uas.sso.support.Page<BrandCount> getBrandProductsCount(PageParams params, @RequestBody GoodsFilter filter) {
|
|
|
|
|
|
|
+ @RequestMapping(value = "/brandProductsCount/page", method = RequestMethod.GET)
|
|
|
|
|
+ public com.uas.sso.support.Page<BrandCount> getBrandProductsCount(PageParams params, @DateTimeFormat(pattern = "yyyy-MM-dd") Date startTime, @DateTimeFormat(pattern = "yyyy-MM-dd") Date endTime) {
|
|
|
logger.info("后台产品管理", "分页获取品牌数量信息");
|
|
logger.info("后台产品管理", "分页获取品牌数量信息");
|
|
|
PageInfo info = new PageInfo(params);
|
|
PageInfo info = new PageInfo(params);
|
|
|
- return goodsService.getBrandProductsCount(info, filter);
|
|
|
|
|
|
|
+ return goodsService.getBrandProductsCount(info, startTime, endTime);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
* 通过分页参数获取类目数量
|
|
* 通过分页参数获取类目数量
|
|
|
*
|
|
*
|
|
|
* @param params 分页参数
|
|
* @param params 分页参数
|
|
|
- * @param filter 过滤条件
|
|
|
|
|
|
|
+ * @param endTime 截止时间
|
|
|
|
|
+ * @param startTime 开始时间
|
|
|
* @return Page<KindHierarchicalCount>
|
|
* @return Page<KindHierarchicalCount>
|
|
|
*/
|
|
*/
|
|
|
- @RequestMapping(value = "/kindProductsCount/page", method = RequestMethod.POST)
|
|
|
|
|
- public com.uas.sso.support.Page<KindHierarchicalCount> getKindProductsCount(PageParams params, @RequestBody GoodsFilter filter) {
|
|
|
|
|
|
|
+ @RequestMapping(value = "/kindProductsCount/page", method = RequestMethod.GET)
|
|
|
|
|
+ public com.uas.sso.support.Page<KindHierarchicalCount> getKindProductsCount(PageParams params, @DateTimeFormat(pattern = "yyyy-MM-dd") Date startTime, @DateTimeFormat(pattern = "yyyy-MM-dd") Date endTime) {
|
|
|
logger.info("后台产品管理", "分页获取类目数量信息");
|
|
logger.info("后台产品管理", "分页获取类目数量信息");
|
|
|
PageInfo info = new PageInfo(params);
|
|
PageInfo info = new PageInfo(params);
|
|
|
- return goodsService.getKindProductsCount(info, filter);
|
|
|
|
|
|
|
+ return goodsService.getKindProductsCount(info, startTime, endTime);
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|