Hey,
its because parent_id form field ID isnt prefixed with "Inputfield_" as all other formfields. It simply has the id="parent_id", so this selector doesnt match:
var $field = $("#Inputfield_" + condition.field);
Dont know if something else breaks if the form field ID is prefixed.
Cheers