Linergrundlagen können nun über mehrfachauswahl ausgewählt werden
This commit is contained in:
@@ -23,12 +23,7 @@ namespace SanSystem
|
||||
|
||||
private void loadObjekte(string streetname)
|
||||
{
|
||||
DataGridViewCheckBoxColumn checkBoxColumn = new DataGridViewCheckBoxColumn();
|
||||
checkBoxColumn.Name = "Auswahl";
|
||||
checkBoxColumn.HeaderText = "Auswahl";
|
||||
//checkBoxColumn.Width = objecteListSetting.configuration["Auswahl"];
|
||||
|
||||
dGObjekte.Columns.Add(checkBoxColumn);
|
||||
|
||||
dGObjekte.DataSource = null;
|
||||
inspektionsobjekte = Datenbank.Instance.loadedProjekt.Objekte.FindAll(x => x.StrasseName.Equals(streetname));
|
||||
|
||||
@@ -72,7 +67,12 @@ namespace SanSystem
|
||||
public frmObjekteList(string streetname)
|
||||
{
|
||||
InitializeComponent();
|
||||
DataGridViewCheckBoxColumn checkBoxColumn = new DataGridViewCheckBoxColumn();
|
||||
checkBoxColumn.Name = "Auswahl";
|
||||
checkBoxColumn.HeaderText = "Auswahl";
|
||||
//checkBoxColumn.Width = objecteListSetting.configuration["Auswahl"];
|
||||
|
||||
dGObjekte.Columns.Add(checkBoxColumn);
|
||||
lbl_ort.Text = Global.Instance.language.Labels["ort"];
|
||||
lbl_projekt.Text = Global.Instance.language.Labels["projekt"];
|
||||
lbl_street.Text = Global.Instance.language.Labels["street"];
|
||||
@@ -287,5 +287,38 @@ namespace SanSystem
|
||||
dataTable.Columns.Add(dataColumn);
|
||||
return dataTable;
|
||||
}
|
||||
|
||||
private void btn_set_kali_Click(object sender, EventArgs e)
|
||||
{
|
||||
List<Inspektionsobjekt> ausdruck = new List<Inspektionsobjekt>();
|
||||
|
||||
DataGridViewCheckBoxCell checkBoxCell = null;
|
||||
|
||||
foreach (DataGridViewRow dr in dGObjekte.Rows)
|
||||
{
|
||||
checkBoxCell = (DataGridViewCheckBoxCell)dr.Cells["Auswahl"];
|
||||
if (checkBoxCell == null) break;
|
||||
if (checkBoxCell.Value == null) continue;
|
||||
if ((bool)checkBoxCell.Value)
|
||||
{
|
||||
Inspektionsobjekt objekt = (dr.DataBoundItem as Inspektionsobjekt);
|
||||
bool bereitsVorhanden = false;
|
||||
foreach(Sanierung san in objekt.Sanierung)
|
||||
{
|
||||
if(san is InlinerSanierung)
|
||||
{
|
||||
bereitsVorhanden = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if(!bereitsVorhanden)
|
||||
ausdruck.Add(objekt);
|
||||
}
|
||||
}
|
||||
|
||||
if (ausdruck.Count <= 0) return;
|
||||
FrmKalibrierungFestlegung frmKalibrierungFestlegung = new FrmKalibrierungFestlegung(ausdruck);
|
||||
frmKalibrierungFestlegung.ShowDialog();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user