mirror of
https://github.com/BookStackApp/BookStack.git
synced 2025-06-16 17:38:18 +08:00

Some checks are pending
analyse-php / build (push) Waiting to run
lint-js / build (push) Waiting to run
lint-php / build (push) Waiting to run
test-js / build (push) Waiting to run
test-migrations / build (8.2) (push) Waiting to run
test-migrations / build (8.3) (push) Waiting to run
test-migrations / build (8.4) (push) Waiting to run
test-php / build (8.2) (push) Waiting to run
test-php / build (8.3) (push) Waiting to run
test-php / build (8.4) (push) Waiting to run
Also added archived property, to be added.
35 lines
717 B
PHP
35 lines
717 B
PHP
<?php
|
|
|
|
namespace Database\Factories\Activity\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Factories\Factory;
|
|
|
|
class CommentFactory extends Factory
|
|
{
|
|
/**
|
|
* The name of the factory's corresponding model.
|
|
*
|
|
* @var string
|
|
*/
|
|
protected $model = \BookStack\Activity\Models\Comment::class;
|
|
|
|
/**
|
|
* Define the model's default state.
|
|
*
|
|
* @return array
|
|
*/
|
|
public function definition()
|
|
{
|
|
$text = $this->faker->paragraph(1);
|
|
$html = '<p>' . $text . '</p>';
|
|
|
|
return [
|
|
'html' => $html,
|
|
'parent_id' => null,
|
|
'local_id' => 1,
|
|
'content_ref' => '',
|
|
'archived' => false,
|
|
];
|
|
}
|
|
}
|