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

Railsifying tries and cases table structure #61

Merged
merged 24 commits into from
Jan 16, 2020
Merged

Conversation

epugh
Copy link
Member

@epugh epugh commented Jan 13, 2020

converting python CamelCase to Rails snake_case.

Description

Lots of updates!

Motivation and Context

At somepoint, someone is going to treat Quepid as an API, and build there own front end, say for doing ratings, or otherwise want to import/extract data via API. Having two styles of how data passes in and out of Quepid is error prone, and has bit me before.

Let's at least get the API side all the same. Pay down some tech debt!

How Has This Been Tested?

unit tests, and then manual testing and looking in the database. Especially since we don't have any true integration tests between the web app JS layer and the back end Rails app.

This is very painful ;-)

@epugh
Copy link
Member Author

epugh commented Jan 13, 2020

The TryFactory.js and the settingsSvc.js both contain the mappings between the future snake_case and the current JS CamelCase, so need to look more there ;-)

@epugh
Copy link
Member Author

epugh commented Jan 15, 2020

Need to deal with NumberOfRows defined in the API, it should be number_of_rows.

@epugh
Copy link
Member Author

epugh commented Jan 15, 2020

down to tryNo and in the cases table the columns caseName, lastTry columns.

@epugh
Copy link
Member Author

epugh commented Jan 15, 2020

so much refactoring need to remember to remove extra debugging...

@epugh
Copy link
Member Author

epugh commented Jan 15, 2020

don't forget to fix json.caseNo

@epugh epugh changed the title WIP: Railsifying tries table Railsifying tries and cases table structure Jan 16, 2020
@epugh epugh requested a review from worleydl January 16, 2020 16:39


angular.forEach(this.cases, function(c) {
// This is really ugly.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Revisit this code if #65 sets up lazy load for cases within a team.

Copy link
Collaborator

@worleydl worleydl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added a comment to come back to the "ugly" mapping solution for Cases with a team.

@o19s-admin
Copy link

o19s-admin commented Jan 16, 2020 via email

@epugh epugh merged commit 1f0bf17 into master Jan 16, 2020
@epugh epugh deleted the railsifying_tries_table branch February 11, 2020 11:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants