com.fastchar.extjs.entity.ExtSystemDataLogEntity Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of fastchar-extjs Show documentation
Show all versions of fastchar-extjs Show documentation
FastChar-ExtJs is a Java Web framework that uses extjs libraries.Quickly build a background management system
package com.fastchar.extjs.entity;
import com.fastchar.core.FastChar;
import com.fastchar.extjs.core.FastExtEntity;
import com.fastchar.database.FastPage;
import com.fastchar.database.info.FastSqlInfo;
import com.fastchar.utils.FastDateUtils;
import java.util.*;
import com.fastchar.utils.FastStringUtils;
import com.fastchar.utils.FastNumberUtils;
import com.fastchar.database.FastPage;
import com.fastchar.core.FastEntity;
/**
* 系统数据日志管理数据库实体类
*
* @author Janesen
* @date 2024/03/11 16:55
*/
public class ExtSystemDataLogEntity extends FastExtEntity {
private static final long serialVersionUID = 1L;
public static ExtSystemDataLogEntity dao() {
return FastChar.getOverrides().singleInstance(ExtSystemDataLogEntity.class);
}
public static ExtSystemDataLogEntity newInstance() {
return FastChar.getOverrides().newInstance(ExtSystemDataLogEntity.class);
}
@Override
public String getTableName() {
return "ext_system_data_log";
}
@Override
public String getTableDetails() {
return "系统数据日志管理";
}
@Override
public String getEntityCode() {
return this.getClass().getSimpleName();
}
@Override
public FastPage showList(int page, int pageSize) {
String sqlStr = "select t.*" + " from ext_system_data_log as t" + " ";
ShowListSqlAdapter showListSqlAdapter = FastChar.getOverrides().singleInstance(false, ShowListSqlAdapter.class);
if (showListSqlAdapter != null) {
sqlStr = showListSqlAdapter.convertSql(this, sqlStr);
}
FastSqlInfo sqlInfo = toSelectSql(sqlStr);
return selectBySql(page, pageSize, sqlInfo.getSql(), sqlInfo.toParams());
}
@Override
public void setDefaultValue() {
set("dataUserId", 0);
set("dataId", 0);
set("dataLogDateTime", FastDateUtils.getDateString());
}
@Override
public void convertValue() {
super.convertValue();
}
/**
* 获得数据详情
*/
public ExtSystemDataLogEntity getDetails(int dataLogId) {
List linkColumns = new ArrayList<>();
linkColumns.add("t.*");
String sqlStr = "select " + FastStringUtils.join(linkColumns, ",") + " from ext_system_data_log as t" + " "
+ " where t.dataLogId = ? ";
ExtSystemDataLogEntity entity = selectFirstBySql(sqlStr, dataLogId);
if (entity != null) {
// to-do something
}
return entity;
}
/**
* 获得本实体列表集合
*
* @return 分页数据
*/
public FastPage getList(int page, int pageSize, Map where,
Map sort) {
List linkColumns = new ArrayList<>();
linkColumns.add("t.*");
StringBuilder sqlStr = new StringBuilder("select " + FastStringUtils.join(linkColumns, ",")
+ " from ext_system_data_log as t" + " " + " where 1=1 ");
List
© 2015 - 2025 Weber Informatics LLC | Privacy Policy