dynamic_model: fixes

1) default_type now correctly used
2) default_type now can use template too