-
-
Save jaturken/3a8ed5d6cb789796d669 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
class BaseReport | |
def not_implemented *args | |
fail "Not implemented. Implement in your report class" | |
end | |
alias_method :load_db_data, :not_implemented | |
alias_method :load_parsed_data, :not_implemented | |
alias_method :validate_data, :not_implemented | |
alias_method :reparse_data, :not_implemented | |
alias_method :build_report, :not_implemented | |
alias_method :build_statistic, :not_implemented | |
def iterate_over_shop(shop_folder, category_id = nil, &block) | |
# TODO: iterate over shop sitemap | |
# TODO: possibly parse products from category(as customer or competitor) | |
end | |
def parse_product(shop_folder, id, &block) | |
# TODO: find product in shop(by id, sku, url etc) and apply block to it | |
end | |
def send_email(to, subject, body, attach) | |
# TODO: implement sending email | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment