membershipworks: Don't try to set generated fields in from_api_dict
All checks were successful
Ruff / ruff (push) Successful in 22s
All checks were successful
Ruff / ruff (push) Successful in 22s
This commit is contained in:
parent
5f59aac67e
commit
e0b5820bc2
@ -29,7 +29,12 @@ class BaseModel(models.Model):
|
||||
def _remap_headers(cls, data):
|
||||
for field in cls._meta.get_fields():
|
||||
# TODO: more robust filtering of fields that don't have a column
|
||||
if field.auto_created or field.many_to_many or not field.concrete:
|
||||
if (
|
||||
field.auto_created
|
||||
or field.many_to_many
|
||||
or not field.concrete
|
||||
or field.generated
|
||||
):
|
||||
continue
|
||||
|
||||
field_name, api_name = field.get_attname_column()
|
||||
|
Loading…
Reference in New Issue
Block a user