mirror of
https://github.com/NamelessMC/Nameless
synced 2026-08-18 06:29:04 -04:00
* Create StyleCI config file * Disable `phpdoc_separation` * Apply fixes from StyleCI (#3476) Co-authored-by: StyleCI Bot <bot@styleci.io> * style: styleci fixes --------- Co-authored-by: StyleCI Bot <bot@styleci.io> Co-authored-by: Sam <samerton@users.noreply.github.com>
24 lines
773 B
PHP
24 lines
773 B
PHP
<?php
|
|
|
|
class ProfileFieldsSeeder extends Seeder
|
|
{
|
|
public array $tables = [
|
|
'nl2_profile_fields',
|
|
];
|
|
|
|
protected function run(DB $db, \Faker\Generator $faker): void
|
|
{
|
|
$this->times(PROFILE_FIELDS_COUNT, function () use ($db, $faker) {
|
|
$db->insert('profile_fields', [
|
|
'name' => $faker->unique()->word,
|
|
'type' => $faker->randomElement([Fields::TEXT, Fields::TEXTAREA, Fields::DATE]),
|
|
'public' => $faker->boolean(75),
|
|
'required' => $faker->boolean,
|
|
'description' => $faker->sentence,
|
|
'length' => null,
|
|
'forum_posts' => $faker->boolean(75),
|
|
'editable' => $faker->boolean,
|
|
]);
|
|
});
|
|
}
|
|
}
|