Added required and optional fields evaluation when model has resource_fields attribute