Update 20260417

This commit is contained in:
Stefan Hutter
2026-04-17 10:48:36 +02:00
parent a110be5021
commit c60ba71f9d
116 changed files with 3000 additions and 53 deletions

View File

@@ -474,6 +474,7 @@ namespace API_NetFramework.Controllers
{
mailbody = mailbody + "Parnternr:" + paket.Dokumente[0].PartnerNr + " ";
int anhangnr = 0;
foreach (APIDokument dokument in paket.Dokumente)
{
if (dokument.PDFDoc != "" && dokument.PDFDoc != null)
@@ -494,6 +495,7 @@ namespace API_NetFramework.Controllers
OnDocAPI_NetFramework.Helper.Helper.CopyProperties(dokdata, docgendata);
OnDocAPI_NetFramework.Helper.Helper.CopyProperties(dokument, doccreate);
doccreate.Reference = paket.Reference;
doccreate.ResultFileType = paket.ResultFileType;
dokument.DokumentID = gendoc(ref doccreate, ref dokdata, ref docgendata, key.ToString());
dokument.DokumentID = dokdata.Dokumentid;
@@ -1317,10 +1319,7 @@ namespace API_NetFramework.Controllers
{
CLMDocItem d = new CLMDocItem();
if (dr["feldname"].ToString() == "Vertragspartner")
{
int a = 1;
}
d.itemname = "";
d.itemtag = "";
d.itemvalue = "";
@@ -1335,6 +1334,7 @@ namespace API_NetFramework.Controllers
d.width = dr["ess_img_width"].ToString();
d.height = dr["ess_img_height"].ToString();
d.itemvalue = "";
switch (d.type.ToString())
{
case "1":
@@ -1806,6 +1806,14 @@ namespace API_NetFramework.Controllers
;
Database.DB db = new DB(connectionstring);
db.Get_Tabledata("Select * from dokumenttyp where dokumenttypnr=" + doccreate.VorlagenTypID, false, true);
try
{
if (doccreate.Bezeichnung == "")
{
doccreate.Bezeichnung = db.dsdaten.Tables[0].Rows[0]["Bezeichnung"].ToString();
}
}
catch { }
System.Data.DataRow dr = db.dsdaten.Tables[0].Rows[0];
dokdata.Barcode = Convert.ToBoolean(dr["Vertrag"]) == true;
db.Get_Tabledata("Select beschreibung from physischesarchiv where physischesarchivnr = " + dr["physisches_archiv"].ToString(), false, true);
@@ -2192,13 +2200,27 @@ namespace API_NetFramework.Controllers
DOCGEN.Generator.DocGenerator_from_EDOKA Generator = new DOCGEN.Generator.DocGenerator_from_EDOKA(this.connectionstring, OwnHost, key.ToString());
dok = Generator.Generate_Doc_EDOKA(dokumentid, ref dokdata, false, 0, false, false);
DocGet dget = new DocGet(this.connectionstring);
if (System.Configuration.ConfigurationManager.AppSettings["clmwordsave"].ToString() != "")
{
System.IO.File.WriteAllBytes(System.Configuration.ConfigurationManager.AppSettings["clmwordsave"].ToString() + dokumentid + ".docx", Convert.FromBase64String(dok.dokument));
}
if (dok.extension.ToUpper() != "PDF")
{
dok.dokument = dget.Convert_Word_To_PDF(dok.dokument);
db.Get_Tabledata("select count(*) from OnDoc_CLM_Update_PDF_Document_Fields where dokumenttypnr="+dataj.Dokumenttyp.ToString(), false, true);
if (Convert.ToInt32(db.dsdaten.Tables[0].Rows[0][0]) > 0)
{
dok.dokument = dget.Convert_Word_To_PDF(dok.dokument, null, false, false);
}
else
{
dok.dokument = dget.Convert_Word_To_PDF(dok.dokument);
}
db.Exec_SQL("update dokument set dokumentname = dokumentname + '.pdf' where dokumentid = '" + dokumentid + "'");
}
// db.Save_To_DB(dokumentid, "", dok.dokument);
// dok = dget.GetDocAsPDF(dokumentid);
dok.extension = "pdf";