update 20260308
This commit is contained in:
@@ -1099,14 +1099,16 @@ namespace API_NetFramework.Controllers
|
||||
int i = 0;
|
||||
if (archivdoc.DokumentID != "")
|
||||
{
|
||||
int id = 0;
|
||||
if (!archivdoc.Dokument.Contains("OFFEDK"))
|
||||
{
|
||||
string savedokumentid = archivdoc.DokumentID;
|
||||
DB db = new DB(connectionstring);
|
||||
try
|
||||
{
|
||||
db.Get_Tabledata("Select dokumentid from OnDoc_CLM_Dokumente where clmdokumentid='" + archivdoc.DokumentID + "'", false, true);
|
||||
archivdoc.DokumentID = db.dsdaten.Tables[0].Rows[0][0].ToString(); ;
|
||||
db.Get_Tabledata("Select id, dokumentid from OnDoc_CLM_Dokumente where aktiv=1 and clmdokumentid='" + archivdoc.DokumentID + "'", false, true);
|
||||
id = Convert.ToInt32(db.dsdaten.Tables[0].Rows[0][0]);
|
||||
archivdoc.DokumentID = db.dsdaten.Tables[0].Rows[0][1].ToString(); ;
|
||||
}
|
||||
catch
|
||||
{
|
||||
@@ -1133,6 +1135,9 @@ namespace API_NetFramework.Controllers
|
||||
apiok.code = "OK";
|
||||
apiok.status = "200";
|
||||
apiok.documentid = archivdoc.DokumentID;
|
||||
DB db = new DB(connectionstring);
|
||||
db.Exec_SQL("Update ondoc_clm_dokumente set archiviert=1, archiviert_am = getdate() where id = " + id.ToString());
|
||||
db = null;
|
||||
return Content(HttpStatusCode.OK, apiok);
|
||||
}
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user