Skip to content

Active Record Queries Resource

Meckila edited this page Apr 30, 2021 · 12 revisions

Here is a consolidated guide resource for Active Record Queries

Rails Console

UAT Prod

Demo


Appeals

View appeal tree

Code snippet
RequestStore[:current_user] = User.system_user
uuid  = "" # Add uuid here
appeal = Appeal.find_by(uuid: uuid)
appeal.treee # Prints out appeal tree

Factories

Invoking a factory locally

Code snippet
FactoryBot.create(:NAME_OF_FACTORY)
#example 
FactoryBot.create(:bgs_attorney)

Intake Queries

See Intake Bat Team Training

Clone this wiki locally