日期:2014-05-17 浏览次数:21098 次
// IndexCategory实体类
public class IndexCategory {
private int id;
private int parentId;// 父分类id
private String indexCategoryName;// 分类名称
private int userId;
[color=#FF0000]private Set<IndexContext> indexes = new HashSet<IndexContext>();//与指标的关系
private Set<IndexCategory> subCats=new HashSet<IndexCategory>();//与本身的关系 子分类[/color]
//getter and setter...
}
//IndexCategoryRelation实体类
public class IndexCategoryRelation {
private int id;
private int indexId;//指标id
private int indexCategoryId;//分类id
//getter and setter...
}
//IndexCotext实体类
public class IndexContext {
private int id;//主键
private String pubDateCol;//公布日期字段名
private String dataSet;//表名
private boolean isValue;//是否为值字段,默认为F,此记录为指标值,为T时此记录为值,需要生成SQL语句
private String SQL;//"值记录,可以直接用:“select+""tableValue""+""from""+ dataSet +where+ """"指标记录:
字段名=值,如:country_id=30级父节点无此设置"
private String name;//字段显示名,可供用户修改,默认为:isValue为T为字段名的中文,为F为指标的值(ID)的中文
private String tableValue;//字段实际值,parentID=0时为空;isValue为T为字段名,为F为指标的值(ID)
private boolean ishidden;//默认False,是否隐藏
private String Backup1;//备份
private String Backup2;//备份
private int classID;//记录分类的记录ID,如果没被分类,则为0
private String updateDate;//更新日期列名
private Integer tableId;//数据集id
private Double order;//排序
private String freqList;//变频条件
private String newfreq;//变频之后的频率
private Integer rootClassId;//记录根分类的ID
private String indexFreq;//指标增加频率
private String indexUnit;//指标增加单位
private String indexSource;//指标增加来源
private Date saveIndexDate;//保存指标时间
private Date updateIndexDate;//更新指标时间
private String startPubDate;//开始公布日期
private String endPubDate;//最后公布日期
private Date endDataUpdate;//数据最后更新时间
private Boolean edited;//标记指标值是否被修改过
[color=#FF0000] private Set<IndexCategory> cats = new HashSet<IndexCategory>();//与自定义指标分类的关系[/color]
//getter and setter...
<!-- 自定义指标分类 -->
<class name="com.richeninfo.anaplatform.etl.hbean.IndexCategory" table="dc_index_category">
<id column="id" name="id" type="java.lang.Integer">
<generator class="native"/>
</id>
<property column="parent_id" name="parentId" type="java.lang.Integer"/>
<property column="user_id" name="userId" type="java.