This commit is contained in:
@@ -26,18 +26,6 @@ public @interface FilterJoinColumn {
|
||||
*/
|
||||
Class table();
|
||||
|
||||
/**
|
||||
*
|
||||
* 单个关联字段, 默认使用join表(b)的主键, join表与被join表(a)的字段必须一样
|
||||
* 例如: SELECT a.* FROM user a INNER JOIN record b ON a.userid = b.userid
|
||||
* 那么注解为: @FilterJoinColumn(table = Record.class, column = "userid")
|
||||
* <p>
|
||||
* @deprecated 使用columns 代替
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
String column() default "";
|
||||
|
||||
/**
|
||||
*
|
||||
* 多个关联字段, 默认使用join表(b)的主键, join表与被join表(a)的字段必须一样
|
||||
@@ -46,5 +34,5 @@ public @interface FilterJoinColumn {
|
||||
* <p>
|
||||
* @return
|
||||
*/
|
||||
String[] columns() default {};
|
||||
String[] columns();
|
||||
}
|
||||
|
||||
@@ -59,7 +59,7 @@ public final class FilterNodeBean<T> implements Comparable<FilterNodeBean<T>> {
|
||||
private FilterNodeBean(final FilterJoinColumn joinCol, final FilterColumn filterCol, final Attribute<T, Serializable> attr) {
|
||||
this.beanAttr = attr;
|
||||
this.joinClass = joinCol == null ? null : joinCol.table();
|
||||
this.joinColumns = joinCol == null ? null : (joinCol.columns().length == 0 ? new String[]{joinCol.column()} : joinCol.columns());
|
||||
this.joinColumns = joinCol == null ? null : joinCol.columns();
|
||||
|
||||
final Class type = attr.type();
|
||||
this.column = (filterCol != null && !filterCol.name().isEmpty()) ? filterCol.name() : attr.field();
|
||||
|
||||
Reference in New Issue
Block a user