-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit af137b2
Showing
80 changed files
with
12,262 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
root = true | ||
|
||
[*] | ||
charset = utf-8 | ||
end_of_line = lf | ||
indent_size = 4 | ||
indent_style = space | ||
insert_final_newline = true | ||
trim_trailing_whitespace = true | ||
|
||
[*.md] | ||
trim_trailing_whitespace = false | ||
|
||
[*.{yml,yaml}] | ||
indent_size = 2 | ||
|
||
[docker-compose.yml] | ||
indent_size = 4 |
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,68 @@ | ||
APP_NAME=Laravel | ||
APP_ENV=local | ||
APP_KEY= | ||
APP_DEBUG=true | ||
APP_TIMEZONE=UTC | ||
APP_URL=http://localhost | ||
|
||
API_KEY=88005553535 | ||
|
||
APP_LOCALE=en | ||
APP_FALLBACK_LOCALE=en | ||
APP_FAKER_LOCALE=en_US | ||
|
||
APP_MAINTENANCE_DRIVER=file | ||
# APP_MAINTENANCE_STORE=database | ||
|
||
PHP_CLI_SERVER_WORKERS=4 | ||
|
||
BCRYPT_ROUNDS=12 | ||
|
||
LOG_CHANNEL=stack | ||
LOG_STACK=single | ||
LOG_DEPRECATIONS_CHANNEL=null | ||
LOG_LEVEL=debug | ||
|
||
DB_CONNECTION=mysql | ||
DB_HOST=127.0.0.1 | ||
DB_PORT=3306 | ||
DB_DATABASE=example_app | ||
DB_USERNAME=root | ||
DB_PASSWORD= | ||
|
||
SESSION_DRIVER=database | ||
SESSION_LIFETIME=120 | ||
SESSION_ENCRYPT=false | ||
SESSION_PATH=/ | ||
SESSION_DOMAIN=null | ||
|
||
BROADCAST_CONNECTION=log | ||
FILESYSTEM_DISK=local | ||
QUEUE_CONNECTION=database | ||
|
||
CACHE_STORE=database | ||
CACHE_PREFIX= | ||
|
||
MEMCACHED_HOST=127.0.0.1 | ||
|
||
REDIS_CLIENT=phpredis | ||
REDIS_HOST=127.0.0.1 | ||
REDIS_PASSWORD=null | ||
REDIS_PORT=6379 | ||
|
||
MAIL_MAILER=log | ||
MAIL_SCHEME=null | ||
MAIL_HOST=127.0.0.1 | ||
MAIL_PORT=2525 | ||
MAIL_USERNAME=null | ||
MAIL_PASSWORD=null | ||
MAIL_FROM_ADDRESS="[email protected]" | ||
MAIL_FROM_NAME="${APP_NAME}" | ||
|
||
AWS_ACCESS_KEY_ID= | ||
AWS_SECRET_ACCESS_KEY= | ||
AWS_DEFAULT_REGION=us-east-1 | ||
AWS_BUCKET= | ||
AWS_USE_PATH_STYLE_ENDPOINT=false | ||
|
||
VITE_APP_NAME="${APP_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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
* text=auto eol=lf | ||
|
||
*.blade.php diff=html | ||
*.css diff=css | ||
*.html diff=html | ||
*.md diff=markdown | ||
*.php diff=php | ||
|
||
/.github export-ignore | ||
CHANGELOG.md export-ignore | ||
.styleci.yml export-ignore |
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,23 @@ | ||
/.phpunit.cache | ||
/node_modules | ||
/public/build | ||
/public/hot | ||
/public/storage | ||
/storage/*.key | ||
/storage/pail | ||
/vendor | ||
.env | ||
.env.backup | ||
.env.production | ||
.phpactor.json | ||
.phpunit.result.cache | ||
Homestead.json | ||
Homestead.yaml | ||
auth.json | ||
npm-debug.log | ||
yarn-error.log | ||
/.fleet | ||
/.idea | ||
/.nova | ||
/.vscode | ||
/.zed |
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,64 @@ | ||
Organizations Directory API | ||
REST API приложение для справочника Организаций, Зданий и Деятельности. | ||
|
||
Требования: | ||
|
||
Docker(сделал через Laravel Sail) | ||
|
||
Установка: | ||
|
||
Клонируйте репозиторий | ||
|
||
Скопируйте .env.example в .env | ||
|
||
Запустите Docker контейнеры(alias sail='sh $([ -f sail ] && echo sail || echo vendor/bin/sail)' | ||
, после sail up) | ||
|
||
|
||
Установите зависимости: | ||
|
||
sail composer install | ||
|
||
Запустите миграции и сиды: | ||
|
||
sail artisan migrate --seed | ||
|
||
|
||
API Endpoints: | ||
|
||
Организации | ||
|
||
GET /api/organizations/by-building/{building} - список организаций в здании | ||
GET /api/organizations/by-activity/{activity} - список организаций по виду деятельности | ||
GET /api/organizations/by-location - список организаций в заданном радиусе/области | ||
GET /api/organizations/{organization} - информация об организации | ||
GET /api/organizations/search - поиск организаций | ||
|
||
Параметры поиска по локации | ||
jsonCopy{ | ||
"latitude": float, | ||
"longitude": float, | ||
"radius": float (в километрах) | ||
} | ||
|
||
или | ||
|
||
jsonCopy{ | ||
"bounds": { | ||
"sw_lat": float, | ||
"sw_lng": float, | ||
"ne_lat": float, | ||
"ne_lng": float | ||
} | ||
} | ||
Swagger Documentation: | ||
|
||
Swagger UI доступен по адресу: http://localhost/api/documentation | ||
|
||
API-KEY: | ||
|
||
header: X-API-Key | ||
|
||
key: 88005553535 | ||
|
||
PS. для удобства тестинга прописал его так же в экзампл файле) |
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,28 @@ | ||
<?php | ||
|
||
namespace App\Docs; | ||
|
||
use OpenApi\Annotations as OA; | ||
|
||
/** | ||
* @OA\Info( | ||
* version="1.0.0", | ||
* title="API Documentation", | ||
* description="This is the API documentation for the project.", | ||
* @OA\Contact( | ||
* email="[email protected]" | ||
* ), | ||
* @OA\License( | ||
* name="MIT", | ||
* url="https://opensource.org/licenses/MIT" | ||
* ) | ||
* ) | ||
* | ||
* @OA\Server( | ||
* url="http://localhost", | ||
* description="Local development server" | ||
* ) | ||
*/ | ||
class OpenApi | ||
{ | ||
} |
Oops, something went wrong.