mirror of
https://github.com/Xahau/xahaud.git
synced 2025-12-06 17:27:52 +00:00
add seq to offer json
This commit is contained in:
@@ -12,4 +12,5 @@ Offer::Offer(SerializedLedgerEntry::pointer ledgerEntry) : AccountItem(ledgerEnt
|
||||
mAccount=mLedgerEntry->getFieldAccount(sfAccount);
|
||||
mTakerGets = mLedgerEntry->getFieldAmount(sfTakerGets);
|
||||
mTakerPays = mLedgerEntry->getFieldAmount(sfTakerPays);
|
||||
mSeq = mLedgerEntry->getFieldU32(sfSequence);
|
||||
}
|
||||
@@ -6,6 +6,7 @@ class Offer : public AccountItem
|
||||
RippleAddress mAccount;
|
||||
STAmount mTakerGets;
|
||||
STAmount mTakerPays;
|
||||
int mSeq;
|
||||
|
||||
|
||||
Offer(SerializedLedgerEntry::pointer ledgerEntry); // For accounts in a ledger
|
||||
@@ -17,5 +18,6 @@ public:
|
||||
STAmount getTakerPays(){ return(mTakerPays); }
|
||||
STAmount getTakerGets(){ return(mTakerGets); }
|
||||
RippleAddress getAccount(){ return(mAccount); }
|
||||
int getSeq(){ return(mSeq); }
|
||||
|
||||
};
|
||||
@@ -643,6 +643,7 @@ Json::Value RPCHandler::doAccountOffers(Json::Value jvRequest)
|
||||
//obj["account"] = account.humanAccountID();
|
||||
obj["taker_pays"] = takerPays.getJson(0);
|
||||
obj["taker_gets"] = takerGets.getJson(0);
|
||||
obj["seq"] = offer->getSeq();
|
||||
|
||||
jsonLines.append(obj);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user