From cc9dc2192fc5ca670b8edd154565a05930672b70 Mon Sep 17 00:00:00 2001 From: pengtao Date: Wed, 23 Oct 2019 10:29:37 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=AF=BC=E5=87=BA=E7=8E=87?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- daily_report/dreport.py | 4 +-- daily_report/templates/report.html | 48 +++++++++++++++--------------- 2 files changed, 26 insertions(+), 26 deletions(-) diff --git a/daily_report/dreport.py b/daily_report/dreport.py index a33c020..4f27fac 100644 --- a/daily_report/dreport.py +++ b/daily_report/dreport.py @@ -341,5 +341,5 @@ def main(): if __name__ == "__main__": - main() - #app.run(host='0.0.0.0', port=6700, debug=False) + #main() + app.run(host='0.0.0.0', port=6700, debug=False) diff --git a/daily_report/templates/report.html b/daily_report/templates/report.html index 7d5ae7a..dd07b9a 100644 --- a/daily_report/templates/report.html +++ b/daily_report/templates/report.html @@ -5,18 +5,18 @@ 金蚕游戏日报,By ops + +{% for line in data %} + +

游戏内容 - - - - - 游戏ID:{{data['gameid']}}
- 渠道ID:{{data['channelid']}}
- 日期:{{data['day']}}
+ 游戏ID:{{line['gameid']}}
+ 渠道ID:{{line['channelid']}}
+

@@ -37,7 +37,7 @@ -{% for item in data.get('all') %} +{% for item in line.get('all') %} {{ item }} {% endfor %} @@ -50,21 +50,21 @@

导入数据:

> - 渠道ID - 游戏名称 - 活跃 - 新增 - 分享 - K值 + 渠道ID + 游戏名称 + 活跃 + 新增 + 分享 + K值
-{% for line in data.get('input') %} +{% for one in line.get('input') %} - {%for item in line%} - {{ item }} + {% for item in one %} + {{ item }} {% endfor %}
@@ -72,18 +72,18 @@

导出数据:

> - 渠道ID - 跳转目标 - 跳转次数 - 跳转人数 + 渠道ID + 跳转目标 + 跳转次数 + 跳转人数
-{% for line in data.get('output') %} +{% for one in data.get('output') %} - {% for item in line %} - {{ item }} + {% for item in one %} + {{ item }} {% endfor %}