diff --git a/lib/features/customers/models/customer_model.dart b/lib/features/customers/models/customer_model.dart index 898d228..fc2519d 100644 --- a/lib/features/customers/models/customer_model.dart +++ b/lib/features/customers/models/customer_model.dart @@ -99,9 +99,9 @@ class CustomerModel extends Equatable { Map toJson() { return { if (id != null) 'id': id, - 'nome': nome.toLowerCase(), + 'nome': nome.toLowerCase().trim(), 'telefono': telefono, - 'email': email.toLowerCase(), + 'email': email.toLowerCase().trim(), 'note': note, if (dataUltimoContatto != null) 'data_ultimo_contatto': dataUltimoContatto!.toIso8601String(), diff --git a/lib/features/products/models/model_model.dart b/lib/features/products/models/model_model.dart index 39304b8..31aa504 100644 --- a/lib/features/products/models/model_model.dart +++ b/lib/features/products/models/model_model.dart @@ -34,8 +34,7 @@ class ModelModel extends Equatable { Map toJson() { return { if (id != null) 'id': id, - 'name': name.toLowerCase(), - 'name_with_brand': nameWithBrand.toLowerCase(), + 'name': name.toLowerCase().trim(), 'brand_id': brandId, 'is_active': isActive, };