Interface: SingleBrokerMetaInfo
Broker.SingleBrokerMetaInfo
Properties
configFlags
• configFlags: BrokerConfigFlags
Broker Configuration Flags
customNotificationFields
• Optional
customNotificationFields: string
[]
Optional field. You can use it if you have custom fields in orders or positions that should be taken into account when showing notifications.
Example
if you have field additionalType
in orders and you want the chart to show a notification when it is changed, you should set:
customNotificationFields: ['additionalType']
customUI
• Optional
customUI: BrokerCustomUI
This optional field can be used to replace the standard Order Ticket and the Add Protection dialogs with your own.
Values of the following two fields are functions that are called by the Trading Platform to show the dialogs. Each function shows a dialog and returns a Promise
object that should be resolved when the operation is finished or cancelled.
NOTE: The returned Promise
object should be resolved with either true
or false
value.
Example
customUI: {
showOrderDialog?: (order: Order, focus?: OrderTicketFocusControl) => Promise<boolean>;
showPositionDialog?: (position: Position | IndividualPosition, brackets: Brackets, focus?: OrderTicketFocusControl) => Promise<boolean>;
showCancelOrderDialog?: (order: Order) => Promise<boolean>;
showClosePositionDialog?: (position: Position) => Promise<boolean>;
}
durations
• Optional
durations: OrderDurationMetaInfo
[]
List of order duration options that determine how long the order remains active.
Specifying durations
enables a drop-down menu in the Order Ticket for supported orders.
Refer to Set order duration for more information.
The objects have the following keys: { name, value, hasDatePicker?, hasTimePicker?, default?, supportedOrderTypes? }
.
orderRules
• Optional
orderRules: OrderRule
[]
Order Rules