Commit b71458e1 by 赵宇

fix

parent ddc1d2dc
......@@ -97,14 +97,24 @@ def menu():
dengl = company.filter_by(dengl="1").count() # 瞪羚
dujs = company.filter_by(unicorn="1").count() # 独角兽
table_dic = {"t_c5": t_c5, # 500强企业
tbe_sjmy = company.filter_by(tbe_sjmy="1").count() # 省级民营科技企业
zjtg_gjjxjr = company.filter_by(zjtg_gjjxjr="1").count() # 国家级专精特新小巨人企业
zjtg_sjxjr = company.filter_by(zjtg_sjxjr="1").count() # 省级专精特新小巨人企业
table_dic = {
# "t_c5": t_c5, # 500强企业
"ssqy": ssqy, # 上市企业
"gmys": gmys, # 规模以上企业
"zjtx": zjtx, # 专精特新企业
"gxjs": gxjs, # 高新技术企业
"kjzx": kjzx, # 科技型中小企业
"dengl": dengl, # 瞪羚企业
"dujs": dujs} # 独角兽企业
# "dengl": dengl, # 瞪羚企业
# "dujs": dujs, # 独角兽企业
"tbe_sjmy": tbe_sjmy, # 省级民营科技企业
"zjtg_gjjxjr": zjtg_gjjxjr, # 国家级专精特新小巨人企业
"zjtg_sjxjr": zjtg_sjxjr # 省级专精特新小巨人企业
}
# 2. 左上角获取经济指标数据
jjzb_data = get_jjzb(district)
......@@ -120,25 +130,25 @@ def menu():
count_szjj = company.filter_by(f_type=6).count() # 数字经济产业集群
count_qt = count_all - count_mcq - count_gjd - count_wlky - count_xdfw - count_szjj
ctys = int(count_ctys / count_all * 100)
gjd = int(count_gjd / count_all * 100)
mcq = int(count_mcq / count_all * 100)
wlky = int(count_wlky / count_all * 100)
xdfw = int(count_xdfw / count_all * 100)
szjj = int(count_szjj / count_all * 100)
# ctys = int(count_ctys / count_all * 100)
# gjd = int(count_gjd / count_all * 100)
# mcq = int(count_mcq / count_all * 100)
# wlky = int(count_wlky / count_all * 100)
# xdfw = int(count_xdfw / count_all * 100)
# szjj = int(count_szjj / count_all * 100)
# xdfu = int(count_xdfu / count_all * 100)
# qt = 100 - mcq - gjd - mtmhg - gtzz - qyly - xdfu
qt = 100 - ctys - gjd - mcq - wlky - xdfw - szjj
# qt = 100 - ctys - gjd - mcq - wlky - xdfw - szjj
# 产业结构分布
indu_dic = [
{"per": ctys, "name": "传统优势产业集群", "count": count_ctys}, # {百分比,value}
{"per": gjd, "name": "光机电产业集群", "count": count_gjd},
{"per": mcq, "name": "煤层气产业集群", "count": count_mcq},
{"per": wlky, "name": "文旅康养产业集群", "count": count_wlky},
{"per": xdfw, "name": "现代服务业产业集群", "count": count_xdfw},
{"per": szjj, "name": "数字经济产业集群", "count": count_szjj},
{"per": qt, "name": "其他", "count": count_qt},
{"name": "传统优势产业集群", "value": count_ctys}, # {百分比,value}
{"name": "光机电产业集群", "value": count_gjd},
{"name": "煤层气产业集群", "value": count_mcq},
{"name": "文旅康养产业集群", "value": count_wlky},
{"name": "现代服务业产业集群", "value": count_xdfw},
{"name": "数字经济产业集群", "value": count_szjj},
{"name": "其他", "value": count_qt},
]
# TODO 4.五大千亿级产业集群
......@@ -188,7 +198,9 @@ def project():
i = 0
for project in project_list:
i += 1
if i > 6:
print(i)
print(i)
if i > 7:
pass
else:
industry_money.append({"name": project.type,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment