update 20250119

This commit is contained in:
Stefan Hutter
2025-01-19 21:13:37 +01:00
parent bc996921a1
commit 578525cfc4
73 changed files with 271 additions and 134 deletions

View File

@@ -36,6 +36,8 @@ namespace OnDoc.UICintrols
this.dokumentAnzeigenToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.dokumentBearbeitenToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.dokumentLöschenToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.toolStripMenuItem2 = new System.Windows.Forms.ToolStripSeparator();
this.zurUnterschriftenPrüfungToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.archivierenToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.druckenToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.dokumentKopierenToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
@@ -154,8 +156,6 @@ namespace OnDoc.UICintrols
this.RibbonButtonCreateNewDoc = new System.Windows.Forms.RibbonButton();
this.ribbonButton5 = new System.Windows.Forms.RibbonButton();
this.dokwerte1 = new OnDoc.UIControls.Dokwerte();
this.toolStripMenuItem2 = new System.Windows.Forms.ToolStripSeparator();
this.zurUnterschriftenPrüfungToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.ctxMenuDokList.SuspendLayout();
this.toolStrip1.SuspendLayout();
((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit();
@@ -188,7 +188,7 @@ namespace OnDoc.UICintrols
this.historyToolStripMenuItem,
this.dokumentFürPartnerErstellenToolStripMenuItem});
this.ctxMenuDokList.Name = "ctxMenuDokList";
this.ctxMenuDokList.Size = new System.Drawing.Size(280, 390);
this.ctxMenuDokList.Size = new System.Drawing.Size(280, 368);
//
// dokumentAnzeigenToolStripMenuItem
//
@@ -213,6 +213,19 @@ namespace OnDoc.UICintrols
this.dokumentLöschenToolStripMenuItem.Text = "Dokument löschen";
this.dokumentLöschenToolStripMenuItem.Click += new System.EventHandler(this.dokumentLöschenToolStripMenuItem_Click);
//
// toolStripMenuItem2
//
this.toolStripMenuItem2.Name = "toolStripMenuItem2";
this.toolStripMenuItem2.Size = new System.Drawing.Size(276, 6);
//
// zurUnterschriftenPrüfungToolStripMenuItem
//
this.zurUnterschriftenPrüfungToolStripMenuItem.Image = global::OnDoc.Properties.Resources.Approval_16x16_32;
this.zurUnterschriftenPrüfungToolStripMenuItem.Name = "zurUnterschriftenPrüfungToolStripMenuItem";
this.zurUnterschriftenPrüfungToolStripMenuItem.Size = new System.Drawing.Size(279, 22);
this.zurUnterschriftenPrüfungToolStripMenuItem.Text = "Zur Unterschriften-Prüfung";
this.zurUnterschriftenPrüfungToolStripMenuItem.Click += new System.EventHandler(this.zurUnterschriftenPrüfungToolStripMenuItem_Click);
//
// archivierenToolStripMenuItem
//
this.archivierenToolStripMenuItem.Image = ((System.Drawing.Image)(resources.GetObject("archivierenToolStripMenuItem.Image")));
@@ -1050,6 +1063,8 @@ namespace OnDoc.UICintrols
this.RibbonCBProfil.Name = "RibbonCBProfil";
this.RibbonCBProfil.SelectedIndex = -1;
this.RibbonCBProfil.TextBoxText = "";
this.RibbonCBProfil.DropDownItemClicked += new System.Windows.Forms.RibbonComboBox.RibbonItemEventHandler(this.RibbonCBProfil_DropDownItemClicked);
this.RibbonCBProfil.Click += new System.EventHandler(this.RibbonCBProfil_Click);
//
// ribbonButton1
//
@@ -1270,19 +1285,6 @@ namespace OnDoc.UICintrols
this.dokwerte1.Size = new System.Drawing.Size(0, 694);
this.dokwerte1.TabIndex = 7;
//
// toolStripMenuItem2
//
this.toolStripMenuItem2.Name = "toolStripMenuItem2";
this.toolStripMenuItem2.Size = new System.Drawing.Size(276, 6);
//
// zurUnterschriftenPrüfungToolStripMenuItem
//
this.zurUnterschriftenPrüfungToolStripMenuItem.Image = global::OnDoc.Properties.Resources.Approval_16x16_32;
this.zurUnterschriftenPrüfungToolStripMenuItem.Name = "zurUnterschriftenPrüfungToolStripMenuItem";
this.zurUnterschriftenPrüfungToolStripMenuItem.Size = new System.Drawing.Size(279, 22);
this.zurUnterschriftenPrüfungToolStripMenuItem.Text = "Zur Unterschriften-Prüfung";
this.zurUnterschriftenPrüfungToolStripMenuItem.Click += new System.EventHandler(this.zurUnterschriftenPrüfungToolStripMenuItem_Click);
//
// DokList
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);

View File

@@ -50,6 +50,7 @@ using Syncfusion.Data;
using Syncfusion.WinForms.Input;
using Syncfusion.Windows.Forms.CellGrid.ScrollAxis;
using Syncfusion.Windows.Forms.Edit.Utils;
using Syncfusion.WinForms.DataGrid.Serialization;
@@ -163,9 +164,11 @@ namespace OnDoc.UICintrols
Ansichten = db.dsdaten.Tables[0].Copy();
//string standardview = "";
System.Data.DataRow standardview = null;
int index = 0;
int selindex = 0;
foreach (System.Data.DataRow dr in Ansichten.Rows)
{
RibbonLabel rl = new RibbonLabel();
rl.Text = dr["bezeichnung"].ToString();
rl.Tag = Convert.ToInt32(dr["id"]);
@@ -190,16 +193,19 @@ namespace OnDoc.UICintrols
if (Convert.ToBoolean(dr["standard"]) == true && Bezeichnung == "")
{
ribbonCBAnsicht.SelectedItem = rl;
selindex = index;
standardview = dr;
//standardview = dr["gridsettings"].ToString();
}
if (rl.Text == Bezeichnung)
{
ribbonCBAnsicht.SelectedItem = rl;
//ribbonCBAnsicht.SelectedItem = rl;
//standardview = dr["gridsettings"].ToString();
standardview = dr;
}
index = index + 1;
}
if (selindex>0) { ribbonCBAnsicht.SelectedIndex=selindex; }
db = null;
// if (standardview != "") { refresh_view(standardview); }
if (standardview != null) { refresh_view(standardview); }
@@ -481,6 +487,7 @@ namespace OnDoc.UICintrols
Logging.DocLog.Info("Verantwortung für Bearbeitung übernommen", "Doklist", selected_dokumentid, selected_partnernr, "Verantwortung übernommen");
}
}
Logging.Logging.Debug("Vor Dok In Bearbeitung", "ondoc client", "");
db.Dok_in_Bearbeitung(1, selected_dokumentid, AppParams.CurrentMitarbeiter);
}
@@ -759,7 +766,7 @@ namespace OnDoc.UICintrols
public void createdocumentpaket(int partnernr, int dokumentpaketnr)
{
Dokumentpaket dp = new Dokumentpaket(dokumentpaketnr, partnernr);
Dokumentpaket dp = new Dokumentpaket(dokumentpaketnr, partnernr, this.profilnr);
dp.Show();
}
public void createnewdoc(int partnernr, int dokumenttypnr, bool Favoriten = false, string interaktion = "Yes", string showdoc = "Yes")
@@ -845,7 +852,7 @@ namespace OnDoc.UICintrols
db = null;
return;
}
Logging.Logging.Debug("Doklist Docfunction=6", "Doklist", "");
db.Dok_in_Bearbeitung(1, selected_dokumentid, AppParams.CurrentMitarbeiter);
db = null;
clsProcessWatch.AddToList(selected_dokumentid, filename, "Word");
@@ -1137,18 +1144,24 @@ namespace OnDoc.UICintrols
OfficePrinter.OnDocOffice op = new OfficePrinter.OnDocOffice();
Filename = AppParams.tempdir + dokumentid + "." + dok.extension;
fh.SaveBase64ToFile(dok.dokument, Filename);
op.PrintInWord(Filename, AppParams.wordprintmacro, AppParams.OfficeSpleep1);
string error = op.PrintInWord(Filename, AppParams.wordprintmacro, AppParams.OfficeSpleep1);
if (error != "")
{
Logging.Logging.Debug("Print Error: " + error, "OnDoc", dokumentid);
}
System.IO.File.Delete(Filename);
op = null;
break;
case "X":
System.Diagnostics.Process.Start("winword.exe", "/w " + Filename);
Filename = AppParams.tempdir + dokumentid + "." + dok.extension;
fh.SaveBase64ToFile(dok.dokument, Filename);
System.Diagnostics.Process.Start("excel.exe", "/w " + Filename);
break;
case "P":
DocPreview docPreview = new DocPreview();
docPreview.Show_Doc(dokumentid);
docPreview.printpdf();
docPreview.Dispose();
Filename = AppParams.tempdir + dokumentid + "." + dok.extension;
fh.SaveBase64ToFile(dok.dokument, Filename);
System.Diagnostics.Process.Start(Filename);
break;
default:
break;
@@ -1681,16 +1694,10 @@ return;
}
return Encoding.UTF8.GetString(Convert.FromBase64String(text));
}
//private void ribbonButton4_Click(object sender, EventArgs e)
//{
// if (System.IO.File.Exists(@"x:\gridsettings.xml"))
// {
// using (var file = File.Open(@"x:\gridsettings.xml", FileMode.Open))
// {
// this.sfDataGrid1.Deserialize(file);
// }
// }
//}
private void ribbonButton4_Click(object sender, EventArgs e)
{
}
private void ribbonCBAnsicht_DropDownItemClicked(object sender, System.Windows.Forms.RibbonItemEventArgs e)
@@ -1739,6 +1746,7 @@ return;
{
MemoryStream ms = new MemoryStream();
this.sfDataGrid1.Serialize(ms);
string inputAsString = Convert.ToBase64String(ms.ToArray());
DB db = new DB(AppParams.connectionstring);
@@ -1805,6 +1813,11 @@ return;
private void ribbonButton4_Click_1(object sender, EventArgs e)
{
//using (var file = File.Open(@"x:\DataGrid.xml", FileMode.Open))
//{
// this.sfDataGrid1.Deserialize(file);
//}
string bez = ribbonCBAnsicht.SelectedItem.Text.Trim();
string id = ribbonCBAnsicht.SelectedItem.Tag.ToString();
@@ -1819,7 +1832,12 @@ return;
db.Exec_SQL("Update mitarbeiter_gridsettings set gridsettings='" + inputAsString + "' where id=" + id.ToString());
db = null;
//using (var file = File.Create(@"x:\DataGrid.xml"))
//{
// SerializationOptions options = new SerializationOptions();
// options.SerializeSorting = false;
// this.sfDataGrid1.Serialize(file, options);
//}
}
@@ -2184,6 +2202,16 @@ return;
{
ribbonButtonToApproval_Click(sender, e);
}
private void RibbonCBProfil_Click(object sender, EventArgs e)
{
// this.profilnr = Convert.ToInt32(this.RibbonCBProfil.SelectedValue);
}
private void RibbonCBProfil_DropDownItemClicked(object sender, System.Windows.Forms.RibbonItemEventArgs e)
{
this.profilnr = Convert.ToInt32(RibbonCBProfil.SelectedItem.Tag);
}
}

View File

@@ -152,7 +152,7 @@
this.sfButton2.Name = "sfButton2";
this.sfButton2.Size = new System.Drawing.Size(108, 28);
this.sfButton2.TabIndex = 7;
this.sfButton2.Text = "Abbruch";
this.sfButton2.Text = "Abbrechen";
this.sfButton2.Click += new System.EventHandler(this.sfButton2_Click);
//
// chksaldiert

View File

@@ -262,23 +262,31 @@ namespace OnDoc.UIControls
{
}
Logging.Logging.Debug("Profilnr", "OnDOc", profilnr.ToString());
if (profilnr != 0)
{
db.Get_Tabledata("Select * from profil where profilnr=" + profilnr, false, true);
int ulinks = 0;
int urechts = 0;
try
{
ulinks = Convert.ToInt32(db.dsdaten.Tables[0].Rows[0]["unterschriftlinks"].ToString());
ulinks = Convert.ToInt32(db.dsdaten.Tables[0].Rows[0]["unterschriftlinks"]);
cbboxunterschriftlinks.SelectedValue = ulinks;
}
catch { ulinks = 0; }
catch {
ulinks = 0;
Logging.Logging.Debug("Unterschrift links nicht zugewiesen","DokPaket",ulinks.ToString()+" / "+ profilnr.ToString());
}
try
{
urechts = Convert.ToInt32(db.dsdaten.Tables[0].Rows[0]["unterschriftrechts"].ToString());
urechts = Convert.ToInt32(db.dsdaten.Tables[0].Rows[0]["unterschriftrechts"]);
cbboxunterschriftrechts.SelectedValue = urechts;
}
catch { urechts = 0; }
catch {
urechts = 0;
Logging.Logging.Debug("Unterschrift rechts nicht zugewiesen", "DokPaket", urechts.ToString() + " / " + profilnr.ToString());
}
}
System.Data.DataTable dokwertlist = new System.Data.DataTable();