refactor query
This commit is contained in:
+1
-1
@@ -136,7 +136,7 @@ Notes:
|
||||
|
||||
- Serves `GET /relays/:id/activity`
|
||||
- Authorizes admin or relay owner
|
||||
- Get activity from `query.list_activity_for_relay`
|
||||
- Get activity from `query.list_activity_for_resource`
|
||||
- Return `data` is `{activity}`
|
||||
|
||||
## `async fn deactivate_relay(...) -> Response`
|
||||
|
||||
@@ -39,7 +39,7 @@ Members:
|
||||
|
||||
- Returns the tenant matching the given `stripe_customer_id`
|
||||
|
||||
## `pub fn list_activity_for_relay(&self, relay_id: &str) -> Result<Vec<Activity>>`
|
||||
## `pub fn list_activity_for_resource(&self, relay_id: &str) -> Result<Vec<Activity>>`
|
||||
|
||||
- Returns all activity where `resource_type = 'relay'` and `resource_id = relay_id`
|
||||
- Ordered newest-first
|
||||
|
||||
Reference in New Issue
Block a user