|
|
|
@ -55,8 +55,8 @@ public class IndexServiceImpl implements IndexService { |
|
|
|
calendar.add(Calendar.DATE,-1); |
|
|
|
SimpleDateFormat sdf =new SimpleDateFormat("yyyy-MM-dd"); |
|
|
|
String yesterday=sdf.format(calendar.getTime()); |
|
|
|
String yesterday_start = yesterday+"00:00:00"; |
|
|
|
String yesterday_end = yesterday+"23:59:59"; |
|
|
|
String yesterday_start = "'"+yesterday+" 00:00:00'"; |
|
|
|
String yesterday_end = "'"+yesterday+" 23:59:59'"; |
|
|
|
// 现在时刻
|
|
|
|
String nowtime=sdf.format(System.currentTimeMillis()); |
|
|
|
|
|
|
|
@ -83,16 +83,16 @@ public class IndexServiceImpl implements IndexService { |
|
|
|
//上架数量
|
|
|
|
Map xgmap = new HashMap(); |
|
|
|
xgmap.put("goods_status","1"); |
|
|
|
xgmap.put("createtime","between "+yesterday_start+" and "+yesterday_end); |
|
|
|
xgmap.put("btwstr","createtime between "+yesterday_start+" and "+yesterday_end); |
|
|
|
Integer shelfCount=goodsMapper.goodsCount(xgmap); |
|
|
|
result.put("shelf_count",shelfCount); |
|
|
|
result.put("shelf_count",shelfCount==null?0:shelfCount); |
|
|
|
|
|
|
|
//下架数量
|
|
|
|
Map ogmap = new HashMap(); |
|
|
|
ogmap.put("goods_status","2"); |
|
|
|
ogmap.put("canceltime","between "+yesterday_start+" and "+yesterday_end); |
|
|
|
ogmap.put("btwstr","canceltime between "+yesterday_start+" and "+yesterday_end); |
|
|
|
Integer outCount= goodsMapper.goodsCount(ogmap); |
|
|
|
result.put("out_count",goodsCount); |
|
|
|
result.put("out_count",outCount==null?0:outCount); |
|
|
|
|
|
|
|
//新增订单
|
|
|
|
Integer yesterOrderCount = orderMapper.countOrderTimeSection("createtime",yesterday_start,yesterday_end); |
|
|
|
|