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

Hammer/permissions #845

Merged
merged 7 commits into from
Nov 29, 2023
Merged

Hammer/permissions #845

merged 7 commits into from
Nov 29, 2023

Conversation

aaronchongth
Copy link
Member

@aaronchongth aaronchongth commented Nov 28, 2023

What's new

  • stub to be admin
  • only admins allowed to cancel tasks
  • refactored task cancellation button into a component that handles enforcing permissions, events and toasts
  • edit schedule series only available for admins
  • removed all inspect buttons

Self-checks

  • I have prototyped this new feature (if necessary) on Figma
  • I'm familiar with and follow this Typescript guideline
  • I added unit-tests for new components
  • I tried testing edge cases
  • I tested the behavior of the components that interact with the backend, with an e2e test

Copy link

codecov bot commented Nov 28, 2023

Codecov Report

Attention: 441 lines in your changes are missing coverage. Please review.

Comparison is base (fe0e808) 49.35% compared to head (dd8190d) 47.11%.
Report is 26 commits behind head on deploy/hammer.

Files Patch % Lines
packages/dashboard/src/components/map-app.tsx 0.00% 103 Missing ⚠️
...es/api-server/api_server/models/delivery_alerts.py 12.94% 74 Missing ⚠️
.../dashboard/src/components/delivery-alert-store.tsx 0.00% 61 Missing ⚠️
...shboard/src/components/tasks/task-cancellation.tsx 0.00% 37 Missing ⚠️
...s/dashboard/src/components/tasks/task-schedule.tsx 0.00% 28 Missing ⚠️
...es/api-server/api_server/routes/delivery_alerts.py 26.66% 22 Missing ⚠️
...ckages/api-server/api_server/routes/tasks/tasks.py 36.36% 14 Missing ⚠️
...shboard/src/components/three-fiber/robot-three.tsx 0.00% 11 Missing ⚠️
...ashboard/src/components/three-fiber/lift-three.tsx 0.00% 10 Missing ⚠️
...react-components/lib/lifts/lift-table-datagrid.tsx 10.00% 1 Missing and 8 partials ⚠️
... and 20 more
Additional details and impacted files
@@                Coverage Diff                @@
##           deploy/hammer     #845      +/-   ##
=================================================
- Coverage          49.35%   47.11%   -2.25%     
=================================================
  Files                285      289       +4     
  Lines               7564     8030     +466     
  Branches            1050     1175     +125     
=================================================
+ Hits                3733     3783      +50     
- Misses              3682     4071     +389     
- Partials             149      176      +27     
Flag Coverage Δ
api-server 76.34% <33.33%> (-4.46%) ⬇️
dashboard 14.90% <7.59%> (-0.16%) ⬇️
react-components 46.43% <23.91%> (-1.65%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@aaronchongth aaronchongth marked this pull request as ready for review November 28, 2023 13:43
Signed-off-by: Aaron Chong <[email protected]>
Copy link
Collaborator

@Angatupyry Angatupyry left a comment

Choose a reason for hiding this comment

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

LGTM!

Signed-off-by: Aaron Chong <[email protected]>
@aaronchongth aaronchongth merged commit 74235a6 into deploy/hammer Nov 29, 2023
@aaronchongth aaronchongth deleted the hammer/permissions branch November 29, 2023 06:20
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.

2 participants