Example #1
0
 public function morphtable($table, $morph, $suffix = '_morphs')
 {
     $morphtable = new Table($table . $suffix);
     $this->tables[] = $morphtable;
     $morphtable->id('id');
     $morphtable->integer($morph)->references($table);
     $morphtable->varchar('morph_id');
     $morphtable->integer('poly_id');
     return $morphtable;
 }
Example #2
0
 public function __construct(Table $table)
 {
     $this->table = $table;
     $table->integer('order');
 }