Advertisement
Guest User

Untitled

a guest
Sep 11th, 2016
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.93 KB | None | 0 0
  1. def create_store_information(store, meta)
  2. user = @datasource.user
  3. user.store_informations.create!(
  4. name: store['name'],
  5. description: store['description'],
  6. status: 1,
  7. url: store['URL'].downcase,
  8. store_version: store['version'],
  9. api_version: store['wc_version'],
  10. timezone: meta['timezone'],
  11. currency: meta['currency'],
  12. currency_format: meta['currency_format'],
  13. currency_position: meta['currency_position'],
  14. thousand_separator: meta['thousand_separator'],
  15. decimal_separator: meta['decimal_separator'],
  16. price_num_decimals: meta['price_num_decimals'],
  17. tax_included: cast_to_bool(meta['tax_included']),
  18. weight_unit: meta['weight_unit'],
  19. dimension_unit: meta['dimension_unit'],
  20. ssl_enabled: cast_to_bool(meta['ssl_enabled']),
  21. permalinks_enabled: cast_to_bool(meta['permalinks_enabled']),
  22. generate_password: cast_to_bool(meta['generate_password']),
  23. user: user
  24. )
  25. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement