This commit is contained in:
@@ -1121,3 +1121,289 @@ Map<String, dynamic> _$$ExclusiveSummaryTransactionDtoImplToJson(
|
||||
'amount': instance.amount,
|
||||
'source': instance.source,
|
||||
};
|
||||
|
||||
_$ProfitSharingDtoImpl _$$ProfitSharingDtoImplFromJson(
|
||||
Map<String, dynamic> json,
|
||||
) => _$ProfitSharingDtoImpl(
|
||||
organizationId: json['organization_id'] as String?,
|
||||
outletId: json['outlet_id'] as String?,
|
||||
outletName: json['outlet_name'] as String?,
|
||||
dateFrom: json['date_from'] == null
|
||||
? null
|
||||
: DateTime.parse(json['date_from'] as String),
|
||||
dateTo: json['date_to'] == null
|
||||
? null
|
||||
: DateTime.parse(json['date_to'] as String),
|
||||
data: (json['data'] as List<dynamic>?)
|
||||
?.map((e) => ProfitSharingCategoryDto.fromJson(e as Map<String, dynamic>))
|
||||
.toList(),
|
||||
budget: json['budget'] == null
|
||||
? null
|
||||
: ProfitSharingBudgetDto.fromJson(json['budget'] as Map<String, dynamic>),
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$ProfitSharingDtoImplToJson(
|
||||
_$ProfitSharingDtoImpl instance,
|
||||
) => <String, dynamic>{
|
||||
'organization_id': instance.organizationId,
|
||||
'outlet_id': instance.outletId,
|
||||
'outlet_name': instance.outletName,
|
||||
'date_from': instance.dateFrom?.toIso8601String(),
|
||||
'date_to': instance.dateTo?.toIso8601String(),
|
||||
'data': instance.data,
|
||||
'budget': instance.budget,
|
||||
};
|
||||
|
||||
_$ProfitSharingCategoryDtoImpl _$$ProfitSharingCategoryDtoImplFromJson(
|
||||
Map<String, dynamic> json,
|
||||
) => _$ProfitSharingCategoryDtoImpl(
|
||||
parentCategoryId: json['parent_category_id'] as String?,
|
||||
parentCategoryName: json['parent_category_name'] as String?,
|
||||
totalRevenue: json['total_revenue'] as num?,
|
||||
totalQuantity: json['total_quantity'] as num?,
|
||||
categoryCount: json['category_count'] as num?,
|
||||
productCount: json['product_count'] as num?,
|
||||
orderCount: json['order_count'] as num?,
|
||||
totalStandardHpp: json['total_standard_hpp'] as num?,
|
||||
totalFifoHpp: json['total_fifo_hpp'] as num?,
|
||||
totalMovingAverageHpp: json['total_moving_average_hpp'] as num?,
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$ProfitSharingCategoryDtoImplToJson(
|
||||
_$ProfitSharingCategoryDtoImpl instance,
|
||||
) => <String, dynamic>{
|
||||
'parent_category_id': instance.parentCategoryId,
|
||||
'parent_category_name': instance.parentCategoryName,
|
||||
'total_revenue': instance.totalRevenue,
|
||||
'total_quantity': instance.totalQuantity,
|
||||
'category_count': instance.categoryCount,
|
||||
'product_count': instance.productCount,
|
||||
'order_count': instance.orderCount,
|
||||
'total_standard_hpp': instance.totalStandardHpp,
|
||||
'total_fifo_hpp': instance.totalFifoHpp,
|
||||
'total_moving_average_hpp': instance.totalMovingAverageHpp,
|
||||
};
|
||||
|
||||
_$ProfitSharingBudgetDtoImpl _$$ProfitSharingBudgetDtoImplFromJson(
|
||||
Map<String, dynamic> json,
|
||||
) => _$ProfitSharingBudgetDtoImpl(
|
||||
percentages: json['percentages'] == null
|
||||
? null
|
||||
: ProfitSharingPercentageDto.fromJson(
|
||||
json['percentages'] as Map<String, dynamic>,
|
||||
),
|
||||
cutOffFrom: json['cut_off_from'] == null
|
||||
? null
|
||||
: DateTime.parse(json['cut_off_from'] as String),
|
||||
cutOffTo: json['cut_off_to'] == null
|
||||
? null
|
||||
: DateTime.parse(json['cut_off_to'] as String),
|
||||
total: json['total'] == null
|
||||
? null
|
||||
: ProfitSharingPeriodDto.fromJson(json['total'] as Map<String, dynamic>),
|
||||
weekly: (json['weekly'] as List<dynamic>?)
|
||||
?.map((e) => ProfitSharingPeriodDto.fromJson(e as Map<String, dynamic>))
|
||||
.toList(),
|
||||
monthly: (json['monthly'] as List<dynamic>?)
|
||||
?.map((e) => ProfitSharingPeriodDto.fromJson(e as Map<String, dynamic>))
|
||||
.toList(),
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$ProfitSharingBudgetDtoImplToJson(
|
||||
_$ProfitSharingBudgetDtoImpl instance,
|
||||
) => <String, dynamic>{
|
||||
'percentages': instance.percentages,
|
||||
'cut_off_from': instance.cutOffFrom?.toIso8601String(),
|
||||
'cut_off_to': instance.cutOffTo?.toIso8601String(),
|
||||
'total': instance.total,
|
||||
'weekly': instance.weekly,
|
||||
'monthly': instance.monthly,
|
||||
};
|
||||
|
||||
_$ProfitSharingPercentageDtoImpl _$$ProfitSharingPercentageDtoImplFromJson(
|
||||
Map<String, dynamic> json,
|
||||
) => _$ProfitSharingPercentageDtoImpl(
|
||||
purchase: json['purchase'] as num?,
|
||||
owner: json['owner'] as num?,
|
||||
team: json['team'] as num?,
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$ProfitSharingPercentageDtoImplToJson(
|
||||
_$ProfitSharingPercentageDtoImpl instance,
|
||||
) => <String, dynamic>{
|
||||
'purchase': instance.purchase,
|
||||
'owner': instance.owner,
|
||||
'team': instance.team,
|
||||
};
|
||||
|
||||
_$ProfitSharingPeriodDtoImpl _$$ProfitSharingPeriodDtoImplFromJson(
|
||||
Map<String, dynamic> json,
|
||||
) => _$ProfitSharingPeriodDtoImpl(
|
||||
periodStart: json['period_start'] == null
|
||||
? null
|
||||
: DateTime.parse(json['period_start'] as String),
|
||||
periodEnd: json['period_end'] == null
|
||||
? null
|
||||
: DateTime.parse(json['period_end'] as String),
|
||||
revenue: json['revenue'] as num?,
|
||||
orderCount: json['order_count'] as num?,
|
||||
limitPurchase: json['limit_purchase'] as num?,
|
||||
limitOwner: json['limit_owner'] as num?,
|
||||
limitTeam: json['limit_team'] as num?,
|
||||
month: json['month'] as String?,
|
||||
weekCount: json['week_count'] as num?,
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$ProfitSharingPeriodDtoImplToJson(
|
||||
_$ProfitSharingPeriodDtoImpl instance,
|
||||
) => <String, dynamic>{
|
||||
'period_start': instance.periodStart?.toIso8601String(),
|
||||
'period_end': instance.periodEnd?.toIso8601String(),
|
||||
'revenue': instance.revenue,
|
||||
'order_count': instance.orderCount,
|
||||
'limit_purchase': instance.limitPurchase,
|
||||
'limit_owner': instance.limitOwner,
|
||||
'limit_team': instance.limitTeam,
|
||||
'month': instance.month,
|
||||
'week_count': instance.weekCount,
|
||||
};
|
||||
|
||||
_$ProfitSharingDetailDtoImpl _$$ProfitSharingDetailDtoImplFromJson(
|
||||
Map<String, dynamic> json,
|
||||
) => _$ProfitSharingDetailDtoImpl(
|
||||
organizationId: json['organization_id'] as String?,
|
||||
outletId: json['outlet_id'] as String?,
|
||||
outletName: json['outlet_name'] as String?,
|
||||
dateFrom: json['date_from'] == null
|
||||
? null
|
||||
: DateTime.parse(json['date_from'] as String),
|
||||
dateTo: json['date_to'] == null
|
||||
? null
|
||||
: DateTime.parse(json['date_to'] as String),
|
||||
parentCategoryId: json['parent_category_id'] as String?,
|
||||
parentCategoryName: json['parent_category_name'] as String?,
|
||||
summary: json['summary'] == null
|
||||
? null
|
||||
: ProfitSharingSummaryDto.fromJson(
|
||||
json['summary'] as Map<String, dynamic>,
|
||||
),
|
||||
categories: (json['categories'] as List<dynamic>?)
|
||||
?.map(
|
||||
(e) => ProfitSharingSubCategoryDto.fromJson(e as Map<String, dynamic>),
|
||||
)
|
||||
.toList(),
|
||||
budget: json['budget'] == null
|
||||
? null
|
||||
: ProfitSharingBudgetDto.fromJson(json['budget'] as Map<String, dynamic>),
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$ProfitSharingDetailDtoImplToJson(
|
||||
_$ProfitSharingDetailDtoImpl instance,
|
||||
) => <String, dynamic>{
|
||||
'organization_id': instance.organizationId,
|
||||
'outlet_id': instance.outletId,
|
||||
'outlet_name': instance.outletName,
|
||||
'date_from': instance.dateFrom?.toIso8601String(),
|
||||
'date_to': instance.dateTo?.toIso8601String(),
|
||||
'parent_category_id': instance.parentCategoryId,
|
||||
'parent_category_name': instance.parentCategoryName,
|
||||
'summary': instance.summary,
|
||||
'categories': instance.categories,
|
||||
'budget': instance.budget,
|
||||
};
|
||||
|
||||
_$ProfitSharingSummaryDtoImpl _$$ProfitSharingSummaryDtoImplFromJson(
|
||||
Map<String, dynamic> json,
|
||||
) => _$ProfitSharingSummaryDtoImpl(
|
||||
totalRevenue: json['total_revenue'] as num?,
|
||||
totalQuantity: json['total_quantity'] as num?,
|
||||
categoryCount: json['category_count'] as num?,
|
||||
productCount: json['product_count'] as num?,
|
||||
orderCount: json['order_count'] as num?,
|
||||
totalStandardHpp: json['total_standard_hpp'] as num?,
|
||||
totalFifoHpp: json['total_fifo_hpp'] as num?,
|
||||
totalMovingAverageHpp: json['total_moving_average_hpp'] as num?,
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$ProfitSharingSummaryDtoImplToJson(
|
||||
_$ProfitSharingSummaryDtoImpl instance,
|
||||
) => <String, dynamic>{
|
||||
'total_revenue': instance.totalRevenue,
|
||||
'total_quantity': instance.totalQuantity,
|
||||
'category_count': instance.categoryCount,
|
||||
'product_count': instance.productCount,
|
||||
'order_count': instance.orderCount,
|
||||
'total_standard_hpp': instance.totalStandardHpp,
|
||||
'total_fifo_hpp': instance.totalFifoHpp,
|
||||
'total_moving_average_hpp': instance.totalMovingAverageHpp,
|
||||
};
|
||||
|
||||
_$ProfitSharingSubCategoryDtoImpl _$$ProfitSharingSubCategoryDtoImplFromJson(
|
||||
Map<String, dynamic> json,
|
||||
) => _$ProfitSharingSubCategoryDtoImpl(
|
||||
categoryId: json['category_id'] as String?,
|
||||
categoryName: json['category_name'] as String?,
|
||||
totalRevenue: json['total_revenue'] as num?,
|
||||
totalQuantity: json['total_quantity'] as num?,
|
||||
productCount: json['product_count'] as num?,
|
||||
orderCount: json['order_count'] as num?,
|
||||
totalStandardHpp: json['total_standard_hpp'] as num?,
|
||||
totalFifoHpp: json['total_fifo_hpp'] as num?,
|
||||
totalMovingAverageHpp: json['total_moving_average_hpp'] as num?,
|
||||
products: (json['products'] as List<dynamic>?)
|
||||
?.map((e) => ProfitSharingProductDto.fromJson(e as Map<String, dynamic>))
|
||||
.toList(),
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$ProfitSharingSubCategoryDtoImplToJson(
|
||||
_$ProfitSharingSubCategoryDtoImpl instance,
|
||||
) => <String, dynamic>{
|
||||
'category_id': instance.categoryId,
|
||||
'category_name': instance.categoryName,
|
||||
'total_revenue': instance.totalRevenue,
|
||||
'total_quantity': instance.totalQuantity,
|
||||
'product_count': instance.productCount,
|
||||
'order_count': instance.orderCount,
|
||||
'total_standard_hpp': instance.totalStandardHpp,
|
||||
'total_fifo_hpp': instance.totalFifoHpp,
|
||||
'total_moving_average_hpp': instance.totalMovingAverageHpp,
|
||||
'products': instance.products,
|
||||
};
|
||||
|
||||
_$ProfitSharingProductDtoImpl _$$ProfitSharingProductDtoImplFromJson(
|
||||
Map<String, dynamic> json,
|
||||
) => _$ProfitSharingProductDtoImpl(
|
||||
productId: json['product_id'] as String?,
|
||||
productName: json['product_name'] as String?,
|
||||
productSku: json['product_sku'] as String?,
|
||||
productPrice: json['product_price'] as num?,
|
||||
quantitySold: json['quantity_sold'] as num?,
|
||||
revenue: json['revenue'] as num?,
|
||||
averagePrice: json['average_price'] as num?,
|
||||
orderCount: json['order_count'] as num?,
|
||||
standardHppPerUnit: json['standard_hpp_per_unit'] as num?,
|
||||
standardHppTotal: json['standard_hpp_total'] as num?,
|
||||
fifoHppPerUnit: json['fifo_hpp_per_unit'] as num?,
|
||||
fifoHppTotal: json['fifo_hpp_total'] as num?,
|
||||
movingAverageHppPerUnit: json['moving_average_hpp_per_unit'] as num?,
|
||||
movingAverageHppTotal: json['moving_average_hpp_total'] as num?,
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$ProfitSharingProductDtoImplToJson(
|
||||
_$ProfitSharingProductDtoImpl instance,
|
||||
) => <String, dynamic>{
|
||||
'product_id': instance.productId,
|
||||
'product_name': instance.productName,
|
||||
'product_sku': instance.productSku,
|
||||
'product_price': instance.productPrice,
|
||||
'quantity_sold': instance.quantitySold,
|
||||
'revenue': instance.revenue,
|
||||
'average_price': instance.averagePrice,
|
||||
'order_count': instance.orderCount,
|
||||
'standard_hpp_per_unit': instance.standardHppPerUnit,
|
||||
'standard_hpp_total': instance.standardHppTotal,
|
||||
'fifo_hpp_per_unit': instance.fifoHppPerUnit,
|
||||
'fifo_hpp_total': instance.fifoHppTotal,
|
||||
'moving_average_hpp_per_unit': instance.movingAverageHppPerUnit,
|
||||
'moving_average_hpp_total': instance.movingAverageHppTotal,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user