src/com/marry/service/impl/GrapherServiceImpl.java

(完整代码) 1KB

package com.marry.service.impl;

import com.github.pagehelper.PageHelper;
import com.github.pagehelper.PageInfo;
import com.marry.dao.GrapherMapper;
import com.marry.entity.Grapher;
import com.marry.service.GrapherService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

@Service("grapherService")
public class GrapherServiceImpl implements GrapherService {
    @Autowired
    private GrapherMapper grapherMapper;

    @Override
    public int delete(Integer uid) {
        return grapherMapper.delete(uid);
    }

    @Override
    public int insert(Grapher record) {
        return grapherMapper.insert(record);
    }

    @Override
    public List<Grapher> selectList() {
        return grapherMapper.selectList(null);
    }

    @Override
    public Grapher select(Integer id) {
        return grapherMapper.select(id);
    }

    @Override
    public PageInfo<Grapher> selectList(String name,String tel,Integer pageNo) {
        PageHelper.startPage(pageNo,15);
        Map<String,Object> params=new HashMap<String,Object>();
        params.put("name",name);
        params.put("tel",tel);
        return new PageInfo<Grapher>(grapherMapper.selectList(params));
    }

    @Override
    public int update(Grapher record) {
        return grapherMapper.update(record);
    }
}

24 小时内免费解锁 3 个项目,之后 1 算力/个。 规则说明

AI 解读 AI

登录后可用,每次 10 算力,解读结果公开显示在下面。

还没有人解读过这个文件。