public CampaignDetailsViewModel(Campaign campaign, IEnumerable <CampaignOption> campaignOptions, IEnumerable <CampaignAccount> campaignAccounts, IEnumerable <Transaction> transactions) : base(campaign) { EnabledAccountChargeExtra = campaign.EnabledAccountChargeExtra; AccountChargeTime = campaign.AccountChargeTime; campaignAccounts = campaignAccounts.Where(m => m.Status != CampaignAccountStatus.Canceled); Payment = new CampaignPaymentModel(campaign, campaignOptions, campaignAccounts, transactions); Transactions = TransactionViewModel.GetList(transactions); CampaignAccounts = CampaignAccountViewModel.GetList(campaignAccounts); }
public CampaignWithAccountViewModel(Campaign campaign, CampaignAccount campaignAccount) : base(campaign) { CampaignAccount = new CampaignAccountViewModel(campaignAccount); }