Skip to content

Commit

Permalink
Merge branch 'dev'
Browse files Browse the repository at this point in the history
  • Loading branch information
Olav van Schie committed Aug 18, 2015
2 parents c8794b4 + d490aa6 commit 0a28b15
Show file tree
Hide file tree
Showing 10 changed files with 438 additions and 170 deletions.
12 changes: 9 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@ U can insert unlimited data of any type. It is not designed for showcase content
#Features

- Add any number of desired content. 1 - 10.000 products for example (large numbers can take a while)
- Products can be assigned to any category (or multiple)
- Multilayered categories
- Remove any type of fake data, without losing "real" content
- Products can be assigned to multiple categories
- Ability to remove fake data, without losing "real" content

#Currently supported data types

- Categories
- Simple products
- Configurable products & color swatches
- Product reviews and ratings

More to come.
Expand All @@ -35,3 +35,9 @@ U can insert unlimited data of any type. It is not designed for showcase content
- Go to system -> Faker data
- Choose your options and press start
- Run indexer

#Enable configurable (color) swatch

1. Generate some fake configurable products
2. Go to system -> configuration -> configurable swatches
3. Enable configurable swatches and choose "Fake Color" as attribute to show in product detail and product listing page
Original file line number Diff line number Diff line change
Expand Up @@ -21,16 +21,16 @@ protected function _prepareForm()
));

$category->addField('categories_parent', 'select', array(
'label' => $this->__('Parent'),
'label' => $this->__('Parent category'),
'required' => true,
'name' => 'categories_parent',
'values' => Mage::getModel('ovs_magefaker/source_category')->toOptionArray(false),
'value' => Mage::getModel('ovs_magefaker/source_category')->getFirstValue(),
'after_element_html' => 'Will append new categories to this parent',
'after_element_html' => 'Appends new categories to this parent'
));

$category->addField('categories_insert', 'select', array(
'label' => $this->__('Number of categories to insert'),
'label' => $this->__('Amount of categories to insert'),
'name' => 'categories_insert',
'value' => '0',
'values' => array(
Expand All @@ -41,7 +41,6 @@ protected function _prepareForm()
'25' => '25',
'50' => '50',
'100' => '100',
'150' => '150',
'250' => '250',
'500' => '500'
)
Expand All @@ -53,21 +52,24 @@ protected function _prepareForm()
));

$product->addField('products_category', 'multiselect', array(
'label' => $this->__('Select categories'),
'label' => $this->__('Categories'),
'required' => true,
'name' => 'products_category',
'values' => Mage::getModel('ovs_magefaker/source_category')->toOptionArray(false),
'value' => Mage::getModel('ovs_magefaker/source_category')->getFirstValue()
'value' => Mage::getModel('ovs_magefaker/source_category')->getFirstValue(),
'after_element_html' => 'Appends new products to these categories',
));

$product->addField('products_insert', 'select', array(
'label' => $this->__('Number of products to insert'),
'label' => $this->__('Amount of products to insert of each type'),
'name' => 'products_insert',
'value' => '0',
'values' => array(
'0' => '0',
'1' => '1',
'5' => '5',
'10' => '10',
'25' => '25',
'50' => '50',
'100' => '100',
'250' => '250',
Expand All @@ -78,6 +80,20 @@ protected function _prepareForm()
)
));

$product->addField('products_simple', 'checkbox', array(
'label' => $this->__('Insert simple products'),
'name' => 'products_simple',
'value' => 1,
'checked' => true
));

$product->addField('products_configurable', 'checkbox', array(
'label' => $this->__('Insert configurable products'),
'name' => 'products_configurable',
'value' => 1,
'checked' => true
));

$form->setUseContainer(false);
$this->setForm($form);

Expand Down
Loading

0 comments on commit 0a28b15

Please sign in to comment.