diff --git a/wallet/api/v7_3/v7_3_api_parse.cpp b/wallet/api/v7_3/v7_3_api_parse.cpp index 9d844f0ab1..cc6fe4d3cb 100644 --- a/wallet/api/v7_3/v7_3_api_parse.cpp +++ b/wallet/api/v7_3/v7_3_api_parse.cpp @@ -35,11 +35,12 @@ void V73Api::getResponse(const JsonRpcId& id, const AssetsList::Response& res, j msg = json { {JsonRpcHeader, JsonRpcVersion}, - {"id", id} + {"id", id}, + {"result", json::object()} }; - msg["assets"] = json::array(); - auto& jsonAssets = msg["assets"]; + msg["result"]["assets"] = json::array(); + auto& jsonAssets = msg["result"]["assets"]; for (auto& asset: res.assets) { diff --git a/wallet/transactions/assets/aissue_transaction.cpp b/wallet/transactions/assets/aissue_transaction.cpp index fa12f9313d..dfad8558f2 100644 --- a/wallet/transactions/assets/aissue_transaction.cpp +++ b/wallet/transactions/assets/aissue_transaction.cpp @@ -86,12 +86,25 @@ namespace beam::wallet auto& builder = *_builder; if (GetState() == State::Initial) { + Asset::ID assetId = 0; + std::string unitName = kAmountASSET; + std::string nthName = kAmountAGROTH; + + const auto pInfo = GetWalletDB()->findAsset(builder.m_pidAsset); + if (pInfo) + { + assetId = pInfo->m_ID; + WalletAssetMeta meta(*pInfo); + unitName = meta.GetUnitName(); + nthName = meta.GetNthUnitName(); + } + BEAM_LOG_INFO() << GetTxID() << " " << (_issue ? "Generating" : "Consuming") << " asset with owner id " << builder.m_pidAsset - << ". Amount: " << PrintableAmount(builder.m_Value, false, 0, kAmountASSET, kAmountAGROTH); + << ". Amount: " << PrintableAmount(builder.m_Value, false, assetId, unitName.c_str(), nthName.c_str()); UpdateTxDescription(TxStatus::InProgress); }