From af6d43a41205f8c7fc1a965cb019c039063bf4f0 Mon Sep 17 00:00:00 2001 From: puzhibing <393733352@qq.com> Date: 星期三, 13 十二月 2023 01:15:07 +0800 Subject: [PATCH] 更新接口 --- DriverIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/service/impl/OrderEvaluateServiceImpl.java | 9 ++++++++- 1 files changed, 8 insertions(+), 1 deletions(-) diff --git a/DriverIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/service/impl/OrderEvaluateServiceImpl.java b/DriverIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/service/impl/OrderEvaluateServiceImpl.java index 28e8e38..84a0f37 100644 --- a/DriverIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/service/impl/OrderEvaluateServiceImpl.java +++ b/DriverIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/service/impl/OrderEvaluateServiceImpl.java @@ -4,6 +4,7 @@ import com.stylefeng.guns.modular.system.dao.OrderEvaluateMapper; import com.stylefeng.guns.modular.system.model.OrderEvaluate; import com.stylefeng.guns.modular.system.service.IOrderEvaluateService; +import com.stylefeng.guns.modular.system.util.DateUtil; import org.springframework.stereotype.Service; import javax.annotation.Resource; @@ -32,11 +33,17 @@ * @throws Exception */ @Override - public Map<String, Object> queryEvaluate(Integer pageNum, Integer size, Integer uid) throws Exception { + public Map<String, Object> queryEvaluate(Integer language, Integer pageNum, Integer size, Integer uid) throws Exception { pageNum = (pageNum - 1) * size; Map<String, Object> map = new HashMap<>(); Double aDouble = orderEvaluateMapper.queryCount(uid); List<Map<String, Object>> list = orderEvaluateMapper.queryEvaluate(pageNum, size, uid); + for (Map<String, Object> objectMap : list) { + if(null != objectMap.get("insertTime")){ + String insertTime = objectMap.get("insertTime").toString(); + objectMap.put("insertTime", DateUtil.conversionFormat(language, insertTime)); + } + } map.put("sumScore", null != aDouble ? new BigDecimal(aDouble).setScale(1, BigDecimal.ROUND_HALF_EVEN).doubleValue() : 0); map.put("list", list); return map; -- Gitblit v1.7.1