Sendungsdetails, etc.
This commit is contained in:
@@ -80,12 +80,7 @@ Public Class frmGesamtsicherheitenNEU
|
||||
|
||||
cboFiliale.fillWithSQL("SELECT FilialenNr, cast(FilialenNr as varchar(4)) + ' ' + Grenzstelle FROM Filialen WHERE Fil_Status='A' ORDER BY FilialenNr ", True, "FMZOLL", True)
|
||||
|
||||
If warenortPrefix <> "" Then
|
||||
cboWarenort.fillWithSQL("SELECT [wo_warenort],CONCAT([wo_bezeichnung],' - ' ,[wo_knnr]) FROM [tblWarenorte] WHERE [wo_aktiv] = 1 AND wo_ze = 1 AND LEFT([wo_warenort],2) = " & warenortPrefix & " ORDER BY [wo_reihenfolge] ", True, "AVISO", True)
|
||||
Else
|
||||
cboWarenort.fillWithSQL("SELECT [wo_warenort],CONCAT([wo_bezeichnung],' - ' ,[wo_knnr]) FROM [tblWarenorte] WHERE [wo_aktiv] = 1 AND wo_ze = 1 AND [wo_firma] = " & firmaId & " ORDER BY [wo_reihenfolge] ", True, "AVISO", True) '
|
||||
End If
|
||||
|
||||
setcboWarenort(True)
|
||||
|
||||
|
||||
If datum = Nothing Then datum = Date.Now
|
||||
@@ -94,28 +89,6 @@ Public Class frmGesamtsicherheitenNEU
|
||||
|
||||
txtlkwIdSearch.initSearchBox(Me.FindForm, " LKW_Nr, AvisoID, CAST(Datum as Date) as Datum FROM [Aviso]", {"LKW_Nr", "AvisoID", "Datum"}, "", "Datum desc", "LKW_Nr", "AvisoID", "AVISO",, 250, 200)
|
||||
|
||||
If Standort = "AMBAR GmbH" Then
|
||||
For i As Integer = 0 To cboFiliale.Items.Count - 1
|
||||
If cboFiliale.Items(i).ToString().Contains("5701") Then
|
||||
cboFiliale.SelectedIndex = i
|
||||
Exit For
|
||||
End If
|
||||
Next
|
||||
For i As Integer = 0 To cboWarenort.Items.Count - 1
|
||||
If cboWarenort.Items(i).ToString().Contains("AMBAR") Then
|
||||
cboWarenort.SelectedIndex = i
|
||||
Exit For
|
||||
End If
|
||||
Next
|
||||
ElseIf grenzstelle <> "" Then
|
||||
|
||||
For i As Integer = 0 To cboWarenort.Items.Count - 1
|
||||
If cboWarenort.Items(i).ToString().Contains(grenzstelle) Then
|
||||
cboWarenort.SelectedIndex = i
|
||||
Exit For
|
||||
End If
|
||||
Next
|
||||
End If
|
||||
|
||||
Else
|
||||
LoadDGVSicherheiten(True)
|
||||
@@ -2339,4 +2312,58 @@ Public Class frmGesamtsicherheitenNEU
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub setcboWarenort(setDefaultValue As Boolean)
|
||||
|
||||
Dim whereWarenort As String = " WHERE [wo_aktiv] = 1 AND wo_ze = 1"
|
||||
|
||||
|
||||
If Standort = "Atilla GmbH" Then
|
||||
|
||||
'----'nicht unisped und cs und ambar aber alle anderen - laut j.Siener am 23.03.2026
|
||||
|
||||
whereWarenort &= " AND [wo_firma] not in (24, 21,22,23, 11)"
|
||||
|
||||
Else
|
||||
If warenortPrefix <> "" Then
|
||||
whereWarenort &= " AND LEFT([wo_warenort],2) = " & warenortPrefix & ""
|
||||
Else
|
||||
whereWarenort &= " AND [wo_firma] = " & firmaId
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
cboWarenort.fillWithSQL("SELECT [wo_warenort],CONCAT([wo_bezeichnung],' - ' ,[wo_knnr]) FROM [tblWarenorte] " & whereWarenort, True, "AVISO", True)
|
||||
|
||||
|
||||
If setDefaultValue AndAlso cboWarenort.Items.Count > 0 Then
|
||||
|
||||
If Standort = "AMBAR GmbH" Then
|
||||
For i As Integer = 0 To cboFiliale.Items.Count - 1
|
||||
If cboFiliale.Items(i).ToString().Contains("5701") Then
|
||||
cboFiliale.SelectedIndex = i
|
||||
Exit For
|
||||
End If
|
||||
Next
|
||||
For i As Integer = 0 To cboWarenort.Items.Count - 1
|
||||
If cboWarenort.Items(i).ToString().Contains("AMBAR") Then
|
||||
cboWarenort.SelectedIndex = i
|
||||
Exit For
|
||||
End If
|
||||
Next
|
||||
ElseIf grenzstelle <> "" Then
|
||||
|
||||
For i As Integer = 0 To cboWarenort.Items.Count - 1
|
||||
If cboWarenort.Items(i).ToString().Contains(grenzstelle) Then
|
||||
cboWarenort.SelectedIndex = i
|
||||
Exit For
|
||||
End If
|
||||
Next
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
End Class
|
||||
|
||||
Reference in New Issue
Block a user