/**
  * @param Seller $seller
  * @param array $data
  * @return AttributeGroup
  */
 protected function createAttributeGroup(Seller $seller, $data = []) : AttributeGroup
 {
     return $seller->attributeGroups()->save(factory(AttributeGroup::class)->make($data));
 }
Beispiel #2
0
 public function seedPaymentMethods(Seller $seller)
 {
     return $seller->paymentMethods()->saveMany(factory(PaymentMethod::class, 3)->make());
 }
Beispiel #3
0
 protected function seedShipping(Seller $seller)
 {
     return $seller->shippingPlans()->saveMany(factory(ShippingPlan::class, 2)->make())->each(function (ShippingPlan $shippingPlan) {
         $shippingPlan->shippingOptions()->saveMany(factory(ShippingOption::class, 3)->make());
     });
 }