-
Notifications
You must be signed in to change notification settings - Fork 0
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
Create tables for Validation app #143
Conversation
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.
This looks good, although dash
isn't super easy to read. My only somewhat major comment at this time is the scrollbars one: there are too many! Is there anything we can do about it?
Also, I thought you were planning to put the tables in tabs. Whatever you choose is ok, just checking if you changed your mind.
# Create layout | ||
app.layout = html.Div([dcc.Graph(figure=plot)]) | ||
# Layout | ||
app.layout = html.Div( |
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.
I think this results in an odd number of vertical scroll bars.
- I've the external one - the normal one of the browser.
- The internal one to scroll a single table.
- An intermediate one that apparently scrolls through the two tables and the plot.
I don't think I see the point of this intermediate scrollbar and, moreover, it makes the navigation rather complicated. Is there a way of removing it and leave just two (the browser one and the table specific one)?.
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.
This seems to have fixed itself in a later PR
"resizable": True, | ||
"sortable": True, | ||
"checkboxSelection": { | ||
"function": "params.column == params.columnApi.getAllDisplayedColumns()[0]" |
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.
Where is this params
object coming from? Or, in other words, how this checkboxSelection
business work?
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.
params
is a Javascript object created under the hood. This is JS code to ensure the checkbox is always associated with the left-most column.
from variable.models import Variable | ||
|
||
# Create a Dash app | ||
DEFAULT_FONT = "Open Sans, Raleway, Dosis, Ubuntu, sans-serif" | ||
|
||
app = DjangoDash("DailyValidation") | ||
|
||
# Filters (in final app this will get data from forms) |
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.
I'm not logged in and all this DB querying works fine. Nothing to worry about at this time, as this part is under development, but at some point this will need to go thorugh the authentication system - specially the validation view, not so much @CWestICL 's reporting view.
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.
I'll add this as a separate issue
Continuing with #121. This PR is just about setting the layout of the tables, showing the right data, and conditional colouring of cells. I still need to write callbacks and buttons to make this functional, and decide on the overall layout of the app
Close #138