CRM-12965 more cleanup and fixes
CRM-12965, worked on form building and postprocess
Merge pull request #1079 from kurund/CRM-12965

CRM-12965