|
|
|
@ -77,6 +77,7 @@ import org.apache.commons.lang3.RandomUtils;
|
|
|
|
|
import org.apache.commons.lang3.StringUtils;
|
|
|
|
|
import org.apache.commons.lang3.time.DateFormatUtils;
|
|
|
|
|
import org.apache.commons.lang3.time.DateUtils;
|
|
|
|
|
import org.joda.time.DateTime;
|
|
|
|
|
import org.jsoup.Jsoup;
|
|
|
|
|
import org.jsoup.nodes.Document;
|
|
|
|
|
import org.slf4j.LoggerFactory;
|
|
|
|
@ -855,7 +856,15 @@ public class RetailAppServiceImp implements RetailAppService {
|
|
|
|
|
params.put("dev_id", device.getString("dev_id"));
|
|
|
|
|
}
|
|
|
|
|
params.put("client_id", client_id);
|
|
|
|
|
|
|
|
|
|
if (StringUtils.isBlank(params.getString("begin"))) {
|
|
|
|
|
Date now = new Date();
|
|
|
|
|
Date lastWeekDay = DateUtils.addDays(now, -7);
|
|
|
|
|
lastWeekDay = new DateTime(lastWeekDay.getTime()).withTimeAtStartOfDay().toDate();
|
|
|
|
|
params.put("from", lastWeekDay);
|
|
|
|
|
params.put("begin", lastWeekDay);
|
|
|
|
|
params.put("end", now);
|
|
|
|
|
params.put("to", now);
|
|
|
|
|
}
|
|
|
|
|
PageList<JSONObject> orders = orderMapper.listTransactionsForApp(params,
|
|
|
|
|
new PageBounds(query.getPage(), query.getLimit(), Order.formString("transaction_time.desc")));
|
|
|
|
|
TimeZoneUtils.switchTimeZone(orders, query.getTimezone(), "create_time", "transaction_time", "confirm_time");
|
|
|
|
|