| | |
| | | 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; |
| | |
| | | @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; |