code
app/controllers/api/v1/crags_controller.rb:147
|
27 ms
|
1.0
|
43 %
|
Api::V1::CragsController#photos
|
sql
app/controllers/api/v1/crags_controller.rb:157
|
16 ms
|
1.0
|
25 %
|
SELECT `photos`.* FROM `photos` WHERE ((illustrable_type = "Crag" AND illustrable_id = 1037) OR
(illustrable_type = "CragSector" AND illustrable_id IN (SELECT id FROM crag_sectors WHERE crag_id = 1037)) OR
(illustrable_type = "CragRoute" AND illustrable_id IN (SELECT id FROM crag_routes WHERE crag_id = 1037))) ORDER BY `photos`.`posted_at` DESC LIMIT 25 OFFSET 0
|
sql
app/controllers/api/v1/crags_controller.rb:218
|
2 ms
|
3.0
|
11 %
|
SELECT `crags`.* FROM `crags` WHERE (`crags`.`deleted_at` IS NULL OR `crags`.`deleted_at` > '2022-06-30 00:59:49.956962') AND `crags`.`id` = 1037 LIMIT 1
|
sql
app/models/photo.rb:43
|
4 ms
|
1.1
|
8 %
|
SELECT `active_storage_attachments`.* FROM `active_storage_attachments` WHERE `active_storage_attachments`.`record_id` = 1289 AND `active_storage_attachments`.`record_type` = 'Photo' AND `active_storage_attachments`.`name` = 'picture' LIMIT 1
|
code
/var/www/oblyk/api/shared/bundle/ruby/2.6.0/gems/railties-6.0.3.6/lib/rails/engine.rb:525
|
4 ms
|
1.0
|
6 %
|
|
sql
app/controllers/api/v1/api_controller.rb:42
|
3 ms
|
1.0
|
5 %
|
SELECT `organizations`.* FROM `organizations` WHERE `organizations`.`api_access_token` IS NULL LIMIT 1
|
sql
app/models/photo.rb:63
|
2 ms
|
0.6
|
2 %
|
SELECT `crags`.* FROM `crags` WHERE (`crags`.`deleted_at` IS NULL OR `crags`.`deleted_at` > '2022-06-30 00:50:58.450160') AND `crags`.`id` = 1053 LIMIT 1
|
sql
app/models/photo.rb:72
|
2 ms
|
0.3
|
<1 %
|
SELECT `crags`.* FROM `crags` WHERE (`crags`.`deleted_at` IS NULL OR `crags`.`deleted_at` > '2022-06-29 23:32:47.119701') AND `crags`.`id` = 779 LIMIT 1
|
sql
app/models/photo.rb:93
|
<1 ms
|
0.6
|
<1 %
|
SELECT `users`.* FROM `users` WHERE `users`.`id` = 3351 LIMIT 1
|