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

Admin dashboard #20

Merged
merged 17 commits into from Jul 22, 2022
Merged

Admin dashboard #20

merged 17 commits into from Jul 22, 2022

Conversation

annesatran
Copy link
Contributor

  • Added admin dashboard with searchbar and sort dropdown
  • Need to add "Add" button on admin dashboard
  • Added routing to view an individual dog record with DogRecordPage component
  • DogRecordPage component makes API call to get a dog record, but nothing displays on frontend
  • Still need work on styling/choosing exactly what information is displayed

<img className="dog-record-image" src={props.imageUrl} alt={`Image of ${props.name}`} />
<Card.Title>{props.name}</Card.Title>
<Card.Subtitle className="mb-2 text-muted">{props.breed} | {props.sex == "m" ? "Male" : "Female"} | {props.ageGroup}</Card.Subtitle>
<Card.Text>Entered {moment(new Date(props.dateEntered)).format("MM/DD/YYYY")}</Card.Text>
Copy link
Contributor

Choose a reason for hiding this comment

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

Nice work! How is it working with moment?
I was also working with dates and found the command toLocaleDateString().
Maybe that could work in this case?
My only hesitation is that people say that moment is a relatively big package for what it is used for.

Copy link
Contributor

Choose a reason for hiding this comment

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

But if you tried vanilla JS and it was giving issues, let's go with moment :)

@annesatran annesatran merged commit 632acc4 into main Jul 22, 2022
@annesatran annesatran deleted the admin-dashboard branch July 22, 2022 16:01
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