add index to model