- 修正所有模組 Controller 的 Model 引用路徑 (App\Modules\...) - 更新 ProductionOrder 與 ProductionOrderItem 模型結構以符合新版邏輯 - 修復 resources/js/utils/format.ts 在處理空值時導致 toLocaleString 崩潰的問題 - 清除全域路徑與 Controller 遷移殘留檔案
34 lines
660 B
PHP
34 lines
660 B
PHP
<?php
|
|
|
|
namespace Database\Seeders;
|
|
|
|
use App\Modules\Core\Models\User;
|
|
use Illuminate\Database\Console\Seeds\WithoutModelEvents;
|
|
use Illuminate\Database\Seeder;
|
|
|
|
class DatabaseSeeder extends Seeder
|
|
{
|
|
use WithoutModelEvents;
|
|
|
|
/**
|
|
* Seed the application's database.
|
|
*/
|
|
public function run(): void
|
|
{
|
|
// User::factory(10)->create();
|
|
|
|
User::firstOrCreate(
|
|
['username' => 'admin'],
|
|
[
|
|
'name' => '系統管理員',
|
|
'email' => 'admin@example.com',
|
|
'password' => 'password',
|
|
]
|
|
);
|
|
|
|
$this->call(PermissionSeeder::class);
|
|
|
|
|
|
}
|
|
}
|