Skip to content

Commit

Permalink
feat: Indicate positions direction on quantity
Browse files Browse the repository at this point in the history
  • Loading branch information
holzeis committed Jan 25, 2024
1 parent c11af69 commit 76e477b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion webapp/frontend/lib/trade/order_and_position_table.dart
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,9 @@ class OpenPositionTable extends StatelessWidget {
for (var position in positions)
TableRow(
children: [
buildTableCell(Text(position.quantity.toString())),
buildTableCell(Text(position.direction == "short"
? "-${position.quantity}"
: "+${position.quantity}")),
buildTableCell(Text(position.averageEntryPrice.toString())),
buildTableCell(Text(position.liquidationPrice.toString())),
buildTableCell(Text(position.collateral.toString())),
Expand Down

0 comments on commit 76e477b

Please sign in to comment.