IDEMPIERE-4313 : WebServices : Yes-No output values not consistent be… (#85)

* IDEMPIERE-4313 : WebServices : Yes-No output values not consistent between Read and Query

* Update code using Carlos's suggestion
This commit is contained in:
Nicolas Micoud 2020-05-29 14:49:55 +02:00 committed by GitHub
parent 3837a8e32b
commit ed7952945a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 7 additions and 2 deletions

View File

@ -1390,8 +1390,13 @@ public class ModelADServiceImpl extends AbstractService implements ModelADServic
if (po.get_Value(i) != null){
if(po.get_Value(i) instanceof byte[]){
dfid.setVal(new String(Base64.encodeBase64((byte[]) po.get_Value(i))));
}else
dfid.setVal(po.get_Value(i).toString());
}
else if(po.get_Value(i) instanceof Boolean) {
dfid.setVal((Boolean)po.get_Value(i) ? "Y" : "N");
}
else {
dfid.setVal(po.get_Value(i).toString());
}
}else
dfid.setVal(null);
}