Clean-up and haml improvements to templates
allow helper functions for edit fields