29 lines
856 B
C#
29 lines
856 B
C#
using System.Collections.ObjectModel;
|
|
|
|
namespace MembranePoreTester.ViewModels
|
|
{
|
|
public class MainViewModel : ViewModelBase
|
|
{
|
|
public ObservableCollection<StationItem> Stations { get; } = new();
|
|
|
|
public MainViewModel()
|
|
{
|
|
for (int i = 1; i <= 3; i++)
|
|
{
|
|
Stations.Add(new StationItem
|
|
{
|
|
Name = $"工位 {i}",
|
|
BubblePointVM = new BubblePointViewModel { StationId = i },
|
|
PoreDistributionVM = new PoreDistributionViewModel { StationId = i }
|
|
});
|
|
}
|
|
}
|
|
}
|
|
|
|
public class StationItem
|
|
{
|
|
public string Name { get; set; }
|
|
public BubblePointViewModel BubblePointVM { get; set; }
|
|
public PoreDistributionViewModel PoreDistributionVM { get; set; }
|
|
}
|
|
} |