Open mattymess opened 10 years ago
Did you upgrade Sugar recently? The gem enforces validations defined by the Sugar metadata on the module. Try setting team count to 1, and save! again.
We haven't upgraded Sugar. Maybe they did it without telling us?
I'm honestly not even sure what team count is. I've never seen it before.
team_count is the total number of teams associated with a record. It will get calculated automatically on save, but since the module vardefs mark the field as "required", the gem requires you put a value there.
If I set account.team_count = 1' and then do a
save`, it does work. My question now is, why all of a sudden do we need to set this value?
We've been communicating and updating data in Sugar via the gem for months without needing to do this.
So, the field is required because the Sugar Accounts metadata is marking it as required. This could have been changed a number of ways:
This only started happening in the past few weeks, so at first I thought it was an issue on the SugarCRM side, but their technical support said it doesn't appear to be a Sugar error.
If I get an object from Sugar and try to save it, the gem responds with false when doing
object.save
. If I useobject.save!
, it responds with anInvaidRecord
error