....
This commit is contained in:
@@ -209,6 +209,7 @@ fun IntegratedOrderSection(
|
||||
println("basePrice : $basePrice, oneTickLowerPrice : $oneTickLowerPrice, finalPrice : $finalPrice")
|
||||
tradeService.postOrder(stockCode, orderQty, finalPrice.toLong().toString(), isBuy = true)
|
||||
.onSuccess { realOrderNo -> // KIS 서버에서 생성된 실제 주문번호
|
||||
println("주문 성공: $realOrderNo ${stockCode} $orderQty $finalPrice")
|
||||
onOrderResult("주문 성공: $realOrderNo", true)
|
||||
if (willEnableAutoSell) {
|
||||
// 1. 기본 설정값 파싱
|
||||
@@ -246,7 +247,10 @@ fun IntegratedOrderSection(
|
||||
onOrderResult("매수 및 감시 설정 완료 (목표 수익률: ${String.format("%.4f", effectiveProfitRate)}%): $realOrderNo", true)
|
||||
}
|
||||
}
|
||||
.onFailure { onOrderResult(it.message ?: "매수 실패", false) }
|
||||
.onFailure {
|
||||
println("매수 실패: ${it.message} ${stockCode} $orderQty $finalPrice")
|
||||
onOrderResult(it.message ?: "매수 실패", false)
|
||||
}
|
||||
}
|
||||
}
|
||||
LaunchedEffect(completeTradingDecision) {
|
||||
|
||||
Reference in New Issue
Block a user