grains has_value()

Provide the user the ability in a template to easily see whether or not a particular grain has a value.  Refs #7829.
Pylint fixes.
Merge pull request #8285 from cachedout/#7829

Add a hasvalue function to grains module