Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Student Model for Migration #1

Open
wants to merge 32 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
323ce35
simple clean up
onlyphantom Apr 9, 2019
ef2d4d4
first phase of caching
onlyphantom Apr 15, 2019
ddbb123
Merge pull request #25 from onlyphantom/caching
onlyphantom Apr 15, 2019
101b490
update to jinja 2.10.1 / vulnerability patch
onlyphantom Apr 15, 2019
04561ab
Merge pull request #26 from onlyphantom/caching
onlyphantom Apr 15, 2019
c7cb7f1
inexpensive homepage
onlyphantom Apr 16, 2019
5731cb3
Merge pull request #27 from onlyphantom/caching
onlyphantom Apr 16, 2019
869bf9e
code refactoring on accomplishment page
onlyphantom Apr 17, 2019
4c5c6ac
more human-friendly names in leaderboard #14
onlyphantom Apr 17, 2019
bf4bcf9
Merge pull request #29 from onlyphantom/caching
onlyphantom Apr 17, 2019
f54e335
refactoring #28
onlyphantom Apr 18, 2019
b42339a
Merge pull request #32 from onlyphantom/caching
onlyphantom Apr 18, 2019
b1e09e2
implemented caching #22
onlyphantom Apr 18, 2019
d31641b
Merge pull request #33 from onlyphantom/caching
onlyphantom Apr 18, 2019
6afc635
update dependencies file
onlyphantom Apr 19, 2019
7637261
README and config cleanup
onlyphantom Apr 20, 2019
90162f8
extended admin privileges for backend portal
onlyphantom Apr 20, 2019
c0d44d4
Merge pull request #34 from onlyphantom/veteran
onlyphantom Apr 20, 2019
26f713c
team analytics page sleleton
onlyphantom Apr 21, 2019
6bfde56
Merge pull request #35 from onlyphantom/veteran
onlyphantom Apr 21, 2019
27ff662
added team analytics table
onlyphantom Apr 22, 2019
00abd90
fixed caching
onlyphantom Apr 23, 2019
cf72746
Merge pull request #36 from onlyphantom/veteran
onlyphantom Apr 23, 2019
a649c3a
improved recommendation section
onlyphantom Apr 23, 2019
331e217
added feature for #7 and fixed #37
onlyphantom Apr 24, 2019
5b0e2be
Merge pull request #38 from onlyphantom/veteran
onlyphantom Apr 24, 2019
262f62d
change config setup for modularity
onlyphantom Apr 25, 2019
64cba88
1 less env variables; constructed through string formatting
onlyphantom May 1, 2019
70c97ab
reset cache timeout and use fstring
onlyphantom May 2, 2019
36cf0ea
Bump werkzeug from 0.14.1 to 0.15.3
dependabot[bot] Nov 2, 2019
42c6bb1
Merge pull request #45 from onlyphantom/dependabot/pip/werkzeug-0.15.3
onlyphantom Nov 5, 2019
6401943
logo and homepage improvements
onlyphantom Nov 18, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
implemented caching onlyphantom#22
onlyphantom committed Apr 18, 2019
commit b1e09e2c7676ed8b2a8f05cc3492cacc2dd9a53b
11 changes: 6 additions & 5 deletions app/analytics.py
Original file line number Diff line number Diff line change
@@ -74,7 +74,7 @@ def accum_global():


@app.route('/data/accum_global_line')
@cache.cached(timeout=86400, key_prefix='gt_line')
@cache.cached(timeout=86400, key_prefix='accum_g_l')
def accum_global_line():
dat = df.copy()
dat = dat[['workshop_start', 'class_size']].sort_values(by='workshop_start')
@@ -125,7 +125,7 @@ def accum_global_line():
return chart.to_json()

@app.route('/data/punchcode')
@cache.cached(timeout=86400, key_prefix='gt_line')
@cache.cached(timeout=86400, key_prefix='pc')
def punchcode():
dat = df.copy()
dat['mnth_yr'] = dat['workshop_start'].dt.to_period('M').astype(str)
@@ -146,7 +146,7 @@ def punchcode():
return chart.to_json()

@app.route('/data/category_bars')
@cache.cached(timeout=86400, key_prefix='gt_line')
@cache.cached(timeout=86400, key_prefix='c_b')
def category_bars():
chart = alt.Chart(df).mark_bar(color='#bbc6cbe6').encode(
x=alt.X('sum(workshop_hours):Q', title='Accumulated Hours'),
@@ -220,6 +220,7 @@ def person_class_bar():
return chart.to_json()

@app.route('/data/person_vs_area')
@cache.cached(timeout=86400, key_prefix='p_v_a')
def person_vs_area():
dat_ori = getuserdb()
dat = dat_ori.loc[dat_ori.this_user == True,:].copy()
@@ -237,13 +238,13 @@ def person_vs_area():
chart = alt.Chart(dat).mark_area().encode(
column='workshop_category',
x=alt.X("workshop_start"),
y=alt.Y("cumsum:Q"),
y=alt.Y("value:Q"),
color=alt.Color("variable",
scale=alt.Scale(
range=['#7dbbd2cc', '#bbc6cbe6']),
legend=None
),
tooltip=['variable', 'cumsum:Q']
tooltip=['variable', 'value:Q']
).properties(
width=250
).configure_axis(
2 changes: 1 addition & 1 deletion app/templates/accomplishment.html
Original file line number Diff line number Diff line change
@@ -149,7 +149,7 @@ <h4><i class="material-icons md-light">rate_review</i> Most Recent Reviews</h4>
}
parse("/data/person_contrib_area", "#vis_accomp_1")
parse("/data/person_class_bar", "#vis_accomp_2")
parse("/data/accum_personal", "#vis_accomp_3")
parse("/data/person_vs_area", "#vis_accomp_3")
</script>
<!-- {% endcache %} -->
{% endblock %}