This patch is a workaround to https://github.com/encode/django-rest-framework/issues/7479
Load and dump YAML using a dumper with disabled aliases in order to
workaround the aforementioned bug.
Signed-off-by: Vasilis Tsiligiannis <acinonyx@openwrt.gr>
Linting for imported-auth-user to use get_user_model() instead
Pulled unused (old) variables and queries out of views for home, satellites, satellite, stats. Should improve page load a bit.
Relates to #424
Signed-off-by: Corey Shields <cshields@gmail.com>
Adds 2 fields to transmitter model, coordination (fixed set of choices, defaulting to blank) and coordination_url. API, UI, and tests are included.
Also introduces a bad_transmitter property to transmitter that will return true if any 'Uncoordinated' or '..Rejected' status is selected.
Fixes#311
Signed-off-by: Corey Shields <cshields@gmail.com>
Changes the admin email notifications to a backend celery task so that the UI does not block on it.
Also prevents this process from running twice as form_valid gets triggered for validation and saving.
Should fix#421
Signed-off-by: Corey Shields <cshields@gmail.com>
handle deep-linking of anchors into tabbed panes on the satellite and stats pages.
Fixes#399
Also clean up map visibility, only showing if a satellite has not re-entered *and* has a TLE associated with it (note, we are not testing for validity of the TLE).
Fixes#412
Signed-off-by: Corey Shields <cshields@gmail.com>
Image files were not getting uploaded due to the lack of enctype on the form.
Easy fix, hard discovery (sigh)
Fixes#413
Signed-off-by: Corey Shields <cshields@gmail.com>
Fix the toggling of the control-sidebar, the text coloring of the control-sidebar, and clean up html on the help page.
Signed-off-by: Corey Shields <cshields@gmail.com>
Adds a chart card showing the last month of decoded data as currently stored in influxdb.
Unfortunately there's no native way to count the number of 'entries' for a measurement across a given time, so we have to do a count(*) across all points. This returns a blob of <timestamp>, <count(pointa)>, <count(pointb)>, <...> and in almost (but not all) cases those counts will be identical but we have to account for it not, so I iterate over each timestamp (client side) and take the max count to assign to that point in time. Since we are doing a 30d query from influx with 1d aggregation this should not be too intensive.
Also cleaned up the coloring of the profile link buttons.
Signed-off-by: Corey Shields <cshields@gmail.com>
Update the card look and feel from the Data panel to match everything else in the Info/Profile panel.
Signed-off-by: Corey Shields <cshields@gmail.com>
Relates to #233Fixes#364
More improvements to the transmitter submission process to auto-convert PPB to Hz and back, as well as popover.js tooltips from help_text in the model.
Signed-off-by: Corey Shields <cshields@gmail.com>
Re-implementing the case-on-type of the prior db UI.
To keep CSP happy along with the fact that we dynamically load the modal with django-bootstrap-modal, the javascript for these modals is in a new file, and that file's hash is kept in the CSP.
Also re-introduces child_src to test fixing a safari mapbox bug
Relates to #233Fixes#387