From 060a33b5a36abead19f51bddbcc257221920d685 Mon Sep 17 00:00:00 2001 From: sairaj mote Date: Sun, 24 Sep 2023 23:32:05 +0530 Subject: [PATCH] added min | nax subscription amount to smart contract creation tx --- index.html | 98 +++++++++++++++++++++++++++++++++--------------------- 1 file changed, 60 insertions(+), 38 deletions(-) diff --git a/index.html b/index.html index 9c38dd8..ec0e99b 100644 --- a/index.html +++ b/index.html @@ -837,7 +837,10 @@ `; }, contractCreationCard(obj) { - const { hash, blockHeight, token, contractName, incAddress, contractType, expiration, participationFees, availableChoices, time, acceptingToken, sellingToken, price } = obj; + const { + hash, blockHeight, token, contractName, incAddress, contractType, + expiration, participationFees, availableChoices, time, acceptingToken, sellingToken, price, + minAmount, maxAmount } = obj; console.log(obj) return html`
  • @@ -864,42 +867,56 @@ ${replaceDash(contractType) === 'continuos event' ? 'continuous event' : replaceDash(contractType)} - ${token ? html` -
    -
    token used
    -

    ${token}

    -
    - `: ''} - ${acceptingToken ? html` -
    -
    Participation token
    -

    ${acceptingToken}

    -
    - `: ''} - ${sellingToken ? html` -
    -
    Deposit token
    -

    ${sellingToken}

    -
    - `: ''} - ${expiration ? html` -
    -
    expiration
    -

    ${getFormattedTime(new Date(expiration).getTime())}

    -
    - `: ''} - ${participationFees ? html` -
    -
    participation amount
    -

    ${participationFees} ${token}

    -
    - `: ''} - ${price ? html` -
    -
    price
    -

    1 ${sellingToken} = ${formatAmount(price, 'usd')} ${acceptingToken}

    -
    - `: ''} +
    + ${token ? html` +
    +
    token used
    +

    ${token}

    +
    + `: ''} + ${acceptingToken ? html` +
    +
    Participation token
    +

    ${acceptingToken}

    +
    + `: ''} + ${sellingToken ? html` +
    +
    Deposit token
    +

    ${sellingToken}

    +
    + `: ''} + ${expiration ? html` +
    +
    expiration
    +

    ${getFormattedTime(new Date(expiration).getTime())}

    +
    + `: ''} + ${participationFees ? html` +
    +
    participation amount
    +

    ${participationFees} ${token}

    +
    + `: ''} + ${price ? html` +
    +
    price
    +

    1 ${sellingToken} = ${formatAmount(price, 'usd')} ${acceptingToken}

    +
    + `: ''} + ${minAmount ? html` +
    +
    min amount
    +

    ${minAmount} ${token}

    +
    + `: ''} + ${maxAmount ? html` +
    +
    max amount
    +

    ${maxAmount} ${token}

    +
    + `: ''} +
    Transaction ID
    @@ -1702,7 +1719,10 @@ senderAddress, contractAddress, contractType, - contractConditions: { expiryTime, accepting_token, selling_token, subtype, price } = {}, + contractConditions: { + expiryTime, accepting_token, selling_token, subtype, price, + participationAmount, minimumsubscriptionamount, maximumsubscriptionamount + } = {}, contractAmount, type, tokenAmount, @@ -1784,6 +1804,8 @@ participationFees: contractAmount, availableChoices: "", type: "contractincorp", + minAmount: minimumsubscriptionamount, + maxAmount: maximumsubscriptionamount, }); break; }