kami-nashi / skatetrax Goto Github PK
View Code? Open in Web Editor NEWPython/Flask Implementation Of My KN-FSM
License: GNU General Public License v3.0
Python/Flask Implementation Of My KN-FSM
License: GNU General Public License v3.0
The total hours is wrong.
Coach to practice ratio pie is wrong.
Budgeting is wrong.
Its all wrong.
Update various sections (charts, tables, etc) with the ability to refresh data on click or onload with out refreshing the whole page.
to be used for
The notes, videos, etc items need to be moved:
route: journal
Not helpful. dunno what happened.
Based on:
https://github.com/roytuts/python/tree/master/python_flask_mysql_bootstrap_calendar_events
The idea is to have a calendar, per coach, for scheduling and availability.
Bonus points:
Needs a RPM to setup the nginx crap.
Dirs
venv
flask
gunicorn
pymysql
and such.
Needs a bit of review and probably re-engineering. old code did not account for multiple rinks yet, now it should.
Also, needs to be able to handle punch voids and credits (because its happened and messed this up)
???
the before_request fixes issues where values were not being updated in the pages.
login/session data is not populating the before_request var's.
Not sure how to fix this yet. Needs research, brainstorming, or higher level help.
Here is the concept. The "Acquisition of Skills" guidelines are just that - guidelines. Lets enable users to create a goal based on this document.
Example:
Total Hours Discipline Years Expected Hours
750 Free Skating 1-4 3 250-500
500 Beginner 5-8 2 250-350
250 Beginner 1-4 1 250-350
AcquisitionOfSkills.pdf
Most of the code can be re-used and slightly adjusted from the dashboard page, just needs to be done
Alignment & readability could use a make over.
login page does not use a template and is basically a duplication of the welcome page.
This will require some var's being dropped into position, instead of feeding json to chartJS.... until we figure out how to do that.
It works on the PHP version, just needs to be ported and enabled here. Bonus points if no refresh occurs (but that wont block success)
This stuff isn't going to explain itself, we need some general workflow guidance and a map of where things are.
Maintenance issue in 'issue 31' is a side effect of buying new skates. Time on old skates did not reset for new skates, because none of that is set up.
Needs:
Ice_time = valid skate_config_ID & value
Skater's personal config = active skate_config & value
Modals will need to submit the active skate_config into the ice_time config_id
Maintenance will have to select the active skate_config, then total hours and cost on each config
Maintenance will have to sum all skate_config costs.
ice_time UI will need to reference active skate_config hours against "maintenance_limit"
Exclude all off-ice skates
Bonus Points:
Enable a skater's preference for how many hours are wanted for maintenance. Mine is typically 21 hours, but could change with new skates.
On maintenance UI, show hours on per skate_config
Sessions tables are not displaying coach rate.
Specifically to clean form data
Something like:
https://gist.github.com/dustyfresh/10d4e260499612c055f91f824ebd8a64
This will require some var's being dropped into position, instead of feeding json to chartJS.... until we figure out how to do that.
Only creatable/editable via coach types
View-only by student types or parent types
Consult with Robin as to what should be included.
In the modal for "update time", the drop down for coaches list isn't populating dynamically as expected. Maybe that it wasn't completely ported over from PHP, or its just not working like we thought it was.
Reference Data:
2020-07-15; ice_time table line 247 had to be manually updated for coach ID 5 because coach ID 5 wasn't in the drop down list.
Certain entries need a if/then or true/false expression to reset var's to other things, like html.... or the such.
It appears that certain parts of the page do not update after submitting ice_time. I think anything that is json api related is working as expected, which is mostly just graphs and session tables - but the lists and non-json based items require a service restart to update data.
There are various versions of skating journals available in print. Lets take a first step to create a form that focuses on what the student wants to work on during the next lesson, week, or month. Ideally, the skater should be able to disposition the journal entry with some type of "goal met" or "we did it", or some other short response so that as time passes, the skater, parent, and/or coach and assess as to if goals are being met.
Coach feedback will need to be planned for a separate feature release
The time axis is showing minutes, should show hours. Whoops.
The date axis would benefit from being reversed, showing the oldest date on the left.
This will require some var's being dropped into position, instead of feeding json to chartJS.... until we figure out how to do that.
No need to hide anything behind an auth-wall yet, just get it working and in the right places.
This would need ....
additional skate_type added in db (freestyle, public, punch_card, pic)
a way to differentiate skate config's between pic vs ice so that pic time doesn't interfere with blade maintenance
a way to show pic practice time vs ice practice time
a way to show pic coaching time vs ice coaching time.
Probably want to see that in the last_month vs this_month icetime view
Currently, if one over skates the maintenance limit, it shows a negative amount of hours until maintenance is due.
Lets do an IF statement that basically says: If posative, show text "Hours Remaining", else show text "Hours OVER"
We dun messed up.
After reviewing: https://blog.paradoxis.nl/defeating-flasks-session-management-65706ba9d3ce
It is clear that there a few easy things we can do to secure the application.
First, move the secret into the config file that we use for database credentials (sample in asset folder) and have the app pull that data in from the file.
Second, generate a 'secure as hell' key for said file
Third, update the example and any documentation around it.
Bonus points:
Have a competent friend give it a beating and report the results.
Currently, each pie/donut chart on the dashboard (/) has its own splat of code, dynamically created in the template.
Need to get these converted to something a bit more scalable, preferably external JS files that can be re-used and fed via json URL
Maintenance page needs moved over, with all associated elements.
Previously implemented feature now broken:
On Ice Time page, video icon would provide a url to the journal with a filter for only that specific day
Referenced Legacy Code:
https://github.com/kami-nashi/kn-fsm/blob/master/include.d/table_sessions.php
Potential corrections/suggestions:
https://stackoverflow.com/questions/24892035/how-can-i-get-the-named-parameters-from-a-url-using-flask
https://stackoverflow.com/questions/52117522/how-to-pass-get-parameters-to-url-using-flask-request
List coach's active students
Include:
Current month's practice/coach ratio pie
Current month's practice/coach text
YTD Area Chart
Now that logins are 'secure', skater info can be pulled in accurately.
To prevent some attacks
Add spreadsheet and git repo links, for reference and such.
JS Files Located @ https://github.com/kami-nashi/skatetrax/blob/master/app/static/js/
https://github.com/kami-nashi/skatetrax/blob/master/app/static/js/charts_monthlyCoaching.js
At line 28 & 29, the var's have data assigned to them. How ever, once they are referenced in the new chart, on line 32 - they're empty.
Really bad in the ice_time page, and finance part of dashboard.
Originally, punch card data seemed like it fit well on the ICETIME menu item. How ever, now, that doesn't appear to be the case.
We can move it to a punch card section of its own, but that view needs to be useful in its entirety. Bonus points if we can make a bootstrap 'card' for the current punch status, if any, for the dashboard view.
Seems have happened as correcting the math for total tracked hours vs coached/uncoached hours
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.