/**
  * Run the database seeds.
  *
  * @return void
  */
 public function run()
 {
     $attributes = [];
     $attributes[] = ['name' => 'رنگ', 'type' => 'color'];
     $attributes[] = ['name' => 'سایز', 'type' => 'text'];
     foreach ($attributes as $attribute) {
         AttributeGroup::create($attribute);
     }
 }
Esempio n. 2
0
 public function step2(Shop $shop, Product $product)
 {
     $attribute_groups = AttributeGroup::get();
     return view('store.shop.product.attributes', compact('shop', 'product', 'attribute_groups'))->with(['title' => 'ویرایش محصول']);
 }