...
This commit is contained in:
parent
b7fb5c9085
commit
ad91e10ad9
@ -323,7 +323,7 @@ object KisTradeService {
|
||||
price: String,
|
||||
isBuy: Boolean,
|
||||
orderDivision: String = "",
|
||||
marketCode : String = "KRX"
|
||||
marketCode : String = ""
|
||||
): Result<String> {
|
||||
val config = KisSession.config
|
||||
val isDomestic = stockCode.length == 6 && stockCode.all { it.isDigit() }
|
||||
@ -357,7 +357,7 @@ object KisTradeService {
|
||||
header("Content-Type", "application/json")
|
||||
|
||||
setBody(mapOf(
|
||||
"EXCG_ID_DVSN_CD" to marketCode,
|
||||
// "EXCG_ID_DVSN_CD" to marketCode,
|
||||
"CANO" to cano,
|
||||
"ACNT_PRDT_CD" to acntPrdtCd,
|
||||
"PDNO" to stockCode,
|
||||
|
||||
@ -430,7 +430,7 @@ object AutoTradingManager {
|
||||
if (isRunning()) return
|
||||
val now = LocalTime.now()
|
||||
val currentMinute = now.minute
|
||||
if (now.isBefore(H16) && now.isAfter(H08M35)) {
|
||||
// if (now.isBefore(H16) && now.isAfter(H08M35)) {
|
||||
println("resumePendingSellOrders")
|
||||
balance.holdings.forEach { holding ->
|
||||
if (BLACKLISTEDSTOCKCODES.contains(holding.code)){
|
||||
@ -487,7 +487,7 @@ object AutoTradingManager {
|
||||
delay(200) // API 호출 부하 방지
|
||||
}
|
||||
}
|
||||
}
|
||||
// }
|
||||
}
|
||||
var isSystemReadyToday = false
|
||||
var isSystemCleanedUpToday = false
|
||||
@ -621,7 +621,7 @@ object AutoTradingManager {
|
||||
var loadedTops = mutableListOf<Pair<String, String>>()
|
||||
|
||||
fun poll100Stocks(): List<Pair<String, String>> {
|
||||
val count = minOf(loadedTops.size, 100)
|
||||
val count = minOf(loadedTops.size, 150)
|
||||
if (count == 0) return emptyList()
|
||||
|
||||
// 앞의 100개를 복사
|
||||
@ -723,7 +723,7 @@ object AutoTradingManager {
|
||||
val now = LocalTime.now()
|
||||
val currentMinute = now.minute
|
||||
println("매도 스케줄 체크")
|
||||
if (now.hour == 9 && (currentMinute == 1 || currentMinute == 15 || currentMinute == 40)) {
|
||||
if (now.hour == 9 && (currentMinute == 1 || currentMinute == 15 || currentMinute == 45)) {
|
||||
if (lastForceCheckMinute != currentMinute) {
|
||||
TradingLogStore.addAnalyzer(" - ", " - ", "⏰ [강제 스케줄 실행] 오전 9시 ${currentMinute}분 - 보유주식 매도 체크를 시작합니다.", true)
|
||||
println("⏰ [강제 스케줄 실행] 오전 9시 ${currentMinute}분 - 보유주식 매도 체크를 시작합니다.")
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user