Settings
This commit is contained in:
parent
75951bae10
commit
84ef755832
|
|
@ -342,6 +342,14 @@ abstract class ClientEntity extends Object
|
|||
.where((contact) => contact.matchesFilter(filter))
|
||||
.isNotEmpty) {
|
||||
return true;
|
||||
} else if (customValue1.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue2.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue3.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue4.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
|
|
@ -373,6 +381,14 @@ abstract class ClientEntity extends Object
|
|||
} else if (contact != null) {
|
||||
final match = contact.matchesFilterValue(filter);
|
||||
return match == displayName ? null : match;
|
||||
} else if (customValue1.toLowerCase().contains(filter)) {
|
||||
return customValue1;
|
||||
} else if (customValue2.toLowerCase().contains(filter)) {
|
||||
return customValue2;
|
||||
} else if (customValue3.toLowerCase().contains(filter)) {
|
||||
return customValue3;
|
||||
} else if (customValue4.toLowerCase().contains(filter)) {
|
||||
return customValue4;
|
||||
}
|
||||
|
||||
return null;
|
||||
|
|
@ -540,7 +556,6 @@ abstract class ContactEntity extends Object
|
|||
@BuiltValueField(wireName: 'custom_value4')
|
||||
String get customValue4;
|
||||
|
||||
|
||||
String get fullName {
|
||||
return (firstName + ' ' + lastName).trim();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -102,6 +102,8 @@ abstract class ExpenseEntity extends Object
|
|||
categoryId: '',
|
||||
customValue1: '',
|
||||
customValue2: '',
|
||||
customValue3: '',
|
||||
customValue4: '',
|
||||
isDeleted: false,
|
||||
);
|
||||
}
|
||||
|
|
@ -205,6 +207,14 @@ abstract class ExpenseEntity extends Object
|
|||
@BuiltValueField(wireName: 'custom_value2')
|
||||
String get customValue2;
|
||||
|
||||
@nullable
|
||||
@BuiltValueField(wireName: 'custom_value3')
|
||||
String get customValue3;
|
||||
|
||||
@nullable
|
||||
@BuiltValueField(wireName: 'custom_value4')
|
||||
String get customValue4;
|
||||
|
||||
@override
|
||||
List<EntityAction> getActions(
|
||||
{UserCompanyEntity userCompany,
|
||||
|
|
@ -270,9 +280,19 @@ abstract class ExpenseEntity extends Object
|
|||
|
||||
if (publicNotes.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
if (privateNotes.toLowerCase().contains(filter)) {
|
||||
} else if (privateNotes.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue1.isNotEmpty &&
|
||||
customValue1.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue2.isNotEmpty &&
|
||||
customValue2.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue3.isNotEmpty &&
|
||||
customValue3.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue4.isNotEmpty &&
|
||||
customValue4.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
@ -301,6 +321,18 @@ abstract class ExpenseEntity extends Object
|
|||
return transactionReference;
|
||||
} else if (transactionReference.toLowerCase().contains(filter)) {
|
||||
return transactionReference;
|
||||
} else if (customValue1.isNotEmpty &&
|
||||
customValue1.toLowerCase().contains(filter)) {
|
||||
return customValue1;
|
||||
} else if (customValue2.isNotEmpty &&
|
||||
customValue2.toLowerCase().contains(filter)) {
|
||||
return customValue2;
|
||||
} else if (customValue3.isNotEmpty &&
|
||||
customValue3.toLowerCase().contains(filter)) {
|
||||
return customValue3;
|
||||
} else if (customValue4.isNotEmpty &&
|
||||
customValue4.toLowerCase().contains(filter)) {
|
||||
return customValue4;
|
||||
}
|
||||
|
||||
return null;
|
||||
|
|
|
|||
|
|
@ -213,6 +213,18 @@ class _$ExpenseEntitySerializer implements StructuredSerializer<ExpenseEntity> {
|
|||
..add(serializers.serialize(object.vendorId,
|
||||
specifiedType: const FullType(String)));
|
||||
}
|
||||
if (object.customValue3 != null) {
|
||||
result
|
||||
..add('custom_value3')
|
||||
..add(serializers.serialize(object.customValue3,
|
||||
specifiedType: const FullType(String)));
|
||||
}
|
||||
if (object.customValue4 != null) {
|
||||
result
|
||||
..add('custom_value4')
|
||||
..add(serializers.serialize(object.customValue4,
|
||||
specifiedType: const FullType(String)));
|
||||
}
|
||||
if (object.isChanged != null) {
|
||||
result
|
||||
..add('isChanged')
|
||||
|
|
@ -380,6 +392,14 @@ class _$ExpenseEntitySerializer implements StructuredSerializer<ExpenseEntity> {
|
|||
result.customValue2 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'custom_value3':
|
||||
result.customValue3 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'custom_value4':
|
||||
result.customValue4 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'isChanged':
|
||||
result.isChanged = serializers.deserialize(value,
|
||||
specifiedType: const FullType(bool)) as bool;
|
||||
|
|
@ -837,6 +857,10 @@ class _$ExpenseEntity extends ExpenseEntity {
|
|||
@override
|
||||
final String customValue2;
|
||||
@override
|
||||
final String customValue3;
|
||||
@override
|
||||
final String customValue4;
|
||||
@override
|
||||
final bool isChanged;
|
||||
@override
|
||||
final int createdAt;
|
||||
|
|
@ -883,6 +907,8 @@ class _$ExpenseEntity extends ExpenseEntity {
|
|||
this.vendorId,
|
||||
this.customValue1,
|
||||
this.customValue2,
|
||||
this.customValue3,
|
||||
this.customValue4,
|
||||
this.isChanged,
|
||||
this.createdAt,
|
||||
this.updatedAt,
|
||||
|
|
@ -998,6 +1024,8 @@ class _$ExpenseEntity extends ExpenseEntity {
|
|||
vendorId == other.vendorId &&
|
||||
customValue1 == other.customValue1 &&
|
||||
customValue2 == other.customValue2 &&
|
||||
customValue3 == other.customValue3 &&
|
||||
customValue4 == other.customValue4 &&
|
||||
isChanged == other.isChanged &&
|
||||
createdAt == other.createdAt &&
|
||||
updatedAt == other.updatedAt &&
|
||||
|
|
@ -1028,18 +1056,18 @@ class _$ExpenseEntity extends ExpenseEntity {
|
|||
$jc(
|
||||
$jc(
|
||||
$jc(
|
||||
$jc($jc($jc($jc($jc($jc($jc($jc($jc($jc($jc($jc($jc($jc($jc($jc(0, privateNotes.hashCode), publicNotes.hashCode), shouldBeInvoiced.hashCode), invoiceDocuments.hashCode), transactionId.hashCode), transactionReference.hashCode), bankId.hashCode), expenseCurrencyId.hashCode), categoryId.hashCode), amount.hashCode), expenseDate.hashCode), paymentDate.hashCode), exchangeRate.hashCode), invoiceCurrencyId.hashCode), paymentTypeId.hashCode),
|
||||
taxName1.hashCode),
|
||||
taxName2.hashCode),
|
||||
taxRate1.hashCode),
|
||||
taxRate2.hashCode),
|
||||
taxName3.hashCode),
|
||||
taxRate3.hashCode),
|
||||
clientId.hashCode),
|
||||
invoiceId.hashCode),
|
||||
vendorId.hashCode),
|
||||
customValue1.hashCode),
|
||||
customValue2.hashCode),
|
||||
$jc($jc($jc($jc($jc($jc($jc($jc($jc($jc($jc($jc($jc($jc($jc($jc($jc($jc(0, privateNotes.hashCode), publicNotes.hashCode), shouldBeInvoiced.hashCode), invoiceDocuments.hashCode), transactionId.hashCode), transactionReference.hashCode), bankId.hashCode), expenseCurrencyId.hashCode), categoryId.hashCode), amount.hashCode), expenseDate.hashCode), paymentDate.hashCode), exchangeRate.hashCode), invoiceCurrencyId.hashCode), paymentTypeId.hashCode), taxName1.hashCode), taxName2.hashCode),
|
||||
taxRate1.hashCode),
|
||||
taxRate2.hashCode),
|
||||
taxName3.hashCode),
|
||||
taxRate3.hashCode),
|
||||
clientId.hashCode),
|
||||
invoiceId.hashCode),
|
||||
vendorId.hashCode),
|
||||
customValue1.hashCode),
|
||||
customValue2.hashCode),
|
||||
customValue3.hashCode),
|
||||
customValue4.hashCode),
|
||||
isChanged.hashCode),
|
||||
createdAt.hashCode),
|
||||
updatedAt.hashCode),
|
||||
|
|
@ -1079,6 +1107,8 @@ class _$ExpenseEntity extends ExpenseEntity {
|
|||
..add('vendorId', vendorId)
|
||||
..add('customValue1', customValue1)
|
||||
..add('customValue2', customValue2)
|
||||
..add('customValue3', customValue3)
|
||||
..add('customValue4', customValue4)
|
||||
..add('isChanged', isChanged)
|
||||
..add('createdAt', createdAt)
|
||||
..add('updatedAt', updatedAt)
|
||||
|
|
@ -1206,6 +1236,14 @@ class ExpenseEntityBuilder
|
|||
String get customValue2 => _$this._customValue2;
|
||||
set customValue2(String customValue2) => _$this._customValue2 = customValue2;
|
||||
|
||||
String _customValue3;
|
||||
String get customValue3 => _$this._customValue3;
|
||||
set customValue3(String customValue3) => _$this._customValue3 = customValue3;
|
||||
|
||||
String _customValue4;
|
||||
String get customValue4 => _$this._customValue4;
|
||||
set customValue4(String customValue4) => _$this._customValue4 = customValue4;
|
||||
|
||||
bool _isChanged;
|
||||
bool get isChanged => _$this._isChanged;
|
||||
set isChanged(bool isChanged) => _$this._isChanged = isChanged;
|
||||
|
|
@ -1270,6 +1308,8 @@ class ExpenseEntityBuilder
|
|||
_vendorId = _$v.vendorId;
|
||||
_customValue1 = _$v.customValue1;
|
||||
_customValue2 = _$v.customValue2;
|
||||
_customValue3 = _$v.customValue3;
|
||||
_customValue4 = _$v.customValue4;
|
||||
_isChanged = _$v.isChanged;
|
||||
_createdAt = _$v.createdAt;
|
||||
_updatedAt = _$v.updatedAt;
|
||||
|
|
@ -1326,6 +1366,8 @@ class ExpenseEntityBuilder
|
|||
vendorId: vendorId,
|
||||
customValue1: customValue1,
|
||||
customValue2: customValue2,
|
||||
customValue3: customValue3,
|
||||
customValue4: customValue4,
|
||||
isChanged: isChanged,
|
||||
createdAt: createdAt,
|
||||
updatedAt: updatedAt,
|
||||
|
|
|
|||
|
|
@ -376,6 +376,12 @@ abstract class InvoiceEntity extends Object
|
|||
} else if (customValue2.isNotEmpty &&
|
||||
customValue2.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue3.isNotEmpty &&
|
||||
customValue3.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue4.isNotEmpty &&
|
||||
customValue4.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
|
|
@ -394,6 +400,12 @@ abstract class InvoiceEntity extends Object
|
|||
} else if (customValue2.isNotEmpty &&
|
||||
customValue2.toLowerCase().contains(filter)) {
|
||||
return customValue2;
|
||||
} else if (customValue3.isNotEmpty &&
|
||||
customValue3.toLowerCase().contains(filter)) {
|
||||
return customValue3;
|
||||
} else if (customValue4.isNotEmpty &&
|
||||
customValue4.toLowerCase().contains(filter)) {
|
||||
return customValue4;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
|
@ -630,6 +642,7 @@ abstract class InvoiceItemEntity
|
|||
quantity == 0 &&
|
||||
customValue1.isEmpty &&
|
||||
customValue2.isEmpty;
|
||||
|
||||
// TODO add custom 3 and 4
|
||||
|
||||
InvoiceItemEntity applyTax(TaxRateEntity taxRate,
|
||||
|
|
|
|||
|
|
@ -76,6 +76,10 @@ abstract class PaymentEntity extends Object
|
|||
updatedAt: 0,
|
||||
archivedAt: 0,
|
||||
isDeleted: false,
|
||||
customValue1: '',
|
||||
customValue2: '',
|
||||
customValue3: '',
|
||||
customValue4: '',
|
||||
);
|
||||
}
|
||||
|
||||
|
|
@ -120,6 +124,22 @@ abstract class PaymentEntity extends Object
|
|||
@BuiltValueField(wireName: 'private_notes')
|
||||
String get privateNotes;
|
||||
|
||||
@nullable
|
||||
@BuiltValueField(wireName: 'custom_value1')
|
||||
String get customValue1;
|
||||
|
||||
@nullable
|
||||
@BuiltValueField(wireName: 'custom_value2')
|
||||
String get customValue2;
|
||||
|
||||
@nullable
|
||||
@BuiltValueField(wireName: 'custom_value3')
|
||||
String get customValue3;
|
||||
|
||||
@nullable
|
||||
@BuiltValueField(wireName: 'custom_value4')
|
||||
String get customValue4;
|
||||
|
||||
@nullable
|
||||
@BuiltValueField(wireName: 'exchange_rate')
|
||||
double get exchangeRate;
|
||||
|
|
@ -162,7 +182,25 @@ abstract class PaymentEntity extends Object
|
|||
return true;
|
||||
} else if (privateNotes.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue1.isNotEmpty &&
|
||||
customValue1.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue2.isNotEmpty &&
|
||||
customValue2.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue3.isNotEmpty &&
|
||||
customValue3.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue4.isNotEmpty &&
|
||||
customValue4.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
}
|
||||
/*
|
||||
} else if (customValue1.isNotEmpty &&
|
||||
customValue2.toLowerCase().contains(filter)) {
|
||||
return customValue2;
|
||||
}
|
||||
*/
|
||||
|
||||
return false;
|
||||
}
|
||||
|
|
@ -179,6 +217,18 @@ abstract class PaymentEntity extends Object
|
|||
return transactionReference;
|
||||
} else if (privateNotes.toLowerCase().contains(filter)) {
|
||||
return privateNotes;
|
||||
} else if (customValue1.isNotEmpty &&
|
||||
customValue1.toLowerCase().contains(filter)) {
|
||||
return customValue1;
|
||||
} else if (customValue2.isNotEmpty &&
|
||||
customValue2.toLowerCase().contains(filter)) {
|
||||
return customValue2;
|
||||
} else if (customValue3.isNotEmpty &&
|
||||
customValue3.toLowerCase().contains(filter)) {
|
||||
return customValue3;
|
||||
} else if (customValue4.isNotEmpty &&
|
||||
customValue4.toLowerCase().contains(filter)) {
|
||||
return customValue4;
|
||||
}
|
||||
|
||||
return null;
|
||||
|
|
|
|||
|
|
@ -167,6 +167,30 @@ class _$PaymentEntitySerializer implements StructuredSerializer<PaymentEntity> {
|
|||
..add(serializers.serialize(object.privateNotes,
|
||||
specifiedType: const FullType(String)));
|
||||
}
|
||||
if (object.customValue1 != null) {
|
||||
result
|
||||
..add('custom_value1')
|
||||
..add(serializers.serialize(object.customValue1,
|
||||
specifiedType: const FullType(String)));
|
||||
}
|
||||
if (object.customValue2 != null) {
|
||||
result
|
||||
..add('custom_value2')
|
||||
..add(serializers.serialize(object.customValue2,
|
||||
specifiedType: const FullType(String)));
|
||||
}
|
||||
if (object.customValue3 != null) {
|
||||
result
|
||||
..add('custom_value3')
|
||||
..add(serializers.serialize(object.customValue3,
|
||||
specifiedType: const FullType(String)));
|
||||
}
|
||||
if (object.customValue4 != null) {
|
||||
result
|
||||
..add('custom_value4')
|
||||
..add(serializers.serialize(object.customValue4,
|
||||
specifiedType: const FullType(String)));
|
||||
}
|
||||
if (object.exchangeRate != null) {
|
||||
result
|
||||
..add('exchange_rate')
|
||||
|
|
@ -282,6 +306,22 @@ class _$PaymentEntitySerializer implements StructuredSerializer<PaymentEntity> {
|
|||
result.privateNotes = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'custom_value1':
|
||||
result.customValue1 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'custom_value2':
|
||||
result.customValue2 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'custom_value3':
|
||||
result.customValue3 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'custom_value4':
|
||||
result.customValue4 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'exchange_rate':
|
||||
result.exchangeRate = serializers.deserialize(value,
|
||||
specifiedType: const FullType(double)) as double;
|
||||
|
|
@ -540,6 +580,14 @@ class _$PaymentEntity extends PaymentEntity {
|
|||
@override
|
||||
final String privateNotes;
|
||||
@override
|
||||
final String customValue1;
|
||||
@override
|
||||
final String customValue2;
|
||||
@override
|
||||
final String customValue3;
|
||||
@override
|
||||
final String customValue4;
|
||||
@override
|
||||
final double exchangeRate;
|
||||
@override
|
||||
final String exchangeCurrencyId;
|
||||
|
|
@ -574,6 +622,10 @@ class _$PaymentEntity extends PaymentEntity {
|
|||
this.paymentTypeId,
|
||||
this.invoiceId,
|
||||
this.privateNotes,
|
||||
this.customValue1,
|
||||
this.customValue2,
|
||||
this.customValue3,
|
||||
this.customValue4,
|
||||
this.exchangeRate,
|
||||
this.exchangeCurrencyId,
|
||||
this.isChanged,
|
||||
|
|
@ -621,6 +673,10 @@ class _$PaymentEntity extends PaymentEntity {
|
|||
paymentTypeId == other.paymentTypeId &&
|
||||
invoiceId == other.invoiceId &&
|
||||
privateNotes == other.privateNotes &&
|
||||
customValue1 == other.customValue1 &&
|
||||
customValue2 == other.customValue2 &&
|
||||
customValue3 == other.customValue3 &&
|
||||
customValue4 == other.customValue4 &&
|
||||
exchangeRate == other.exchangeRate &&
|
||||
exchangeCurrencyId == other.exchangeCurrencyId &&
|
||||
isChanged == other.isChanged &&
|
||||
|
|
@ -653,26 +709,16 @@ class _$PaymentEntity extends PaymentEntity {
|
|||
$jc(
|
||||
$jc(
|
||||
$jc(
|
||||
$jc(
|
||||
$jc(
|
||||
0,
|
||||
amount
|
||||
.hashCode),
|
||||
refunded
|
||||
.hashCode),
|
||||
number
|
||||
.hashCode),
|
||||
clientId
|
||||
.hashCode),
|
||||
paymentStatusId
|
||||
.hashCode),
|
||||
transactionReference
|
||||
.hashCode),
|
||||
paymentDate
|
||||
.hashCode),
|
||||
paymentTypeId.hashCode),
|
||||
invoiceId.hashCode),
|
||||
privateNotes.hashCode),
|
||||
$jc($jc($jc($jc($jc($jc(0, amount.hashCode), refunded.hashCode), number.hashCode), clientId.hashCode), paymentStatusId.hashCode),
|
||||
transactionReference.hashCode),
|
||||
paymentDate.hashCode),
|
||||
paymentTypeId.hashCode),
|
||||
invoiceId.hashCode),
|
||||
privateNotes.hashCode),
|
||||
customValue1.hashCode),
|
||||
customValue2.hashCode),
|
||||
customValue3.hashCode),
|
||||
customValue4.hashCode),
|
||||
exchangeRate.hashCode),
|
||||
exchangeCurrencyId.hashCode),
|
||||
isChanged.hashCode),
|
||||
|
|
@ -698,6 +744,10 @@ class _$PaymentEntity extends PaymentEntity {
|
|||
..add('paymentTypeId', paymentTypeId)
|
||||
..add('invoiceId', invoiceId)
|
||||
..add('privateNotes', privateNotes)
|
||||
..add('customValue1', customValue1)
|
||||
..add('customValue2', customValue2)
|
||||
..add('customValue3', customValue3)
|
||||
..add('customValue4', customValue4)
|
||||
..add('exchangeRate', exchangeRate)
|
||||
..add('exchangeCurrencyId', exchangeCurrencyId)
|
||||
..add('isChanged', isChanged)
|
||||
|
|
@ -759,6 +809,22 @@ class PaymentEntityBuilder
|
|||
String get privateNotes => _$this._privateNotes;
|
||||
set privateNotes(String privateNotes) => _$this._privateNotes = privateNotes;
|
||||
|
||||
String _customValue1;
|
||||
String get customValue1 => _$this._customValue1;
|
||||
set customValue1(String customValue1) => _$this._customValue1 = customValue1;
|
||||
|
||||
String _customValue2;
|
||||
String get customValue2 => _$this._customValue2;
|
||||
set customValue2(String customValue2) => _$this._customValue2 = customValue2;
|
||||
|
||||
String _customValue3;
|
||||
String get customValue3 => _$this._customValue3;
|
||||
set customValue3(String customValue3) => _$this._customValue3 = customValue3;
|
||||
|
||||
String _customValue4;
|
||||
String get customValue4 => _$this._customValue4;
|
||||
set customValue4(String customValue4) => _$this._customValue4 = customValue4;
|
||||
|
||||
double _exchangeRate;
|
||||
double get exchangeRate => _$this._exchangeRate;
|
||||
set exchangeRate(double exchangeRate) => _$this._exchangeRate = exchangeRate;
|
||||
|
|
@ -816,6 +882,10 @@ class PaymentEntityBuilder
|
|||
_paymentTypeId = _$v.paymentTypeId;
|
||||
_invoiceId = _$v.invoiceId;
|
||||
_privateNotes = _$v.privateNotes;
|
||||
_customValue1 = _$v.customValue1;
|
||||
_customValue2 = _$v.customValue2;
|
||||
_customValue3 = _$v.customValue3;
|
||||
_customValue4 = _$v.customValue4;
|
||||
_exchangeRate = _$v.exchangeRate;
|
||||
_exchangeCurrencyId = _$v.exchangeCurrencyId;
|
||||
_isChanged = _$v.isChanged;
|
||||
|
|
@ -858,6 +928,10 @@ class PaymentEntityBuilder
|
|||
paymentTypeId: paymentTypeId,
|
||||
invoiceId: invoiceId,
|
||||
privateNotes: privateNotes,
|
||||
customValue1: customValue1,
|
||||
customValue2: customValue2,
|
||||
customValue3: customValue3,
|
||||
customValue4: customValue4,
|
||||
exchangeRate: exchangeRate,
|
||||
exchangeCurrencyId: exchangeCurrencyId,
|
||||
isChanged: isChanged,
|
||||
|
|
|
|||
|
|
@ -67,6 +67,8 @@ abstract class ProductEntity extends Object
|
|||
taxRate3: 0,
|
||||
customValue1: '',
|
||||
customValue2: '',
|
||||
customValue3: '',
|
||||
customValue4: '',
|
||||
updatedAt: 0,
|
||||
archivedAt: 0,
|
||||
isDeleted: false,
|
||||
|
|
@ -120,6 +122,14 @@ abstract class ProductEntity extends Object
|
|||
@BuiltValueField(wireName: 'custom_value2')
|
||||
String get customValue2;
|
||||
|
||||
@nullable
|
||||
@BuiltValueField(wireName: 'custom_value3')
|
||||
String get customValue3;
|
||||
|
||||
@nullable
|
||||
@BuiltValueField(wireName: 'custom_value4')
|
||||
String get customValue4;
|
||||
|
||||
@override
|
||||
String get listDisplayName {
|
||||
return productKey;
|
||||
|
|
@ -173,6 +183,12 @@ abstract class ProductEntity extends Object
|
|||
} else if (customValue2.isNotEmpty &&
|
||||
customValue2.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue3.isNotEmpty &&
|
||||
customValue3.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue4.isNotEmpty &&
|
||||
customValue4.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
|
|
@ -193,6 +209,12 @@ abstract class ProductEntity extends Object
|
|||
} else if (customValue2.isNotEmpty &&
|
||||
customValue2.toLowerCase().contains(filter)) {
|
||||
return customValue2;
|
||||
} else if (customValue3.isNotEmpty &&
|
||||
customValue3.toLowerCase().contains(filter)) {
|
||||
return customValue1;
|
||||
} else if (customValue3.isNotEmpty &&
|
||||
customValue3.toLowerCase().contains(filter)) {
|
||||
return customValue2;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -157,6 +157,18 @@ class _$ProductEntitySerializer implements StructuredSerializer<ProductEntity> {
|
|||
serializers.serialize(object.customValue2,
|
||||
specifiedType: const FullType(String)),
|
||||
];
|
||||
if (object.customValue3 != null) {
|
||||
result
|
||||
..add('custom_value3')
|
||||
..add(serializers.serialize(object.customValue3,
|
||||
specifiedType: const FullType(String)));
|
||||
}
|
||||
if (object.customValue4 != null) {
|
||||
result
|
||||
..add('custom_value4')
|
||||
..add(serializers.serialize(object.customValue4,
|
||||
specifiedType: const FullType(String)));
|
||||
}
|
||||
if (object.isChanged != null) {
|
||||
result
|
||||
..add('isChanged')
|
||||
|
|
@ -272,6 +284,14 @@ class _$ProductEntitySerializer implements StructuredSerializer<ProductEntity> {
|
|||
result.customValue2 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'custom_value3':
|
||||
result.customValue3 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'custom_value4':
|
||||
result.customValue4 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'isChanged':
|
||||
result.isChanged = serializers.deserialize(value,
|
||||
specifiedType: const FullType(bool)) as bool;
|
||||
|
|
@ -528,6 +548,10 @@ class _$ProductEntity extends ProductEntity {
|
|||
@override
|
||||
final String customValue2;
|
||||
@override
|
||||
final String customValue3;
|
||||
@override
|
||||
final String customValue4;
|
||||
@override
|
||||
final bool isChanged;
|
||||
@override
|
||||
final int createdAt;
|
||||
|
|
@ -561,6 +585,8 @@ class _$ProductEntity extends ProductEntity {
|
|||
this.taxRate3,
|
||||
this.customValue1,
|
||||
this.customValue2,
|
||||
this.customValue3,
|
||||
this.customValue4,
|
||||
this.isChanged,
|
||||
this.createdAt,
|
||||
this.updatedAt,
|
||||
|
|
@ -635,6 +661,8 @@ class _$ProductEntity extends ProductEntity {
|
|||
taxRate3 == other.taxRate3 &&
|
||||
customValue1 == other.customValue1 &&
|
||||
customValue2 == other.customValue2 &&
|
||||
customValue3 == other.customValue3 &&
|
||||
customValue4 == other.customValue4 &&
|
||||
isChanged == other.isChanged &&
|
||||
createdAt == other.createdAt &&
|
||||
updatedAt == other.updatedAt &&
|
||||
|
|
@ -665,18 +693,18 @@ class _$ProductEntity extends ProductEntity {
|
|||
$jc(
|
||||
$jc(
|
||||
$jc(
|
||||
$jc($jc($jc(0, productKey.hashCode), notes.hashCode),
|
||||
cost.hashCode),
|
||||
price.hashCode),
|
||||
quantity.hashCode),
|
||||
taxName1.hashCode),
|
||||
taxRate1.hashCode),
|
||||
taxName2.hashCode),
|
||||
taxRate2.hashCode),
|
||||
taxName3.hashCode),
|
||||
taxRate3.hashCode),
|
||||
customValue1.hashCode),
|
||||
customValue2.hashCode),
|
||||
$jc($jc($jc($jc($jc(0, productKey.hashCode), notes.hashCode), cost.hashCode), price.hashCode),
|
||||
quantity.hashCode),
|
||||
taxName1.hashCode),
|
||||
taxRate1.hashCode),
|
||||
taxName2.hashCode),
|
||||
taxRate2.hashCode),
|
||||
taxName3.hashCode),
|
||||
taxRate3.hashCode),
|
||||
customValue1.hashCode),
|
||||
customValue2.hashCode),
|
||||
customValue3.hashCode),
|
||||
customValue4.hashCode),
|
||||
isChanged.hashCode),
|
||||
createdAt.hashCode),
|
||||
updatedAt.hashCode),
|
||||
|
|
@ -703,6 +731,8 @@ class _$ProductEntity extends ProductEntity {
|
|||
..add('taxRate3', taxRate3)
|
||||
..add('customValue1', customValue1)
|
||||
..add('customValue2', customValue2)
|
||||
..add('customValue3', customValue3)
|
||||
..add('customValue4', customValue4)
|
||||
..add('isChanged', isChanged)
|
||||
..add('createdAt', createdAt)
|
||||
..add('updatedAt', updatedAt)
|
||||
|
|
@ -771,6 +801,14 @@ class ProductEntityBuilder
|
|||
String get customValue2 => _$this._customValue2;
|
||||
set customValue2(String customValue2) => _$this._customValue2 = customValue2;
|
||||
|
||||
String _customValue3;
|
||||
String get customValue3 => _$this._customValue3;
|
||||
set customValue3(String customValue3) => _$this._customValue3 = customValue3;
|
||||
|
||||
String _customValue4;
|
||||
String get customValue4 => _$this._customValue4;
|
||||
set customValue4(String customValue4) => _$this._customValue4 = customValue4;
|
||||
|
||||
bool _isChanged;
|
||||
bool get isChanged => _$this._isChanged;
|
||||
set isChanged(bool isChanged) => _$this._isChanged = isChanged;
|
||||
|
|
@ -822,6 +860,8 @@ class ProductEntityBuilder
|
|||
_taxRate3 = _$v.taxRate3;
|
||||
_customValue1 = _$v.customValue1;
|
||||
_customValue2 = _$v.customValue2;
|
||||
_customValue3 = _$v.customValue3;
|
||||
_customValue4 = _$v.customValue4;
|
||||
_isChanged = _$v.isChanged;
|
||||
_createdAt = _$v.createdAt;
|
||||
_updatedAt = _$v.updatedAt;
|
||||
|
|
@ -865,6 +905,8 @@ class ProductEntityBuilder
|
|||
taxRate3: taxRate3,
|
||||
customValue1: customValue1,
|
||||
customValue2: customValue2,
|
||||
customValue3: customValue3,
|
||||
customValue4: customValue4,
|
||||
isChanged: isChanged,
|
||||
createdAt: createdAt,
|
||||
updatedAt: updatedAt,
|
||||
|
|
|
|||
|
|
@ -64,6 +64,8 @@ abstract class ProjectEntity extends Object
|
|||
budgetedHours: 0.0,
|
||||
customValue1: '',
|
||||
customValue2: '',
|
||||
customValue3: '',
|
||||
customValue4: '',
|
||||
updatedAt: 0,
|
||||
archivedAt: 0,
|
||||
isDeleted: false,
|
||||
|
|
@ -105,6 +107,12 @@ abstract class ProjectEntity extends Object
|
|||
@BuiltValueField(wireName: 'custom_value2')
|
||||
String get customValue2;
|
||||
|
||||
@BuiltValueField(wireName: 'custom_value3')
|
||||
String get customValue3;
|
||||
|
||||
@BuiltValueField(wireName: 'custom_value4')
|
||||
String get customValue4;
|
||||
|
||||
@override
|
||||
List<EntityAction> getActions(
|
||||
{UserCompanyEntity userCompany,
|
||||
|
|
@ -159,8 +167,19 @@ abstract class ProjectEntity extends Object
|
|||
bool matchesFilter(String filter) {
|
||||
if (filter == null || filter.isEmpty) {
|
||||
return true;
|
||||
} else if (customValue1.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue2.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue3.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue4.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
return name.toLowerCase().contains(filter);
|
||||
}
|
||||
|
||||
|
|
@ -168,6 +187,14 @@ abstract class ProjectEntity extends Object
|
|||
String matchesFilterValue(String filter) {
|
||||
if (filter == null || filter.isEmpty) {
|
||||
return null;
|
||||
} else if (customValue1.toLowerCase().contains(filter)) {
|
||||
return customValue1;
|
||||
} else if (customValue2.toLowerCase().contains(filter)) {
|
||||
return customValue2;
|
||||
} else if (customValue3.toLowerCase().contains(filter)) {
|
||||
return customValue3;
|
||||
} else if (customValue4.toLowerCase().contains(filter)) {
|
||||
return customValue4;
|
||||
}
|
||||
|
||||
return null;
|
||||
|
|
|
|||
|
|
@ -141,6 +141,12 @@ class _$ProjectEntitySerializer implements StructuredSerializer<ProjectEntity> {
|
|||
'custom_value2',
|
||||
serializers.serialize(object.customValue2,
|
||||
specifiedType: const FullType(String)),
|
||||
'custom_value3',
|
||||
serializers.serialize(object.customValue3,
|
||||
specifiedType: const FullType(String)),
|
||||
'custom_value4',
|
||||
serializers.serialize(object.customValue4,
|
||||
specifiedType: const FullType(String)),
|
||||
];
|
||||
if (object.isChanged != null) {
|
||||
result
|
||||
|
|
@ -237,6 +243,14 @@ class _$ProjectEntitySerializer implements StructuredSerializer<ProjectEntity> {
|
|||
result.customValue2 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'custom_value3':
|
||||
result.customValue3 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'custom_value4':
|
||||
result.customValue4 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'isChanged':
|
||||
result.isChanged = serializers.deserialize(value,
|
||||
specifiedType: const FullType(bool)) as bool;
|
||||
|
|
@ -483,6 +497,10 @@ class _$ProjectEntity extends ProjectEntity {
|
|||
@override
|
||||
final String customValue2;
|
||||
@override
|
||||
final String customValue3;
|
||||
@override
|
||||
final String customValue4;
|
||||
@override
|
||||
final bool isChanged;
|
||||
@override
|
||||
final int createdAt;
|
||||
|
|
@ -511,6 +529,8 @@ class _$ProjectEntity extends ProjectEntity {
|
|||
this.budgetedHours,
|
||||
this.customValue1,
|
||||
this.customValue2,
|
||||
this.customValue3,
|
||||
this.customValue4,
|
||||
this.isChanged,
|
||||
this.createdAt,
|
||||
this.updatedAt,
|
||||
|
|
@ -544,6 +564,12 @@ class _$ProjectEntity extends ProjectEntity {
|
|||
if (customValue2 == null) {
|
||||
throw new BuiltValueNullFieldError('ProjectEntity', 'customValue2');
|
||||
}
|
||||
if (customValue3 == null) {
|
||||
throw new BuiltValueNullFieldError('ProjectEntity', 'customValue3');
|
||||
}
|
||||
if (customValue4 == null) {
|
||||
throw new BuiltValueNullFieldError('ProjectEntity', 'customValue4');
|
||||
}
|
||||
}
|
||||
|
||||
@override
|
||||
|
|
@ -565,6 +591,8 @@ class _$ProjectEntity extends ProjectEntity {
|
|||
budgetedHours == other.budgetedHours &&
|
||||
customValue1 == other.customValue1 &&
|
||||
customValue2 == other.customValue2 &&
|
||||
customValue3 == other.customValue3 &&
|
||||
customValue4 == other.customValue4 &&
|
||||
isChanged == other.isChanged &&
|
||||
createdAt == other.createdAt &&
|
||||
updatedAt == other.updatedAt &&
|
||||
|
|
@ -593,17 +621,24 @@ class _$ProjectEntity extends ProjectEntity {
|
|||
$jc(
|
||||
$jc(
|
||||
$jc(
|
||||
0,
|
||||
name
|
||||
$jc(
|
||||
$jc(
|
||||
0,
|
||||
name
|
||||
.hashCode),
|
||||
clientId
|
||||
.hashCode),
|
||||
taskRate
|
||||
.hashCode),
|
||||
clientId
|
||||
dueDate
|
||||
.hashCode),
|
||||
taskRate.hashCode),
|
||||
dueDate.hashCode),
|
||||
privateNotes.hashCode),
|
||||
budgetedHours.hashCode),
|
||||
customValue1.hashCode),
|
||||
customValue2.hashCode),
|
||||
privateNotes
|
||||
.hashCode),
|
||||
budgetedHours.hashCode),
|
||||
customValue1.hashCode),
|
||||
customValue2.hashCode),
|
||||
customValue3.hashCode),
|
||||
customValue4.hashCode),
|
||||
isChanged.hashCode),
|
||||
createdAt.hashCode),
|
||||
updatedAt.hashCode),
|
||||
|
|
@ -625,6 +660,8 @@ class _$ProjectEntity extends ProjectEntity {
|
|||
..add('budgetedHours', budgetedHours)
|
||||
..add('customValue1', customValue1)
|
||||
..add('customValue2', customValue2)
|
||||
..add('customValue3', customValue3)
|
||||
..add('customValue4', customValue4)
|
||||
..add('isChanged', isChanged)
|
||||
..add('createdAt', createdAt)
|
||||
..add('updatedAt', updatedAt)
|
||||
|
|
@ -674,6 +711,14 @@ class ProjectEntityBuilder
|
|||
String get customValue2 => _$this._customValue2;
|
||||
set customValue2(String customValue2) => _$this._customValue2 = customValue2;
|
||||
|
||||
String _customValue3;
|
||||
String get customValue3 => _$this._customValue3;
|
||||
set customValue3(String customValue3) => _$this._customValue3 = customValue3;
|
||||
|
||||
String _customValue4;
|
||||
String get customValue4 => _$this._customValue4;
|
||||
set customValue4(String customValue4) => _$this._customValue4 = customValue4;
|
||||
|
||||
bool _isChanged;
|
||||
bool get isChanged => _$this._isChanged;
|
||||
set isChanged(bool isChanged) => _$this._isChanged = isChanged;
|
||||
|
|
@ -720,6 +765,8 @@ class ProjectEntityBuilder
|
|||
_budgetedHours = _$v.budgetedHours;
|
||||
_customValue1 = _$v.customValue1;
|
||||
_customValue2 = _$v.customValue2;
|
||||
_customValue3 = _$v.customValue3;
|
||||
_customValue4 = _$v.customValue4;
|
||||
_isChanged = _$v.isChanged;
|
||||
_createdAt = _$v.createdAt;
|
||||
_updatedAt = _$v.updatedAt;
|
||||
|
|
@ -758,6 +805,8 @@ class ProjectEntityBuilder
|
|||
budgetedHours: budgetedHours,
|
||||
customValue1: customValue1,
|
||||
customValue2: customValue2,
|
||||
customValue3: customValue3,
|
||||
customValue4: customValue4,
|
||||
isChanged: isChanged,
|
||||
createdAt: createdAt,
|
||||
updatedAt: updatedAt,
|
||||
|
|
|
|||
|
|
@ -144,6 +144,8 @@ abstract class TaskEntity extends Object
|
|||
isRunning: isRunning,
|
||||
customValue1: '',
|
||||
customValue2: '',
|
||||
customValue3: '',
|
||||
customValue4: '',
|
||||
updatedAt: 0,
|
||||
archivedAt: 0,
|
||||
isDeleted: false,
|
||||
|
|
@ -348,6 +350,14 @@ abstract class TaskEntity extends Object
|
|||
@BuiltValueField(wireName: 'custom_value2')
|
||||
String get customValue2;
|
||||
|
||||
@nullable
|
||||
@BuiltValueField(wireName: 'custom_value3')
|
||||
String get customValue3;
|
||||
|
||||
@nullable
|
||||
@BuiltValueField(wireName: 'custom_value4')
|
||||
String get customValue4;
|
||||
|
||||
@nullable
|
||||
@BuiltValueField(wireName: 'task_status_id')
|
||||
String get taskStatusId;
|
||||
|
|
@ -420,6 +430,14 @@ abstract class TaskEntity extends Object
|
|||
bool matchesFilter(String filter) {
|
||||
if (filter == null || filter.isEmpty) {
|
||||
return true;
|
||||
} else if (customValue1.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue2.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue3.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue4.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return description.toLowerCase().contains(filter);
|
||||
|
|
@ -448,6 +466,14 @@ abstract class TaskEntity extends Object
|
|||
String matchesFilterValue(String filter) {
|
||||
if (filter == null || filter.isEmpty) {
|
||||
return null;
|
||||
} else if (customValue1.toLowerCase().contains(filter)) {
|
||||
return customValue1;
|
||||
} else if (customValue2.toLowerCase().contains(filter)) {
|
||||
return customValue2;
|
||||
} else if (customValue3.toLowerCase().contains(filter)) {
|
||||
return customValue3;
|
||||
} else if (customValue4.toLowerCase().contains(filter)) {
|
||||
return customValue4;
|
||||
}
|
||||
|
||||
return null;
|
||||
|
|
|
|||
|
|
@ -198,6 +198,18 @@ class _$TaskEntitySerializer implements StructuredSerializer<TaskEntity> {
|
|||
..add(serializers.serialize(object.projectId,
|
||||
specifiedType: const FullType(String)));
|
||||
}
|
||||
if (object.customValue3 != null) {
|
||||
result
|
||||
..add('custom_value3')
|
||||
..add(serializers.serialize(object.customValue3,
|
||||
specifiedType: const FullType(String)));
|
||||
}
|
||||
if (object.customValue4 != null) {
|
||||
result
|
||||
..add('custom_value4')
|
||||
..add(serializers.serialize(object.customValue4,
|
||||
specifiedType: const FullType(String)));
|
||||
}
|
||||
if (object.taskStatusId != null) {
|
||||
result
|
||||
..add('task_status_id')
|
||||
|
|
@ -308,6 +320,14 @@ class _$TaskEntitySerializer implements StructuredSerializer<TaskEntity> {
|
|||
result.customValue2 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'custom_value3':
|
||||
result.customValue3 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'custom_value4':
|
||||
result.customValue4 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'task_status_id':
|
||||
result.taskStatusId = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
|
|
@ -702,6 +722,10 @@ class _$TaskEntity extends TaskEntity {
|
|||
@override
|
||||
final String customValue2;
|
||||
@override
|
||||
final String customValue3;
|
||||
@override
|
||||
final String customValue4;
|
||||
@override
|
||||
final String taskStatusId;
|
||||
@override
|
||||
final int taskStatusSortOrder;
|
||||
|
|
@ -735,6 +759,8 @@ class _$TaskEntity extends TaskEntity {
|
|||
this.isRunning,
|
||||
this.customValue1,
|
||||
this.customValue2,
|
||||
this.customValue3,
|
||||
this.customValue4,
|
||||
this.taskStatusId,
|
||||
this.taskStatusSortOrder,
|
||||
this.isChanged,
|
||||
|
|
@ -786,6 +812,8 @@ class _$TaskEntity extends TaskEntity {
|
|||
isRunning == other.isRunning &&
|
||||
customValue1 == other.customValue1 &&
|
||||
customValue2 == other.customValue2 &&
|
||||
customValue3 == other.customValue3 &&
|
||||
customValue4 == other.customValue4 &&
|
||||
taskStatusId == other.taskStatusId &&
|
||||
taskStatusSortOrder == other.taskStatusSortOrder &&
|
||||
isChanged == other.isChanged &&
|
||||
|
|
@ -818,22 +846,16 @@ class _$TaskEntity extends TaskEntity {
|
|||
$jc(
|
||||
$jc(
|
||||
$jc(
|
||||
$jc(
|
||||
0,
|
||||
description
|
||||
.hashCode),
|
||||
duration
|
||||
.hashCode),
|
||||
invoiceId
|
||||
.hashCode),
|
||||
clientId
|
||||
.hashCode),
|
||||
projectId
|
||||
.hashCode),
|
||||
timeLog.hashCode),
|
||||
isRunning.hashCode),
|
||||
customValue1.hashCode),
|
||||
customValue2.hashCode),
|
||||
$jc($jc($jc(0, description.hashCode), duration.hashCode),
|
||||
invoiceId.hashCode),
|
||||
clientId.hashCode),
|
||||
projectId.hashCode),
|
||||
timeLog.hashCode),
|
||||
isRunning.hashCode),
|
||||
customValue1.hashCode),
|
||||
customValue2.hashCode),
|
||||
customValue3.hashCode),
|
||||
customValue4.hashCode),
|
||||
taskStatusId.hashCode),
|
||||
taskStatusSortOrder.hashCode),
|
||||
isChanged.hashCode),
|
||||
|
|
@ -858,6 +880,8 @@ class _$TaskEntity extends TaskEntity {
|
|||
..add('isRunning', isRunning)
|
||||
..add('customValue1', customValue1)
|
||||
..add('customValue2', customValue2)
|
||||
..add('customValue3', customValue3)
|
||||
..add('customValue4', customValue4)
|
||||
..add('taskStatusId', taskStatusId)
|
||||
..add('taskStatusSortOrder', taskStatusSortOrder)
|
||||
..add('isChanged', isChanged)
|
||||
|
|
@ -911,6 +935,14 @@ class TaskEntityBuilder implements Builder<TaskEntity, TaskEntityBuilder> {
|
|||
String get customValue2 => _$this._customValue2;
|
||||
set customValue2(String customValue2) => _$this._customValue2 = customValue2;
|
||||
|
||||
String _customValue3;
|
||||
String get customValue3 => _$this._customValue3;
|
||||
set customValue3(String customValue3) => _$this._customValue3 = customValue3;
|
||||
|
||||
String _customValue4;
|
||||
String get customValue4 => _$this._customValue4;
|
||||
set customValue4(String customValue4) => _$this._customValue4 = customValue4;
|
||||
|
||||
String _taskStatusId;
|
||||
String get taskStatusId => _$this._taskStatusId;
|
||||
set taskStatusId(String taskStatusId) => _$this._taskStatusId = taskStatusId;
|
||||
|
|
@ -967,6 +999,8 @@ class TaskEntityBuilder implements Builder<TaskEntity, TaskEntityBuilder> {
|
|||
_isRunning = _$v.isRunning;
|
||||
_customValue1 = _$v.customValue1;
|
||||
_customValue2 = _$v.customValue2;
|
||||
_customValue3 = _$v.customValue3;
|
||||
_customValue4 = _$v.customValue4;
|
||||
_taskStatusId = _$v.taskStatusId;
|
||||
_taskStatusSortOrder = _$v.taskStatusSortOrder;
|
||||
_isChanged = _$v.isChanged;
|
||||
|
|
@ -1008,6 +1042,8 @@ class TaskEntityBuilder implements Builder<TaskEntity, TaskEntityBuilder> {
|
|||
isRunning: isRunning,
|
||||
customValue1: customValue1,
|
||||
customValue2: customValue2,
|
||||
customValue3: customValue3,
|
||||
customValue4: customValue4,
|
||||
taskStatusId: taskStatusId,
|
||||
taskStatusSortOrder: taskStatusSortOrder,
|
||||
isChanged: isChanged,
|
||||
|
|
|
|||
|
|
@ -154,6 +154,12 @@ abstract class VendorEntity extends Object
|
|||
@BuiltValueField(wireName: 'custom_value2')
|
||||
String get customValue2;
|
||||
|
||||
@BuiltValueField(wireName: 'custom_value3')
|
||||
String get customValue3;
|
||||
|
||||
@BuiltValueField(wireName: 'custom_value4')
|
||||
String get customValue4;
|
||||
|
||||
@BuiltValueField(wireName: 'vendor_contacts')
|
||||
BuiltList<VendorContactEntity> get contacts;
|
||||
|
||||
|
|
@ -223,6 +229,14 @@ abstract class VendorEntity extends Object
|
|||
.where((contact) => contact.matchesFilter(filter))
|
||||
.isNotEmpty) {
|
||||
return true;
|
||||
} else if (customValue1.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue2.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue3.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
} else if (customValue4.toLowerCase().contains(filter)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
|
|
@ -252,6 +266,14 @@ abstract class VendorEntity extends Object
|
|||
} else if (contact != null) {
|
||||
final match = contact.matchesFilterValue(filter);
|
||||
return match == name ? null : match;
|
||||
} else if (customValue1.toLowerCase().contains(filter)) {
|
||||
return customValue1;
|
||||
} else if (customValue2.toLowerCase().contains(filter)) {
|
||||
return customValue2;
|
||||
} else if (customValue3.toLowerCase().contains(filter)) {
|
||||
return customValue3;
|
||||
} else if (customValue4.toLowerCase().contains(filter)) {
|
||||
return customValue4;
|
||||
}
|
||||
|
||||
return null;
|
||||
|
|
|
|||
|
|
@ -164,6 +164,12 @@ class _$VendorEntitySerializer implements StructuredSerializer<VendorEntity> {
|
|||
'custom_value2',
|
||||
serializers.serialize(object.customValue2,
|
||||
specifiedType: const FullType(String)),
|
||||
'custom_value3',
|
||||
serializers.serialize(object.customValue3,
|
||||
specifiedType: const FullType(String)),
|
||||
'custom_value4',
|
||||
serializers.serialize(object.customValue4,
|
||||
specifiedType: const FullType(String)),
|
||||
'vendor_contacts',
|
||||
serializers.serialize(object.contacts,
|
||||
specifiedType: const FullType(
|
||||
|
|
@ -303,6 +309,14 @@ class _$VendorEntitySerializer implements StructuredSerializer<VendorEntity> {
|
|||
result.customValue2 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'custom_value3':
|
||||
result.customValue3 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'custom_value4':
|
||||
result.customValue4 = serializers.deserialize(value,
|
||||
specifiedType: const FullType(String)) as String;
|
||||
break;
|
||||
case 'vendor_contacts':
|
||||
result.contacts.replace(serializers.deserialize(value,
|
||||
specifiedType: const FullType(
|
||||
|
|
@ -728,6 +742,10 @@ class _$VendorEntity extends VendorEntity {
|
|||
@override
|
||||
final String customValue2;
|
||||
@override
|
||||
final String customValue3;
|
||||
@override
|
||||
final String customValue4;
|
||||
@override
|
||||
final BuiltList<VendorContactEntity> contacts;
|
||||
@override
|
||||
final bool isChanged;
|
||||
|
|
@ -768,6 +786,8 @@ class _$VendorEntity extends VendorEntity {
|
|||
this.currencyId,
|
||||
this.customValue1,
|
||||
this.customValue2,
|
||||
this.customValue3,
|
||||
this.customValue4,
|
||||
this.contacts,
|
||||
this.isChanged,
|
||||
this.createdAt,
|
||||
|
|
@ -832,6 +852,12 @@ class _$VendorEntity extends VendorEntity {
|
|||
if (customValue2 == null) {
|
||||
throw new BuiltValueNullFieldError('VendorEntity', 'customValue2');
|
||||
}
|
||||
if (customValue3 == null) {
|
||||
throw new BuiltValueNullFieldError('VendorEntity', 'customValue3');
|
||||
}
|
||||
if (customValue4 == null) {
|
||||
throw new BuiltValueNullFieldError('VendorEntity', 'customValue4');
|
||||
}
|
||||
if (contacts == null) {
|
||||
throw new BuiltValueNullFieldError('VendorEntity', 'contacts');
|
||||
}
|
||||
|
|
@ -866,6 +892,8 @@ class _$VendorEntity extends VendorEntity {
|
|||
currencyId == other.currencyId &&
|
||||
customValue1 == other.customValue1 &&
|
||||
customValue2 == other.customValue2 &&
|
||||
customValue3 == other.customValue3 &&
|
||||
customValue4 == other.customValue4 &&
|
||||
contacts == other.contacts &&
|
||||
isChanged == other.isChanged &&
|
||||
createdAt == other.createdAt &&
|
||||
|
|
@ -897,17 +925,17 @@ class _$VendorEntity extends VendorEntity {
|
|||
$jc(
|
||||
$jc(
|
||||
$jc(
|
||||
$jc($jc($jc($jc($jc($jc($jc($jc($jc(0, name.hashCode), balance.hashCode), paidToDate.hashCode), address1.hashCode), address2.hashCode), city.hashCode), state.hashCode), postalCode.hashCode),
|
||||
countryId.hashCode),
|
||||
workPhone.hashCode),
|
||||
privateNotes.hashCode),
|
||||
lastLogin.hashCode),
|
||||
website.hashCode),
|
||||
vatNumber.hashCode),
|
||||
idNumber.hashCode),
|
||||
currencyId.hashCode),
|
||||
customValue1.hashCode),
|
||||
customValue2.hashCode),
|
||||
$jc($jc($jc($jc($jc($jc($jc($jc($jc($jc($jc(0, name.hashCode), balance.hashCode), paidToDate.hashCode), address1.hashCode), address2.hashCode), city.hashCode), state.hashCode), postalCode.hashCode), countryId.hashCode), workPhone.hashCode),
|
||||
privateNotes.hashCode),
|
||||
lastLogin.hashCode),
|
||||
website.hashCode),
|
||||
vatNumber.hashCode),
|
||||
idNumber.hashCode),
|
||||
currencyId.hashCode),
|
||||
customValue1.hashCode),
|
||||
customValue2.hashCode),
|
||||
customValue3.hashCode),
|
||||
customValue4.hashCode),
|
||||
contacts.hashCode),
|
||||
isChanged.hashCode),
|
||||
createdAt.hashCode),
|
||||
|
|
@ -940,6 +968,8 @@ class _$VendorEntity extends VendorEntity {
|
|||
..add('currencyId', currencyId)
|
||||
..add('customValue1', customValue1)
|
||||
..add('customValue2', customValue2)
|
||||
..add('customValue3', customValue3)
|
||||
..add('customValue4', customValue4)
|
||||
..add('contacts', contacts)
|
||||
..add('isChanged', isChanged)
|
||||
..add('createdAt', createdAt)
|
||||
|
|
@ -1029,6 +1059,14 @@ class VendorEntityBuilder
|
|||
String get customValue2 => _$this._customValue2;
|
||||
set customValue2(String customValue2) => _$this._customValue2 = customValue2;
|
||||
|
||||
String _customValue3;
|
||||
String get customValue3 => _$this._customValue3;
|
||||
set customValue3(String customValue3) => _$this._customValue3 = customValue3;
|
||||
|
||||
String _customValue4;
|
||||
String get customValue4 => _$this._customValue4;
|
||||
set customValue4(String customValue4) => _$this._customValue4 = customValue4;
|
||||
|
||||
ListBuilder<VendorContactEntity> _contacts;
|
||||
ListBuilder<VendorContactEntity> get contacts =>
|
||||
_$this._contacts ??= new ListBuilder<VendorContactEntity>();
|
||||
|
|
@ -1091,6 +1129,8 @@ class VendorEntityBuilder
|
|||
_currencyId = _$v.currencyId;
|
||||
_customValue1 = _$v.customValue1;
|
||||
_customValue2 = _$v.customValue2;
|
||||
_customValue3 = _$v.customValue3;
|
||||
_customValue4 = _$v.customValue4;
|
||||
_contacts = _$v.contacts?.toBuilder();
|
||||
_isChanged = _$v.isChanged;
|
||||
_createdAt = _$v.createdAt;
|
||||
|
|
@ -1142,6 +1182,8 @@ class VendorEntityBuilder
|
|||
currencyId: currencyId,
|
||||
customValue1: customValue1,
|
||||
customValue2: customValue2,
|
||||
customValue3: customValue3,
|
||||
customValue4: customValue4,
|
||||
contacts: contacts.build(),
|
||||
isChanged: isChanged,
|
||||
createdAt: createdAt,
|
||||
|
|
|
|||
Loading…
Reference in New Issue