public FrmCampaignAddUpdate() { InitializeComponent(); _campaignInfo = new CampaignInfoEx(); _campaignInfo.CampaignId = BplIdentity.Get(Guid.NewGuid().ToString()); _title = "New Campaign"; _isNew = true; }
public FrmCampaignAddUpdate(CampaignInfoEx campaignInfo) { InitializeComponent(); _campaignInfo = campaignInfo; _isNew = false; CampaignWorkStatus ws = _campaignInfo.WorkStatus; CampaignCompletionStatus cs = _campaignInfo.CompletionStatus; _title = "Campaign - " + _campaignInfo.Name + " (" + ws.ToString() + ", " + cs.ToString() + ")"; }
public CampaignListItem(CampaignInfoEx campaign) : base(campaign.Name) { /* switch (campaign.CompletionStatus) { case CampaignCompletionStatus.Failed: ForeColor = System.Drawing.Color.Red; break; case CampaignCompletionStatus.Success: ForeColor = System.Drawing.Color.Green; break; }*/ _campaign = campaign; SubItems.Add(campaign.Type.ToString()); SubItems.Add(campaign.PlatformId.LocalId.ToString()); SubItems.Add(SwlVersion.FromInt32(campaign.DstInstallVersionNumber).Format()); SubItems.Add(campaign.DateStart.ToLocalTime().Format()); SubItems.Add(campaign.WorkStatus.ToString()); SubItems.Add(campaign.CompletionStatus.ToString()); }