-
Notifications
You must be signed in to change notification settings - Fork 629
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
Resources redesign #10308
Merged
bodhish
merged 5 commits into
ohcnetwork:develop
from
Jacobjeevan:issues/10285-resources-redesign
Jan 31, 2025
+388
−3,768
Merged
Resources redesign #10308
Changes from 2 commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
a964e29
Resources redesign
Jacobjeevan d3580a9
switching urls, styling tweaks, outgoing/incoming
Jacobjeevan 4cd3ec0
remove unused stuff
rithviknishad 090f5fc
minor styling
Jacobjeevan db0f427
Merge branch 'develop' into issues/10285-resources-redesign
Jacobjeevan File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,19 @@ | ||
import View from "@/components/Common/View"; | ||
import BoardView from "@/components/Resource/ResourceBoard"; | ||
import ResourceDetails from "@/components/Resource/ResourceDetails"; | ||
import { ResourceDetailsUpdate } from "@/components/Resource/ResourceDetailsUpdate"; | ||
import ListView from "@/components/Resource/ResourceList"; | ||
import ResourceList from "@/components/Resource/ResourceList"; | ||
|
||
import { AppRoutes } from "@/Routers/AppRouter"; | ||
|
||
const ResourceRoutes: AppRoutes = { | ||
"/resource": () => <View name="resource" board={BoardView} list={ListView} />, | ||
"/resource/:id": ({ id }) => <ResourceDetails id={id} />, | ||
"/resource/:id/update": ({ id }) => <ResourceDetailsUpdate id={id} />, | ||
"/facility/:facilityId/resource": ({ facilityId }) => ( | ||
<ResourceList facilityId={facilityId} /> | ||
), | ||
"/facility/:facilityId/resource/:id": ({ facilityId, id }) => ( | ||
<ResourceDetails facilityId={facilityId} id={id} /> | ||
), | ||
"/facility/:facilityId/resource/:id/update": ({ facilityId, id }) => ( | ||
<ResourceDetailsUpdate facilityId={facilityId} id={id} /> | ||
), | ||
}; | ||
|
||
export default ResourceRoutes; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
💡 Codebase verification
Inconsistent status value casing found in resource components
The new
RESOURCE_STATUS_CHOICES
uses lowercase values, but some components still use uppercase status values. This inconsistency should be fixed in:src/components/Resource/ResourceCreate.tsx
: Uses "PENDING"src/components/Resource/PrintResourceLetter.tsx
: Uses "PENDING" and "REJECTED"🔗 Analysis chain
LGTM! The new resource status choices are well-structured.
The changes improve the code in several ways:
as const
for better type safetyLet's verify the usage of these new status choices:
🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
Length of output: 3463
Script:
Length of output: 468
Script:
Length of output: 2830