Administrator
2024-06-07 1a0be577a89727ef6b80245b6b53c8ddf43ca7d9
trade/trade_juejin.py
@@ -66,12 +66,12 @@
def order_volume(code, price, count):
    if not constant.TRADE_ENABLE:
        return
    if not tool.is_shsz_code(code):
    if not tool.is_can_buy_code(code):
        raise Exception("只支持00开头与60开头的代码下单")
    code_str = code
    if code[0:2] == '00':
    if tool.is_sz_code(code):
        code_str = f"SZSE.{code}"
    elif code[0:2] == '60':
    elif tool.is_sh_code(code):
        code_str = f"SHSE.{code}"
    start_time = time.time()
    results = gmapi.order_volume(code_str, count, gmapi.OrderSide_Buy, gmapi.OrderType_Limit, gmapi.PositionEffect_Open,