4.20.1 (Option) Handle Offer

(Option) Handle Offer Step-by-Step test guide

Seller accepts or rejects an offer. Accept: enforce ownership cap, transfer tokens, finalize purchase (buying_token_process), emit OfferAccepted. Reject: release funds, emit OfferRejected.

Action:

  1. Developer → Extrinsics → pallet marketplacehandleOffer

    • origin: Investor

    • listingId: 3 . The listingId increases after relist action taken, the number of make offer, handle offer and buy relisted token happened to the listed property by the real estate developer at 4.1.1 List Property. This is the listing the offeror investor wants to buy from.

    • offeror: Investor. AccountId of the investor that the seller wants to handle the offer from.

    • offer: Accept or Reject .

    • offerNonce: 3 . This is not for each investor. For example, if in the past Bob has offerNonce 0 , Eve is offerNonce 1 , Dave is offerNonce 2 , then Bob comes back now now become offerNonce 3 .

  1. Submit & sign.

Post-checks:

Developer → Chain State

marketplacebalancesOnHold :

  • u32: paymentAsset accepted id ( 1337 or 1984 ).

The transaction can also be seen in Network → Explorer

Post-checks:

Developer → Chain State

realEstateAssetsaccount :

  • u32: 0 - As this is real estate assets pallet, this is not the same as the listed property by the real estate developer at 4.1.1 List Property. The remaining relist token, 5 left as the offer above is rejected.

[ [ [ 0 14E5nqKAp3oAJcmzgZhUD2RcptBeUBScxKHgJKU4HPNcKVf3 ] { balance: 36 status: Liquid reason: Consumer extra: null } ] [ [ 0 15oF4uVJwmo4TdGW7VfQxNLavjCXviqxT9S1MgbjMNHr6Sp5 ] { balance: 31 status: Liquid reason: Consumer extra: null } ] [ [ 0 126TwBzBM4jUEK2gTphmW4oLoBWWnYvPp8hygmduTr4uds57 ] { balance: 28 status: Liquid reason: Consumer extra: null } ] [ [ 0 13UVJyLnbVp8bnHxNWbLyh78torEMtxiF5eHbSn2JZWYVHPH ] { balance: 5 status: Liquid reason: Consumer extra: null } ] ]

Repeat Action (1) and (2) above on another offer and this time to accept.

The transaction can also be seen in Network → Explorer

Repeat Post-checks. As the 2 tokens offer above accepted, there are only 3 tokens left (green colour font).

[ [ [ 0 14E5nqKAp3oAJcmzgZhUD2RcptBeUBScxKHgJKU4HPNcKVf3 ] { balance: 36 status: Liquid reason: Consumer extra: null } ] [ [ 0 15oF4uVJwmo4TdGW7VfQxNLavjCXviqxT9S1MgbjMNHr6Sp5 ] { balance: 31 status: Liquid reason: Consumer extra: null } ] [ [ 0 126TwBzBM4jUEK2gTphmW4oLoBWWnYvPp8hygmduTr4uds57 ] { balance: 30 status: Liquid reason: Consumer extra: null } ] [ [ 0 13UVJyLnbVp8bnHxNWbLyh78torEMtxiF5eHbSn2JZWYVHPH ] { balance: 3 status: Liquid reason: Consumer extra: null } ] ]

assetsHolderbalancesOnHold :

  • Balances on hold will clear after the offer is accepted.

Last updated