uses referrerpk if it exists for modifyPerpOrder
This commit is contained in:
parent
2824be1e8d
commit
bd4c4145b5
|
@ -39,6 +39,7 @@ const MarketCloseModal: FunctionComponent<MarketCloseModalProps> = ({
|
|||
|
||||
const orderbook = useMangoStore.getState().selectedMarket.orderBook
|
||||
const markPrice = useMangoStore.getState().selectedMarket.markPrice
|
||||
const referrerPk = useMangoStore.getState().referrerPk
|
||||
|
||||
// The reference price is the book mid if book is double sided; else mark price
|
||||
const bb = orderbook?.bids?.length > 0 && Number(orderbook.bids[0][0])
|
||||
|
@ -70,7 +71,8 @@ const MarketCloseModal: FunctionComponent<MarketCloseModalProps> = ({
|
|||
'ioc',
|
||||
0, // client order id
|
||||
side === 'buy' ? askInfo : bidInfo,
|
||||
true // reduce only
|
||||
true, // reduce only
|
||||
referrerPk ? referrerPk : undefined
|
||||
)
|
||||
await sleep(500)
|
||||
actions.reloadMangoAccount()
|
||||
|
|
|
@ -458,7 +458,7 @@ const OpenOrdersTable = () => {
|
|||
0,
|
||||
order.side === 'buy' ? askInfo : bidInfo,
|
||||
false,
|
||||
referrerPk
|
||||
referrerPk ? referrerPk : undefined
|
||||
)
|
||||
}
|
||||
notify({ title: t('successfully-placed'), txid })
|
||||
|
|
|
@ -314,7 +314,7 @@ const TVChartContainer = () => {
|
|||
0,
|
||||
order.side === 'buy' ? askInfo : bidInfo,
|
||||
false,
|
||||
referrerPk
|
||||
referrerPk ? referrerPk : undefined
|
||||
)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue