Throw (toString (t.buyOrder.orderType))

You can try an example here: Order type in smart assets