Neue struktur funktioniert nun
This commit is contained in:
@@ -31,7 +31,7 @@ namespace SanSystem
|
|||||||
txt_dn.DataBindings.Add(new Binding("Text", inspektionsobjekt, "Kanalrohrweite"));
|
txt_dn.DataBindings.Add(new Binding("Text", inspektionsobjekt, "Kanalrohrweite"));
|
||||||
txt_temp_aussen.DataBindings.Add(new Binding("Text", inspektionsobjekt.Sanierung, "TempAusen"));
|
txt_temp_aussen.DataBindings.Add(new Binding("Text", inspektionsobjekt.Sanierung, "TempAusen"));
|
||||||
txt_temp_kanal.DataBindings.Add(new Binding("Text", inspektionsobjekt.Sanierung, "tempKanal"));
|
txt_temp_kanal.DataBindings.Add(new Binding("Text", inspektionsobjekt.Sanierung, "tempKanal"));
|
||||||
txt_pro_nr.DataBindings.Add(new Binding("Text", inspektionsobjekt.Sanierung, "ProjektNummer"));
|
txt_pro_nr.DataBindings.Add(new Binding("Text", inspektionsobjekt, "ProjektNummer"));
|
||||||
cb_genehmigung.DataBindings.Add(new Binding("Checked", inspektionsobjekt.Sanierung, "genehmigungVorhanden"));
|
cb_genehmigung.DataBindings.Add(new Binding("Checked", inspektionsobjekt.Sanierung, "genehmigungVorhanden"));
|
||||||
cb_stvo.DataBindings.Add(new Binding("Checked", inspektionsobjekt.Sanierung, "sTVOAbsicherung"));
|
cb_stvo.DataBindings.Add(new Binding("Checked", inspektionsobjekt.Sanierung, "sTVOAbsicherung"));
|
||||||
cb_wasserhaltung.DataBindings.Add(new Binding("Checked", inspektionsobjekt.Sanierung, "wasserhaltungEingerichtet"));
|
cb_wasserhaltung.DataBindings.Add(new Binding("Checked", inspektionsobjekt.Sanierung, "wasserhaltungEingerichtet"));
|
||||||
|
|||||||
67
SanSystem/frmObjekteList.Designer.cs
generated
67
SanSystem/frmObjekteList.Designer.cs
generated
@@ -30,13 +30,6 @@
|
|||||||
{
|
{
|
||||||
this.components = new System.ComponentModel.Container();
|
this.components = new System.ComponentModel.Container();
|
||||||
this.dGObjekte = new System.Windows.Forms.DataGridView();
|
this.dGObjekte = new System.Windows.Forms.DataGridView();
|
||||||
this.objektbezeichnungDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
|
||||||
this.vonPunktDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
|
||||||
this.bisPunktDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
|
||||||
this.rohrMaterialDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
|
||||||
this.kanalrohrweiteDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
|
||||||
this.haltungslaengeDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
|
||||||
this.sanierungDataGridViewTextBoxColumn = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
|
||||||
this.strasseBindingSource = new System.Windows.Forms.BindingSource(this.components);
|
this.strasseBindingSource = new System.Windows.Forms.BindingSource(this.components);
|
||||||
this.button1 = new System.Windows.Forms.Button();
|
this.button1 = new System.Windows.Forms.Button();
|
||||||
this.label1 = new System.Windows.Forms.Label();
|
this.label1 = new System.Windows.Forms.Label();
|
||||||
@@ -56,74 +49,16 @@
|
|||||||
// dGObjekte
|
// dGObjekte
|
||||||
//
|
//
|
||||||
this.dGObjekte.AllowUserToOrderColumns = true;
|
this.dGObjekte.AllowUserToOrderColumns = true;
|
||||||
this.dGObjekte.AutoGenerateColumns = false;
|
|
||||||
this.dGObjekte.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
this.dGObjekte.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
|
||||||
this.dGObjekte.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
|
|
||||||
this.objektbezeichnungDataGridViewTextBoxColumn,
|
|
||||||
this.vonPunktDataGridViewTextBoxColumn,
|
|
||||||
this.bisPunktDataGridViewTextBoxColumn,
|
|
||||||
this.rohrMaterialDataGridViewTextBoxColumn,
|
|
||||||
this.kanalrohrweiteDataGridViewTextBoxColumn,
|
|
||||||
this.haltungslaengeDataGridViewTextBoxColumn,
|
|
||||||
this.sanierungDataGridViewTextBoxColumn});
|
|
||||||
this.dGObjekte.DataMember = "Objekte";
|
|
||||||
this.dGObjekte.DataSource = this.strasseBindingSource;
|
|
||||||
this.dGObjekte.Location = new System.Drawing.Point(9, 133);
|
this.dGObjekte.Location = new System.Drawing.Point(9, 133);
|
||||||
this.dGObjekte.Margin = new System.Windows.Forms.Padding(2);
|
this.dGObjekte.Margin = new System.Windows.Forms.Padding(2);
|
||||||
this.dGObjekte.MultiSelect = false;
|
this.dGObjekte.MultiSelect = false;
|
||||||
this.dGObjekte.Name = "dGObjekte";
|
this.dGObjekte.Name = "dGObjekte";
|
||||||
this.dGObjekte.RowTemplate.Height = 24;
|
this.dGObjekte.RowTemplate.Height = 24;
|
||||||
this.dGObjekte.Size = new System.Drawing.Size(951, 238);
|
this.dGObjekte.Size = new System.Drawing.Size(957, 238);
|
||||||
this.dGObjekte.TabIndex = 0;
|
this.dGObjekte.TabIndex = 0;
|
||||||
this.dGObjekte.RowHeaderMouseDoubleClick += new System.Windows.Forms.DataGridViewCellMouseEventHandler(this.dGObjekte_RowHeaderMouseDoubleClick);
|
this.dGObjekte.RowHeaderMouseDoubleClick += new System.Windows.Forms.DataGridViewCellMouseEventHandler(this.dGObjekte_RowHeaderMouseDoubleClick);
|
||||||
//
|
//
|
||||||
// objektbezeichnungDataGridViewTextBoxColumn
|
|
||||||
//
|
|
||||||
this.objektbezeichnungDataGridViewTextBoxColumn.DataPropertyName = "Objektbezeichnung";
|
|
||||||
this.objektbezeichnungDataGridViewTextBoxColumn.HeaderText = "Objektbezeichnung";
|
|
||||||
this.objektbezeichnungDataGridViewTextBoxColumn.Name = "objektbezeichnungDataGridViewTextBoxColumn";
|
|
||||||
//
|
|
||||||
// vonPunktDataGridViewTextBoxColumn
|
|
||||||
//
|
|
||||||
this.vonPunktDataGridViewTextBoxColumn.DataPropertyName = "VonPunkt";
|
|
||||||
this.vonPunktDataGridViewTextBoxColumn.HeaderText = "VonPunkt";
|
|
||||||
this.vonPunktDataGridViewTextBoxColumn.Name = "vonPunktDataGridViewTextBoxColumn";
|
|
||||||
//
|
|
||||||
// bisPunktDataGridViewTextBoxColumn
|
|
||||||
//
|
|
||||||
this.bisPunktDataGridViewTextBoxColumn.DataPropertyName = "BisPunkt";
|
|
||||||
this.bisPunktDataGridViewTextBoxColumn.HeaderText = "BisPunkt";
|
|
||||||
this.bisPunktDataGridViewTextBoxColumn.Name = "bisPunktDataGridViewTextBoxColumn";
|
|
||||||
//
|
|
||||||
// rohrMaterialDataGridViewTextBoxColumn
|
|
||||||
//
|
|
||||||
this.rohrMaterialDataGridViewTextBoxColumn.DataPropertyName = "RohrMaterial";
|
|
||||||
this.rohrMaterialDataGridViewTextBoxColumn.HeaderText = "RohrMaterial";
|
|
||||||
this.rohrMaterialDataGridViewTextBoxColumn.Name = "rohrMaterialDataGridViewTextBoxColumn";
|
|
||||||
//
|
|
||||||
// kanalrohrweiteDataGridViewTextBoxColumn
|
|
||||||
//
|
|
||||||
this.kanalrohrweiteDataGridViewTextBoxColumn.DataPropertyName = "Kanalrohrweite";
|
|
||||||
this.kanalrohrweiteDataGridViewTextBoxColumn.HeaderText = "Kanalrohrweite";
|
|
||||||
this.kanalrohrweiteDataGridViewTextBoxColumn.Name = "kanalrohrweiteDataGridViewTextBoxColumn";
|
|
||||||
//
|
|
||||||
// haltungslaengeDataGridViewTextBoxColumn
|
|
||||||
//
|
|
||||||
this.haltungslaengeDataGridViewTextBoxColumn.DataPropertyName = "Haltungslaenge";
|
|
||||||
this.haltungslaengeDataGridViewTextBoxColumn.HeaderText = "Haltungslaenge";
|
|
||||||
this.haltungslaengeDataGridViewTextBoxColumn.Name = "haltungslaengeDataGridViewTextBoxColumn";
|
|
||||||
//
|
|
||||||
// sanierungDataGridViewTextBoxColumn
|
|
||||||
//
|
|
||||||
this.sanierungDataGridViewTextBoxColumn.DataPropertyName = "Sanierung";
|
|
||||||
this.sanierungDataGridViewTextBoxColumn.HeaderText = "Sanierung";
|
|
||||||
this.sanierungDataGridViewTextBoxColumn.Name = "sanierungDataGridViewTextBoxColumn";
|
|
||||||
this.sanierungDataGridViewTextBoxColumn.Visible = false;
|
|
||||||
//
|
|
||||||
// strasseBindingSource
|
|
||||||
//
|
|
||||||
//this.strasseBindingSource.DataSource = typeof(KlassenBIB.Strasse);
|
|
||||||
//
|
|
||||||
// button1
|
// button1
|
||||||
//
|
//
|
||||||
this.button1.Location = new System.Drawing.Point(763, 387);
|
this.button1.Location = new System.Drawing.Point(763, 387);
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
using KlassenBIB;
|
using Database;
|
||||||
|
using KlassenBIB;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
using System.Collections.ObjectModel;
|
using System.Collections.ObjectModel;
|
||||||
@@ -14,18 +15,31 @@ namespace SanSystem
|
|||||||
{
|
{
|
||||||
public partial class frmObjekteList : Form
|
public partial class frmObjekteList : Form
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
private List<Inspektionsobjekt> inspektionsobjekte;
|
||||||
|
|
||||||
public frmObjekteList(string streetname)
|
public frmObjekteList(string streetname)
|
||||||
{
|
{
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
|
|
||||||
|
|
||||||
|
inspektionsobjekte = Datenbank.Instance.loadedProjekt.Objekte.FindAll(x => x.StrasseName.Equals(streetname));
|
||||||
//dGObjekte.BindingContext = strasse.Objekte;
|
//dGObjekte.BindingContext = strasse.Objekte;
|
||||||
//dGObjekte.DataSource = strasse.Objekte;// bs; //strasse.Objekte;
|
dGObjekte.DataSource = inspektionsobjekte;
|
||||||
//dGObjekte.AutoGenerateColumns = false;
|
dGObjekte.AutoGenerateColumns = false;
|
||||||
|
|
||||||
|
txt_strasse.Text = streetname;
|
||||||
|
Inspektionsobjekt temp = inspektionsobjekte.Last();
|
||||||
|
txt_ort.Text = temp.OrtName;
|
||||||
|
|
||||||
|
string[] vs = temp.Projektnummer.Split('-');
|
||||||
|
if (vs.Length > 0)
|
||||||
|
txt_pro_nr_1.Text = vs[0];
|
||||||
|
if (vs.Length > 1)
|
||||||
|
txt_pro_nr_2.Text = vs[1];
|
||||||
|
if (vs.Length > 2)
|
||||||
|
txt_pro_nr_3.Text = vs[2];
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
txt_strasse.DataBindings.Add(new Binding("Text", strasse, "Strassename"));
|
txt_strasse.DataBindings.Add(new Binding("Text", strasse, "Strassename"));
|
||||||
@@ -58,6 +72,7 @@ namespace SanSystem
|
|||||||
|
|
||||||
private void dGObjekte_RowHeaderMouseDoubleClick(object sender, DataGridViewCellMouseEventArgs e)
|
private void dGObjekte_RowHeaderMouseDoubleClick(object sender, DataGridViewCellMouseEventArgs e)
|
||||||
{
|
{
|
||||||
|
|
||||||
DataGridView dataGridView = (DataGridView)sender;
|
DataGridView dataGridView = (DataGridView)sender;
|
||||||
if (dataGridView == null) return;
|
if (dataGridView == null) return;
|
||||||
DataGridViewSelectedRowCollection dataGridViewRowsSelect = dataGridView.SelectedRows;
|
DataGridViewSelectedRowCollection dataGridViewRowsSelect = dataGridView.SelectedRows;
|
||||||
@@ -74,8 +89,6 @@ namespace SanSystem
|
|||||||
frmObjektEdit.MdiParent = this.MdiParent;
|
frmObjektEdit.MdiParent = this.MdiParent;
|
||||||
frmObjektEdit.Show();
|
frmObjektEdit.Show();
|
||||||
|
|
||||||
|
|
||||||
//throw new Exception();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -24,9 +24,9 @@ namespace SanSystem
|
|||||||
|
|
||||||
private void frmStrassenList_Load(object sender, EventArgs e)
|
private void frmStrassenList_Load(object sender, EventArgs e)
|
||||||
{
|
{
|
||||||
List<string> strassen = Database.Datenbank.Instance.loadedProjekt.Objekte.Select(x => x.StrasseName).Distinct().ToList();
|
List<string> strassen = Datenbank.Instance.loadedProjekt.Objekte.Select(x => x.StrasseName).Distinct().ToList();
|
||||||
bs.DataSource = strassen;
|
//bs.DataSource = strassen;
|
||||||
lst_strassen.DataSource = bs;
|
lst_strassen.DataSource = strassen;
|
||||||
|
|
||||||
this.Height = this.MdiParent.Height - 120;
|
this.Height = this.MdiParent.Height - 120;
|
||||||
|
|
||||||
@@ -54,7 +54,7 @@ namespace SanSystem
|
|||||||
frmObjekteList frmObjekteList = new frmObjekteList(selectedStreetName);
|
frmObjekteList frmObjekteList = new frmObjekteList(selectedStreetName);
|
||||||
frmObjekteList.MdiParent = this.MdiParent;
|
frmObjekteList.MdiParent = this.MdiParent;
|
||||||
frmObjekteList.Show();
|
frmObjekteList.Show();
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user