Datum der Sanierung kann jetzt gesetzt werden
This commit is contained in:
@@ -9,11 +9,11 @@ namespace KlassenBIB
|
||||
public abstract class Sanieren : Sanierung
|
||||
{
|
||||
Guid guid;
|
||||
DateTime datum;
|
||||
DateTime? datum;
|
||||
bool fertig = false;
|
||||
|
||||
public Guid Guid { get => guid; set => guid = value; }
|
||||
public DateTime Datum { get => datum; set => datum = value; }
|
||||
public DateTime? Datum { get => datum; set => datum = value; }
|
||||
public bool Fertig { get => fertig; set => fertig = value; }
|
||||
}
|
||||
}
|
||||
|
||||
91
SanSystem/UCInliner.Designer.cs
generated
91
SanSystem/UCInliner.Designer.cs
generated
@@ -30,6 +30,9 @@
|
||||
{
|
||||
this.tabControl1 = new System.Windows.Forms.TabControl();
|
||||
this.tabPage2 = new System.Windows.Forms.TabPage();
|
||||
this.cb_fertig = new System.Windows.Forms.CheckBox();
|
||||
this.cbb_wetter = new System.Windows.Forms.ComboBox();
|
||||
this.label24 = new System.Windows.Forms.Label();
|
||||
this.groupBox3 = new System.Windows.Forms.GroupBox();
|
||||
this.btn_get_temp = new System.Windows.Forms.Button();
|
||||
this.txt_temp_kanal = new System.Windows.Forms.TextBox();
|
||||
@@ -62,9 +65,8 @@
|
||||
this.label11 = new System.Windows.Forms.Label();
|
||||
this.label10 = new System.Windows.Forms.Label();
|
||||
this.label9 = new System.Windows.Forms.Label();
|
||||
this.cbb_wetter = new System.Windows.Forms.ComboBox();
|
||||
this.label24 = new System.Windows.Forms.Label();
|
||||
this.cb_fertig = new System.Windows.Forms.CheckBox();
|
||||
this.dt_eingebaut = new System.Windows.Forms.DateTimePicker();
|
||||
this.label1 = new System.Windows.Forms.Label();
|
||||
this.tabControl1.SuspendLayout();
|
||||
this.tabPage2.SuspendLayout();
|
||||
this.groupBox3.SuspendLayout();
|
||||
@@ -86,6 +88,8 @@
|
||||
//
|
||||
// tabPage2
|
||||
//
|
||||
this.tabPage2.Controls.Add(this.label1);
|
||||
this.tabPage2.Controls.Add(this.dt_eingebaut);
|
||||
this.tabPage2.Controls.Add(this.cb_fertig);
|
||||
this.tabPage2.Controls.Add(this.cbb_wetter);
|
||||
this.tabPage2.Controls.Add(this.label24);
|
||||
@@ -105,6 +109,42 @@
|
||||
this.tabPage2.Text = "Vorraussetzungen";
|
||||
this.tabPage2.UseVisualStyleBackColor = true;
|
||||
//
|
||||
// cb_fertig
|
||||
//
|
||||
this.cb_fertig.AutoSize = true;
|
||||
this.cb_fertig.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
|
||||
this.cb_fertig.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.cb_fertig.Location = new System.Drawing.Point(573, 347);
|
||||
this.cb_fertig.Name = "cb_fertig";
|
||||
this.cb_fertig.Size = new System.Drawing.Size(100, 35);
|
||||
this.cb_fertig.TabIndex = 25;
|
||||
this.cb_fertig.Text = "Fertig";
|
||||
this.cb_fertig.UseVisualStyleBackColor = true;
|
||||
this.cb_fertig.CheckedChanged += new System.EventHandler(this.cb_fertig_CheckedChanged);
|
||||
//
|
||||
// cbb_wetter
|
||||
//
|
||||
this.cbb_wetter.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.cbb_wetter.FormattingEnabled = true;
|
||||
this.cbb_wetter.Items.AddRange(new object[] {
|
||||
"Trocken",
|
||||
"Niederschlag",
|
||||
"Schnee - Eisschmelze"});
|
||||
this.cbb_wetter.Location = new System.Drawing.Point(205, 348);
|
||||
this.cbb_wetter.Name = "cbb_wetter";
|
||||
this.cbb_wetter.Size = new System.Drawing.Size(282, 28);
|
||||
this.cbb_wetter.TabIndex = 23;
|
||||
//
|
||||
// label24
|
||||
//
|
||||
this.label24.AutoSize = true;
|
||||
this.label24.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.label24.Location = new System.Drawing.Point(8, 351);
|
||||
this.label24.Name = "label24";
|
||||
this.label24.Size = new System.Drawing.Size(57, 20);
|
||||
this.label24.TabIndex = 24;
|
||||
this.label24.Text = "Wetter";
|
||||
//
|
||||
// groupBox3
|
||||
//
|
||||
this.groupBox3.Controls.Add(this.btn_get_temp);
|
||||
@@ -454,40 +494,21 @@
|
||||
this.label9.TabIndex = 0;
|
||||
this.label9.Text = "Harz";
|
||||
//
|
||||
// cbb_wetter
|
||||
// dt_eingebaut
|
||||
//
|
||||
this.cbb_wetter.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.cbb_wetter.FormattingEnabled = true;
|
||||
this.cbb_wetter.Items.AddRange(new object[] {
|
||||
"Trocken",
|
||||
"Niederschlag",
|
||||
"Schnee - Eisschmelze"});
|
||||
this.cbb_wetter.Location = new System.Drawing.Point(205, 348);
|
||||
this.cbb_wetter.Name = "cbb_wetter";
|
||||
this.cbb_wetter.Size = new System.Drawing.Size(282, 28);
|
||||
this.cbb_wetter.TabIndex = 23;
|
||||
this.dt_eingebaut.Location = new System.Drawing.Point(205, 434);
|
||||
this.dt_eingebaut.Name = "dt_eingebaut";
|
||||
this.dt_eingebaut.Size = new System.Drawing.Size(291, 26);
|
||||
this.dt_eingebaut.TabIndex = 26;
|
||||
//
|
||||
// label24
|
||||
// label1
|
||||
//
|
||||
this.label24.AutoSize = true;
|
||||
this.label24.Font = new System.Drawing.Font("Microsoft Sans Serif", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.label24.Location = new System.Drawing.Point(8, 351);
|
||||
this.label24.Name = "label24";
|
||||
this.label24.Size = new System.Drawing.Size(57, 20);
|
||||
this.label24.TabIndex = 24;
|
||||
this.label24.Text = "Wetter";
|
||||
//
|
||||
// cb_fertig
|
||||
//
|
||||
this.cb_fertig.AutoSize = true;
|
||||
this.cb_fertig.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
|
||||
this.cb_fertig.Font = new System.Drawing.Font("Microsoft Sans Serif", 20.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.cb_fertig.Location = new System.Drawing.Point(573, 347);
|
||||
this.cb_fertig.Name = "cb_fertig";
|
||||
this.cb_fertig.Size = new System.Drawing.Size(100, 35);
|
||||
this.cb_fertig.TabIndex = 25;
|
||||
this.cb_fertig.Text = "Fertig";
|
||||
this.cb_fertig.UseVisualStyleBackColor = true;
|
||||
this.label1.AutoSize = true;
|
||||
this.label1.Location = new System.Drawing.Point(47, 439);
|
||||
this.label1.Name = "label1";
|
||||
this.label1.Size = new System.Drawing.Size(108, 20);
|
||||
this.label1.TabIndex = 27;
|
||||
this.label1.Text = "Eingebaut am";
|
||||
//
|
||||
// UCInliner
|
||||
//
|
||||
@@ -551,5 +572,7 @@
|
||||
private System.Windows.Forms.ComboBox cbb_wetter;
|
||||
private System.Windows.Forms.Label label24;
|
||||
private System.Windows.Forms.CheckBox cb_fertig;
|
||||
private System.Windows.Forms.Label label1;
|
||||
private System.Windows.Forms.DateTimePicker dt_eingebaut;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,6 +8,8 @@ using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows.Forms;
|
||||
using KlassenBIB;
|
||||
using System.Diagnostics;
|
||||
using System.IO;
|
||||
|
||||
namespace SanSystem
|
||||
{
|
||||
@@ -67,6 +69,10 @@ namespace SanSystem
|
||||
|
||||
cb_fertig.DataBindings.Add(new Binding("Checked", inliner, "fertig"));
|
||||
cbb_wetter.DataBindings.Add(new Binding("Text", inliner, "Wetter"));
|
||||
if (inliner.Datum != null)
|
||||
dt_eingebaut.DataBindings.Add(new Binding("Value", inliner, "Datum"));
|
||||
else
|
||||
dt_eingebaut.Enabled = false;
|
||||
cb_genehmigung.DataBindings.Add(new Binding("Checked", inliner, "genehmigungVorhanden"));
|
||||
cb_stvo.DataBindings.Add(new Binding("Checked", inliner, "sTVOAbsicherung"));
|
||||
cb_wasserhaltung.DataBindings.Add(new Binding("Checked", inliner, "wasserhaltungEingerichtet"));
|
||||
@@ -74,5 +80,27 @@ namespace SanSystem
|
||||
txt_temp_kanal.DataBindings.Add(new Binding("Text", inliner, "TempKanal"));
|
||||
|
||||
}
|
||||
|
||||
private void cb_fertig_CheckedChanged(object sender, EventArgs e)
|
||||
{
|
||||
if(cb_fertig.CheckState == CheckState.Checked)
|
||||
{
|
||||
if(inliner.Datum == null)
|
||||
{
|
||||
inliner.Datum = DateTime.Now;
|
||||
dt_eingebaut.DataBindings.Clear();
|
||||
dt_eingebaut.DataBindings.Add(new Binding("Value", inliner, "Datum"));
|
||||
dt_eingebaut.Enabled = true;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void CheckDirectories()
|
||||
{
|
||||
string verzeichnispfad = string.Format("{0}-{1}")
|
||||
string path = Path.Combine("")
|
||||
if(!Directory.Exists())
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user