Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
way committed Aug 28, 2020
1 parent 9439d40 commit f1fb1ce
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions ironman/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@
# @Site :
# @Describe:

import os
import sys

sys.path.append(os.path.dirname(os.path.abspath(__file__)) + '/../')

from flask import Flask, render_template
from ironman.data import SourceData

Expand All @@ -31,11 +36,13 @@ def bar():
xAxis = data.pop('legend')
return render_template('bar.html', title='每日访问情况', data=data, legend=list(data.keys()), xAxis=xAxis)


@app.route('/pie')
def pie():
data = source.pie
return render_template('pie.html', title='客户端设备占比', data=data, legend=[i.get('name') for i in data])


@app.route('/china')
def china():
data = source.china
Expand Down

0 comments on commit f1fb1ce

Please sign in to comment.