Plan/DB: Added templates to parse different plans data to planinfo.
Plan/DB: Avoiding repeat code with the use of templates.