Add editable pages
This commit is contained in:
11
app/repos/page_repo.rb
Normal file
11
app/repos/page_repo.rb
Normal file
@@ -0,0 +1,11 @@
|
||||
module Adamantium
|
||||
module Repos
|
||||
class PageRepo < Adamantium::Repo[:pages]
|
||||
def fetch!(slug:)
|
||||
pages
|
||||
.published
|
||||
.where(slug: slug).one!
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
Reference in New Issue
Block a user