Commit 07dbede4 by Tuukka Kivilahti

asdf

1 parent 9aaaffd3
......@@ -55,6 +55,8 @@ public class GenericEntity extends EntityEquals implements ModelInterface, Entit
@Override
public JsonObject getMeta() {
// TODO: do not return null, it's not logical
// empty jsonobject would be moar logical (maybe?)
return meta;
}
......
......@@ -273,21 +273,20 @@ public class IncomingView extends GenericCDIView {
*/
public String getCardFiling() {
String ret = "";
// try {
PrintedCard card = cardBean.checkPrintedCard(userview.getSelectedUser());
if (card != null) {
JsonObject cardMeta = card.getMeta();
JsonObject cardFilingObject = cardMeta.getJsonObject("card-filing");
if(cardFilingObject != null) {
ret = cardFilingObject.getString("cardplace");
if(cardMeta != null) {
JsonObject cardFilingObject = cardMeta.getJsonObject("card-filing");
if (cardFilingObject != null) {
ret = cardFilingObject.getString("cardplace");
}
}
}
// Hmm, onkohan tää ihan tarkoituksenmukaista?
// (mergerequestin tekijä vois arvioida)
// } catch (Exception e) {
// logger.warn("Could not get card filing info", e);
// }
return ret;
}
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!