added gains edit view, updated conditionals #447