Build permutas functionality on back-end side and implement model and collection classes on the front-end with BackboneJS.