Mailbenachrichtigung, etc.
This commit is contained in:
@@ -2429,8 +2429,8 @@ Public Class usrCntlFaktAbrechnung
|
||||
RECHNUNG.Währungscode = cProgramFunctions.isLeerNothing(cboWaehrungUmrechnung._value)
|
||||
Call przFixeTaxe(RECHNUNG) ' Fixe Taxe errechnen
|
||||
Call przPP(RECHNUNG) ' Porto/Papiere errechnen
|
||||
|
||||
Call przBS415(RECHNUNG) ' Bankspesen errechnen
|
||||
Call setFixeTaxeMin(RECHNUNG, 500, 20) ' Mind Fixe Taxe errechnen
|
||||
|
||||
'Me![SteuerpflichtigerGesamtbetrag] = 0.0#
|
||||
'Me![SteuerfreierGesamtbetrag] = 0.0#
|
||||
@@ -3052,30 +3052,44 @@ Public Class usrCntlFaktAbrechnung
|
||||
|
||||
End Sub
|
||||
Shared Sub setFixeTaxeMin(ByRef RECHNUNG As VERAG_PROG_ALLGEMEIN.cRechnungsausgang, ByRef minBetrag As Double, fixeTaxe As Double)
|
||||
|
||||
Dim FixeTaxe_Berechnungbetrag As Double = 0
|
||||
|
||||
If Not leistungExistsInPos(RECHNUNG, 441, 1) Then Exit Sub 'Schauen, ob die Leistung in den Positionen vorhanden ist
|
||||
|
||||
If (RECHNUNG.SteuerfreierGesamtbetrag + RECHNUNG.SteuerpflichtigerGesamtbetrag) >= minBetrag Then Exit Sub
|
||||
|
||||
If fixeTaxe <= 0 Then Exit Sub
|
||||
|
||||
'Sucht, ob Fixetaxe schon vorhanden ist,...
|
||||
Dim FixeTaxePOS = RECHNUNG.POSITIONEN.Find(Function(x) x.LeistungsNr = 441 And x.BerechnungsartNr = 1)
|
||||
'... sonst wird eine neue Pos eingefügt...
|
||||
If FixeTaxePOS IsNot Nothing Then
|
||||
'FixeTaxePOS = New VERAG_PROG_ALLGEMEIN.cRechnungsausgangPositionen
|
||||
FixeTaxePOS.LeistungsNr = 441 '441 und nicht 440 laut Brigitte weil Steuerfrei!!
|
||||
FixeTaxePOS.LeistungsBez = "P.P./Fixe Taxe"
|
||||
FixeTaxePOS.BerechnungsartNr = 9
|
||||
'RECHNUNG.POSITIONEN.Add(FixeTaxePOS)
|
||||
'...und der Wert gesetzt.
|
||||
FixeTaxePOS.Anzahl = 1
|
||||
FixeTaxePOS.Preis = getVorzeichen(RECHNUNG) * fixeTaxe
|
||||
|
||||
initSteuerbetraege(RECHNUNG, FixeTaxePOS)
|
||||
Dim PapirePorti As Double = 0
|
||||
If Not CBool(SQL.DLookup("[PP441]", "Filialen", "[FilialenNr]=" & RECHNUNG.FilialenNr, "FMZOLL", False)) Then
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
If Not leistungExistsInPos(RECHNUNG, 441) Then Exit Sub 'Schauen, ob die Leistung in den Positionen vorhanden ist
|
||||
|
||||
For Each POS In RECHNUNG.POSITIONEN
|
||||
If POS.LeistungsNr <> 441 Then
|
||||
FixeTaxe_Berechnungbetrag += POS.[Preis] * POS.Anzahl
|
||||
End If
|
||||
Next
|
||||
|
||||
If FixeTaxe_Berechnungbetrag < 0 Then FixeTaxe_Berechnungbetrag *= -1
|
||||
|
||||
If FixeTaxe_Berechnungbetrag < minBetrag Then
|
||||
|
||||
'Sucht, ob Fixetaxe schon vorhanden ist,...
|
||||
Dim FixeTaxePOS = RECHNUNG.POSITIONEN.Find(Function(x) x.LeistungsNr = 441)
|
||||
'... sonst wird eine neue Pos eingefügt...
|
||||
If FixeTaxePOS IsNot Nothing Then
|
||||
'FixeTaxePOS = New VERAG_PROG_ALLGEMEIN.cRechnungsausgangPositionen
|
||||
FixeTaxePOS.LeistungsNr = 441 '441 und nicht 440 laut Brigitte weil Steuerfrei!!
|
||||
FixeTaxePOS.LeistungsBez = "P.P./Fixe Taxe"
|
||||
FixeTaxePOS.BerechnungsartNr = 1
|
||||
'RECHNUNG.POSITIONEN.Add(FixeTaxePOS)
|
||||
'...und der Wert gesetzt.
|
||||
FixeTaxePOS.Anzahl = 1
|
||||
FixeTaxePOS.Preis = getVorzeichen(RECHNUNG) * fixeTaxe 'Preis wird bewusst überschrieben!!!
|
||||
|
||||
initSteuerbetraege(RECHNUNG, FixeTaxePOS)
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user