@@ -0,0 +1,64 @@ | |||
package cc.smtweb.system.bpm.web.sys.base.dict; | |||
import cc.smtweb.framework.core.annotation.SwTable; | |||
import cc.smtweb.framework.core.common.SwMap; | |||
import cc.smtweb.framework.core.db.impl.DefaultEntity; | |||
/** | |||
* Created by 1 at 2022-07-27 19:59:05 | |||
* 实体【[数据字典](SYS_DICT)】的Entity类 | |||
*/ | |||
@SwTable("SYS_DICT") | |||
public class Dict extends DefaultEntity { | |||
public static final String ENTITY_NAME = "SYS_DICT"; | |||
public Dict() { | |||
super(ENTITY_NAME); | |||
} | |||
/** 主键 */ | |||
public long getId() { | |||
return getLong("sdc_id"); | |||
} | |||
/** 主键 */ | |||
public void setId(long sdc_id) { | |||
put("sdc_id", sdc_id); | |||
} | |||
/** 类别 */ | |||
public long getType() { | |||
return getLong("sdc_type"); | |||
} | |||
/** 类别 */ | |||
public void setType(long sdc_type) { | |||
put("sdc_type", sdc_type); | |||
} | |||
/** 编码 */ | |||
public String getCode() { | |||
return getStr("sdc_code"); | |||
} | |||
/** 编码 */ | |||
public void setCode(String sdc_code) { | |||
put("sdc_code", sdc_code); | |||
} | |||
/** 名称 */ | |||
public String getName() { | |||
return getStr("sdc_name"); | |||
} | |||
/** 名称 */ | |||
public void setName(String sdc_name) { | |||
put("sdc_name", sdc_name); | |||
} | |||
/** 备注 */ | |||
public String getRemark() { | |||
return getStr("sdc_remark"); | |||
} | |||
/** 备注 */ | |||
public void setRemark(String sdc_remark) { | |||
put("sdc_remark", sdc_remark); | |||
} | |||
} |
@@ -0,0 +1,34 @@ | |||
package cc.smtweb.system.bpm.web.sys.base.dict; | |||
import cc.smtweb.framework.core.annotation.SwCache; | |||
import cc.smtweb.framework.core.cache.AbstractEntityCache; | |||
import cc.smtweb.framework.core.cache.CacheManager; | |||
import java.util.ArrayList; | |||
import java.util.Comparator; | |||
import java.util.List; | |||
import java.util.Set; | |||
/** | |||
* Created by 1 at 2022-07-27 19:59:05 | |||
* 实体【[数据字典](SYS_DICT)】的缓存类 | |||
*/ | |||
@SwCache(ident = "SYS_DICT", title = "数据字典") | |||
public class DictCache extends AbstractEntityCache<Dict> { | |||
//缓存key:按编码 | |||
public final static String mk_code = "code"; | |||
public static DictCache getInstance() { | |||
return CacheManager.getIntance().getCache(DictCache.class); | |||
} | |||
public DictCache() { | |||
//缓存key:按编码 | |||
regMap(mk_code, "sdc_type,sdc_code"); | |||
} | |||
//缓存key:按编码 | |||
public final Dict getByCode(String key) { | |||
return getByKey(mk_code, key); | |||
} | |||
} |
@@ -0,0 +1,64 @@ | |||
package cc.smtweb.system.bpm.web.sys.base.dict; | |||
import cc.smtweb.framework.core.annotation.SwTable; | |||
import cc.smtweb.framework.core.common.SwMap; | |||
import cc.smtweb.framework.core.db.impl.DefaultEntity; | |||
/** | |||
* Created by 1 at 2022-07-27 19:59:05 | |||
* 实体【[字典类别](SYS_DICT_TYPE)】的Entity类 | |||
*/ | |||
@SwTable("SYS_DICT_TYPE") | |||
public class DictType extends DefaultEntity { | |||
public static final String ENTITY_NAME = "SYS_DICT_TYPE"; | |||
public DictType() { | |||
super(ENTITY_NAME); | |||
} | |||
/** 主键 */ | |||
public long getId() { | |||
return getLong("sdct_id"); | |||
} | |||
/** 主键 */ | |||
public void setId(long sdct_id) { | |||
put("sdct_id", sdct_id); | |||
} | |||
/** 编码 */ | |||
public String getCode() { | |||
return getStr("sdct_code"); | |||
} | |||
/** 编码 */ | |||
public void setCode(String sdct_code) { | |||
put("sdct_code", sdct_code); | |||
} | |||
/** 名称 */ | |||
public String getName() { | |||
return getStr("sdct_name"); | |||
} | |||
/** 名称 */ | |||
public void setName(String sdct_name) { | |||
put("sdct_name", sdct_name); | |||
} | |||
/** 归属项目 */ | |||
public long getPrjId() { | |||
return getLong("sdct_prj_id"); | |||
} | |||
/** 归属项目 */ | |||
public void setPrjId(long sdct_prj_id) { | |||
put("sdct_prj_id", sdct_prj_id); | |||
} | |||
/** 备注 */ | |||
public String getRemark() { | |||
return getStr("sdct_remark"); | |||
} | |||
/** 备注 */ | |||
public void setRemark(String sdct_remark) { | |||
put("sdct_remark", sdct_remark); | |||
} | |||
} |
@@ -0,0 +1,34 @@ | |||
package cc.smtweb.system.bpm.web.sys.base.dict; | |||
import cc.smtweb.framework.core.annotation.SwCache; | |||
import cc.smtweb.framework.core.cache.AbstractEntityCache; | |||
import cc.smtweb.framework.core.cache.CacheManager; | |||
import java.util.ArrayList; | |||
import java.util.Comparator; | |||
import java.util.List; | |||
import java.util.Set; | |||
/** | |||
* Created by 1 at 2022-07-27 19:59:05 | |||
* 实体【[字典类别](SYS_DICT_TYPE)】的缓存类 | |||
*/ | |||
@SwCache(ident = "SYS_DICT_TYPE", title = "字典类别") | |||
public class DictTypeCache extends AbstractEntityCache<DictType> { | |||
//缓存key:按编码 | |||
public final static String mk_code = "code"; | |||
public static DictTypeCache getInstance() { | |||
return CacheManager.getIntance().getCache(DictTypeCache.class); | |||
} | |||
public DictTypeCache() { | |||
//缓存key:按编码 | |||
regMap(mk_code, "sdct_code"); | |||
} | |||
//缓存key:按编码 | |||
public final DictType getByCode(String key) { | |||
return getByKey(mk_code, key); | |||
} | |||
} |