Various fixes for field templates