lib/ireporter/reporter.rb in ireporter-0.1.1 vs lib/ireporter/reporter.rb in ireporter-0.1.2
- old
+ new
@@ -13,10 +13,12 @@
URL_SALES = 'https://reportingitc-reporter.apple.com/reportservice/sales/v1'
URL_FINANCE = 'https://reportingitc-reporter.apple.com/reportservice/finance/v1'
DATE_TYPE_DAILY = "Daily"
DATE_TYPE_WEEKLY = "Weekly"
+DATE_TYPE_MONTHLY = "Monthly"
+DATE_TYPE_YEARLY = "Yearly"
#constructor
def initialize(username,password)
@@ -49,10 +51,10 @@
response = post_request(parameters,URL_SALES)
if response.headers[:"errormsg"]
raise "vendor number not found"
else response.headers[:"filename"]
- return response.body
+ return response.body.chomp
end
end
def get_sales_report(datetype,reportdate)
\ No newline at end of file