neu
This commit is contained in:
@@ -320,6 +320,18 @@ Public Class cWorker_NCTS
|
||||
WP.nctsWP_PACKSTUECKE.Add(PST)
|
||||
Next
|
||||
End If
|
||||
|
||||
|
||||
If GOODSITEM.Document IsNot Nothing AndAlso GOODSITEM.Document.Count > 0 Then
|
||||
For Each ULdoc In GOODSITEM.Document
|
||||
Dim UL = New DAKOSY_Worker.cDakosy_NCTSOut_WarenpositionVorgelegteUnterlagen()
|
||||
UL.nctsWpUl_Referenz = ULdoc.ReferenceNumber
|
||||
UL.nctsWpUl_Typ = ULdoc.Type
|
||||
UL.nctsWpUl_Zusatz = ULdoc.Complement
|
||||
WP.nctsWP_UNTERLAGEN.Add(UL)
|
||||
Next
|
||||
End If
|
||||
|
||||
NCTS.ncts_WARENPOS.Add(WP)
|
||||
Next
|
||||
End If
|
||||
@@ -1461,9 +1473,10 @@ Public Class cWorker_NCTS
|
||||
If DY_TMP IsNot Nothing Then STATUS.dySt_dyId = DY_TMP.dy_Id
|
||||
STATUS.SAVE()
|
||||
statusTMP = STATUS
|
||||
copyFileFTP(NCTS_TMP, DY_TMP)
|
||||
|
||||
'If If(NCTS_TMP.ncts_firma, "") = "IMEX" Then NCTS_TMP.insertIntoSpedBuch(DY_TMP)
|
||||
|
||||
' BEREITSTELLUNG DER DATEN AN FREMDSYSTEME
|
||||
cVERAG_Interface.copyFileFTP_VERAGncts_DY(NCTS_TMP, DY_TMP)
|
||||
|
||||
|
||||
NCTS_TMP.insertIntoSpedBuch(DY_TMP)
|
||||
@@ -1673,6 +1686,9 @@ Public Class cWorker_NCTS
|
||||
If DY_TMP IsNot Nothing Then STATUS.dySt_dyId = DY_TMP.dy_Id
|
||||
STATUS.SAVE()
|
||||
|
||||
' BEREITSTELLUNG DER DATEN AN FREMDSYSTEME
|
||||
cVERAG_Interface.copyFileFTP_VERAGncts_DY(NCTS_TMP, DY_TMP)
|
||||
|
||||
FORM.addDGVEinarbeitung("NCTS: Erledigungsmeldung", STATUS.dySt_BezugsNr)
|
||||
End If
|
||||
|
||||
@@ -1741,7 +1757,7 @@ Public Class cWorker_NCTS
|
||||
If DY_TMP IsNot Nothing Then STATUS.dySt_dyId = DY_TMP.dy_Id
|
||||
STATUS.SAVE()
|
||||
statusTMP = STATUS
|
||||
copyFileFTP(NCTS_TMP, DY_TMP)
|
||||
cVERAG_Interface.copyFileFTP_VERAGncts_DY(NCTS_TMP, DY_TMP)
|
||||
' If If(NCTS_TMP.ncts_firma, "") = "IMEX" Then
|
||||
|
||||
NCTS_TMP.insertIntoSpedBuch(DY_TMP)
|
||||
@@ -1816,7 +1832,7 @@ Public Class cWorker_NCTS
|
||||
If DY_TMP IsNot Nothing Then STATUS.dySt_dyId = DY_TMP.dy_Id
|
||||
STATUS.SAVE()
|
||||
statusTMP = STATUS
|
||||
copyFileFTP(NCTS_TMP, DY_TMP)
|
||||
cVERAG_Interface.copyFileFTP_VERAGncts_DY(NCTS_TMP, DY_TMP)
|
||||
' If If(NCTS_TMP.ncts_firma, "") = "IMEX" Then
|
||||
|
||||
NCTS_TMP.insertIntoSpedBuch(DY_TMP)
|
||||
@@ -1831,45 +1847,6 @@ Public Class cWorker_NCTS
|
||||
End Try
|
||||
End Function
|
||||
|
||||
Shared Function copyFileFTP(NCTS_TMP As DAKOSY_Worker.cDakosyNCTSOut, DY_TMP As DAKOSY_Worker.cDakosy_Zollanmeldungen) ', filePath As String)
|
||||
Try
|
||||
If NCTS_TMP Is Nothing Then Return False
|
||||
If NCTS_TMP.ncts_ObjectName Is Nothing Then Return False
|
||||
If NCTS_TMP.ncts_ObjectName.ToString.StartsWith("DU") Then Return False
|
||||
If NCTS_TMP.ncts_firma.ToString = "DURMAZ" Then Return False
|
||||
|
||||
Dim filePath = SQL.getValueTxtBySql("select [dySt_pfad] from [tblDakosy_Statusmeldungen] where dySt_BezugsNr='" & NCTS_TMP.ncts_ObjectName & "' and [dySt_status]=5 and [dySt_pfad] is not null ", "FMZOLL")
|
||||
If filePath = "" Then Return False
|
||||
|
||||
NCTS_TMP.LOAD_Sicherheitsangaben()
|
||||
If NCTS_TMP.ncts_SICHERHEITSANGABEN IsNot Nothing AndAlso NCTS_TMP.ncts_SICHERHEITSANGABEN.Count > 0 Then
|
||||
Dim GRN = NCTS_TMP.ncts_SICHERHEITSANGABEN(0).nctsSA_GRN
|
||||
Dim destFile = ""
|
||||
Select Case GRN
|
||||
' --> FTP Bereitstellung
|
||||
'\\192.168.0.91\Datenarchiv\DAKOSY\ECHTSYSTEM\FTP\TOBB
|
||||
Case "15TR0004000020917", "12TR0004000004665", "17TR0004000032349"
|
||||
frmStartOptions.copyFile(filePath, "\\ftps.verag.ag\FTP\TOBB\OUT\", destFile)
|
||||
If IO.File.Exists(destFile) Then insertFTPLOG(destFile, "TOBB") Else VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR("Datei existiert nicht: " & destFile & vbNewLine & NCTS_TMP.ncts_ObjectName, "", "copyFileFTP")
|
||||
Case "18DE0000000073276", "19DE0000000075520", "18DE0000000075520"
|
||||
frmStartOptions.copyFile(filePath, "\\ftps.verag.ag\FTP\OREGON\OUT\", destFile)
|
||||
If IO.File.Exists(destFile) Then insertFTPLOG(destFile, "OREGON") Else VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR("Datei existiert nicht: " & destFile & vbNewLine & NCTS_TMP.ncts_ObjectName, "", "copyFileFTP")
|
||||
Case "17DE0000000071678", "05AT510000G000FP7" 'VERAG
|
||||
frmStartOptions.copyFile(filePath, "\\192.168.0.91\Datenarchiv\DAKOSY\ECHTSYSTEM\FTP\VERAG\", destFile)
|
||||
If IO.File.Exists(destFile) Then insertFTPLOG(destFile, "VERAG") Else VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR("Datei existiert nicht: " & destFile & vbNewLine & NCTS_TMP.ncts_ObjectName, "", "copyFileFTP")
|
||||
End Select
|
||||
End If
|
||||
Return True
|
||||
Catch ex As Exception
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace & vbNewLine & "Datei: " & Dateiname, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
Return False
|
||||
End Try
|
||||
End Function
|
||||
|
||||
Shared Function insertFTPLOG(filePath, user)
|
||||
Return SQL.doSQL("INSERT INTO tblFTP_Log (ftp_filepath,ftp_user) VALUES ('" & filePath & "','" & user & "')", "FMZOLL")
|
||||
End Function
|
||||
|
||||
Shared Sub SaveNCTS_WGDAT(ByRef NCTS_TMP As DAKOSY_Worker.cDakosyNCTSOut, WGDAT As Object)
|
||||
|
||||
If WGDAT IsNot Nothing AndAlso IsDate(WGDAT) Then
|
||||
|
||||
Reference in New Issue
Block a user