/*
- * Copyright © 2019 Damyan Ivanov.
+ * Copyright © 2020 Damyan Ivanov.
* This file is part of MoLe.
* MoLe is free software: you can distribute it and/or modify it
* under the term of the GNU General Public License as published by
import java.util.List;
@JsonIgnoreProperties(ignoreUnknown = true)
-public class ParsedPosting {
+public class ParsedPosting extends net.ktnx.mobileledger.json.ParsedPosting {
private Void pbalanceassertion;
private String pstatus = "Unmarked";
private String paccount;
qty.setDecimalPlaces(2);
qty.setDecimalMantissa(Math.round(acc.getAmount() * 100));
amt.setAquantity(qty);
- ParsedStyle style = new ParsedStyle();
- style.setAscommodityside('L');
- style.setAscommodityspaced(false);
- style.setAsprecision(2);
- style.setAsdecimalpoint('.');
- amt.setAstyle(style);
+ if (acc.getCurrency() != null)
+ amt.setAcommodity(acc.getCurrency());
amounts.add(amt);
result.setPamount(amounts);
return result;