tanthammar/tall-blueprint-addon
Auto generate TALL-forms for all models with the php artisan blueprint:build command.
draft.yaml related to store, update and destroy, will be written to both Controllers and the Livewire form components.
To avoid code duplication you can manually remove the code in Controllers after the build command. Another suggestion is to refactor into Actions that you can use in both Controllers, and the Livewire form components.
Controller => TallForm, duplicated code position:
DatePicker instead of Input->type('datetime-local'). See the configuration option below.Repeaters, Selects or MultiSelect. This will change when I create required fields in TALL-formscomposer require --dev tanthammar/tall-blueprint-addon
You may publish the configuration with the following command:
php artisan vendor:publish --tag=tall_forms_blueprint
sponsor to true.
The build command will generate sponsor fields instead of open source versions.
Like DatePicker instead of Input->type('datetime-local').//Do you have access to the tall-forms-sponsor repository?
'sponsor' => true,
To disable the generation of timestamp fields for all forms set this option to false.
Refer to Blueprint's Basic Usage
to get started. Afterwards you can run the blueprint:build command to
generate Tall-forms automatically. Try this example draft.yaml file.
# draft.yaml
models:
Post:
author_id: id foreign:users
title: string:400
content: longtext
published_at: nullable timestamp
relationships:
HasMany: Comment
Comment:
post_id: id foreign
content: longtext
published_at: nullable timestamp
controllers:
Post:
index:
query: all
render: post.index with:posts
create:
render: post.create
store:
validate: title, content, author_id
save: post
dispatch: SyncMedia with:post
notify: post.author ReviewPost with:post
send: ReviewPost to:post.author with:post
flash: post.title
fire: NewPost with:post
redirect: post.index
update:
update: post
dispatch: SyncMedia with:post
destroy:
flash: post.title
send: SupportPostDeleted to:support with:post
delete: post
redirect: post.index
Comment:
resource
This is open source, I'll gladly accept every effort to contribute.
The MIT License (MIT). Please see License File for more information.
How can I help you explore Laravel packages today?