AccountDao.java 838 字节
Newer Older
Xiang想`'s avatar
Xiang想` 已提交
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37
package cn.itcast.dao;

import cn.itcast.domain.Account;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * @version v1.0
 * @ProjectName: springmvc
 * @ClassName: AccountDao
 * @Description: TODO(账号)
 * @Author: Array
 * @Date: 2020/5/16 13:04
 */
@Repository
public interface AccountDao {

    /**
     * 查询所有账户信息
     * @return list 所有成员
     * @author Array
     * @date 2020/5/16 13:04
     */
    @Select("select * from account")
    public List<Account> findAll();
    
    /**
     * 保存账户信息
     * @author Array
     * @date 2020/5/16 13:05
     */
    @Insert("insert into account(name,money) values(#{name},#{money})")
    public void saveAccount(Account account);
}