Sha256: 6bcf3a6c0f1274095fc1071ea5cff36c93961ce3ffa9aacbb322f83f808ca19c
Contents?: true
Size: 317 Bytes
Versions: 3
Compression:
Stored size: 317 Bytes
Contents
class ShopCategoriesDataset < Dataset::Base def load categories = [:bread, :milk, :salad] categories.each_with_index do |category, i| create_record :shop_category, category, :name => category.to_s, :handle => category.to_s, :position => i + 1 end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
radiant-shop-extension-0.10.0 | spec/datasets/shop_categories.rb |
radiant-shop-extension-0.9.3 | spec/datasets/shop_categories.rb |
radiant-shop-extension-0.9.2 | spec/datasets/shop_categories.rb |