My Elasticsearch cheatsheet with example usage via rest api (still a work-in-progress)
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
<?php | |
declare(strict_types=1); | |
namespace App\VO; | |
use InvalidArgumentException; | |
/** | |
* Class Email обьект значение которое инкапсулирует в себе email значение |
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
<?php | |
declare(strict_types=1); | |
namespace App\VO; | |
use InvalidArgumentException; | |
/** | |
* VinCode class. |
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
<template> | |
<v-container fluid> | |
<v-alert v-if="getError || errorGetReport" type="warning"> | |
<v-card-text>{{ getError || errorGetReport }}</v-card-text> | |
</v-alert> | |
<v-row> | |
<v-col cols="12"> | |
<v-card> | |
<v-card-text> | |
<v-row align="center"> |
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
<?php | |
namespace App\EventSubscriber; | |
use Exception; | |
use InvalidArgumentException; | |
use Psr\Log\LoggerInterface; | |
use Symfony\Component\EventDispatcher\EventSubscriberInterface; | |
use Symfony\Component\HttpFoundation\JsonResponse; | |
use Symfony\Component\HttpKernel\Event\ExceptionEvent; |
FWIW: I didn't produce the content presented here (the outline from Edmond Lau's book). I've just copy-pasted it from somewhere over the Internet, but I cannot remember what exactly the original source is. I was also not able to find the author's name, so I cannot give him/her the proper credits.
- By Edmond Lau
- Highly Recommended 👍
- http://www.theeffectiveengineer.com/
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
<?php | |
declare(strict_types=1); | |
namespace App\Domain\Company\Factory; | |
use App\Domain\Company\DTO\CompanyRegistrationDTO; | |
use App\Domain\ValueObjects\Okpo; | |
use App\Entities\Company\Company; | |
use App\Entities\PersonalCabinet\PersonalCabinet; |
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
<?php | |
declare(strict_types=1); | |
namespace App\Domain\Company\Factory; | |
use App\Domain\Company\DTO\CompanyRegistrationDTO; | |
use App\Domain\ValueObjects\Okpo; | |
use App\Entities\Company\Company; | |
use App\Infrastructure\Repository\PersonalCabinet\PersonalCabinetRepository; |
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
<?php | |
namespace App\ValueObjects; | |
use Webmozart\Assert\Assert; | |
/** | |
* Class MobilePhone обьект-значения мобильного телефона | |
*/ | |
class MobilePhone implements FromStringCreatable |
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
#!/usr/bin/env bash | |
STAGED_FILES_CMD=`git show --pretty="" --name-only $CI_COMMIT_SHA --diff-filter=ACMR | grep \\\\.php` | |
if [ -z "$STAGED_FILES_CMD" ]; then | |
echo -e '\e[32m Файлов нет, пропускаю.\e[0m'; | |
exit 0; | |
else | |
php ./vendor/bin/phpcs --error-severity=1 --warning-severity=8 --colors $STAGED_FILES_CMD | |
php ./vendor/bin/phpcs --error-severity=1 --warning-severity=8 --colors --report=summary $STAGED_FILES_CMD |
NewerOlder