Skip to content

Migrate to laravel 5.6 & Add order trait

Compare
Choose a tag to compare
@mfrancois mfrancois released this 13 Feb 15:47
· 50 commits to master since this release

2. Order

Add basic order feature to a component .

Handle Controller

  • must implements \Distilleries\Expendable\Contracts\OrderStateContract
  • methods are implemented in \Distilleries\Expendable\States\OrderStateTrait

Handle Model

  • must implements \Distilleries\Expendable\Contracts\OrderContract

Methods

  • orderLabel() must return a string displayed in order page (by using model attributes)
  • orderFieldName() must return the name of the field where the model persist the order