Administrator
2024-11-20 428413d9261a1e96d76626a491d31537e5453cc2
bug修改
1个文件已修改
17 ■■■■ 已修改文件
servers/data_server.py 17 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
servers/data_server.py
@@ -97,10 +97,19 @@
                if b not in current_reason_dict:
                    current_reason_dict[b] = []
                current_reason_dict[b].append(_code)
        # (板块名称,涨停代码数量,炸板数量,涨停时间)
        limit_up_reason_statistic_info = [(k, len(record_reason_dict[k]), len(record_reason_dict[k]) - len(
        # (板块名称,涨停代码数量,炸板数量,涨停时间, 是否有辨识度的票)
        limit_up_reason_statistic_info = [[k, len(record_reason_dict[k]), len(record_reason_dict[k]) - len(
            current_reason_dict.get(k) if k in current_reason_dict else []),
                                           0) for k in record_reason_dict]
                                           0, 0] for k in record_reason_dict]
        try:
            for b in limit_up_reason_statistic_info:
                codes_ = BlockSpecialCodesManager().get_block_codes(b)
                if not codes_:
                    codes_ = set()
                b[4] = len(set(record_reason_dict[b])&set(codes_))
        except:
            pass
        limit_up_reason_statistic_info.sort(key=lambda x: x[1] - x[2])
        limit_up_reason_statistic_info.reverse()
@@ -788,7 +797,7 @@
        elif url.path == "/get_blocks_in_money_info":
            # 获取板块资金流入状况
            ps_dict = dict([(k, v[0]) for k, v in parse_qs(url.query).items()])
            type_ = ps_dict.get("type")
            type_ = int(ps_dict.get("type"))
            try:
                fdatas = []
                if type_ == 0: