Fixes #4596 - Change parent of host group via AJAX

Reparenting host groups requires submitting the form to see the changes
nowadays, this fix makes the host group model inherit all properties
from the parent and show them in real time.
Fixes #3848, #3309: Support deep merging of hash and array structures in smart class parameters

 Please enter the commit message for your changes. Lines starting