Init
This commit is contained in:
19
.env
Normal file
19
.env
Normal file
@@ -0,0 +1,19 @@
|
||||
APP_NAME=Lumen
|
||||
APP_ENV=local
|
||||
APP_KEY=
|
||||
APP_DEBUG=true
|
||||
APP_URL=http://localhost
|
||||
APP_TIMEZONE=UTC
|
||||
|
||||
LOG_CHANNEL=stack
|
||||
LOG_SLACK_WEBHOOK_URL=
|
||||
|
||||
DB_CONNECTION=mysql
|
||||
DB_HOST=127.0.0.1
|
||||
DB_PORT=3306
|
||||
DB_DATABASE=admin_module
|
||||
DB_USERNAME=root
|
||||
DB_PASSWORD=
|
||||
|
||||
CACHE_DRIVER=file
|
||||
QUEUE_CONNECTION=sync
|
||||
19
.env.example
Normal file
19
.env.example
Normal file
@@ -0,0 +1,19 @@
|
||||
APP_NAME=Lumen
|
||||
APP_ENV=local
|
||||
APP_KEY=
|
||||
APP_DEBUG=true
|
||||
APP_URL=http://localhost
|
||||
APP_TIMEZONE=UTC
|
||||
|
||||
LOG_CHANNEL=stack
|
||||
LOG_SLACK_WEBHOOK_URL=
|
||||
|
||||
DB_CONNECTION=mysql
|
||||
DB_HOST=127.0.0.1
|
||||
DB_PORT=3306
|
||||
DB_DATABASE=homestead
|
||||
DB_USERNAME=homestead
|
||||
DB_PASSWORD=secret
|
||||
|
||||
CACHE_DRIVER=file
|
||||
QUEUE_CONNECTION=sync
|
||||
2
.gitignore
vendored
Normal file
2
.gitignore
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
./idea
|
||||
temp/
|
||||
123
.idea/admin-php-module.iml
generated
Normal file
123
.idea/admin-php-module.iml
generated
Normal file
@@ -0,0 +1,123 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<module type="WEB_MODULE" version="4">
|
||||
<component name="NewModuleRootManager">
|
||||
<content url="file://$MODULE_DIR$">
|
||||
<sourceFolder url="file://$MODULE_DIR$/spec" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/core/database/seeders" isTestSource="false" packagePrefix="Database\Seeders\" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/commands" isTestSource="false" packagePrefix="App\Commands\" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/core/app" isTestSource="false" packagePrefix="App\" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/tests" isTestSource="true" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/core/database/factories" isTestSource="false" packagePrefix="Database\Factories\" />
|
||||
<sourceFolder url="file://$MODULE_DIR$/models" isTestSource="false" packagePrefix="App\Models\" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/brick/math" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/composer" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/doctrine/inflector" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/doctrine/instantiator" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/doctrine/lexer" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/dragonmantank/cron-expression" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/egulias/email-validator" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/fakerphp/faker" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/graham-campbell/result-type" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/hamcrest/hamcrest-php" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/auth" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/broadcasting" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/bus" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/cache" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/collections" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/config" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/console" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/container" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/contracts" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/database" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/encryption" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/events" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/filesystem" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/hashing" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/http" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/log" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/macroable" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/pagination" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/pipeline" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/queue" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/session" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/support" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/testing" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/translation" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/validation" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/illuminate/view" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/laravel/lumen-framework" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/mockery/mockery" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/monolog/monolog" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/myclabs/deep-copy" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/nesbot/carbon" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/nikic/fast-route" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/nikic/php-parser" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/opis/closure" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/phar-io/manifest" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/phar-io/version" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/phpdocumentor/reflection-common" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/phpdocumentor/reflection-docblock" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/phpdocumentor/type-resolver" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/phpoption/phpoption" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/phpspec/prophecy" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/phpunit/php-code-coverage" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/phpunit/php-file-iterator" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/phpunit/php-invoker" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/phpunit/php-text-template" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/phpunit/php-timer" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/phpunit/phpunit" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/psr/container" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/psr/event-dispatcher" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/psr/log" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/psr/simple-cache" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/ramsey/collection" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/ramsey/uuid" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/sebastian/cli-parser" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/sebastian/code-unit" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/sebastian/code-unit-reverse-lookup" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/sebastian/comparator" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/sebastian/complexity" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/sebastian/diff" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/sebastian/environment" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/sebastian/exporter" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/sebastian/global-state" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/sebastian/lines-of-code" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/sebastian/object-enumerator" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/sebastian/object-reflector" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/sebastian/recursion-context" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/sebastian/resource-operations" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/sebastian/type" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/sebastian/version" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/console" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/deprecation-contracts" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/error-handler" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/event-dispatcher" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/event-dispatcher-contracts" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/finder" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/http-client-contracts" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/http-foundation" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/http-kernel" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/mime" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/polyfill-ctype" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/polyfill-intl-grapheme" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/polyfill-intl-idn" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/polyfill-intl-normalizer" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/polyfill-mbstring" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/polyfill-php72" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/polyfill-php73" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/polyfill-php80" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/process" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/service-contracts" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/string" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/translation" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/translation-contracts" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/symfony/var-dumper" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/theseer/tokenizer" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/vlucas/phpdotenv" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/voku/portable-ascii" />
|
||||
<excludeFolder url="file://$MODULE_DIR$/core/vendor/webmozart/assert" />
|
||||
</content>
|
||||
<orderEntry type="inheritedJdk" />
|
||||
<orderEntry type="sourceFolder" forTests="false" />
|
||||
</component>
|
||||
</module>
|
||||
5
.idea/inspectionProfiles/profiles_settings.xml
generated
Normal file
5
.idea/inspectionProfiles/profiles_settings.xml
generated
Normal file
@@ -0,0 +1,5 @@
|
||||
<component name="InspectionProjectProfileManager">
|
||||
<settings>
|
||||
<option name="PROJECT_PROFILE" />
|
||||
</settings>
|
||||
</component>
|
||||
6
.idea/misc.xml
generated
Normal file
6
.idea/misc.xml
generated
Normal file
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="JavaScriptSettings">
|
||||
<option name="languageLevel" value="ES6" />
|
||||
</component>
|
||||
</project>
|
||||
8
.idea/modules.xml
generated
Normal file
8
.idea/modules.xml
generated
Normal file
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ProjectModuleManager">
|
||||
<modules>
|
||||
<module fileurl="file://$PROJECT_DIR$/.idea/admin-php-module.iml" filepath="$PROJECT_DIR$/.idea/admin-php-module.iml" />
|
||||
</modules>
|
||||
</component>
|
||||
</project>
|
||||
119
.idea/php.xml
generated
Normal file
119
.idea/php.xml
generated
Normal file
@@ -0,0 +1,119 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="PhpIncludePathManager">
|
||||
<include_path>
|
||||
<path value="$PROJECT_DIR$/core/vendor/composer" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/psr/container" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/psr/event-dispatcher" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/psr/log" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/psr/simple-cache" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/opis/closure" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/voku/portable-ascii" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/brick/math" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/nikic/fast-route" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/nikic/php-parser" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/nesbot/carbon" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/ramsey/collection" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/ramsey/uuid" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/vlucas/phpdotenv" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/egulias/email-validator" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/laravel/lumen-framework" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/mockery/mockery" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/monolog/monolog" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/myclabs/deep-copy" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phar-io/manifest" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phar-io/version" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpspec/prophecy" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpunit/php-code-coverage" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpunit/php-file-iterator" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpunit/php-invoker" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpunit/php-text-template" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpunit/php-timer" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpunit/phpunit" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/console" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/deprecation-contracts" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/error-handler" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/event-dispatcher" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/event-dispatcher-contracts" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/contracts" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/finder" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/http-client-contracts" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/http-foundation" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/http-kernel" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/mime" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/polyfill-ctype" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/polyfill-intl-grapheme" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/polyfill-intl-idn" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/polyfill-intl-normalizer" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/polyfill-mbstring" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/polyfill-php72" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/polyfill-php73" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/polyfill-php80" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/process" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/service-contracts" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/string" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/translation" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/translation-contracts" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/var-dumper" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/theseer/tokenizer" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/doctrine/inflector" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/doctrine/instantiator" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/doctrine/lexer" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/fakerphp/faker" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/hamcrest/hamcrest-php" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpoption/phpoption" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/cli-parser" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/code-unit" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/code-unit-reverse-lookup" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/comparator" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/complexity" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/diff" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/environment" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/exporter" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/global-state" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/lines-of-code" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/object-enumerator" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/object-reflector" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/recursion-context" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/resource-operations" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/type" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/version" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/webmozart/assert" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/auth" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/broadcasting" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/bus" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/cache" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/collections" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/config" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/console" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/container" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/database" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/encryption" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/events" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/filesystem" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/hashing" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/http" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/log" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/macroable" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/pagination" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/pipeline" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/queue" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/session" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/support" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/testing" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/translation" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/validation" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/view" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/dragonmantank/cron-expression" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpdocumentor/reflection-common" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpdocumentor/reflection-docblock" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpdocumentor/type-resolver" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/graham-campbell/result-type" />
|
||||
</include_path>
|
||||
</component>
|
||||
<component name="PhpUnit">
|
||||
<phpunit_settings>
|
||||
<PhpUnitSettings custom_loader_path="$PROJECT_DIR$/core/vendor/autoload.php" />
|
||||
</phpunit_settings>
|
||||
</component>
|
||||
</project>
|
||||
180
.idea/workspace.xml
generated
Normal file
180
.idea/workspace.xml
generated
Normal file
@@ -0,0 +1,180 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project version="4">
|
||||
<component name="ChangeListManager">
|
||||
<list default="true" id="acbd8209-e4f8-4693-a23c-d41bf1e7512d" name="Default Changelist" comment="" />
|
||||
<option name="SHOW_DIALOG" value="false" />
|
||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||
<option name="HIGHLIGHT_NON_ACTIVE_CHANGELIST" value="false" />
|
||||
<option name="LAST_RESOLUTION" value="IGNORE" />
|
||||
</component>
|
||||
<component name="ComposerSettings" synchronizationState="SYNCHRONIZE">
|
||||
<pharConfigPath>$PROJECT_DIR$/core/composer.json</pharConfigPath>
|
||||
<execution>
|
||||
<executable />
|
||||
</execution>
|
||||
</component>
|
||||
<component name="FavoritesManager">
|
||||
<favorites_list name="admin-php-module" />
|
||||
</component>
|
||||
<component name="PhpWorkspaceProjectConfiguration">
|
||||
<include_path>
|
||||
<path value="$PROJECT_DIR$/core/vendor/composer" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/psr/container" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/psr/event-dispatcher" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/psr/log" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/psr/simple-cache" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/opis/closure" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/voku/portable-ascii" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/brick/math" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/nikic/fast-route" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/nikic/php-parser" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/nesbot/carbon" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/ramsey/collection" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/ramsey/uuid" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/vlucas/phpdotenv" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/egulias/email-validator" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/laravel/lumen-framework" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/mockery/mockery" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/monolog/monolog" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/myclabs/deep-copy" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phar-io/manifest" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phar-io/version" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpspec/prophecy" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpunit/php-code-coverage" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpunit/php-file-iterator" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpunit/php-invoker" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpunit/php-text-template" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpunit/php-timer" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpunit/phpunit" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/console" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/deprecation-contracts" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/error-handler" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/event-dispatcher" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/event-dispatcher-contracts" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/contracts" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/finder" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/http-client-contracts" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/http-foundation" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/http-kernel" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/mime" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/polyfill-ctype" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/polyfill-intl-grapheme" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/polyfill-intl-idn" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/polyfill-intl-normalizer" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/polyfill-mbstring" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/polyfill-php72" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/polyfill-php73" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/polyfill-php80" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/process" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/service-contracts" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/string" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/translation" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/translation-contracts" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/symfony/var-dumper" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/theseer/tokenizer" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/doctrine/inflector" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/doctrine/instantiator" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/doctrine/lexer" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/fakerphp/faker" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/hamcrest/hamcrest-php" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpoption/phpoption" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/cli-parser" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/code-unit" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/code-unit-reverse-lookup" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/comparator" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/complexity" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/diff" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/environment" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/exporter" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/global-state" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/lines-of-code" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/object-enumerator" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/object-reflector" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/recursion-context" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/resource-operations" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/type" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/sebastian/version" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/webmozart/assert" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/auth" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/broadcasting" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/bus" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/cache" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/collections" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/config" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/console" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/container" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/database" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/encryption" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/events" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/filesystem" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/hashing" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/http" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/log" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/macroable" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/pagination" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/pipeline" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/queue" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/session" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/support" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/testing" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/translation" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/validation" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/illuminate/view" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/dragonmantank/cron-expression" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpdocumentor/reflection-common" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpdocumentor/reflection-docblock" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/phpdocumentor/type-resolver" />
|
||||
<path value="$PROJECT_DIR$/core/vendor/graham-campbell/result-type" />
|
||||
</include_path>
|
||||
</component>
|
||||
<component name="ProjectId" id="1lgXWp5IbXs2WPw34fdYWky9n6a" />
|
||||
<component name="ProjectViewState">
|
||||
<option name="hideEmptyMiddlePackages" value="true" />
|
||||
<option name="showExcludedFiles" value="true" />
|
||||
<option name="showLibraryContents" value="true" />
|
||||
</component>
|
||||
<component name="PropertiesComponent">
|
||||
<property name="RunOnceActivity.ShowReadmeOnStart" value="true" />
|
||||
<property name="WebServerToolWindowFactoryState" value="false" />
|
||||
<property name="nodejs_interpreter_path.stuck_in_default_project" value="undefined stuck path" />
|
||||
<property name="nodejs_npm_path_reset_for_default_project" value="true" />
|
||||
<property name="settings.editor.selected.configurable" value="preferences.lookFeel" />
|
||||
</component>
|
||||
<component name="RecentsManager">
|
||||
<key name="MoveFile.RECENT_KEYS">
|
||||
<recent name="E:\Projects\admin-php-module" />
|
||||
</key>
|
||||
</component>
|
||||
<component name="SvnConfiguration">
|
||||
<configuration />
|
||||
</component>
|
||||
<component name="TaskManager">
|
||||
<task active="true" id="Default" summary="Default task">
|
||||
<changelist id="acbd8209-e4f8-4693-a23c-d41bf1e7512d" name="Default Changelist" comment="" />
|
||||
<created>1608019741102</created>
|
||||
<option name="number" value="Default" />
|
||||
<option name="presentableId" value="Default" />
|
||||
<updated>1608019741102</updated>
|
||||
<workItem from="1608019742478" duration="10854000" />
|
||||
<workItem from="1608547130152" duration="9012000" />
|
||||
</task>
|
||||
<servers />
|
||||
</component>
|
||||
<component name="TypeScriptGeneratedFilesManager">
|
||||
<option name="version" value="1" />
|
||||
</component>
|
||||
<component name="WindowStateProjectService">
|
||||
<state x="690" y="275" key="#com.jetbrains.php.actions.copyPaste.importReferences.PhpImportReferencesDialog" timestamp="1608548729947">
|
||||
<screen x="0" y="0" width="1920" height="1040" />
|
||||
</state>
|
||||
<state x="690" y="275" key="#com.jetbrains.php.actions.copyPaste.importReferences.PhpImportReferencesDialog/0.0.1920.1040/-1600.182.1600.860/1920.0.1920.1040@0.0.1920.1040" timestamp="1608548729947" />
|
||||
<state x="645" y="252" width="630" height="536" key="find.popup" timestamp="1608553677697">
|
||||
<screen x="0" y="0" width="1920" height="1040" />
|
||||
</state>
|
||||
<state x="645" y="252" width="630" height="536" key="find.popup/0.0.1920.1040/-1600.182.1600.860/1920.0.1920.1040@0.0.1920.1040" timestamp="1608553677697" />
|
||||
<state x="623" y="225" width="672" height="678" key="search.everywhere.popup" timestamp="1608539372756">
|
||||
<screen x="0" y="0" width="1920" height="1040" />
|
||||
</state>
|
||||
<state x="623" y="225" width="672" height="678" key="search.everywhere.popup/0.0.1920.1040/-1600.182.1600.860/1920.0.1920.1040@0.0.1920.1040" timestamp="1608539372756" />
|
||||
</component>
|
||||
</project>
|
||||
35
artisan
Normal file
35
artisan
Normal file
@@ -0,0 +1,35 @@
|
||||
#!/usr/bin/env php
|
||||
<?php
|
||||
|
||||
use Symfony\Component\Console\Input\ArgvInput;
|
||||
use Symfony\Component\Console\Output\ConsoleOutput;
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Create The Application
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| First we need to get an application instance. This creates an instance
|
||||
| of the application / container and bootstraps the application so it
|
||||
| is ready to receive HTTP / Console requests from the environment.
|
||||
|
|
||||
*/
|
||||
|
||||
$app = require __DIR__.'/core/bootstrap/app.php';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Run The Artisan Application
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| When we run the console application, the current CLI command will be
|
||||
| executed in this console and the response sent back to a terminal
|
||||
| or another output device for the developers. Here goes nothing!
|
||||
|
|
||||
*/
|
||||
|
||||
$kernel = $app->make(
|
||||
'Illuminate\Contracts\Console\Kernel'
|
||||
);
|
||||
|
||||
exit($kernel->handle(new ArgvInput, new ConsoleOutput));
|
||||
22
commands/HelloWorld.php
Normal file
22
commands/HelloWorld.php
Normal file
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
|
||||
namespace App\Commands;
|
||||
|
||||
use App\Console\Commands\HRCCommand;
|
||||
use App\Console\Commands\HRCCommandInterface;
|
||||
use App\Models\User;
|
||||
|
||||
class HelloWorld extends HRCCommand implements HRCCommandInterface
|
||||
{
|
||||
protected $signature = 'gethello';
|
||||
|
||||
public function command($input)
|
||||
{
|
||||
$users = User::all();
|
||||
|
||||
return [
|
||||
'status' => 'success',
|
||||
'users' => $users
|
||||
];
|
||||
}
|
||||
}
|
||||
15
core/.editorconfig
Normal file
15
core/.editorconfig
Normal file
@@ -0,0 +1,15 @@
|
||||
root = true
|
||||
|
||||
[*]
|
||||
charset = utf-8
|
||||
end_of_line = lf
|
||||
insert_final_newline = true
|
||||
indent_style = space
|
||||
indent_size = 4
|
||||
trim_trailing_whitespace = true
|
||||
|
||||
[*.md]
|
||||
trim_trailing_whitespace = false
|
||||
|
||||
[*.{yml,yaml}]
|
||||
indent_size = 2
|
||||
6
core/.gitignore
vendored
Normal file
6
core/.gitignore
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
/vendor
|
||||
/.idea
|
||||
Homestead.json
|
||||
Homestead.yaml
|
||||
../.env
|
||||
.phpunit.result.cache
|
||||
6
core/.styleci.yml
Normal file
6
core/.styleci.yml
Normal file
@@ -0,0 +1,6 @@
|
||||
php:
|
||||
preset: laravel
|
||||
disabled:
|
||||
- unused_use
|
||||
js: true
|
||||
css: true
|
||||
24
core/README.md
Normal file
24
core/README.md
Normal file
@@ -0,0 +1,24 @@
|
||||
# Lumen PHP Framework
|
||||
|
||||
[](https://travis-ci.org/laravel/lumen-framework)
|
||||
[](https://packagist.org/packages/laravel/lumen-framework)
|
||||
[](https://packagist.org/packages/laravel/lumen-framework)
|
||||
[](https://packagist.org/packages/laravel/lumen-framework)
|
||||
|
||||
Laravel Lumen is a stunningly fast PHP micro-framework for building web applications with expressive, elegant syntax. We believe development must be an enjoyable, creative experience to be truly fulfilling. Lumen attempts to take the pain out of development by easing common tasks used in the majority of web projects, such as routing, database abstraction, queueing, and caching.
|
||||
|
||||
## Official Documentation
|
||||
|
||||
Documentation for the framework can be found on the [Lumen website](https://lumen.laravel.com/docs).
|
||||
|
||||
## Contributing
|
||||
|
||||
Thank you for considering contributing to Lumen! The contribution guide can be found in the [Laravel documentation](https://laravel.com/docs/contributions).
|
||||
|
||||
## Security Vulnerabilities
|
||||
|
||||
If you discover a security vulnerability within Lumen, please send an e-mail to Taylor Otwell at taylor@laravel.com. All security vulnerabilities will be promptly addressed.
|
||||
|
||||
## License
|
||||
|
||||
The Lumen framework is open-sourced software licensed under the [MIT license](https://opensource.org/licenses/MIT).
|
||||
0
core/app/Console/Commands/.gitkeep
Normal file
0
core/app/Console/Commands/.gitkeep
Normal file
71
core/app/Console/Commands/HRCCommand.php
Normal file
71
core/app/Console/Commands/HRCCommand.php
Normal file
@@ -0,0 +1,71 @@
|
||||
<?php
|
||||
|
||||
namespace App\Console\Commands;
|
||||
|
||||
use Illuminate\Console\Command;
|
||||
use Illuminate\Support\Facades\Config;
|
||||
use Illuminate\Support\Facades\DB;
|
||||
|
||||
/**
|
||||
* Class HRCCommand
|
||||
*
|
||||
* @property object data
|
||||
*/
|
||||
class HRCCommand extends Command
|
||||
{
|
||||
public function __construct()
|
||||
{
|
||||
$this->signature = $this->signature . ' {source} {result} {--unn=}';
|
||||
parent::__construct();
|
||||
|
||||
print_r($this->getApplication());
|
||||
}
|
||||
|
||||
public function __get($get)
|
||||
{
|
||||
if ($get == 'data') {
|
||||
return $this->prepareRaw();
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
private function prepareRaw()
|
||||
{
|
||||
$source_file = base_path() . '/../temp/' . $this->argument('source');
|
||||
return json_decode(file_get_contents($source_file));
|
||||
}
|
||||
|
||||
public function save($result)
|
||||
{
|
||||
$result_file = base_path() . '/../temp/' . $this->argument('result');
|
||||
file_put_contents($result_file, json_encode($result));
|
||||
}
|
||||
|
||||
public function initDB()
|
||||
{
|
||||
$code = $this->option('unn');
|
||||
|
||||
DB::disconnect('mysql');
|
||||
Config::set('database.connections.mysql.database', $code);
|
||||
DB::reconnect();
|
||||
}
|
||||
|
||||
public function handle()
|
||||
{
|
||||
$data = $this->prepareRaw();
|
||||
$this->initDB();
|
||||
|
||||
try {
|
||||
$result = $this->command($data);
|
||||
}
|
||||
catch (\Exception $e) {
|
||||
$result = [
|
||||
'status' => 'error',
|
||||
'message' => $e->getMessage()
|
||||
];
|
||||
}
|
||||
|
||||
$this->save($result);
|
||||
}
|
||||
}
|
||||
7
core/app/Console/Commands/HRCCommandInterface.php
Normal file
7
core/app/Console/Commands/HRCCommandInterface.php
Normal file
@@ -0,0 +1,7 @@
|
||||
<?php
|
||||
|
||||
namespace App\Console\Commands;
|
||||
|
||||
interface HRCCommandInterface {
|
||||
public function command($data);
|
||||
}
|
||||
30
core/app/Console/Kernel.php
Normal file
30
core/app/Console/Kernel.php
Normal file
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
namespace App\Console;
|
||||
|
||||
use App\Commands\HelloWorld;
|
||||
use Illuminate\Console\Scheduling\Schedule;
|
||||
use Laravel\Lumen\Console\Kernel as ConsoleKernel;
|
||||
|
||||
class Kernel extends ConsoleKernel
|
||||
{
|
||||
/**
|
||||
* The Artisan commands provided by your application.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $commands = [
|
||||
HelloWorld::class
|
||||
];
|
||||
|
||||
/**
|
||||
* Define the application's command schedule.
|
||||
*
|
||||
* @param \Illuminate\Console\Scheduling\Schedule $schedule
|
||||
* @return void
|
||||
*/
|
||||
protected function schedule(Schedule $schedule)
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
10
core/app/Events/Event.php
Normal file
10
core/app/Events/Event.php
Normal file
@@ -0,0 +1,10 @@
|
||||
<?php
|
||||
|
||||
namespace App\Events;
|
||||
|
||||
use Illuminate\Queue\SerializesModels;
|
||||
|
||||
abstract class Event
|
||||
{
|
||||
use SerializesModels;
|
||||
}
|
||||
16
core/app/Events/ExampleEvent.php
Normal file
16
core/app/Events/ExampleEvent.php
Normal file
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
|
||||
namespace App\Events;
|
||||
|
||||
class ExampleEvent extends Event
|
||||
{
|
||||
/**
|
||||
* Create a new event instance.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
54
core/app/Exceptions/Handler.php
Normal file
54
core/app/Exceptions/Handler.php
Normal file
@@ -0,0 +1,54 @@
|
||||
<?php
|
||||
|
||||
namespace App\Exceptions;
|
||||
|
||||
use Illuminate\Auth\Access\AuthorizationException;
|
||||
use Illuminate\Database\Eloquent\ModelNotFoundException;
|
||||
use Illuminate\Validation\ValidationException;
|
||||
use Laravel\Lumen\Exceptions\Handler as ExceptionHandler;
|
||||
use Symfony\Component\HttpKernel\Exception\HttpException;
|
||||
use Throwable;
|
||||
|
||||
class Handler extends ExceptionHandler
|
||||
{
|
||||
/**
|
||||
* A list of the exception types that should not be reported.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $dontReport = [
|
||||
AuthorizationException::class,
|
||||
HttpException::class,
|
||||
ModelNotFoundException::class,
|
||||
ValidationException::class,
|
||||
];
|
||||
|
||||
/**
|
||||
* Report or log an exception.
|
||||
*
|
||||
* This is a great spot to send exceptions to Sentry, Bugsnag, etc.
|
||||
*
|
||||
* @param \Throwable $exception
|
||||
* @return void
|
||||
*
|
||||
* @throws \Exception
|
||||
*/
|
||||
public function report(Throwable $exception)
|
||||
{
|
||||
parent::report($exception);
|
||||
}
|
||||
|
||||
/**
|
||||
* Render an exception into an HTTP response.
|
||||
*
|
||||
* @param \Illuminate\Http\Request $request
|
||||
* @param \Throwable $exception
|
||||
* @return \Illuminate\Http\Response|\Illuminate\Http\JsonResponse
|
||||
*
|
||||
* @throws \Throwable
|
||||
*/
|
||||
public function render($request, Throwable $exception)
|
||||
{
|
||||
return parent::render($request, $exception);
|
||||
}
|
||||
}
|
||||
10
core/app/Http/Controllers/Controller.php
Normal file
10
core/app/Http/Controllers/Controller.php
Normal file
@@ -0,0 +1,10 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Controllers;
|
||||
|
||||
use Laravel\Lumen\Routing\Controller as BaseController;
|
||||
|
||||
class Controller extends BaseController
|
||||
{
|
||||
//
|
||||
}
|
||||
18
core/app/Http/Controllers/ExampleController.php
Normal file
18
core/app/Http/Controllers/ExampleController.php
Normal file
@@ -0,0 +1,18 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Controllers;
|
||||
|
||||
class ExampleController extends Controller
|
||||
{
|
||||
/**
|
||||
* Create a new controller instance.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
//
|
||||
}
|
||||
|
||||
//
|
||||
}
|
||||
44
core/app/Http/Middleware/Authenticate.php
Normal file
44
core/app/Http/Middleware/Authenticate.php
Normal file
@@ -0,0 +1,44 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Middleware;
|
||||
|
||||
use Closure;
|
||||
use Illuminate\Contracts\Auth\Factory as Auth;
|
||||
|
||||
class Authenticate
|
||||
{
|
||||
/**
|
||||
* The authentication guard factory instance.
|
||||
*
|
||||
* @var \Illuminate\Contracts\Auth\Factory
|
||||
*/
|
||||
protected $auth;
|
||||
|
||||
/**
|
||||
* Create a new middleware instance.
|
||||
*
|
||||
* @param \Illuminate\Contracts\Auth\Factory $auth
|
||||
* @return void
|
||||
*/
|
||||
public function __construct(Auth $auth)
|
||||
{
|
||||
$this->auth = $auth;
|
||||
}
|
||||
|
||||
/**
|
||||
* Handle an incoming request.
|
||||
*
|
||||
* @param \Illuminate\Http\Request $request
|
||||
* @param \Closure $next
|
||||
* @param string|null $guard
|
||||
* @return mixed
|
||||
*/
|
||||
public function handle($request, Closure $next, $guard = null)
|
||||
{
|
||||
if ($this->auth->guard($guard)->guest()) {
|
||||
return response('Unauthorized.', 401);
|
||||
}
|
||||
|
||||
return $next($request);
|
||||
}
|
||||
}
|
||||
20
core/app/Http/Middleware/ExampleMiddleware.php
Normal file
20
core/app/Http/Middleware/ExampleMiddleware.php
Normal file
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Middleware;
|
||||
|
||||
use Closure;
|
||||
|
||||
class ExampleMiddleware
|
||||
{
|
||||
/**
|
||||
* Handle an incoming request.
|
||||
*
|
||||
* @param \Illuminate\Http\Request $request
|
||||
* @param \Closure $next
|
||||
* @return mixed
|
||||
*/
|
||||
public function handle($request, Closure $next)
|
||||
{
|
||||
return $next($request);
|
||||
}
|
||||
}
|
||||
26
core/app/Jobs/ExampleJob.php
Normal file
26
core/app/Jobs/ExampleJob.php
Normal file
@@ -0,0 +1,26 @@
|
||||
<?php
|
||||
|
||||
namespace App\Jobs;
|
||||
|
||||
class ExampleJob extends Job
|
||||
{
|
||||
/**
|
||||
* Create a new job instance.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
//
|
||||
}
|
||||
|
||||
/**
|
||||
* Execute the job.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function handle()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
24
core/app/Jobs/Job.php
Normal file
24
core/app/Jobs/Job.php
Normal file
@@ -0,0 +1,24 @@
|
||||
<?php
|
||||
|
||||
namespace App\Jobs;
|
||||
|
||||
use Illuminate\Bus\Queueable;
|
||||
use Illuminate\Contracts\Queue\ShouldQueue;
|
||||
use Illuminate\Queue\InteractsWithQueue;
|
||||
use Illuminate\Queue\SerializesModels;
|
||||
|
||||
abstract class Job implements ShouldQueue
|
||||
{
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Queueable Jobs
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| This job base class provides a central location to place any logic that
|
||||
| is shared across all of your jobs. The trait included with the class
|
||||
| provides access to the "queueOn" and "delay" queue helper methods.
|
||||
|
|
||||
*/
|
||||
|
||||
use InteractsWithQueue, Queueable, SerializesModels;
|
||||
}
|
||||
31
core/app/Listeners/ExampleListener.php
Normal file
31
core/app/Listeners/ExampleListener.php
Normal file
@@ -0,0 +1,31 @@
|
||||
<?php
|
||||
|
||||
namespace App\Listeners;
|
||||
|
||||
use App\Events\ExampleEvent;
|
||||
use Illuminate\Contracts\Queue\ShouldQueue;
|
||||
use Illuminate\Queue\InteractsWithQueue;
|
||||
|
||||
class ExampleListener
|
||||
{
|
||||
/**
|
||||
* Create the event listener.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function __construct()
|
||||
{
|
||||
//
|
||||
}
|
||||
|
||||
/**
|
||||
* Handle the event.
|
||||
*
|
||||
* @param \App\Events\ExampleEvent $event
|
||||
* @return void
|
||||
*/
|
||||
public function handle(ExampleEvent $event)
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
18
core/app/Providers/AppServiceProvider.php
Normal file
18
core/app/Providers/AppServiceProvider.php
Normal file
@@ -0,0 +1,18 @@
|
||||
<?php
|
||||
|
||||
namespace App\Providers;
|
||||
|
||||
use Illuminate\Support\ServiceProvider;
|
||||
|
||||
class AppServiceProvider extends ServiceProvider
|
||||
{
|
||||
/**
|
||||
* Register any application services.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function register()
|
||||
{
|
||||
//
|
||||
}
|
||||
}
|
||||
39
core/app/Providers/AuthServiceProvider.php
Normal file
39
core/app/Providers/AuthServiceProvider.php
Normal file
@@ -0,0 +1,39 @@
|
||||
<?php
|
||||
|
||||
namespace App\Providers;
|
||||
|
||||
use App\Models\User;
|
||||
use Illuminate\Support\Facades\Gate;
|
||||
use Illuminate\Support\ServiceProvider;
|
||||
|
||||
class AuthServiceProvider extends ServiceProvider
|
||||
{
|
||||
/**
|
||||
* Register any application services.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function register()
|
||||
{
|
||||
//
|
||||
}
|
||||
|
||||
/**
|
||||
* Boot the authentication services for the application.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function boot()
|
||||
{
|
||||
// Here you may define how you wish users to be authenticated for your Lumen
|
||||
// application. The callback which receives the incoming request instance
|
||||
// should return either a User instance or null. You're free to obtain
|
||||
// the User instance via an API token or any other method necessary.
|
||||
|
||||
$this->app['auth']->viaRequest('api', function ($request) {
|
||||
if ($request->input('api_token')) {
|
||||
return User::where('api_token', $request->input('api_token'))->first();
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
19
core/app/Providers/EventServiceProvider.php
Normal file
19
core/app/Providers/EventServiceProvider.php
Normal file
@@ -0,0 +1,19 @@
|
||||
<?php
|
||||
|
||||
namespace App\Providers;
|
||||
|
||||
use Laravel\Lumen\Providers\EventServiceProvider as ServiceProvider;
|
||||
|
||||
class EventServiceProvider extends ServiceProvider
|
||||
{
|
||||
/**
|
||||
* The event listener mappings for the application.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
protected $listen = [
|
||||
\App\Events\ExampleEvent::class => [
|
||||
\App\Listeners\ExampleListener::class,
|
||||
],
|
||||
];
|
||||
}
|
||||
114
core/bootstrap/app.php
Normal file
114
core/bootstrap/app.php
Normal file
@@ -0,0 +1,114 @@
|
||||
<?php
|
||||
|
||||
require_once __DIR__.'/../vendor/autoload.php';
|
||||
|
||||
(new Laravel\Lumen\Bootstrap\LoadEnvironmentVariables(
|
||||
dirname(__DIR__) . '/../'
|
||||
))->bootstrap();
|
||||
|
||||
date_default_timezone_set(env('APP_TIMEZONE', 'UTC'));
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Create The Application
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here we will load the environment and create the application instance
|
||||
| that serves as the central piece of this framework. We'll use this
|
||||
| application as an "IoC" container and router for this framework.
|
||||
|
|
||||
*/
|
||||
|
||||
$app = new Laravel\Lumen\Application(
|
||||
dirname(__DIR__)
|
||||
);
|
||||
|
||||
$app->withFacades();
|
||||
$app->withEloquent();
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Register Container Bindings
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Now we will register a few bindings in the service container. We will
|
||||
| register the exception handler and the console kernel. You may add
|
||||
| your own bindings here if you like or you can make another file.
|
||||
|
|
||||
*/
|
||||
|
||||
$app->singleton(
|
||||
Illuminate\Contracts\Debug\ExceptionHandler::class,
|
||||
App\Exceptions\Handler::class
|
||||
);
|
||||
|
||||
$app->singleton(
|
||||
Illuminate\Contracts\Console\Kernel::class,
|
||||
App\Console\Kernel::class
|
||||
);
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Register Config Files
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Now we will register the "app" configuration file. If the file exists in
|
||||
| your configuration directory it will be loaded; otherwise, we'll load
|
||||
| the default version. You may register other files below as needed.
|
||||
|
|
||||
*/
|
||||
|
||||
$app->configure('app');
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Register Middleware
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Next, we will register the middleware with the application. These can
|
||||
| be global middleware that run before and after each request into a
|
||||
| route or middleware that'll be assigned to some specific routes.
|
||||
|
|
||||
*/
|
||||
|
||||
// $app->middleware([
|
||||
// App\Http\Middleware\ExampleMiddleware::class
|
||||
// ]);
|
||||
|
||||
// $app->routeMiddleware([
|
||||
// 'auth' => App\Http\Middleware\Authenticate::class,
|
||||
// ]);
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Register Service Providers
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here we will register all of the application's service providers which
|
||||
| are used to bind services into the container. Service providers are
|
||||
| totally optional, so you are not required to uncomment this line.
|
||||
|
|
||||
*/
|
||||
|
||||
// $app->register(App\Providers\AppServiceProvider::class);
|
||||
// $app->register(App\Providers\AuthServiceProvider::class);
|
||||
// $app->register(App\Providers\EventServiceProvider::class);
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Load The Application Routes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Next we will include the routes file so that they can all be added to
|
||||
| the application. This will provide all of the URLs the application
|
||||
| can respond to, as well as the controllers that may handle them.
|
||||
|
|
||||
*/
|
||||
|
||||
$app->router->group([
|
||||
'namespace' => 'App\Http\Controllers',
|
||||
], function ($router) {
|
||||
require __DIR__.'/../routes/web.php';
|
||||
});
|
||||
|
||||
return $app;
|
||||
47
core/composer.json
Normal file
47
core/composer.json
Normal file
@@ -0,0 +1,47 @@
|
||||
{
|
||||
"name": "laravel/lumen",
|
||||
"description": "The Laravel Lumen Framework.",
|
||||
"keywords": [
|
||||
"framework",
|
||||
"laravel",
|
||||
"lumen"
|
||||
],
|
||||
"license": "MIT",
|
||||
"type": "project",
|
||||
"require": {
|
||||
"php": "^7.3|^8.0",
|
||||
"laravel/lumen-framework": "^8.0",
|
||||
"ext-json": "*"
|
||||
},
|
||||
"require-dev": {
|
||||
"fakerphp/faker": "^1.9.1",
|
||||
"mockery/mockery": "^1.3.1",
|
||||
"phpunit/phpunit": "^9.3"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"App\\": "app/",
|
||||
"Database\\Factories\\": "database/factories/",
|
||||
"Database\\Seeders\\": "database/seeders/",
|
||||
"App\\Commands\\": "../commands/",
|
||||
"App\\Models\\": "../models/"
|
||||
}
|
||||
},
|
||||
"autoload-dev": {
|
||||
"classmap": [
|
||||
"tests/"
|
||||
]
|
||||
},
|
||||
"config": {
|
||||
"preferred-install": "dist",
|
||||
"sort-packages": true,
|
||||
"optimize-autoloader": true
|
||||
},
|
||||
"minimum-stability": "dev",
|
||||
"prefer-stable": true,
|
||||
"scripts": {
|
||||
"post-root-package-install": [
|
||||
"@php -r \"file_exists('.env') || copy('.env.example', '.env');\""
|
||||
]
|
||||
}
|
||||
}
|
||||
5959
core/composer.lock
generated
Normal file
5959
core/composer.lock
generated
Normal file
File diff suppressed because it is too large
Load Diff
29
core/database/factories/UserFactory.php
Normal file
29
core/database/factories/UserFactory.php
Normal file
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
|
||||
namespace Database\Factories;
|
||||
|
||||
use App\Models\User;
|
||||
use Illuminate\Database\Eloquent\Factories\Factory;
|
||||
|
||||
class UserFactory extends Factory
|
||||
{
|
||||
/**
|
||||
* The name of the factory's corresponding model.
|
||||
*
|
||||
* @var string
|
||||
*/
|
||||
protected $model = User::class;
|
||||
|
||||
/**
|
||||
* Define the model's default state.
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function definition()
|
||||
{
|
||||
return [
|
||||
'name' => $this->faker->name,
|
||||
'email' => $this->faker->unique()->safeEmail,
|
||||
];
|
||||
}
|
||||
}
|
||||
0
core/database/migrations/.gitkeep
Normal file
0
core/database/migrations/.gitkeep
Normal file
18
core/database/seeders/DatabaseSeeder.php
Normal file
18
core/database/seeders/DatabaseSeeder.php
Normal file
@@ -0,0 +1,18 @@
|
||||
<?php
|
||||
|
||||
namespace Database\Seeders;
|
||||
|
||||
use Illuminate\Database\Seeder;
|
||||
|
||||
class DatabaseSeeder extends Seeder
|
||||
{
|
||||
/**
|
||||
* Run the database seeds.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function run()
|
||||
{
|
||||
// $this->call('UsersTableSeeder');
|
||||
}
|
||||
}
|
||||
17
core/phpunit.xml
Normal file
17
core/phpunit.xml
Normal file
@@ -0,0 +1,17 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:noNamespaceSchemaLocation="./vendor/phpunit/phpunit/phpunit.xsd"
|
||||
bootstrap="vendor/autoload.php"
|
||||
colors="true"
|
||||
>
|
||||
<testsuites>
|
||||
<testsuite name="Application Test Suite">
|
||||
<directory suffix="Test.php">./tests</directory>
|
||||
</testsuite>
|
||||
</testsuites>
|
||||
<php>
|
||||
<env name="APP_ENV" value="testing"/>
|
||||
<env name="CACHE_DRIVER" value="array"/>
|
||||
<env name="QUEUE_CONNECTION" value="sync"/>
|
||||
</php>
|
||||
</phpunit>
|
||||
21
core/public/.htaccess
Normal file
21
core/public/.htaccess
Normal file
@@ -0,0 +1,21 @@
|
||||
<IfModule mod_rewrite.c>
|
||||
<IfModule mod_negotiation.c>
|
||||
Options -MultiViews -Indexes
|
||||
</IfModule>
|
||||
|
||||
RewriteEngine On
|
||||
|
||||
# Handle Authorization Header
|
||||
RewriteCond %{HTTP:Authorization} .
|
||||
RewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
|
||||
|
||||
# Redirect Trailing Slashes If Not A Folder...
|
||||
RewriteCond %{REQUEST_FILENAME} !-d
|
||||
RewriteCond %{REQUEST_URI} (.+)/$
|
||||
RewriteRule ^ %1 [L,R=301]
|
||||
|
||||
# Handle Front Controller...
|
||||
RewriteCond %{REQUEST_FILENAME} !-d
|
||||
RewriteCond %{REQUEST_FILENAME} !-f
|
||||
RewriteRule ^ index.php [L]
|
||||
</IfModule>
|
||||
28
core/public/index.php
Normal file
28
core/public/index.php
Normal file
@@ -0,0 +1,28 @@
|
||||
<?php
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Create The Application
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| First we need to get an application instance. This creates an instance
|
||||
| of the application / container and bootstraps the application so it
|
||||
| is ready to receive HTTP / Console requests from the environment.
|
||||
|
|
||||
*/
|
||||
|
||||
$app = require __DIR__.'/../bootstrap/app.php';
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Run The Application
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Once we have the application, we can handle the incoming request
|
||||
| through the kernel, and send the associated response back to
|
||||
| the client's browser allowing them to enjoy the creative
|
||||
| and wonderful application we have prepared for them.
|
||||
|
|
||||
*/
|
||||
|
||||
$app->run();
|
||||
0
core/resources/views/.gitkeep
Normal file
0
core/resources/views/.gitkeep
Normal file
18
core/routes/web.php
Normal file
18
core/routes/web.php
Normal file
@@ -0,0 +1,18 @@
|
||||
<?php
|
||||
|
||||
/** @var \Laravel\Lumen\Routing\Router $router */
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Application Routes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here is where you can register all of the routes for an application.
|
||||
| It is a breeze. Simply tell Lumen the URIs it should respond to
|
||||
| and give it the Closure to call when that URI is requested.
|
||||
|
|
||||
*/
|
||||
|
||||
$router->get('/', function () use ($router) {
|
||||
return $router->app->version();
|
||||
});
|
||||
2
core/storage/app/.gitignore
vendored
Normal file
2
core/storage/app/.gitignore
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
*
|
||||
!.gitignore
|
||||
3
core/storage/framework/cache/.gitignore
vendored
Normal file
3
core/storage/framework/cache/.gitignore
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
*
|
||||
!data/
|
||||
!.gitignore
|
||||
2
core/storage/framework/cache/data/.gitignore
vendored
Normal file
2
core/storage/framework/cache/data/.gitignore
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
*
|
||||
!.gitignore
|
||||
2
core/storage/framework/views/.gitignore
vendored
Normal file
2
core/storage/framework/views/.gitignore
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
*
|
||||
!.gitignore
|
||||
2
core/storage/logs/.gitignore
vendored
Normal file
2
core/storage/logs/.gitignore
vendored
Normal file
@@ -0,0 +1,2 @@
|
||||
*
|
||||
!.gitignore
|
||||
21
core/tests/ExampleTest.php
Normal file
21
core/tests/ExampleTest.php
Normal file
@@ -0,0 +1,21 @@
|
||||
<?php
|
||||
|
||||
use Laravel\Lumen\Testing\DatabaseMigrations;
|
||||
use Laravel\Lumen\Testing\DatabaseTransactions;
|
||||
|
||||
class ExampleTest extends TestCase
|
||||
{
|
||||
/**
|
||||
* A basic test example.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function testExample()
|
||||
{
|
||||
$this->get('/');
|
||||
|
||||
$this->assertEquals(
|
||||
$this->app->version(), $this->response->getContent()
|
||||
);
|
||||
}
|
||||
}
|
||||
16
core/tests/TestCase.php
Normal file
16
core/tests/TestCase.php
Normal file
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
|
||||
use Laravel\Lumen\Testing\TestCase as BaseTestCase;
|
||||
|
||||
abstract class TestCase extends BaseTestCase
|
||||
{
|
||||
/**
|
||||
* Creates the application.
|
||||
*
|
||||
* @return \Laravel\Lumen\Application
|
||||
*/
|
||||
public function createApplication()
|
||||
{
|
||||
return require __DIR__.'/../bootstrap/app.php';
|
||||
}
|
||||
}
|
||||
9
models/User.php
Normal file
9
models/User.php
Normal file
@@ -0,0 +1,9 @@
|
||||
<?php
|
||||
|
||||
namespace App\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class User extends Model {
|
||||
protected $table = 'users';
|
||||
}
|
||||
Reference in New Issue
Block a user