In my application a user has_many :jobs and a job belongs_to :user. I'm using the paranoia gem to soft delete users and jobs.
Lets say I have a user, Joe, and he has a job "Push changes". I can see all the jobs on my listing page by using Job.all, but as soon as I delete Joes' account I can't see the job using Job.all anymore.
I have tried to use Job.with_deleted.all and also tried to unscope the association belongs_to :user, -> { with_deleted }.
The SQL statement produced:
SELECT "jobs".* FROM "jobs" INNER JOIN "users" ON "users"."id" = "jobs"."user_id" AND "users"."deleted_at" IS NULL WHERE "jobs"."deleted_at" IS NULL ORDER BY users.name ASC
This seems like you have set
dependent: :destroyon the has many jobs, that's the only way where deleting a user, will make changes on the has_many. of you don't want them to be hided to, then just remove the dependent: :destroy from the user model on the has many jobs