All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.cory.dao.UserDao Maven / Gradle / Ivy

There is a newer version: 0.0.35
Show newest version
package com.cory.dao;

import com.cory.db.annotations.Dao;
import com.cory.db.annotations.Param;
import com.cory.db.annotations.Select;
import com.cory.db.annotations.Update;
import com.cory.model.User;

import java.util.Date;

/**
 * generated by CodeGenerator on 2017/5/10.
 */
@Dao(model = User.class)
public interface UserDao extends BaseDao {

    @Select(whereSql = "USER_NAME = #{userName}")
    User findByUserName(@Param("userName") String userName);

    @Update(columnSql = "LAST_LOGON_TIME = #{time}, LAST_LOGON_IP = #{ip}, LAST_LOGON_SUCCESS = #{success}", whereSql = "id = #{id}")
    void updateLastLogonInfo(@Param("id") Integer id,
                             @Param("ip") String ip,
                             @Param("success") boolean success,
                             @Param("time") Date time);

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy