-
Notifications
You must be signed in to change notification settings - Fork 5
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
Dark Mode & UI Overhauls #152
Open
Ilverism
wants to merge
72
commits into
main
Choose a base branch
from
aidan_cu/dark_mode
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
72 commits
Select commit
Hold shift + click to select a range
a09f9d8
gitignore data/archive/*
Ilverism 24f7bf4
Any Event filtering for trends / severities / flights
Ilverism 4cbcd98
Include Event.java change
Ilverism ed7bb8a
Rework Import rows visuals
Ilverism 12b45e0
Upload summary changes, Navbar icons
Ilverism 4aa90dd
Fix navbar active page name highlighting
Ilverism 789653d
Import badge formatting, Navbar background highlights on hover
Ilverism 023897e
Missing color variable usage
Ilverism 7ec3391
Change Uploads UI to match Imports, Fixes in waiting.html
Ilverism 22cbc48
Prepare to merge with Flight Updates
Ilverism 7cb508d
Categorized CSS
Ilverism 3eaa535
Top level HTML background and page load color fix
Ilverism e3e2f39
Change PostUploads access requirement 'Upload' -> 'View'
Ilverism d755dc2
Dark Mode Toggle Button + Logic
Ilverism 4e04a7a
Disable Confirm Modal 'submitMethod' call if not defined
Ilverism 4537ac9
Move Upload Flights button to the Paginator dock
Ilverism 4170252
Fix Imports Paginator dock
Ilverism eb92c68
Remove unneeded buttons from TTF Header (additional layout changes in…
Ilverism 6ae0d18
Event Definitions table UI improvements
Ilverism 4ffda72
Disable Empty Filters
Ilverism c49d792
Flights Page UI overhaul
Ilverism e95e736
Time Header buttons in one larger container
Ilverism 75fd951
Flight Tags fixes (incomplete)
Ilverism 6ec7d8c
Minor Manage Tail Numbers UI changes
Ilverism 5506062
Summary Page minor UI changes
Ilverism da12495
Paginator Sorter ellipses
Ilverism 37185bf
Event Manager table UI update
Ilverism ad6fc1d
Paginator changes, Flight upload 'triggerInput' method moved to Pagin…
Ilverism 0ed97c1
Manage Fleet UI made consistent with My Preferences UI
Ilverism 6b3c578
Misc. Minor UI changes and Sticky Navbar headers
Ilverism 0c0f9e2
gitignore data/*
Ilverism eb28995
Update scrollbar for Event Definitions page
Ilverism 7eefde4
Rework AirSync Upload Regiment (#146)
jkarns275 5d7e89c
Unsubcribe Links for Email Preferences (#144)
Ilverism 806ca6d
Fix empty default severity columns (#147)
Ilverism 955dc44
Fix Upload access for Users with 'View' perms (#148)
Ilverism c524a2d
Remove RuntimeGlobals import
Ilverism ac00bd1
Replace anti-flashbang inlined code with CSS and JS files
Ilverism 9648bd8
tabs -> spaces
Ilverism 58bfbe1
Remove package and webpack from gitignore
Ilverism 248ac51
Add missing HMTL preload headers
Ilverism f4cd970
More compressed dark mode background
Ilverism 3a1933c
Rework AirSync Upload Regiment (#146)
jkarns275 db3aace
Unsubcribe Links for Email Preferences (#144)
Ilverism 8b9e63b
Fix empty default severity columns (#147)
Ilverism 78918d4
Fix Upload access for Users with 'View' perms (#148)
Ilverism 0c177ec
Prepare to merge with Flight Updates
Ilverism d15c8ae
Move Upload Flights button to the Paginator dock
Ilverism a03e257
Paginator changes, Flight upload 'triggerInput' method moved to Pagin…
Ilverism 4f17217
Remove duplicate Paginator variable declaration
Ilverism 96f32f8
gitignore data/*
Ilverism 21d95b1
Fix button access on Uploads page for users with View and Upload priv…
Ilverism 7da394f
Hide the Upload/Delete buttons for users with View access
Ilverism 072038e
Enabled upload button for all users with upload permissions (managers…
jkarns275 a296a51
Merge branch 'main' into aidan_cu/fix_upload_button_access
jkarns275 7d81c9a
SendEmail System.out.println -> LOG.info
Ilverism 0979959
Rearrange some functions & rename some variables
Ilverism 2aff62b
Undo webpack config change
Ilverism eda975f
Environment variable for email base URL
Ilverism ad5c5c8
Enabled upload button for all users with upload permissions (managers…
jkarns275 f162eb4
Pass existing connections into email functions when possible (#155)
Ilverism 709b4db
Indicate missing Flight Info on Flights page
Ilverism 1472284
Merge branch 'main' into aidan_cu/imports_interface_updates
Ilverism d915541
Merge remote-tracking branch 'origin/main' into aidan_cu/imports_inte…
Ilverism dd0f951
Merge branch 'aidan_cu/imports_interface_updates' of https://github.c…
Ilverism f72280c
Reconcile Orange/Blue Fixes & ANY Event color changes in Trends
Ilverism 9286e0f
Merge branch 'aidan_cu/imports_interface_updates' into aidan_cu/dark_…
Ilverism d1cb6f7
Dashed lines fix for Trends , ANY Event , Percentage of Flights graph
Ilverism 20640de
Migrate Event Sevierites ANY Event fixes
Ilverism 00a4c27
Uploads page delete & download buttons OCD fix
Ilverism c060fb5
Merge remote-tracking branch 'origin/aidan_cu/fix_upload_button_acces…
Ilverism 67ea41d
Reverse percentage graph ordering so blue bars appear above orange ones
Ilverism File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,89 @@ | ||
package org.ngafid.routes; | ||
|
||
import java.time.LocalDate; | ||
|
||
import java.util.List; | ||
import java.util.ArrayList; | ||
import java.util.logging.Logger; | ||
import java.util.HashMap; | ||
|
||
|
||
import java.sql.Connection; | ||
import java.sql.SQLException; | ||
|
||
import com.google.gson.Gson; | ||
|
||
import spark.Route; | ||
import spark.Request; | ||
import spark.Response; | ||
import spark.Session; | ||
import spark.Spark; | ||
|
||
import org.ngafid.Database; | ||
import org.ngafid.WebServer; | ||
import org.ngafid.accounts.User; | ||
import org.ngafid.events.Event; | ||
import org.ngafid.events.EventStatistics; | ||
import org.ngafid.common.*; | ||
|
||
public class PostAllSeverities implements Route { | ||
private static final Logger LOG = Logger.getLogger(PostAllSeverities.class.getName()); | ||
private Gson gson; | ||
|
||
public PostAllSeverities(Gson gson) { | ||
this.gson = gson; | ||
LOG.info("post " + this.getClass().getName() + " initalized"); | ||
} | ||
|
||
|
||
@Override | ||
public Object handle(Request request, Response response) { | ||
LOG.info("handling " + this.getClass().getName() + " route"); | ||
|
||
String startDate = request.queryParams("startDate"); | ||
String endDate = request.queryParams("endDate"); | ||
String eventNames = request.queryParams("eventNames"); | ||
String tagName = request.queryParams("tagName"); | ||
final Session session = request.session(); | ||
User user = session.attribute("user"); | ||
int fleetId = user.getFleetId(); | ||
|
||
//check to see if the user has upload access for this fleet. | ||
if (!user.hasViewAccess(fleetId)) { | ||
LOG.severe("INVALID ACCESS: user did not have access view imports for this fleet."); | ||
Spark.halt(401, "User did not have access to view imports for this fleet."); | ||
return null; | ||
} | ||
|
||
try { | ||
|
||
Connection connection = Database.getConnection(); | ||
String[] eventNamesArray = eventNames.split(","); | ||
HashMap<String, HashMap<String, ArrayList<Event>> > eventMap = new HashMap<>(); | ||
|
||
for (String eventName : eventNamesArray) { | ||
|
||
//Remove leading and trailing quotes | ||
eventName = eventName.replace("\"", ""); | ||
|
||
//Remove brackets | ||
eventName = eventName.replace("[", ""); | ||
eventName = eventName.replace("]", ""); | ||
|
||
//Remove trailing spaces | ||
eventName = eventName.trim(); | ||
|
||
if (eventName.equals("ANY Event")) | ||
continue; | ||
|
||
HashMap<String, ArrayList<Event>> events = Event.getEvents(connection, fleetId, eventName, LocalDate.parse(startDate), LocalDate.parse(endDate), tagName); | ||
eventMap.put(eventName, events); | ||
} | ||
|
||
return gson.toJson(eventMap); | ||
|
||
} catch (SQLException e) { | ||
return gson.toJson(new ErrorResponse(e)); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -73,4 +73,4 @@ public Object handle(Request request, Response response) { | |
return gson.toJson(new ErrorResponse(e)); | ||
} | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would making these JSON parameters simplify the code below?