Model changes

This commit is contained in:
Hillel Coren 2020-09-04 14:15:01 +03:00
parent 845adae414
commit 0f92358772
3 changed files with 7 additions and 43 deletions

View File

@ -81,18 +81,6 @@ const double kTableColumnWidthMax = 120;
const int kTableListWidthCutoff = 500;
const int kDefaultAnimationDuration = 500;
const int kCardTypeVisa = 1;
const int kCardTypeMasterCard = 2;
const int kCardTypeAmEx = 4;
const int kCardTypeDiners = 8;
const int kCardTypeDiscover = 16;
const String kPaymentTypeVisa = '6';
const String kPaymentTypeMasterCard = '7';
const String kPaymentTypeAmEx = '8';
const String kPaymentTypeDiners = '9';
const String kPaymentTypeDiscover = '10';
const String kPlanFree = '';
const String kPlanPro = 'pro';
const String kPlanEnterprise = 'enterprise';
@ -119,30 +107,6 @@ const String kCurrencyEuro = '3';
const String kCountryUnitedStates = '840';
/*
const EVENT_CREATE_CLIENT = 1;
const EVENT_CREATE_INVOICE = 2;
const EVENT_CREATE_QUOTE = 3;
const EVENT_CREATE_PAYMENT = 4;
const EVENT_CREATE_VENDOR = 5;
const EVENT_UPDATE_QUOTE = 6;
const EVENT_DELETE_QUOTE = 7;
const EVENT_UPDATE_INVOICE = 8;
const EVENT_DELETE_INVOICE = 9;
const EVENT_UPDATE_CLIENT = 10;
const EVENT_DELETE_CLIENT = 11;
const EVENT_DELETE_PAYMENT = 12;
const EVENT_UPDATE_VENDOR = 13;
const EVENT_DELETE_VENDOR = 14;
const EVENT_CREATE_EXPENSE = 15;
const EVENT_UPDATE_EXPENSE = 16;
const EVENT_DELETE_EXPENSE = 17;
const EVENT_CREATE_TASK = 18;
const EVENT_UPDATE_TASK = 19;
const EVENT_DELETE_TASK = 20;
const EVENT_APPROVE_QUOTE = 21;
*/
const String kInvoiceStatusPastDue = '-1';
const String kInvoiceStatusDraft = '1';
const String kInvoiceStatusSent = '2';

View File

@ -196,7 +196,7 @@ abstract class GatewayTokenMetaEntity
String get last4;
@nullable
String get type;
int get type;
@nullable
@BuiltValueField(wireName: 'exp_month')

View File

@ -286,7 +286,7 @@ class _$GatewayTokenMetaEntitySerializer
result
..add('type')
..add(serializers.serialize(object.type,
specifiedType: const FullType(String)));
specifiedType: const FullType(int)));
}
if (object.expMonth != null) {
result
@ -325,7 +325,7 @@ class _$GatewayTokenMetaEntitySerializer
break;
case 'type':
result.type = serializers.deserialize(value,
specifiedType: const FullType(String)) as String;
specifiedType: const FullType(int)) as int;
break;
case 'exp_month':
result.expMonth = serializers.deserialize(value,
@ -847,7 +847,7 @@ class _$GatewayTokenMetaEntity extends GatewayTokenMetaEntity {
@override
final String last4;
@override
final String type;
final int type;
@override
final String expMonth;
@override
@ -914,9 +914,9 @@ class GatewayTokenMetaEntityBuilder
String get last4 => _$this._last4;
set last4(String last4) => _$this._last4 = last4;
String _type;
String get type => _$this._type;
set type(String type) => _$this._type = type;
int _type;
int get type => _$this._type;
set type(int type) => _$this._type = type;
String _expMonth;
String get expMonth => _$this._expMonth;