This commit is contained in:
dsyoon
2023-02-06 10:33:40 +09:00
parent 4e459aa4b8
commit 3b6f54fd3a

View File

@@ -82,7 +82,7 @@ class HTS_etf (HTS):
def getCount(self, stock_code, price):
if stock_code == "252670" or stock_code == "122630":
MAX_BUY_PRICE = 300000
MAX_BUY_PRICE = 200000
else:
MAX_BUY_PRICE = 100000
@@ -141,6 +141,8 @@ class HTS_etf (HTS):
if not self.orderChecker.exist(today, "A" + stock['stock_code'], mins=30):
buy_count = self.getCount(stock['stock_code'], bs_buy_price)
if buy_count > 0:
# 매수를 주문한다.
orderNum = self.requestOrder(OrderType.buy, stock['stock_code'], buy_count , bs_buy_price)
self.orderChecker.buy(today, "A" + stock['stock_code'], buy_count, bs_buy_price, orderNum)