change table data on index to rails model