PHPackages                             theoluirard/laravel-get-table-name - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. theoluirard/laravel-get-table-name

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

theoluirard/laravel-get-table-name
==================================

A package that adds a trait to the Laravel Model class and extends the Laravel Relation class with two new types of relations.

v1.0.3(1y ago)0101MITPHPPHP ^7.2|^8.0|^8.1|^8.2|^8.3

Since Apr 16Pushed 1y ago1 watchersCompare

[ Source](https://github.com/theoLuirard/get-table-name)[ Packagist](https://packagist.org/packages/theoluirard/laravel-get-table-name)[ RSS](/packages/theoluirard-laravel-get-table-name/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (4)Dependencies (1)Versions (5)Used By (1)

Get Table Name
==============

[](#get-table-name)

This package provides a way to get statically table name and primary key in laravel

Features
--------

[](#features)

- Implement 2 methods to retrieve table name &amp; primary key name

Installation
------------

[](#installation)

To install the package, use the following command:

```
composer require theoLuirard/laravel-get-table-name
```

Configuration
-------------

[](#configuration)

### Add the trait to your model

[](#add-the-trait-to-your-model)

Simply add the trait to your model definition

```
