You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
93 lines
3.5 KiB
PHTML
93 lines
3.5 KiB
PHTML
3 months ago
|
<?php
|
||
|
|
||
|
namespace Database\Seeders;
|
||
|
|
||
|
use App\Models\Contact;
|
||
|
use App\Models\Customer;
|
||
|
use App\Models\Order;
|
||
|
use App\Models\OrderProduct;
|
||
|
use App\Models\PackingSlip;
|
||
|
use App\Models\ProductService;
|
||
|
use App\Models\ProductSize;
|
||
|
use App\Models\ShippingEntry;
|
||
|
use Illuminate\Database\Seeder;
|
||
|
|
||
|
class CustomerSeeder extends Seeder
|
||
|
{
|
||
|
public function run(): void
|
||
|
{
|
||
|
Customer::factory(3)
|
||
|
->has(Contact::factory(5))
|
||
|
->has(PackingSlip::factory(30))
|
||
|
->has(ShippingEntry::factory(2))
|
||
|
->has(Order::factory(10)
|
||
|
->has(OrderProduct::factory(2)
|
||
|
->has(ProductSize::factory(3)))
|
||
|
->has(ProductService::factory(3)))
|
||
|
// ->has(ServiceFile::factory(1))))
|
||
|
->create();
|
||
|
|
||
|
Customer::factory([
|
||
|
'company_name' => 'Genumark',
|
||
|
'internal_name' => 'genumark',
|
||
|
'shipping_address' => '',
|
||
|
'billing_address' => '',
|
||
|
])
|
||
|
->has(Contact::factory([
|
||
|
'first_name' => 'Tammy',
|
||
|
'last_name' => 'Bookbinder',
|
||
|
'email' => 'tbookbinder@genumark.com',
|
||
|
'phone' => '+1 778 229 5668',
|
||
|
]))
|
||
|
->has(Contact::factory([
|
||
|
'first_name' => 'Kathlyn',
|
||
|
'last_name' => 'Wood',
|
||
|
'email' => 'kwood@genumark.com',
|
||
|
'phone' => '+1 604 294 2376',
|
||
|
'notes' => 'Always CC, unless SOF order',
|
||
|
]))
|
||
|
->has(Contact::factory([
|
||
|
'first_name' => 'Jane',
|
||
|
'last_name' => 'Wellman',
|
||
|
'email' => 'jwellman@genumark.com',
|
||
|
'phone' => '+1 604 742 5584',
|
||
|
'notes' => 'Deals with SOF orders',
|
||
|
]))
|
||
|
->has(Contact::factory([
|
||
|
'first_name' => 'Trisha',
|
||
|
'last_name' => 'Miller',
|
||
|
'email' => 'tmiller@genumark.com',
|
||
|
'phone' => '+1 604 802 8486',
|
||
|
]))
|
||
|
->has(Contact::factory([
|
||
|
'first_name' => 'Brenda',
|
||
|
'last_name' => 'Kuepfer',
|
||
|
'email' => 'bkuepfer@genumark.com',
|
||
|
'phone' => '+1 604 305 5002',
|
||
|
]))
|
||
|
->has(PackingSlip::factory(20))
|
||
|
->has(ShippingEntry::factory([
|
||
|
'account_title' => 'Genumark',
|
||
|
'courier' => 'UPS CampusShip',
|
||
|
'contact' => 'https://www.ups.com/lasso/login',
|
||
|
'account_username' => 'GenumarkTopNotch',
|
||
|
'account_password' => 'TopNotch@13579',
|
||
|
'info_needed' => 'Put PO on box',
|
||
|
'notify' => 'Various reps, CC Kathlyn Wood',
|
||
|
'notes' => 'For Save On Foods orders, see Genumark SOF',
|
||
|
]))
|
||
|
->has(ShippingEntry::factory([
|
||
|
'account_title' => 'Genumark Save-On-Foods',
|
||
|
'courier' => 'UPS CampusShip',
|
||
|
'contact' => 'https://www.ups.com/lasso/login',
|
||
|
'account_username' => 'GenumarkTopNotch',
|
||
|
'account_password' => 'TopNotch@13579',
|
||
|
'info_needed' => 'Put PO on box',
|
||
|
'notify' => 'Jane Wellman',
|
||
|
'notes' => 'Don\'t CC Kathlyn for SOF orders',
|
||
|
]))
|
||
|
->has(Order::factory(10))
|
||
|
->create();
|
||
|
}
|
||
|
}
|