-
Notifications
You must be signed in to change notification settings - Fork 80
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add basic configuration for content bundle storage
- Loading branch information
1 parent
37e9da7
commit 2f80a90
Showing
16 changed files
with
394 additions
and
73 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of Sulu. | ||
* | ||
* (c) Sulu GmbH | ||
* | ||
* This source file is subject to the MIT license that is bundled | ||
* with this source code in the file LICENSE. | ||
*/ | ||
|
||
namespace Sulu\Bundle\ArticleBundle\Article\Domain\Model; | ||
|
||
use Ramsey\Uuid\Uuid; | ||
use Sulu\Component\Persistence\Model\AuditableTrait; | ||
|
||
/** | ||
* @experimental | ||
*/ | ||
class Article implements ArticleInterface | ||
{ | ||
use AuditableTrait; | ||
|
||
/** | ||
* @var string | ||
*/ | ||
private $id; | ||
|
||
public function __construct( | ||
?string $id = null | ||
) { | ||
$this->id = $id ?: Uuid::uuid4()->toString(); | ||
} | ||
|
||
public function getId(): string | ||
{ | ||
return $this->id; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of Sulu. | ||
* | ||
* (c) Sulu GmbH | ||
* | ||
* This source file is subject to the MIT license that is bundled | ||
* with this source code in the file LICENSE. | ||
*/ | ||
|
||
namespace Sulu\Bundle\ArticleBundle\Article\Domain\Model; | ||
|
||
use Sulu\Component\Persistence\Model\AuditableInterface; | ||
|
||
/** | ||
* @experimental | ||
*/ | ||
interface ArticleInterface extends AuditableInterface | ||
{ | ||
public const TEMPLATE_TYPE = 'article'; | ||
public const RESOURCE_KEY = 'article'; | ||
|
||
public function getId(): string; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.