added update mode to form template