Skip to content

Commit

Permalink
Add by_week to inquiry and view
Browse files Browse the repository at this point in the history
  • Loading branch information
bemky committed Jan 27, 2017
1 parent 5300c20 commit b3434ef
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
8 changes: 8 additions & 0 deletions lib/mls/inquiry.rb
Expand Up @@ -47,5 +47,13 @@ def self.by_day(filter)
}.to_json
connection.instance_variable_get(:@connection).send_request(req).body
end

def self.by_week(filter)
req = Net::HTTP::Get.new("/inquiries/by_week")
req.body = {
where: filter
}.to_json
connection.instance_variable_get(:@connection).send_request(req).body
end

end
8 changes: 8 additions & 0 deletions lib/mls/view.rb
Expand Up @@ -8,4 +8,12 @@ def self.by_day(filter)
}.to_json
connection.instance_variable_get(:@connection).send_request(req).body
end

def self.by_week(filter)
req = Net::HTTP::Get.new("/views/by_week")
req.body = {
where: filter
}.to_json
connection.instance_variable_get(:@connection).send_request(req).body
end
end

0 comments on commit b3434ef

Please sign in to comment.