package com.iplatform.model.po;
|
|
import com.walker.jdbc.BaseMapper;
|
import com.walker.jdbc.ResultSetUtils;
|
import com.walker.jdbc.SqlAndParameters;
|
import com.walker.jdbc.sqlgen.DeleteBuilder;
|
import com.walker.jdbc.sqlgen.InsertBuilder;
|
import com.walker.jdbc.sqlgen.SelectBuilder;
|
import com.walker.jdbc.sqlgen.UpdateBuilder;
|
import com.walker.jdbc.util.StringUtils;
|
|
import org.springframework.jdbc.core.RowMapper;
|
|
import java.sql.ResultSet;
|
import java.sql.SQLException;
|
import java.util.Map;
|
|
/**
|
* 表名:S_USER_CORE *
|
* @author genrator
|
*/
|
public class S_user_core_mapper extends S_user_core implements BaseMapper<S_user_core> {
|
// 序列化版本号
|
private static final long serialVersionUID = 1L;
|
|
public static final RowMapper<S_user_core> ROW_MAPPER = new S_user_coreRowMapper();
|
|
// 主键
|
public static final String ID = "id";
|
// 普通属性
|
public static final String DEPT_ID = "dept_id";
|
public static final String ORG_ID = "org_id";
|
public static final String USER_NAME = "user_name";
|
public static final String NICK_NAME = "nick_name";
|
public static final String USER_TYPE = "user_type";
|
public static final String EMAIL = "email";
|
public static final String PHONENUMBER = "phonenumber";
|
public static final String SEX = "sex";
|
public static final String AVATAR = "avatar";
|
public static final String PASSWORD = "password";
|
public static final String STATUS = "status";
|
public static final String DEL_FLAG = "del_flag";
|
public static final String LOGIN_IP = "login_ip";
|
public static final String LOGIN_DATE = "login_date";
|
public static final String CREATE_BY = "create_by";
|
public static final String CREATE_TIME = "create_time";
|
public static final String UPDATE_BY = "update_by";
|
public static final String UPDATE_TIME = "update_time";
|
public static final String REMARK = "remark";
|
public static final String WX_OPEN_ID = "wx_open_id";
|
public static final String WX_UNION_ID = "wx_union_id";
|
public static final String DING_USER_ID = "ding_user_id";
|
public static final String BIND_CLIENT_ID = "bind_client_id";
|
public static final String BIND_WECHAT = "bind_wechat";
|
public static final String MODIFY_PWD = "modify_pwd";
|
public static final String BIND_MOBILE = "bind_mobile";
|
public static final String BIND_MAIL = "bind_mail";
|
public static final String PROFILE_ID = "profile_id";
|
public static final String IS_WECHAT_PUBLIC = "is_wechat_public";
|
public static final String IS_WECHAT_ROUTINE = "is_wechat_routine";
|
public static final String IS_WECHAT_IOS = "is_wechat_ios";
|
public static final String IS_WECHAT_ANDROID = "is_wechat_android";
|
public static final String IS_BINDING_IOS = "is_binding_ios";
|
public static final String REGISTER_TYPE = "register_type";
|
public static final String IS_LOGOFF = "is_logoff";
|
public static final String LOGOFF_TIME = "logoff_time";
|
public static final String IS_SMS = "is_sms";
|
public static final String TYPE = "type";
|
public static final String MER_ID = "mer_id";
|
|
/**
|
* 默认构造函数
|
*/
|
public S_user_core_mapper(S_user_core s_user_core) {
|
if (s_user_core == null) {
|
throw new IllegalArgumentException("po参数不允许为空!");
|
}
|
//主键
|
if (s_user_core.isset_id) {
|
this.setId(s_user_core.getId());
|
}
|
//普通属性
|
if (s_user_core.isset_dept_id) {
|
this.setDept_id(s_user_core.getDept_id());
|
}
|
if (s_user_core.isset_org_id) {
|
this.setOrg_id(s_user_core.getOrg_id());
|
}
|
if (s_user_core.isset_user_name) {
|
this.setUser_name(s_user_core.getUser_name());
|
}
|
if (s_user_core.isset_nick_name) {
|
this.setNick_name(s_user_core.getNick_name());
|
}
|
if (s_user_core.isset_user_type) {
|
this.setUser_type(s_user_core.getUser_type());
|
}
|
if (s_user_core.isset_email) {
|
this.setEmail(s_user_core.getEmail());
|
}
|
if (s_user_core.isset_phonenumber) {
|
this.setPhonenumber(s_user_core.getPhonenumber());
|
}
|
if (s_user_core.isset_sex) {
|
this.setSex(s_user_core.getSex());
|
}
|
if (s_user_core.isset_avatar) {
|
this.setAvatar(s_user_core.getAvatar());
|
}
|
if (s_user_core.isset_password) {
|
this.setPassword(s_user_core.getPassword());
|
}
|
if (s_user_core.isset_status) {
|
this.setStatus(s_user_core.getStatus());
|
}
|
if (s_user_core.isset_del_flag) {
|
this.setDel_flag(s_user_core.getDel_flag());
|
}
|
if (s_user_core.isset_login_ip) {
|
this.setLogin_ip(s_user_core.getLogin_ip());
|
}
|
if (s_user_core.isset_login_date) {
|
this.setLogin_date(s_user_core.getLogin_date());
|
}
|
if (s_user_core.isset_create_by) {
|
this.setCreate_by(s_user_core.getCreate_by());
|
}
|
if (s_user_core.isset_create_time) {
|
this.setCreate_time(s_user_core.getCreate_time());
|
}
|
if (s_user_core.isset_update_by) {
|
this.setUpdate_by(s_user_core.getUpdate_by());
|
}
|
if (s_user_core.isset_update_time) {
|
this.setUpdate_time(s_user_core.getUpdate_time());
|
}
|
if (s_user_core.isset_remark) {
|
this.setRemark(s_user_core.getRemark());
|
}
|
if (s_user_core.isset_wx_open_id) {
|
this.setWx_open_id(s_user_core.getWx_open_id());
|
}
|
if (s_user_core.isset_wx_union_id) {
|
this.setWx_union_id(s_user_core.getWx_union_id());
|
}
|
if (s_user_core.isset_ding_user_id) {
|
this.setDing_user_id(s_user_core.getDing_user_id());
|
}
|
if (s_user_core.isset_bind_client_id) {
|
this.setBind_client_id(s_user_core.getBind_client_id());
|
}
|
if (s_user_core.isset_bind_wechat) {
|
this.setBind_wechat(s_user_core.getBind_wechat());
|
}
|
if (s_user_core.isset_modify_pwd) {
|
this.setModify_pwd(s_user_core.getModify_pwd());
|
}
|
if (s_user_core.isset_bind_mobile) {
|
this.setBind_mobile(s_user_core.getBind_mobile());
|
}
|
if (s_user_core.isset_bind_mail) {
|
this.setBind_mail(s_user_core.getBind_mail());
|
}
|
if (s_user_core.isset_profile_id) {
|
this.setProfile_id(s_user_core.getProfile_id());
|
}
|
if (s_user_core.isset_is_wechat_public) {
|
this.setIs_wechat_public(s_user_core.getIs_wechat_public());
|
}
|
if (s_user_core.isset_is_wechat_routine) {
|
this.setIs_wechat_routine(s_user_core.getIs_wechat_routine());
|
}
|
if (s_user_core.isset_is_wechat_ios) {
|
this.setIs_wechat_ios(s_user_core.getIs_wechat_ios());
|
}
|
if (s_user_core.isset_is_wechat_android) {
|
this.setIs_wechat_android(s_user_core.getIs_wechat_android());
|
}
|
if (s_user_core.isset_is_binding_ios) {
|
this.setIs_binding_ios(s_user_core.getIs_binding_ios());
|
}
|
if (s_user_core.isset_register_type) {
|
this.setRegister_type(s_user_core.getRegister_type());
|
}
|
if (s_user_core.isset_is_logoff) {
|
this.setIs_logoff(s_user_core.getIs_logoff());
|
}
|
if (s_user_core.isset_logoff_time) {
|
this.setLogoff_time(s_user_core.getLogoff_time());
|
}
|
if (s_user_core.isset_is_sms) {
|
this.setIs_sms(s_user_core.getIs_sms());
|
}
|
if (s_user_core.isset_type) {
|
this.setType(s_user_core.getType());
|
}
|
if (s_user_core.isset_mer_id) {
|
this.setMer_id(s_user_core.getMer_id());
|
}
|
// 去掉,2022-09-07
|
// this.setDatabaseName_(s_user_core.getDatabaseName_());
|
}
|
|
/**
|
* 获取表名
|
*/
|
@Override
|
public String getTableName_() {
|
String tableName = "s_user_core";
|
/**
|
if (StringUtils.isNotEmpty(this.getDatabaseName_())) {
|
return this.getDatabaseName_() + "." + tableName;
|
} else {
|
return tableName;
|
}
|
*/
|
return tableName;
|
}
|
|
/**
|
* 获取主键名称
|
*/
|
@Override
|
public String getPkName_() {
|
return ID;
|
}
|
|
/**
|
* 获取主键值
|
*/
|
@Override
|
public Object getPkValue_() {
|
return this.getId();
|
}
|
|
/**
|
* 获取插入语句和参数
|
*/
|
@Override
|
public SqlAndParameters<Map<String, Object>> getInsertSql_() {
|
InsertBuilder ib = new InsertBuilder(this.getTableName_());
|
ib.set(ID, this.getId());
|
ib.set(DEPT_ID, this.getDept_id(), this.isset_dept_id);
|
ib.set(ORG_ID, this.getOrg_id(), this.isset_org_id);
|
ib.set(USER_NAME, this.getUser_name(), this.isset_user_name);
|
ib.set(NICK_NAME, this.getNick_name(), this.isset_nick_name);
|
ib.set(USER_TYPE, this.getUser_type(), this.isset_user_type);
|
ib.set(EMAIL, this.getEmail(), this.isset_email);
|
ib.set(PHONENUMBER, this.getPhonenumber(), this.isset_phonenumber);
|
ib.set(SEX, this.getSex(), this.isset_sex);
|
ib.set(AVATAR, this.getAvatar(), this.isset_avatar);
|
ib.set(PASSWORD, this.getPassword(), this.isset_password);
|
ib.set(STATUS, this.getStatus(), this.isset_status);
|
ib.set(DEL_FLAG, this.getDel_flag(), this.isset_del_flag);
|
ib.set(LOGIN_IP, this.getLogin_ip(), this.isset_login_ip);
|
ib.set(LOGIN_DATE, this.getLogin_date(), this.isset_login_date);
|
ib.set(CREATE_BY, this.getCreate_by(), this.isset_create_by);
|
ib.set(CREATE_TIME, this.getCreate_time(), this.isset_create_time);
|
ib.set(UPDATE_BY, this.getUpdate_by(), this.isset_update_by);
|
ib.set(UPDATE_TIME, this.getUpdate_time(), this.isset_update_time);
|
ib.set(REMARK, this.getRemark(), this.isset_remark);
|
ib.set(WX_OPEN_ID, this.getWx_open_id(), this.isset_wx_open_id);
|
ib.set(WX_UNION_ID, this.getWx_union_id(), this.isset_wx_union_id);
|
ib.set(DING_USER_ID, this.getDing_user_id(), this.isset_ding_user_id);
|
ib.set(BIND_CLIENT_ID, this.getBind_client_id(), this.isset_bind_client_id);
|
ib.set(BIND_WECHAT, this.getBind_wechat(), this.isset_bind_wechat);
|
ib.set(MODIFY_PWD, this.getModify_pwd(), this.isset_modify_pwd);
|
ib.set(BIND_MOBILE, this.getBind_mobile(), this.isset_bind_mobile);
|
ib.set(BIND_MAIL, this.getBind_mail(), this.isset_bind_mail);
|
ib.set(PROFILE_ID, this.getProfile_id(), this.isset_profile_id);
|
ib.set(IS_WECHAT_PUBLIC, this.getIs_wechat_public(), this.isset_is_wechat_public);
|
ib.set(IS_WECHAT_ROUTINE, this.getIs_wechat_routine(), this.isset_is_wechat_routine);
|
ib.set(IS_WECHAT_IOS, this.getIs_wechat_ios(), this.isset_is_wechat_ios);
|
ib.set(IS_WECHAT_ANDROID, this.getIs_wechat_android(), this.isset_is_wechat_android);
|
ib.set(IS_BINDING_IOS, this.getIs_binding_ios(), this.isset_is_binding_ios);
|
ib.set(REGISTER_TYPE, this.getRegister_type(), this.isset_register_type);
|
ib.set(IS_LOGOFF, this.getIs_logoff(), this.isset_is_logoff);
|
ib.set(LOGOFF_TIME, this.getLogoff_time(), this.isset_logoff_time);
|
ib.set(IS_SMS, this.getIs_sms(), this.isset_is_sms);
|
ib.set(TYPE, this.getType(), this.isset_type);
|
ib.set(MER_ID, this.getMer_id(), this.isset_mer_id);
|
return ib.genMapSql();
|
}
|
|
/**
|
* 获取更新语句和参数
|
*/
|
@Override
|
public SqlAndParameters<Map<String, Object>> getUpdateSql_() {
|
UpdateBuilder ub = new UpdateBuilder(this.getTableName_());
|
ub.set(DEPT_ID, this.getDept_id(), this.isset_dept_id);
|
ub.set(ORG_ID, this.getOrg_id(), this.isset_org_id);
|
ub.set(USER_NAME, this.getUser_name(), this.isset_user_name);
|
ub.set(NICK_NAME, this.getNick_name(), this.isset_nick_name);
|
ub.set(USER_TYPE, this.getUser_type(), this.isset_user_type);
|
ub.set(EMAIL, this.getEmail(), this.isset_email);
|
ub.set(PHONENUMBER, this.getPhonenumber(), this.isset_phonenumber);
|
ub.set(SEX, this.getSex(), this.isset_sex);
|
ub.set(AVATAR, this.getAvatar(), this.isset_avatar);
|
ub.set(PASSWORD, this.getPassword(), this.isset_password);
|
ub.set(STATUS, this.getStatus(), this.isset_status);
|
ub.set(DEL_FLAG, this.getDel_flag(), this.isset_del_flag);
|
ub.set(LOGIN_IP, this.getLogin_ip(), this.isset_login_ip);
|
ub.set(LOGIN_DATE, this.getLogin_date(), this.isset_login_date);
|
ub.set(CREATE_BY, this.getCreate_by(), this.isset_create_by);
|
ub.set(CREATE_TIME, this.getCreate_time(), this.isset_create_time);
|
ub.set(UPDATE_BY, this.getUpdate_by(), this.isset_update_by);
|
ub.set(UPDATE_TIME, this.getUpdate_time(), this.isset_update_time);
|
ub.set(REMARK, this.getRemark(), this.isset_remark);
|
ub.set(WX_OPEN_ID, this.getWx_open_id(), this.isset_wx_open_id);
|
ub.set(WX_UNION_ID, this.getWx_union_id(), this.isset_wx_union_id);
|
ub.set(DING_USER_ID, this.getDing_user_id(), this.isset_ding_user_id);
|
ub.set(BIND_CLIENT_ID, this.getBind_client_id(), this.isset_bind_client_id);
|
ub.set(BIND_WECHAT, this.getBind_wechat(), this.isset_bind_wechat);
|
ub.set(MODIFY_PWD, this.getModify_pwd(), this.isset_modify_pwd);
|
ub.set(BIND_MOBILE, this.getBind_mobile(), this.isset_bind_mobile);
|
ub.set(BIND_MAIL, this.getBind_mail(), this.isset_bind_mail);
|
ub.set(PROFILE_ID, this.getProfile_id(), this.isset_profile_id);
|
ub.set(IS_WECHAT_PUBLIC, this.getIs_wechat_public(), this.isset_is_wechat_public);
|
ub.set(IS_WECHAT_ROUTINE, this.getIs_wechat_routine(), this.isset_is_wechat_routine);
|
ub.set(IS_WECHAT_IOS, this.getIs_wechat_ios(), this.isset_is_wechat_ios);
|
ub.set(IS_WECHAT_ANDROID, this.getIs_wechat_android(), this.isset_is_wechat_android);
|
ub.set(IS_BINDING_IOS, this.getIs_binding_ios(), this.isset_is_binding_ios);
|
ub.set(REGISTER_TYPE, this.getRegister_type(), this.isset_register_type);
|
ub.set(IS_LOGOFF, this.getIs_logoff(), this.isset_is_logoff);
|
ub.set(LOGOFF_TIME, this.getLogoff_time(), this.isset_logoff_time);
|
ub.set(IS_SMS, this.getIs_sms(), this.isset_is_sms);
|
ub.set(TYPE, this.getType(), this.isset_type);
|
ub.set(MER_ID, this.getMer_id(), this.isset_mer_id);
|
ub.where(this.getPkName_(), this.getPkValue_());
|
return ub.genMapSql();
|
}
|
|
/**
|
* 获取更新语句和参数
|
*/
|
@Override
|
public SqlAndParameters<Map<String, Object>> getUpdateSql_(String where, Map<String, Object> parameters) {
|
UpdateBuilder ub = new UpdateBuilder(this.getTableName_());
|
ub.set(DEPT_ID, this.getDept_id(), this.isset_dept_id);
|
ub.set(ORG_ID, this.getOrg_id(), this.isset_org_id);
|
ub.set(USER_NAME, this.getUser_name(), this.isset_user_name);
|
ub.set(NICK_NAME, this.getNick_name(), this.isset_nick_name);
|
ub.set(USER_TYPE, this.getUser_type(), this.isset_user_type);
|
ub.set(EMAIL, this.getEmail(), this.isset_email);
|
ub.set(PHONENUMBER, this.getPhonenumber(), this.isset_phonenumber);
|
ub.set(SEX, this.getSex(), this.isset_sex);
|
ub.set(AVATAR, this.getAvatar(), this.isset_avatar);
|
ub.set(PASSWORD, this.getPassword(), this.isset_password);
|
ub.set(STATUS, this.getStatus(), this.isset_status);
|
ub.set(DEL_FLAG, this.getDel_flag(), this.isset_del_flag);
|
ub.set(LOGIN_IP, this.getLogin_ip(), this.isset_login_ip);
|
ub.set(LOGIN_DATE, this.getLogin_date(), this.isset_login_date);
|
ub.set(CREATE_BY, this.getCreate_by(), this.isset_create_by);
|
ub.set(CREATE_TIME, this.getCreate_time(), this.isset_create_time);
|
ub.set(UPDATE_BY, this.getUpdate_by(), this.isset_update_by);
|
ub.set(UPDATE_TIME, this.getUpdate_time(), this.isset_update_time);
|
ub.set(REMARK, this.getRemark(), this.isset_remark);
|
ub.set(WX_OPEN_ID, this.getWx_open_id(), this.isset_wx_open_id);
|
ub.set(WX_UNION_ID, this.getWx_union_id(), this.isset_wx_union_id);
|
ub.set(DING_USER_ID, this.getDing_user_id(), this.isset_ding_user_id);
|
ub.set(BIND_CLIENT_ID, this.getBind_client_id(), this.isset_bind_client_id);
|
ub.set(BIND_WECHAT, this.getBind_wechat(), this.isset_bind_wechat);
|
ub.set(MODIFY_PWD, this.getModify_pwd(), this.isset_modify_pwd);
|
ub.set(BIND_MOBILE, this.getBind_mobile(), this.isset_bind_mobile);
|
ub.set(BIND_MAIL, this.getBind_mail(), this.isset_bind_mail);
|
ub.set(PROFILE_ID, this.getProfile_id(), this.isset_profile_id);
|
ub.set(IS_WECHAT_PUBLIC, this.getIs_wechat_public(), this.isset_is_wechat_public);
|
ub.set(IS_WECHAT_ROUTINE, this.getIs_wechat_routine(), this.isset_is_wechat_routine);
|
ub.set(IS_WECHAT_IOS, this.getIs_wechat_ios(), this.isset_is_wechat_ios);
|
ub.set(IS_WECHAT_ANDROID, this.getIs_wechat_android(), this.isset_is_wechat_android);
|
ub.set(IS_BINDING_IOS, this.getIs_binding_ios(), this.isset_is_binding_ios);
|
ub.set(REGISTER_TYPE, this.getRegister_type(), this.isset_register_type);
|
ub.set(IS_LOGOFF, this.getIs_logoff(), this.isset_is_logoff);
|
ub.set(LOGOFF_TIME, this.getLogoff_time(), this.isset_logoff_time);
|
ub.set(IS_SMS, this.getIs_sms(), this.isset_is_sms);
|
ub.set(TYPE, this.getType(), this.isset_type);
|
ub.set(MER_ID, this.getMer_id(), this.isset_mer_id);
|
|
return ub.genMapSql(where, parameters);
|
}
|
|
/**
|
* 获取更新语句和参数
|
*/
|
@Override
|
public SqlAndParameters<Object[]> getUpdateSql_(String where, Object[] parameters) {
|
UpdateBuilder ub = new UpdateBuilder(this.getTableName_());
|
ub.set(DEPT_ID, this.getDept_id(), this.isset_dept_id);
|
ub.set(ORG_ID, this.getOrg_id(), this.isset_org_id);
|
ub.set(USER_NAME, this.getUser_name(), this.isset_user_name);
|
ub.set(NICK_NAME, this.getNick_name(), this.isset_nick_name);
|
ub.set(USER_TYPE, this.getUser_type(), this.isset_user_type);
|
ub.set(EMAIL, this.getEmail(), this.isset_email);
|
ub.set(PHONENUMBER, this.getPhonenumber(), this.isset_phonenumber);
|
ub.set(SEX, this.getSex(), this.isset_sex);
|
ub.set(AVATAR, this.getAvatar(), this.isset_avatar);
|
ub.set(PASSWORD, this.getPassword(), this.isset_password);
|
ub.set(STATUS, this.getStatus(), this.isset_status);
|
ub.set(DEL_FLAG, this.getDel_flag(), this.isset_del_flag);
|
ub.set(LOGIN_IP, this.getLogin_ip(), this.isset_login_ip);
|
ub.set(LOGIN_DATE, this.getLogin_date(), this.isset_login_date);
|
ub.set(CREATE_BY, this.getCreate_by(), this.isset_create_by);
|
ub.set(CREATE_TIME, this.getCreate_time(), this.isset_create_time);
|
ub.set(UPDATE_BY, this.getUpdate_by(), this.isset_update_by);
|
ub.set(UPDATE_TIME, this.getUpdate_time(), this.isset_update_time);
|
ub.set(REMARK, this.getRemark(), this.isset_remark);
|
ub.set(WX_OPEN_ID, this.getWx_open_id(), this.isset_wx_open_id);
|
ub.set(WX_UNION_ID, this.getWx_union_id(), this.isset_wx_union_id);
|
ub.set(DING_USER_ID, this.getDing_user_id(), this.isset_ding_user_id);
|
ub.set(BIND_CLIENT_ID, this.getBind_client_id(), this.isset_bind_client_id);
|
ub.set(BIND_WECHAT, this.getBind_wechat(), this.isset_bind_wechat);
|
ub.set(MODIFY_PWD, this.getModify_pwd(), this.isset_modify_pwd);
|
ub.set(BIND_MOBILE, this.getBind_mobile(), this.isset_bind_mobile);
|
ub.set(BIND_MAIL, this.getBind_mail(), this.isset_bind_mail);
|
ub.set(PROFILE_ID, this.getProfile_id(), this.isset_profile_id);
|
ub.set(IS_WECHAT_PUBLIC, this.getIs_wechat_public(), this.isset_is_wechat_public);
|
ub.set(IS_WECHAT_ROUTINE, this.getIs_wechat_routine(), this.isset_is_wechat_routine);
|
ub.set(IS_WECHAT_IOS, this.getIs_wechat_ios(), this.isset_is_wechat_ios);
|
ub.set(IS_WECHAT_ANDROID, this.getIs_wechat_android(), this.isset_is_wechat_android);
|
ub.set(IS_BINDING_IOS, this.getIs_binding_ios(), this.isset_is_binding_ios);
|
ub.set(REGISTER_TYPE, this.getRegister_type(), this.isset_register_type);
|
ub.set(IS_LOGOFF, this.getIs_logoff(), this.isset_is_logoff);
|
ub.set(LOGOFF_TIME, this.getLogoff_time(), this.isset_logoff_time);
|
ub.set(IS_SMS, this.getIs_sms(), this.isset_is_sms);
|
ub.set(TYPE, this.getType(), this.isset_type);
|
ub.set(MER_ID, this.getMer_id(), this.isset_mer_id);
|
|
return ub.genArraySql(where, parameters);
|
}
|
|
/**
|
* 获取删除语句和参数
|
*/
|
@Override
|
public SqlAndParameters<Map<String, Object>> getDeleteSql_() {
|
DeleteBuilder db = new DeleteBuilder(this.getTableName_());
|
db.where(this.getPkName_(), this.getPkValue_());
|
return db.genMapSql();
|
}
|
|
/**
|
* 获取删除语句和参数
|
*/
|
@Override
|
public SqlAndParameters<Map<String, Object>> getDeleteSql_(String where, Map<String, Object> parameters) {
|
DeleteBuilder db = new DeleteBuilder(this.getTableName_());
|
return db.genMapSql(where, parameters);
|
}
|
|
/**
|
* 获取删除语句和参数
|
*/
|
@Override
|
public SqlAndParameters<Object[]> getDeleteSql_(String where, Object[] parameters) {
|
DeleteBuilder db = new DeleteBuilder(this.getTableName_());
|
return db.genArraySql(where, parameters);
|
}
|
|
/**
|
* 获取单行查询语句和参数
|
*/
|
@Override
|
public SqlAndParameters<Map<String, Object>> getSingleSql_() {
|
SelectBuilder sb = new SelectBuilder(this.getTableName_());
|
sb.where(this.getPkName_(), this.getPkValue_());
|
return sb.genMapSql();
|
}
|
|
|
/**
|
* 获取查询语句和参数
|
*/
|
@Override
|
public SqlAndParameters<Map<String, Object>> getSelectSql_(String where, Map<String, Object> parameters) {
|
return new SqlAndParameters<>("select id, dept_id, org_id, user_name, nick_name, user_type, email, phonenumber, sex, avatar, password, status, del_flag, login_ip, login_date, create_by, create_time, update_by, update_time, remark, wx_open_id, wx_union_id, ding_user_id, bind_client_id, bind_wechat, modify_pwd, bind_mobile, bind_mail, profile_id, is_wechat_public, is_wechat_routine, is_wechat_ios, is_wechat_android, is_binding_ios, register_type, is_logoff, logoff_time, is_sms, type, mer_id from " + this.getTableName_() + " " + where, parameters);
|
}
|
|
/**
|
* 获取查询语句和参数
|
*/
|
@Override
|
public SqlAndParameters<Object[]> getSelectSql_(String where, Object[] parameters) {
|
return new SqlAndParameters<>("select id, dept_id, org_id, user_name, nick_name, user_type, email, phonenumber, sex, avatar, password, status, del_flag, login_ip, login_date, create_by, create_time, update_by, update_time, remark, wx_open_id, wx_union_id, ding_user_id, bind_client_id, bind_wechat, modify_pwd, bind_mobile, bind_mail, profile_id, is_wechat_public, is_wechat_routine, is_wechat_ios, is_wechat_android, is_binding_ios, register_type, is_logoff, logoff_time, is_sms, type, mer_id from " + this.getTableName_() + " " + where, parameters);
|
}
|
|
/**
|
* 将resultset的一行转化为po
|
*/
|
@Override
|
public S_user_core mapRow(ResultSet rs, int i) throws SQLException {
|
return ROW_MAPPER.mapRow(rs, i);
|
}
|
|
/**
|
* 克隆
|
*/
|
public S_user_core toS_user_core() {
|
return super.$clone();
|
}
|
}
|
|
/**
|
* s_user_core RowMapper
|
*
|
* @author genrator
|
*/
|
class S_user_coreRowMapper implements RowMapper<S_user_core> {
|
|
@Override
|
public S_user_core mapRow(ResultSet rs, int i) throws SQLException {
|
ResultSetUtils resultSetUtils = new ResultSetUtils();
|
S_user_core s_user_core = new S_user_core();
|
Integer columnIndex;
|
//主键
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.ID);
|
if (columnIndex > 0) {
|
s_user_core.setId(rs.getLong(columnIndex));
|
}
|
//普通属性
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.DEPT_ID);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setDept_id(null);
|
} else {
|
s_user_core.setDept_id(rs.getLong(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.ORG_ID);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setOrg_id(null);
|
} else {
|
s_user_core.setOrg_id(rs.getLong(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.USER_NAME);
|
if (columnIndex > 0) {
|
s_user_core.setUser_name(rs.getString(columnIndex));
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.NICK_NAME);
|
if (columnIndex > 0) {
|
s_user_core.setNick_name(rs.getString(columnIndex));
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.USER_TYPE);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setUser_type(null);
|
} else {
|
s_user_core.setUser_type(rs.getInt(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.EMAIL);
|
if (columnIndex > 0) {
|
s_user_core.setEmail(rs.getString(columnIndex));
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.PHONENUMBER);
|
if (columnIndex > 0) {
|
s_user_core.setPhonenumber(rs.getString(columnIndex));
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.SEX);
|
if (columnIndex > 0) {
|
s_user_core.setSex(rs.getString(columnIndex));
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.AVATAR);
|
if (columnIndex > 0) {
|
s_user_core.setAvatar(rs.getString(columnIndex));
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.PASSWORD);
|
if (columnIndex > 0) {
|
s_user_core.setPassword(rs.getString(columnIndex));
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.STATUS);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setStatus(null);
|
} else {
|
s_user_core.setStatus(rs.getInt(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.DEL_FLAG);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setDel_flag(null);
|
} else {
|
s_user_core.setDel_flag(rs.getInt(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.LOGIN_IP);
|
if (columnIndex > 0) {
|
s_user_core.setLogin_ip(rs.getString(columnIndex));
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.LOGIN_DATE);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setLogin_date(null);
|
} else {
|
s_user_core.setLogin_date(rs.getLong(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.CREATE_BY);
|
if (columnIndex > 0) {
|
s_user_core.setCreate_by(rs.getString(columnIndex));
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.CREATE_TIME);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setCreate_time(null);
|
} else {
|
s_user_core.setCreate_time(rs.getLong(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.UPDATE_BY);
|
if (columnIndex > 0) {
|
s_user_core.setUpdate_by(rs.getString(columnIndex));
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.UPDATE_TIME);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setUpdate_time(null);
|
} else {
|
s_user_core.setUpdate_time(rs.getLong(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.REMARK);
|
if (columnIndex > 0) {
|
s_user_core.setRemark(rs.getString(columnIndex));
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.WX_OPEN_ID);
|
if (columnIndex > 0) {
|
s_user_core.setWx_open_id(rs.getString(columnIndex));
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.WX_UNION_ID);
|
if (columnIndex > 0) {
|
s_user_core.setWx_union_id(rs.getString(columnIndex));
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.DING_USER_ID);
|
if (columnIndex > 0) {
|
s_user_core.setDing_user_id(rs.getString(columnIndex));
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.BIND_CLIENT_ID);
|
if (columnIndex > 0) {
|
s_user_core.setBind_client_id(rs.getString(columnIndex));
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.BIND_WECHAT);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setBind_wechat(null);
|
} else {
|
s_user_core.setBind_wechat(rs.getInt(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.MODIFY_PWD);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setModify_pwd(null);
|
} else {
|
s_user_core.setModify_pwd(rs.getInt(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.BIND_MOBILE);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setBind_mobile(null);
|
} else {
|
s_user_core.setBind_mobile(rs.getInt(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.BIND_MAIL);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setBind_mail(null);
|
} else {
|
s_user_core.setBind_mail(rs.getInt(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.PROFILE_ID);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setProfile_id(null);
|
} else {
|
s_user_core.setProfile_id(rs.getLong(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.IS_WECHAT_PUBLIC);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setIs_wechat_public(null);
|
} else {
|
s_user_core.setIs_wechat_public(rs.getInt(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.IS_WECHAT_ROUTINE);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setIs_wechat_routine(null);
|
} else {
|
s_user_core.setIs_wechat_routine(rs.getInt(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.IS_WECHAT_IOS);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setIs_wechat_ios(null);
|
} else {
|
s_user_core.setIs_wechat_ios(rs.getInt(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.IS_WECHAT_ANDROID);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setIs_wechat_android(null);
|
} else {
|
s_user_core.setIs_wechat_android(rs.getInt(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.IS_BINDING_IOS);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setIs_binding_ios(null);
|
} else {
|
s_user_core.setIs_binding_ios(rs.getInt(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.REGISTER_TYPE);
|
if (columnIndex > 0) {
|
s_user_core.setRegister_type(rs.getString(columnIndex));
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.IS_LOGOFF);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setIs_logoff(null);
|
} else {
|
s_user_core.setIs_logoff(rs.getInt(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.LOGOFF_TIME);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setLogoff_time(null);
|
} else {
|
s_user_core.setLogoff_time(rs.getLong(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.IS_SMS);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setIs_sms(null);
|
} else {
|
s_user_core.setIs_sms(rs.getInt(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.TYPE);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setType(null);
|
} else {
|
s_user_core.setType(rs.getInt(columnIndex));
|
}
|
}
|
columnIndex = resultSetUtils.findColumn(rs, S_user_core_mapper.MER_ID);
|
if (columnIndex > 0) {
|
if (rs.getBigDecimal(columnIndex) == null) {
|
s_user_core.setMer_id(null);
|
} else {
|
s_user_core.setMer_id(rs.getLong(columnIndex));
|
}
|
}
|
return s_user_core;
|
}
|
}
|