Fixed errors in table migration template
Setup controller for migration with indexes and foreign keys