Backoffice fun
This commit is contained in:
@@ -18,6 +18,30 @@ namespace PartSource.Backoffice.Components
|
||||
/// </summary>
|
||||
public partial class TaskSetup : UserControl
|
||||
{
|
||||
public IList<string> SelectedTasks
|
||||
{
|
||||
get
|
||||
{
|
||||
IList<string> selectedTasks = new List<string>();
|
||||
|
||||
foreach (object control in ContentPanel.Children)
|
||||
{
|
||||
switch (control)
|
||||
{
|
||||
case CheckBox checkbox:
|
||||
if (checkbox.IsChecked.GetValueOrDefault())
|
||||
{
|
||||
selectedTasks.Add(checkbox.Name);
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return selectedTasks;
|
||||
}
|
||||
}
|
||||
|
||||
public TaskSetup()
|
||||
{
|
||||
InitializeComponent();
|
||||
|
||||
Reference in New Issue
Block a user