Make two different insert Statements?

I’m playing around with some dashboard and API + two simple forms of: BUY and SELL. Now when hitting sell form it takes no matter the same form, as I have same form field names for both forms. Should I separate these form names uniquely and make smth like:

FORM SELL:
pairsell
quantitysell
pricesell
feesell
typesell

and
FORM BUY
pairbuy
quantitybuy
pricebuy
feebuy
typebuy

or handle it via IF statement in Server Insert to identify what was send? I really wanna keep it simple.

Your form name/Id and inputs names/ids must be unique. :slight_smile:

1 Like

Add a hidden field to the forms called ‘action’ (or something like that) and set to ‘sell’ or ‘buy’ depening on which form it is in

Then use a server Connect =>Core=>Condition to select the query based on the value of the ‘action’ field

1 Like

Thank you thats indeed a good idea!