Adds submit, beforeSubmit and viewOptions to nested views