Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
dd82d127ea | ||
|
|
f97e22d6eb | ||
|
|
f9e04ee28c | ||
|
|
1ce00ca13d |
No files matched your search
@@ -4,6 +4,14 @@ weight = 3
|
||||
sort_by = "weight"
|
||||
insert_anchor_links = "right"
|
||||
+++
|
||||
## 2.1.3
|
||||
### User Visible Changes
|
||||
- Fixed a simulator bug in the handling of 0 sized orders
|
||||
|
||||
## 2.2.1
|
||||
### User Visible Changes
|
||||
- Fixed order book form exception when display a spreader order for whichs the legs were not present yet
|
||||
|
||||
## 2.1.1
|
||||
### User Visible Changes
|
||||
- Added PIQ to GLBX Iceberg orders
|
||||
|
||||
@@ -390,12 +390,16 @@ namespace mbts.spark {
|
||||
if (order_properties_vm == null)
|
||||
return;
|
||||
var s = _settings_manager.current_settings();
|
||||
if (DoubleHelper.IsNaNOrInfinity(args.price) || !args.side.HasValue || HasErrors || order_properties_vm.HasErrors || (size_from_alternate && s.alternate_order_size == 0))
|
||||
if (DoubleHelper.IsNaNOrInfinity(args.price) || !args.side.HasValue || HasErrors || order_properties_vm.HasErrors || (size_from_alternate && s.alternate_order_size == 0)) {
|
||||
return;
|
||||
if (!size_from_alternate && (!size_calculator.value.HasValue || size_calculator.value.Value == 0))
|
||||
}
|
||||
if (!size_from_alternate && (!size_calculator.value.HasValue || size_calculator.value.Value == 0)) {
|
||||
size_calculator.flash_error();
|
||||
uint size = size_from_alternate ? s.alternate_order_size : (uint)Math.Abs(size_calculator.value.Value);
|
||||
send_order_async(args.side.Value, size, args.price).ignore();
|
||||
}
|
||||
else {
|
||||
uint size = size_from_alternate ? s.alternate_order_size : (uint)Math.Abs(size_calculator.value ?? 0);
|
||||
send_order_async(args.side.Value, size, args.price).ignore();
|
||||
}
|
||||
}
|
||||
|
||||
public async Task send_order_async(Side side, uint size, double price) {
|
||||
|
||||
@@ -222,7 +222,7 @@ void ExchangeSimApplication::onMessage(const FIX42::NewOrderSingle &message,
|
||||
order.set_type(convert(ordType));
|
||||
|
||||
if (orderQty.getValue() == 0)
|
||||
throw new std::logic_error("Quantity must be greater than 0");
|
||||
throw std::logic_error("Quantity must be greater than 0");
|
||||
|
||||
if (order.type() == api::orderman::NATIVE_ORDER_TYPE_LIMIT)
|
||||
order.set_price(price);
|
||||
@@ -232,13 +232,13 @@ void ExchangeSimApplication::onMessage(const FIX42::NewOrderSingle &message,
|
||||
if (book.asks.size())
|
||||
order.set_price(book.asks.begin()->first.value());
|
||||
else
|
||||
throw new std::logic_error("No sell market");
|
||||
throw std::logic_error("No sell market");
|
||||
} else {
|
||||
|
||||
if (book.bids.size())
|
||||
order.set_price(book.bids.begin()->first.value());
|
||||
else
|
||||
throw new std::logic_error("No buy market");
|
||||
throw std::logic_error("No buy market");
|
||||
}
|
||||
}
|
||||
order.set_quantity(orderQty);
|
||||
|
||||
Reference in new issue
Block a user