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
b1 = BillingChecker.new(coupon: 0, vat: 1, margin: 1, first_date: DateTime.parse("2013-09-01"), end_time: DateTime.parse("2013-09-30")) | |
b2 = BillingChecker.new(coupon: 0, vat: 1, margin: 1, first_date: DateTime.parse("2013-10-01"), end_time: DateTime.parse("2013-10-31")) | |
b1.perform | |
b2.perform | |
result = b2.totals.map do |u| | |
uo = User.find_by_email u[:email] | |
us = b1.totals.detect{|t|t[:email] == u[:email]} | |
rc = us[:net_total] - User::DEFAULT_CREDIT | |
rc = rc > 0 ? 0 : (rc * -1) |
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
Backend liefert Bitfeld: | |
0x0001 - Grosse Auswahl | |
0x0002 - Guenstige Preise | |
0x0004 - Keine Versandkosten | |
0x0008 - Schnelle Lieferung | |
0x0010 - Hohe Qualitaet | |
0x0020 - Marktfuehrer |
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
systems = {"bedundmore.de" => "Gambio", "closed.de" => "OXID", "schuhxl.de" => "Plentymarkets", "skapetze.com" => "xt:Commerce", "shop.ear-band-it.de" => "Afterbuy", "gadsumo.de" => "Magento", "musterbrand.com" => "Shopware", "kern-sohn.com" => "Cosmoshop", "ubercartdemo.com" => "Ubercart", "dirtyshirty.com" => "PrestaShop", "liftstation.eu" => "JTL Shop", "outdoorbilliger.de" => "XANARIO", "flairie.de" => "Smartstore"} | |
systems.each do |k,v| | |
scraper = ShopsystemScraper.new(:website_url => k) | |
scraper.run | |
if scraper.shopsystem != v | |
puts v | |
puts scraper.shopsystem | |
render nothing: true, status: 422 | |
return |
NewerOlder