Created
September 1, 2016 11:02
-
-
Save jmcervera/4510bf17af62de6238ece8d29310364a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'repository' | |
module Persistence | |
module Couch | |
module Repositories | |
class Agencies < Repository[:agencies] | |
def find_id(id) | |
agencies.find_id(id) | |
end | |
end | |
end | |
end | |
end | |
module Persistence | |
module Couch | |
module Relations | |
class Agencies < ROM::Relation[:couchdb] | |
def find_id(id) | |
find_by_id(id) | |
end | |
def find_view(name, params) | |
find_by_view(name, params) | |
end | |
end | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment