Skip to content

Instantly share code, notes, and snippets.

@RyanThompson
Last active August 29, 2015 14:24
Show Gist options
  • Save RyanThompson/1f71012ca664fbfb7fa5 to your computer and use it in GitHub Desktop.
Save RyanThompson/1f71012ca664fbfb7fa5 to your computer and use it in GitHub Desktop.
An example of property normalization and overriding.
<?php namespace Acme\Foo\Table;
use Anomaly\Streams\PlatTable\Ui\Table\TableBuilder;
class FooTableBuilder extends TableBuilder
{
/**
* The table buttons.
*/
protected $buttons = [
'delete',
'delete' => [
'text' => 'DELETE ME!'
],
[
'handler' => 'Anomaly\Streams\Platform\Ui\Table\Component\Button\Handler\Delete@handle',
'text' => 'streams::button.delete',
'icon' => 'trash',
'type' => 'danger',
'attributes' => [
'data-toggle' => 'confirm',
'data-message' => 'streams::message.confirm_delete'
]
]
];
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment