-
Notifications
You must be signed in to change notification settings - Fork 0
Description
Description:
Here are some notes for "things that need to be done for Legacy QC." For context, my next.js and my React is very sloppy compared to my nuxt.js. I likely missed stuff
TODO:
- Prisma
- Pascal case for non-scalars. For example,
model Person {
// Indexes
id String @id @default(uuid())
// Fields
first_name String
last_name String
country_code String?
state_code String?
phone_number String?
type PersonType
// Relations
user User? // capitalize User
teamMember TeamMember? // capitalize TeamMember
}- Collapse User and Team Member tables into User table (move all fields from those tables into User table)
- Rename PersonType to role
- HOLLISTIC enum needs to be changed to HOLISTIC
- Look into maybe doing explicit m-n relationships instead of implicit, but idk if this is required or not
- delete PrintButton.tsx
- API Section
- Collapse multiple routes into strictly just
[id].tsandindex.ts. The two files should handle the basic CRUD functionality and their exact functions can be specified with HTTP methods. - API routes should not have any verbs in them, as long as it's not complicated logic. Imagine instead of member/getScore.ts, it's member/score.ts. So on and so forth. Stick to nouns and the verb can be specified with the HTTP method
- There should be ZERO use case for
letin your typescript. Review all instances of let and change them toconstif possible! - The room directory is bloated. You should probably modularize it into a directory-per-table basis.
- Some of the
req.methodchecks don't make sense. There are a lot ofPOSTrequirements even though POST-ing is not what you're trying to do (unless you're trying to do something weird with non-idempotency) - scheduling has a lot of logic that maybe doesn't need to be done on serverside. Check it out
- Collapse multiple routes into strictly just
- Check the README.md and Legacy-Housekeeping-QC.md. They seem to have the same function.
Sub-issues
Metadata
Metadata
Assignees
Labels
No labels