Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Schema builder helpers #8

Open
rmasters opened this issue Jul 23, 2013 · 0 comments
Open

Schema builder helpers #8

rmasters opened this issue Jul 23, 2013 · 0 comments

Comments

@rmasters
Copy link
Owner

A nice-to-have if it's possible to add these - emulate the timestamps() helper for schema building:

Schema::create('comments', function($table) {
    $table->increments('id');

    $table->createdBy();
    $table->updatedBy();
    $table->deletedBy();
});

Aliasing to something like:

$table->integer('created_by_id')->unsigned();
$table->foreign('created_by_id')->references('id')->on(Config::get('culpa::users.table'));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant