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

feat: Use Common db model types in frontend #291

Merged
merged 1 commit into from
Dec 17, 2024
Merged

Conversation

ayushjain17
Copy link
Collaborator

@ayushjain17 ayushjain17 commented Nov 26, 2024

Problem

Types redefined in frontend crate

Solution

Remove the repeated definitions from frontend crate and re-use types defined in superposition_types

Continuation for this PR

@ayushjain17 ayushjain17 requested a review from a team as a code owner November 26, 2024 16:20
@ayushjain17 ayushjain17 force-pushed the db_model_types_usage branch 2 times, most recently from be305a6 to 90bcdaa Compare December 2, 2024 06:35
@ayushjain17 ayushjain17 force-pushed the db_model_types_usage branch 2 times, most recently from 731d855 to 1c372bd Compare December 4, 2024 07:26
@ayushjain17 ayushjain17 force-pushed the db_model_types_usage branch 6 times, most recently from 58c75da to e7a9767 Compare December 12, 2024 11:29
@@ -66,7 +66,38 @@ pub struct Dimension {
pub position: i32,
}

#[derive(Serialize, Clone)]
#[derive(Debug, Clone, Serialize, Deserialize)]
Copy link
Collaborator

Choose a reason for hiding this comment

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

I dont think these types should be in models , can we use some other file for these types which are not related to
the db table

@@ -155,13 +158,51 @@ impl From<HashMap<String, String>> for QueryMap {
}
}

#[derive(Debug, Clone)]
#[derive(Debug, Clone, PartialEq)]
pub struct PaginationParams {
Copy link
Collaborator

Choose a reason for hiding this comment

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

these types shouldn't be in models file

@ayushjain17 ayushjain17 force-pushed the db_model_types_usage branch 3 times, most recently from bd5c3d8 to 576c6b7 Compare December 17, 2024 12:00
ShreyBana
ShreyBana previously approved these changes Dec 17, 2024
@ayushjain17 ayushjain17 changed the base branch from main to saas December 17, 2024 12:38
@ayushjain17 ayushjain17 dismissed stale reviews from ShreyBana and pratikmishra356 December 17, 2024 12:38

The base branch was changed.

@pratikmishra356 pratikmishra356 self-requested a review December 17, 2024 12:39
@ayushjain17 ayushjain17 merged commit f4301d8 into saas Dec 17, 2024
4 checks passed
@ayushjain17 ayushjain17 deleted the db_model_types_usage branch December 17, 2024 15:12
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.

3 participants