some property names are overwritten in api
This commit is contained in:
parent
52c0ae091c
commit
0be76b6c23
@ -13,4 +13,5 @@ public @interface AnnFieldIO {
|
||||
Class<?> referTo() default Void.class;
|
||||
Class<? extends DefaultSelectableValues> selectableValues() default DefaultSelectableValues.class;
|
||||
String[] referredProps() default { };
|
||||
String overwriteName() default "";
|
||||
}
|
||||
|
@ -69,11 +69,11 @@ public class UnixUser extends AbstractEntity implements Serializable {
|
||||
@Column(name = "locked", columnDefinition = "boolean")
|
||||
private boolean locked;
|
||||
|
||||
@AnnFieldIO(validation="[0-9]*", rw=ReadWriteAccess.READWRITE)
|
||||
@AnnFieldIO(validation="[0-9]*", rw=ReadWriteAccess.READWRITE, overwriteName="quota_softlimit")
|
||||
@Column(name = "quota_softlimit", columnDefinition = "integer")
|
||||
private Integer quotaSoftlimit;
|
||||
|
||||
@AnnFieldIO(validation="[0-9]*", rw=ReadWriteAccess.READWRITE)
|
||||
@AnnFieldIO(validation="[0-9]*", rw=ReadWriteAccess.READWRITE, overwriteName="quota_hardlimit")
|
||||
@Column(name = "quota_hardlimit", columnDefinition = "integer")
|
||||
private Integer quotaHardlimit;
|
||||
|
||||
|
@ -40,6 +40,10 @@ public class PropertyRemote implements IRemote {
|
||||
if (fieldIO != null) {
|
||||
HashMap<String, Object> propertyProperties = new HashMap<String, Object>();
|
||||
String fieldName = f.getName();
|
||||
String overwrite = fieldIO.overwriteName();
|
||||
if (overwrite != null && !overwrite.isEmpty()) {
|
||||
fieldName = overwrite;
|
||||
}
|
||||
propertyProperties.put("module", (String) moduleKey);
|
||||
propertyProperties.put("name", fieldName);
|
||||
propertyProperties.put("searchable", "equals");
|
||||
|
Loading…
Reference in New Issue
Block a user