{"id":15025093,"url":"https://github.com/patinthehat/laravel-support","last_synced_at":"2026-01-30T20:03:40.650Z","repository":{"id":57036221,"uuid":"82299481","full_name":"patinthehat/laravel-support","owner":"patinthehat","description":"Various support classes for Laravel 5+.","archived":false,"fork":false,"pushed_at":"2017-04-02T11:23:42.000Z","size":8,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-12T13:03:12.451Z","etag":null,"topics":["eloquent","eloquent-orm","helpers","laravel","laravel-5","laravel-5-package","laravel-package","laravel5","php","support-library"],"latest_commit_sha":null,"homepage":null,"language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/patinthehat.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-02-17T13:22:30.000Z","updated_at":"2017-03-10T17:55:26.000Z","dependencies_parsed_at":"2022-08-24T14:10:34.952Z","dependency_job_id":null,"html_url":"https://github.com/patinthehat/laravel-support","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"purl":"pkg:github/patinthehat/laravel-support","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/patinthehat%2Flaravel-support","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/patinthehat%2Flaravel-support/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/patinthehat%2Flaravel-support/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/patinthehat%2Flaravel-support/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/patinthehat","download_url":"https://codeload.github.com/patinthehat/laravel-support/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/patinthehat%2Flaravel-support/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28918235,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-30T19:10:10.838Z","status":"ssl_error","status_checked_at":"2026-01-30T19:06:40.573Z","response_time":66,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["eloquent","eloquent-orm","helpers","laravel","laravel-5","laravel-5-package","laravel-package","laravel5","php","support-library"],"created_at":"2024-09-24T20:01:30.539Z","updated_at":"2026-01-30T20:03:40.635Z","avatar_url":"https://github.com/patinthehat.png","language":"PHP","funding_links":[],"categories":[],"sub_categories":[],"readme":"## LaravelSupport\n---\n\nVarious support classes for Laravel 5+.\n\n---\n####Installation\n\nInstall with composer:\n\n`composer require patinthehat/laravel-support`\n\n\n---\n#### Classes\n\n#####ExtendedSeeder\nExtendedSeeder is an extended version of the `Seeder` class and provides easy foreign key check enable/disable and table truncating.  It also allows for easy access to [Faker](https://github.com/fzaninotto/Faker).\n\n######Methods\n - `getFaker()` - returns an instance of Faker\\Factory (see [Faker](https://github.com/fzaninotto/Faker)).\n - `init($tableName, $disableForeignKeyChecks = true, $deleteAllTableEntries = true)` - call at the beginning of `run()`.\n - `cleanup()` - call at the end of `run()`.\n \n\n######Sample Usage:\n\n```php\nuse App\\Support\\ExtendedSeeder;\nuse App\\User;\n\nclass UserTableSeeder extends ExtendedSeeder\n{\n    /**\n     * Run the database seeds.\n     *\n     * @return void\n     */\n    public function run()\n    {\n        //disable foreign key checks, delete all existing table entries\n        $this-\u003einit('users', true, true); \n        //seed the table\n        $text = $this-\u003egetFaker()-\u003etext();\n        $this-\u003ecleanup();\n    }\n}\n```\n\n---\n#####ExtendedMigration\nExtendedMigration is an extended version of the `Migration` class and provides easy foreign key creation/deletion.\n\n######Methods\n --\n \n######Sample Usage:\n\n```php\nuse LaravelSupport\\Database\\ExtendedMigration;\n\nclass CreateForeignKeys extends ExtendedMigration\n{\n    //define the FKs\n    protected $foreignKeyDefinitions = [\n        'info.author_id' =\u003e ['authors.id', 'cascade', 'cascade'],\n        'info.book_id' =\u003e ['books.id', null, null],\n        'table2.test_id' =\u003e 'tests.id',\n        'myinfo.publisher_id' =\u003e null, //creates FK on 'publishers.id'\n    ];\n    \n    //automatically create/delete FKs\n    protected $autoCreateDefinedKeys = true;\n    protected $autoDeleteDefinedKeys = true;\n}\n```\n\n---\n#### License\nLaravelSupport is available under the [MIT License](LICENSE).","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpatinthehat%2Flaravel-support","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpatinthehat%2Flaravel-support","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpatinthehat%2Flaravel-support/lists"}