edit code, add template,layout and add home controller