objectcomputing / check-ins

Other
7 stars 7 forks source link

Implement Pulse Survey report permissions #2429

Closed timyates closed 3 weeks ago

timyates commented 1 month ago

See #2350

Added 1 new permission:

create and update check

  1. If not, are they the user in the teamMemberId field for the report
  2. If not, does the teamMemberId in the supervisory tree of the current user?

And view checks the permission exists, and if not then performs the 2 above checks

timyates commented 1 month ago

I removed the service test, the coverage is almost exactly the same, and the mocking was getting excessive. The controller test does a better job of exercising the paths with real services and actual data (IMO)