-
Notifications
You must be signed in to change notification settings - Fork 158
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #25 from bitbag-commerce/dev
Update Sylius to 1.0.0 and PHP to 7.1+
- Loading branch information
Showing
30 changed files
with
245 additions
and
212 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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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 |
---|---|---|
|
@@ -8,6 +8,8 @@ | |
* an email on [email protected]. | ||
*/ | ||
|
||
declare(strict_types=1); | ||
|
||
namespace BitBag\CmsPlugin\Controller; | ||
|
||
use Symfony\Bundle\FrameworkBundle\Controller\Controller; | ||
|
@@ -24,7 +26,7 @@ final class PageSlugController extends Controller | |
* | ||
* @return JsonResponse | ||
*/ | ||
public function generateAction(Request $request) | ||
public function generateAction(Request $request): JsonResponse | ||
{ | ||
$name = $request->query->get('name'); | ||
|
||
|
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 was deleted.
Oops, something went wrong.
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 |
---|---|---|
|
@@ -8,6 +8,8 @@ | |
* an email on [email protected]. | ||
*/ | ||
|
||
declare(strict_types=1); | ||
|
||
namespace BitBag\CmsPlugin\Entity; | ||
|
||
use Sylius\Component\Core\Model\ImageInterface; | ||
|
@@ -17,6 +19,7 @@ | |
|
||
/** | ||
* @author Patryk Drapik <[email protected]> | ||
* @author Mikołaj Król <[email protected]> | ||
*/ | ||
class Block implements BlockInterface | ||
{ | ||
|
@@ -48,119 +51,119 @@ public function __construct() | |
/** | ||
* {@inheritdoc} | ||
*/ | ||
public function getCode() | ||
public function getCode(): ?string | ||
{ | ||
return $this->code; | ||
} | ||
|
||
/** | ||
* {@inheritdoc} | ||
*/ | ||
public function setCode($code) | ||
public function setCode(?string $code): void | ||
{ | ||
$this->code = $code; | ||
} | ||
|
||
/** | ||
* {@inheritdoc} | ||
*/ | ||
public function getType() | ||
public function getType(): string | ||
{ | ||
return $this->type; | ||
} | ||
|
||
/** | ||
* {@inheritdoc} | ||
*/ | ||
public function setType($type) | ||
public function setType(string $type): void | ||
{ | ||
$this->type = $type; | ||
} | ||
|
||
/** | ||
* {@inheritdoc} | ||
*/ | ||
public function getId() | ||
public function getId(): ?int | ||
{ | ||
return $this->id; | ||
} | ||
|
||
/** | ||
* @return string | ||
*/ | ||
public function getName() | ||
public function getName(): ?string | ||
{ | ||
return $this->getBlockTranslation()->getName(); | ||
} | ||
|
||
/** | ||
* @param string $name | ||
* @param string|null $name | ||
*/ | ||
public function setName($name) | ||
public function setName(?string $name): void | ||
{ | ||
$this->getBlockTranslation()->setName($name); | ||
} | ||
|
||
/** | ||
* {@inheritdoc} | ||
*/ | ||
public function getContent() | ||
public function getContent(): ?string | ||
{ | ||
return $this->getBlockTranslation()->getContent(); | ||
} | ||
|
||
/** | ||
* {@inheritdoc} | ||
*/ | ||
public function setContent($content) | ||
public function setContent(?string $content): void | ||
{ | ||
$this->getBlockTranslation()->setContent($content); | ||
} | ||
|
||
/** | ||
* {@inheritdoc} | ||
*/ | ||
public function getImage() | ||
public function getImage(): ?ImageInterface | ||
{ | ||
return $this->getBlockTranslation()->getImage(); | ||
} | ||
|
||
/** | ||
* {@inheritdoc} | ||
*/ | ||
public function setImage(ImageInterface $image) | ||
public function setImage(?ImageInterface $image): void | ||
{ | ||
$this->getBlockTranslation()->setImage($image); | ||
} | ||
|
||
/** | ||
* {@inheritdoc} | ||
*/ | ||
public function getLink() | ||
public function getLink(): ?string | ||
{ | ||
return $this->getBlockTranslation()->getLink(); | ||
} | ||
|
||
/** | ||
* {@inheritdoc} | ||
*/ | ||
public function setLink($link) | ||
public function setLink(?string $link): void | ||
{ | ||
$this->getBlockTranslation()->setLink($link); | ||
} | ||
|
||
/** | ||
* @return BlockTranslationInterface|TranslationInterface | ||
*/ | ||
protected function getBlockTranslation() | ||
protected function getBlockTranslation(): ?TranslationInterface | ||
{ | ||
return $this->getTranslation(); | ||
} | ||
|
||
/** | ||
* {@inheritdoc} | ||
*/ | ||
protected function createTranslation() | ||
protected function createTranslation(): BlockTranslation | ||
{ | ||
return new BlockTranslation(); | ||
} | ||
|
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 |
---|---|---|
|
@@ -8,6 +8,8 @@ | |
* an email on [email protected]. | ||
*/ | ||
|
||
declare(strict_types=1); | ||
|
||
namespace BitBag\CmsPlugin\Entity; | ||
|
||
use Sylius\Component\Core\Model\ImageInterface; | ||
|
@@ -16,6 +18,7 @@ | |
|
||
/** | ||
* @author Patryk Drapik <[email protected]> | ||
* @author Mikołaj Król <[email protected]> | ||
*/ | ||
interface BlockInterface extends ResourceInterface, TranslatableInterface | ||
{ | ||
|
@@ -26,60 +29,60 @@ interface BlockInterface extends ResourceInterface, TranslatableInterface | |
/** | ||
* @return string | ||
*/ | ||
public function getType(); | ||
public function getType(): string; | ||
|
||
/** | ||
* @param string $type | ||
*/ | ||
public function setType($type); | ||
public function setType(string $type): void; | ||
|
||
/** | ||
* @return string | ||
* @return string|null | ||
*/ | ||
public function getCode(); | ||
public function getCode(): ?string; | ||
|
||
/** | ||
* @param string $code | ||
* @param string|null $code | ||
*/ | ||
public function setCode($code); | ||
public function setCode(?string $code): void; | ||
|
||
/** | ||
* @return string | ||
* @return string|null | ||
*/ | ||
public function getName(); | ||
public function getName(): ?string; | ||
|
||
/** | ||
* @param string $name | ||
* @param string|null $name | ||
*/ | ||
public function setName($name); | ||
public function setName(?string $name): void; | ||
|
||
/** | ||
* @return string | ||
* @return string|null | ||
*/ | ||
public function getContent(); | ||
public function getContent(): ?string; | ||
|
||
/** | ||
* @param string $content | ||
*/ | ||
public function setContent($content); | ||
public function setContent(?string $content): void; | ||
|
||
/** | ||
* @return ImageInterface | ||
*/ | ||
public function getImage(); | ||
public function getImage(): ?ImageInterface; | ||
|
||
/** | ||
* @param ImageInterface $image | ||
*/ | ||
public function setImage(ImageInterface $image); | ||
public function setImage(?ImageInterface $image): void; | ||
|
||
/** | ||
* @return string | ||
* @return string|null | ||
*/ | ||
public function getLink(); | ||
public function getLink(): ?string; | ||
|
||
/** | ||
* @param string $link | ||
* @param string|null $link | ||
*/ | ||
public function setLink($link); | ||
public function setLink(?string $link): void; | ||
} |
Oops, something went wrong.