puzhibing
2023-02-11 521efb9bc33d52ef4772f0b30f8a371ba4b0070c
ManagementIGOTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/system/service/impl/TCarColorServiceImpl.java
@@ -1,6 +1,7 @@
package com.stylefeng.guns.modular.system.service.impl;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import com.stylefeng.guns.core.util.ToolUtil;
import com.stylefeng.guns.modular.system.dao.TCarColorMapper;
import com.stylefeng.guns.modular.system.model.TCarColor;
import com.stylefeng.guns.modular.system.service.ITCarColorService;
@@ -31,8 +32,14 @@
    @Override
    public Map<String, Object> list(String createTime, String name, Integer offset, Integer limit) throws Exception {
        Map<String, Object> map = new HashMap<>();
        List<Map<String, Object>> list = tCarColorMapper.list(createTime, name, offset, limit);
        int i = tCarColorMapper.listCount(createTime, name);
        String start = "";
        String end = "";
        if(ToolUtil.isNotEmpty(createTime)){
            start = createTime.split(" - ")[0];
            end = createTime.split(" - ")[1];
        }
        List<Map<String, Object>> list = tCarColorMapper.list(start, end, name, offset, limit);
        int i = tCarColorMapper.listCount(start, end, name);
        map.put("rows", list);
        map.put("total", i);
        return map;