public MembershipCategoryModel(MembershipCategory membershipCategory) { _membershipCategory = membershipCategory; //if (_membershipCategory.MembershipCategoryGroupDefaults.FirstOrDefault() != null) if (_membershipCategory.MembershipCategoryGroupDefault != null) { MembershipCategoryGroupDefault = new MembershipCategoryGroupDefaultModel(_membershipCategory.MembershipCategoryGroupDefault); } //if (_membershipCategory.MembershipFullPaymentComponents.FirstOrDefault() != null) if (_membershipCategory.MembershipFullPaymentComponent != null) { MembershipFullPaymentComponent = new MembershipFullPaymentCostModel(_membershipCategory.MembershipFullPaymentComponent); } //if (_membershipCategory.MembershipMonthlyPaymentUpFrontCosts.FirstOrDefault() != null) if (_membershipCategory.MembershipMonthlyPaymentUpFrontCost != null) { MembershipMonthlyPaymentUpFrontCost = new MembershipMonthlyPaymentUpFrontCostModel(_membershipCategory.MembershipMonthlyPaymentUpFrontCost); } //if (_membershipCategory.MembershipMonthlyPaymentOngoingCosts.FirstOrDefault() != null) if (_membershipCategory.MembershipMonthlyPaymentOngoingCost != null) { MembershipMonthlyPaymentOngoingCost = new MembershipMonthlyPaymentOngoingCostModel(_membershipCategory.MembershipMonthlyPaymentOngoingCost); } }
public MembershipCategoryModel(MembershipCategory membershipCategory) { _membershipCategory = membershipCategory; //if (_membershipCategory.MembershipCategoryGroupDefaults.FirstOrDefault() != null) if (_membershipCategory.MembershipCategoryGroupDefault != null) MembershipCategoryGroupDefault = new MembershipCategoryGroupDefaultModel(_membershipCategory.MembershipCategoryGroupDefault); //if (_membershipCategory.MembershipFullPaymentComponents.FirstOrDefault() != null) if (_membershipCategory.MembershipFullPaymentComponent != null) MembershipFullPaymentComponent = new MembershipFullPaymentCostModel(_membershipCategory.MembershipFullPaymentComponent); //if (_membershipCategory.MembershipMonthlyPaymentUpFrontCosts.FirstOrDefault() != null) if (_membershipCategory.MembershipMonthlyPaymentUpFrontCost != null) MembershipMonthlyPaymentUpFrontCost = new MembershipMonthlyPaymentUpFrontCostModel(_membershipCategory.MembershipMonthlyPaymentUpFrontCost); //if (_membershipCategory.MembershipMonthlyPaymentOngoingCosts.FirstOrDefault() != null) if (_membershipCategory.MembershipMonthlyPaymentOngoingCost != null) MembershipMonthlyPaymentOngoingCost = new MembershipMonthlyPaymentOngoingCostModel(_membershipCategory.MembershipMonthlyPaymentOngoingCost); }