Überstundenauszahlung, TimasAPI, etc.
This commit is contained in:
@@ -50,22 +50,24 @@ Public Class cFeiertage
|
||||
End Get
|
||||
End Property
|
||||
|
||||
Public Function GetFirstyDayInxMonth(ByVal day As DayOfWeek, ByVal month As Integer, ByVal year As Integer) As DateTime
|
||||
Public Function GetFirstyDayYInxMonth(ByVal day As DayOfWeek, ByVal month As Integer, ByVal year As Integer, Optional irgnoreDay As Boolean = False) As DateTime
|
||||
|
||||
' Create a start date for the 1st day of the month
|
||||
Dim startDate As DateTime = New DateTime(year, month, 1)
|
||||
|
||||
While startDate.DayOfWeek <> day
|
||||
startDate = startDate.AddDays(1)
|
||||
End While
|
||||
If Not irgnoreDay Then
|
||||
|
||||
While startDate.DayOfWeek <> day
|
||||
startDate = startDate.AddDays(1)
|
||||
End While
|
||||
End If
|
||||
|
||||
Return startDate
|
||||
|
||||
End Function
|
||||
|
||||
|
||||
Public Function GetLastyDayInxMonth(ByVal day As DayOfWeek, ByVal month As Integer, ByVal year As Integer) As DateTime
|
||||
Public Function GetLastyDayYInxMonth(ByVal day As DayOfWeek, ByVal month As Integer, ByVal year As Integer, Optional irgnoreDay As Boolean = False) As DateTime
|
||||
|
||||
' Create a start date for the last weekday of the month
|
||||
Dim startDate As DateTime
|
||||
@@ -77,9 +79,14 @@ Public Class cFeiertage
|
||||
startDate = startDate.AddDays(-1)
|
||||
End If
|
||||
|
||||
While (startDate.DayOfWeek <> day)
|
||||
If irgnoreDay Then
|
||||
startDate = startDate.AddDays(-1)
|
||||
End While
|
||||
Else
|
||||
While (startDate.DayOfWeek <> day)
|
||||
startDate = startDate.AddDays(-1)
|
||||
End While
|
||||
End If
|
||||
|
||||
|
||||
Return startDate
|
||||
|
||||
@@ -268,9 +275,9 @@ Public Class cFeiertage
|
||||
|
||||
Case "GB"
|
||||
If datum = Karfreitag Then Return True
|
||||
If datum = GetFirstyDayInxMonth(DayOfWeek.Monday, 5, _Year) Then Return True 'Early May Bank Holiday Erster Montag im Mai
|
||||
If datum = GetLastyDayInxMonth(DayOfWeek.Monday, 5, _Year) Then Return True 'Spring Bank Holiday Letzter Montag im Mai
|
||||
If datum = GetLastyDayInxMonth(DayOfWeek.Monday, 8, _Year) Then Return True 'Summer Bank Holiday Letzter Montag im August
|
||||
If datum = GetFirstyDayYInxMonth(DayOfWeek.Monday, 5, _Year) Then Return True 'Early May Bank Holiday Erster Montag im Mai
|
||||
If datum = GetLastyDayYInxMonth(DayOfWeek.Monday, 5, _Year) Then Return True 'Spring Bank Holiday Letzter Montag im Mai
|
||||
If datum = GetLastyDayYInxMonth(DayOfWeek.Monday, 8, _Year) Then Return True 'Summer Bank Holiday Letzter Montag im August
|
||||
|
||||
Return False
|
||||
Case Else
|
||||
|
||||
@@ -28,8 +28,10 @@ Partial Class frmMitarbeitersuche
|
||||
Me.Button4 = New System.Windows.Forms.Button()
|
||||
Me.btnClose = New System.Windows.Forms.Button()
|
||||
Me.PictureBox2 = New System.Windows.Forms.PictureBox()
|
||||
Me.sbMitarbeiter = New VERAG_PROG_ALLGEMEIN.MySearchBox()
|
||||
Me.pnlMain = New System.Windows.Forms.Panel()
|
||||
Me.pnl = New System.Windows.Forms.Panel()
|
||||
Me.Button3 = New System.Windows.Forms.Button()
|
||||
Me.Panel2 = New System.Windows.Forms.Panel()
|
||||
Me.lblStatusZE = New System.Windows.Forms.Label()
|
||||
Me.Label13 = New System.Windows.Forms.Label()
|
||||
@@ -81,7 +83,6 @@ Partial Class frmMitarbeitersuche
|
||||
Me.lblFirma = New System.Windows.Forms.Label()
|
||||
Me.Label4 = New System.Windows.Forms.Label()
|
||||
Me.Label3 = New System.Windows.Forms.Label()
|
||||
Me.sbMitarbeiter = New VERAG_PROG_ALLGEMEIN.MySearchBox()
|
||||
Me.pnlSrch.SuspendLayout()
|
||||
CType(Me.PictureBox2, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.pnlMain.SuspendLayout()
|
||||
@@ -154,6 +155,32 @@ Partial Class frmMitarbeitersuche
|
||||
Me.PictureBox2.TabIndex = 18
|
||||
Me.PictureBox2.TabStop = False
|
||||
'
|
||||
'sbMitarbeiter
|
||||
'
|
||||
Me.sbMitarbeiter._allowFreitext = False
|
||||
Me.sbMitarbeiter._AllowSetValue = False
|
||||
Me.sbMitarbeiter._allowSpaceAsSplitter = True
|
||||
Me.sbMitarbeiter._autoSizeGross = False
|
||||
Me.sbMitarbeiter._hideIfListEmpty = True
|
||||
Me.sbMitarbeiter._value = Nothing
|
||||
Me.sbMitarbeiter.conn_art = "FMZOLL"
|
||||
Me.sbMitarbeiter.dgvpos = "LEFT"
|
||||
Me.sbMitarbeiter.DISPLAY_PARAM = Nothing
|
||||
Me.sbMitarbeiter.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
|
||||
Me.sbMitarbeiter.INVISIBLE_COLUMNS = Nothing
|
||||
Me.sbMitarbeiter.key_visible = False
|
||||
Me.sbMitarbeiter.KEYPARAM = Nothing
|
||||
Me.sbMitarbeiter.Location = New System.Drawing.Point(45, 11)
|
||||
Me.sbMitarbeiter.Name = "sbMitarbeiter"
|
||||
Me.sbMitarbeiter.searchActive = True
|
||||
Me.sbMitarbeiter.Size = New System.Drawing.Size(582, 29)
|
||||
Me.sbMitarbeiter.SQL_ORDER_BY = Nothing
|
||||
Me.sbMitarbeiter.SQL_SELECT = Nothing
|
||||
Me.sbMitarbeiter.SQL_WHERE = Nothing
|
||||
Me.sbMitarbeiter.SQL_WhereParamList = Nothing
|
||||
Me.sbMitarbeiter.TabIndex = 0
|
||||
Me.sbMitarbeiter.usrcntl = Nothing
|
||||
'
|
||||
'pnlMain
|
||||
'
|
||||
Me.pnlMain.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink
|
||||
@@ -169,6 +196,7 @@ Partial Class frmMitarbeitersuche
|
||||
'
|
||||
Me.pnl.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink
|
||||
Me.pnl.BackColor = System.Drawing.Color.FromArgb(CType(CType(250, Byte), Integer), CType(CType(254, Byte), Integer), CType(CType(255, Byte), Integer))
|
||||
Me.pnl.Controls.Add(Me.Button3)
|
||||
Me.pnl.Controls.Add(Me.Panel2)
|
||||
Me.pnl.Controls.Add(Me.pnlZeiten)
|
||||
Me.pnl.Controls.Add(Me.lblMAId)
|
||||
@@ -199,6 +227,21 @@ Partial Class frmMitarbeitersuche
|
||||
Me.pnl.Size = New System.Drawing.Size(774, 480)
|
||||
Me.pnl.TabIndex = 24
|
||||
'
|
||||
'Button3
|
||||
'
|
||||
Me.Button3.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom
|
||||
Me.Button3.FlatStyle = System.Windows.Forms.FlatStyle.Flat
|
||||
Me.Button3.Image = Global.VERAG_PROG_ALLGEMEIN.My.Resources.Resources.zeiterfassung_s
|
||||
Me.Button3.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
|
||||
Me.Button3.Location = New System.Drawing.Point(647, 138)
|
||||
Me.Button3.Name = "Button3"
|
||||
Me.Button3.Size = New System.Drawing.Size(125, 40)
|
||||
Me.Button3.TabIndex = 129
|
||||
Me.Button3.Text = "ÜS auszahlen"
|
||||
Me.Button3.TextAlign = System.Drawing.ContentAlignment.MiddleRight
|
||||
Me.Button3.UseVisualStyleBackColor = True
|
||||
Me.Button3.Visible = False
|
||||
'
|
||||
'Panel2
|
||||
'
|
||||
Me.Panel2.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
|
||||
@@ -415,7 +458,7 @@ Partial Class frmMitarbeitersuche
|
||||
Me.btnSettings.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
|
||||
Me.btnSettings.Location = New System.Drawing.Point(646, 95)
|
||||
Me.btnSettings.Name = "btnSettings"
|
||||
Me.btnSettings.Size = New System.Drawing.Size(125, 61)
|
||||
Me.btnSettings.Size = New System.Drawing.Size(125, 40)
|
||||
Me.btnSettings.TabIndex = 29
|
||||
Me.btnSettings.Text = "Einstellungen"
|
||||
Me.btnSettings.TextAlign = System.Drawing.ContentAlignment.MiddleRight
|
||||
@@ -592,7 +635,7 @@ Partial Class frmMitarbeitersuche
|
||||
Me.lblHandyNr.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Bold)
|
||||
Me.lblHandyNr.Location = New System.Drawing.Point(360, 164)
|
||||
Me.lblHandyNr.Name = "lblHandyNr"
|
||||
Me.lblHandyNr.Size = New System.Drawing.Size(411, 25)
|
||||
Me.lblHandyNr.Size = New System.Drawing.Size(281, 25)
|
||||
Me.lblHandyNr.TabIndex = 22
|
||||
Me.lblHandyNr.Text = "+43 7711 / 2777 0"
|
||||
Me.lblHandyNr.TextAlign = System.Drawing.ContentAlignment.MiddleLeft
|
||||
@@ -613,7 +656,7 @@ Partial Class frmMitarbeitersuche
|
||||
Me.lblTelefon.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Bold)
|
||||
Me.lblTelefon.Location = New System.Drawing.Point(360, 138)
|
||||
Me.lblTelefon.Name = "lblTelefon"
|
||||
Me.lblTelefon.Size = New System.Drawing.Size(411, 25)
|
||||
Me.lblTelefon.Size = New System.Drawing.Size(281, 25)
|
||||
Me.lblTelefon.TabIndex = 16
|
||||
Me.lblTelefon.Text = "+43 7711 / 2777 0"
|
||||
Me.lblTelefon.TextAlign = System.Drawing.ContentAlignment.MiddleLeft
|
||||
@@ -772,32 +815,6 @@ Partial Class frmMitarbeitersuche
|
||||
Me.Label3.Text = "Niederlassung:"
|
||||
Me.Label3.TextAlign = System.Drawing.ContentAlignment.MiddleLeft
|
||||
'
|
||||
'sbMitarbeiter
|
||||
'
|
||||
Me.sbMitarbeiter._allowFreitext = False
|
||||
Me.sbMitarbeiter._AllowSetValue = False
|
||||
Me.sbMitarbeiter._allowSpaceAsSplitter = True
|
||||
Me.sbMitarbeiter._autoSizeGross = False
|
||||
Me.sbMitarbeiter._hideIfListEmpty = True
|
||||
Me.sbMitarbeiter._value = Nothing
|
||||
Me.sbMitarbeiter.conn_art = "FMZOLL"
|
||||
Me.sbMitarbeiter.dgvpos = "LEFT"
|
||||
Me.sbMitarbeiter.DISPLAY_PARAM = Nothing
|
||||
Me.sbMitarbeiter.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
|
||||
Me.sbMitarbeiter.INVISIBLE_COLUMNS = Nothing
|
||||
Me.sbMitarbeiter.key_visible = False
|
||||
Me.sbMitarbeiter.KEYPARAM = Nothing
|
||||
Me.sbMitarbeiter.Location = New System.Drawing.Point(45, 11)
|
||||
Me.sbMitarbeiter.Name = "sbMitarbeiter"
|
||||
Me.sbMitarbeiter.searchActive = True
|
||||
Me.sbMitarbeiter.Size = New System.Drawing.Size(582, 29)
|
||||
Me.sbMitarbeiter.SQL_ORDER_BY = Nothing
|
||||
Me.sbMitarbeiter.SQL_SELECT = Nothing
|
||||
Me.sbMitarbeiter.SQL_WHERE = Nothing
|
||||
Me.sbMitarbeiter.SQL_WhereParamList = Nothing
|
||||
Me.sbMitarbeiter.TabIndex = 0
|
||||
Me.sbMitarbeiter.usrcntl = Nothing
|
||||
'
|
||||
'frmMitarbeitersuche
|
||||
'
|
||||
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
||||
@@ -894,4 +911,5 @@ Partial Class frmMitarbeitersuche
|
||||
Friend WithEvents Button2 As Windows.Forms.Button
|
||||
Friend WithEvents PictureBox5 As Windows.Forms.PictureBox
|
||||
Friend WithEvents btnAkten As Windows.Forms.Button
|
||||
Friend WithEvents Button3 As Windows.Forms.Button
|
||||
End Class
|
||||
|
||||
@@ -72,6 +72,7 @@ Public Class frmMitarbeitersuche
|
||||
lblTimasSaldo.Visible = False
|
||||
Panel1.Visible = False
|
||||
btnSettings.Visible = False
|
||||
Button3.Visible = False
|
||||
' Dim MA As cMitarbeiter = Nothing
|
||||
If sbMitarbeiter._value <> "" Then
|
||||
MA = New cMitarbeiter(sbMitarbeiter._value)
|
||||
@@ -190,6 +191,8 @@ Public Class frmMitarbeitersuche
|
||||
|
||||
If VERAG_PROG_ALLGEMEIN.cBerechtignunen.CHECK_BERECHTIGUNG_bool("ZE_AKTENGANG", "SDL") Then btnAkten.Visible = True
|
||||
|
||||
If VERAG_PROG_ALLGEMEIN.cBerechtignunen.CHECK_BERECHTIGUNG_bool("Überstunden_auszahlen", "SDL") Then Button3.Visible = True = True
|
||||
|
||||
End If
|
||||
End Sub
|
||||
|
||||
@@ -423,7 +426,7 @@ Public Class frmMitarbeitersuche
|
||||
Dim dtZeiten As New DataTable
|
||||
If timas IsNot Nothing Then
|
||||
Dim isServiceRunning As Boolean = True
|
||||
timas.getTimeSaldo(MA.mit_timasId, lblTimasSaldo.Text, isServiceRunning)
|
||||
timas.getTimeSaldo(MA.mit_timasId, lblTimasSaldo.Text, "dailyBalanceYesterday", isServiceRunning)
|
||||
If Not isServiceRunning Then
|
||||
'Abfrage konnte nicht durchgeführt werden.
|
||||
MsgBox("Abfragefehler am Timas-Server!")
|
||||
@@ -484,4 +487,9 @@ Public Class frmMitarbeitersuche
|
||||
Process.Start(webAddress)
|
||||
End Sub
|
||||
|
||||
Private Sub Button3_Click(sender As Object, e As EventArgs) Handles Button3.Click
|
||||
If sbMitarbeiter._value = "" Then Exit Sub
|
||||
Dim f As New frmUeberstundenauszahlen(sbMitarbeiter._value)
|
||||
f.ShowDialog(Me)
|
||||
End Sub
|
||||
End Class
|
||||
447
VERAG_PROG_ALLGEMEIN/Mitarbeiterverzeichnis/frmUeberstundenauszahlen.Designer.vb
generated
Normal file
447
VERAG_PROG_ALLGEMEIN/Mitarbeiterverzeichnis/frmUeberstundenauszahlen.Designer.vb
generated
Normal file
@@ -0,0 +1,447 @@
|
||||
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()>
|
||||
Partial Class frmUeberstundenauszahlen
|
||||
Inherits System.Windows.Forms.Form
|
||||
|
||||
'Das Formular überschreibt den Löschvorgang, um die Komponentenliste zu bereinigen.
|
||||
<System.Diagnostics.DebuggerNonUserCode()>
|
||||
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
|
||||
Try
|
||||
If disposing AndAlso components IsNot Nothing Then
|
||||
components.Dispose()
|
||||
End If
|
||||
Finally
|
||||
MyBase.Dispose(disposing)
|
||||
End Try
|
||||
End Sub
|
||||
|
||||
'Wird vom Windows Form-Designer benötigt.
|
||||
Private components As System.ComponentModel.IContainer
|
||||
|
||||
'Hinweis: Die folgende Prozedur ist für den Windows Form-Designer erforderlich.
|
||||
'Das Bearbeiten ist mit dem Windows Form-Designer möglich.
|
||||
'Das Bearbeiten mit dem Code-Editor ist nicht möglich.
|
||||
<System.Diagnostics.DebuggerStepThrough()>
|
||||
Private Sub InitializeComponent()
|
||||
Me.components = New System.ComponentModel.Container()
|
||||
Me.dtpMonat = New System.Windows.Forms.DateTimePicker()
|
||||
Me.lblMonat = New System.Windows.Forms.Label()
|
||||
Me.Label2 = New System.Windows.Forms.Label()
|
||||
Me.Label3 = New System.Windows.Forms.Label()
|
||||
Me.Label4 = New System.Windows.Forms.Label()
|
||||
Me.txt100 = New System.Windows.Forms.TextBox()
|
||||
Me.txt50 = New System.Windows.Forms.TextBox()
|
||||
Me.txtMehr = New System.Windows.Forms.TextBox()
|
||||
Me.Label5 = New System.Windows.Forms.Label()
|
||||
Me.txtAusz = New System.Windows.Forms.TextBox()
|
||||
Me.lblMA = New System.Windows.Forms.Label()
|
||||
Me.Label7 = New System.Windows.Forms.Label()
|
||||
Me.Button1 = New System.Windows.Forms.Button()
|
||||
Me.txt100x2 = New System.Windows.Forms.TextBox()
|
||||
Me.txt50x15 = New System.Windows.Forms.TextBox()
|
||||
Me.txtAusz100 = New System.Windows.Forms.TextBox()
|
||||
Me.txtAusz50 = New System.Windows.Forms.TextBox()
|
||||
Me.CheckVatTestService1 = New VERAG_PROG_ALLGEMEIN.eu.europa.ec.checkVatTestService()
|
||||
Me.cbxabwDatum = New System.Windows.Forms.CheckBox()
|
||||
Me.lblBis = New System.Windows.Forms.Label()
|
||||
Me.dtpBis = New System.Windows.Forms.DateTimePicker()
|
||||
Me.txtSummeAuszb = New System.Windows.Forms.TextBox()
|
||||
Me.txtberAusz50 = New System.Windows.Forms.TextBox()
|
||||
Me.txtberAusz100 = New System.Windows.Forms.TextBox()
|
||||
Me.Label1 = New System.Windows.Forms.Label()
|
||||
Me.txtlfdSaldo = New System.Windows.Forms.TextBox()
|
||||
Me.Label6 = New System.Windows.Forms.Label()
|
||||
Me.picDel = New System.Windows.Forms.PictureBox()
|
||||
Me.txtAusz50vonSaldo = New System.Windows.Forms.TextBox()
|
||||
Me.Panel1 = New System.Windows.Forms.Panel()
|
||||
Me.dgvUeberstunden = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components)
|
||||
Me.txt50x1 = New System.Windows.Forms.TextBox()
|
||||
Me.Label8 = New System.Windows.Forms.Label()
|
||||
CType(Me.picDel, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.Panel1.SuspendLayout()
|
||||
CType(Me.dgvUeberstunden, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.SuspendLayout()
|
||||
'
|
||||
'dtpMonat
|
||||
'
|
||||
Me.dtpMonat.CustomFormat = "yyyy/MM"
|
||||
Me.dtpMonat.Format = System.Windows.Forms.DateTimePickerFormat.Custom
|
||||
Me.dtpMonat.Location = New System.Drawing.Point(15, 41)
|
||||
Me.dtpMonat.Name = "dtpMonat"
|
||||
Me.dtpMonat.Size = New System.Drawing.Size(81, 20)
|
||||
Me.dtpMonat.TabIndex = 0
|
||||
'
|
||||
'lblMonat
|
||||
'
|
||||
Me.lblMonat.AutoSize = True
|
||||
Me.lblMonat.Location = New System.Drawing.Point(12, 25)
|
||||
Me.lblMonat.Name = "lblMonat"
|
||||
Me.lblMonat.Size = New System.Drawing.Size(37, 13)
|
||||
Me.lblMonat.TabIndex = 1
|
||||
Me.lblMonat.Text = "Monat"
|
||||
'
|
||||
'Label2
|
||||
'
|
||||
Me.Label2.AutoSize = True
|
||||
Me.Label2.Location = New System.Drawing.Point(13, 11)
|
||||
Me.Label2.Name = "Label2"
|
||||
Me.Label2.Size = New System.Drawing.Size(196, 13)
|
||||
Me.Label2.TabIndex = 2
|
||||
Me.Label2.Text = "Überstunden 100% (So/Nacht/Feiertag)"
|
||||
'
|
||||
'Label3
|
||||
'
|
||||
Me.Label3.AutoSize = True
|
||||
Me.Label3.Location = New System.Drawing.Point(12, 131)
|
||||
Me.Label3.Name = "Label3"
|
||||
Me.Label3.Size = New System.Drawing.Size(138, 13)
|
||||
Me.Label3.TabIndex = 3
|
||||
Me.Label3.Text = "Mehrarbeit (autom. ausbez.)"
|
||||
'
|
||||
'Label4
|
||||
'
|
||||
Me.Label4.AutoSize = True
|
||||
Me.Label4.Location = New System.Drawing.Point(13, 53)
|
||||
Me.Label4.Name = "Label4"
|
||||
Me.Label4.Size = New System.Drawing.Size(113, 13)
|
||||
Me.Label4.TabIndex = 4
|
||||
Me.Label4.Text = "Überstunden 50% (Sa)"
|
||||
'
|
||||
'txt100
|
||||
'
|
||||
Me.txt100.Location = New System.Drawing.Point(16, 27)
|
||||
Me.txt100.Name = "txt100"
|
||||
Me.txt100.ReadOnly = True
|
||||
Me.txt100.Size = New System.Drawing.Size(47, 20)
|
||||
Me.txt100.TabIndex = 5
|
||||
Me.txt100.Text = "0"
|
||||
'
|
||||
'txt50
|
||||
'
|
||||
Me.txt50.Location = New System.Drawing.Point(16, 69)
|
||||
Me.txt50.Name = "txt50"
|
||||
Me.txt50.ReadOnly = True
|
||||
Me.txt50.Size = New System.Drawing.Size(47, 20)
|
||||
Me.txt50.TabIndex = 6
|
||||
Me.txt50.Text = "0"
|
||||
'
|
||||
'txtMehr
|
||||
'
|
||||
Me.txtMehr.Location = New System.Drawing.Point(15, 147)
|
||||
Me.txtMehr.Name = "txtMehr"
|
||||
Me.txtMehr.ReadOnly = True
|
||||
Me.txtMehr.Size = New System.Drawing.Size(47, 20)
|
||||
Me.txtMehr.TabIndex = 7
|
||||
Me.txtMehr.Text = "0"
|
||||
'
|
||||
'Label5
|
||||
'
|
||||
Me.Label5.AutoSize = True
|
||||
Me.Label5.Location = New System.Drawing.Point(75, 179)
|
||||
Me.Label5.Name = "Label5"
|
||||
Me.Label5.Size = New System.Drawing.Size(86, 13)
|
||||
Me.Label5.TabIndex = 8
|
||||
Me.Label5.Text = "max. auszahlbar:"
|
||||
'
|
||||
'txtAusz
|
||||
'
|
||||
Me.txtAusz.Location = New System.Drawing.Point(192, 196)
|
||||
Me.txtAusz.Name = "txtAusz"
|
||||
Me.txtAusz.Size = New System.Drawing.Size(54, 20)
|
||||
Me.txtAusz.TabIndex = 9
|
||||
Me.txtAusz.Text = "0"
|
||||
'
|
||||
'lblMA
|
||||
'
|
||||
Me.lblMA.AutoSize = True
|
||||
Me.lblMA.Location = New System.Drawing.Point(238, 6)
|
||||
Me.lblMA.Name = "lblMA"
|
||||
Me.lblMA.Size = New System.Drawing.Size(56, 13)
|
||||
Me.lblMA.TabIndex = 10
|
||||
Me.lblMA.Text = "Mitarbeiter"
|
||||
'
|
||||
'Label7
|
||||
'
|
||||
Me.Label7.AutoSize = True
|
||||
Me.Label7.Location = New System.Drawing.Point(238, 26)
|
||||
Me.Label7.Name = "Label7"
|
||||
Me.Label7.Size = New System.Drawing.Size(65, 13)
|
||||
Me.Label7.TabIndex = 11
|
||||
Me.Label7.Text = "Mustermann"
|
||||
'
|
||||
'Button1
|
||||
'
|
||||
Me.Button1.DialogResult = System.Windows.Forms.DialogResult.OK
|
||||
Me.Button1.Location = New System.Drawing.Point(321, 170)
|
||||
Me.Button1.Name = "Button1"
|
||||
Me.Button1.Size = New System.Drawing.Size(87, 30)
|
||||
Me.Button1.TabIndex = 12
|
||||
Me.Button1.Text = "Auszahlen"
|
||||
Me.Button1.UseVisualStyleBackColor = True
|
||||
'
|
||||
'txt100x2
|
||||
'
|
||||
Me.txt100x2.Location = New System.Drawing.Point(112, 27)
|
||||
Me.txt100x2.Name = "txt100x2"
|
||||
Me.txt100x2.ReadOnly = True
|
||||
Me.txt100x2.Size = New System.Drawing.Size(49, 20)
|
||||
Me.txt100x2.TabIndex = 14
|
||||
Me.txt100x2.Text = "0"
|
||||
'
|
||||
'txt50x15
|
||||
'
|
||||
Me.txt50x15.Location = New System.Drawing.Point(112, 69)
|
||||
Me.txt50x15.Name = "txt50x15"
|
||||
Me.txt50x15.ReadOnly = True
|
||||
Me.txt50x15.Size = New System.Drawing.Size(49, 20)
|
||||
Me.txt50x15.TabIndex = 15
|
||||
Me.txt50x15.Text = "0"
|
||||
'
|
||||
'txtAusz100
|
||||
'
|
||||
Me.txtAusz100.Location = New System.Drawing.Point(197, 27)
|
||||
Me.txtAusz100.Name = "txtAusz100"
|
||||
Me.txtAusz100.ReadOnly = True
|
||||
Me.txtAusz100.Size = New System.Drawing.Size(54, 20)
|
||||
Me.txtAusz100.TabIndex = 16
|
||||
Me.txtAusz100.Text = "0"
|
||||
'
|
||||
'txtAusz50
|
||||
'
|
||||
Me.txtAusz50.Location = New System.Drawing.Point(197, 69)
|
||||
Me.txtAusz50.Name = "txtAusz50"
|
||||
Me.txtAusz50.ReadOnly = True
|
||||
Me.txtAusz50.Size = New System.Drawing.Size(54, 20)
|
||||
Me.txtAusz50.TabIndex = 17
|
||||
Me.txtAusz50.Text = "0"
|
||||
'
|
||||
'CheckVatTestService1
|
||||
'
|
||||
Me.CheckVatTestService1.Credentials = Nothing
|
||||
Me.CheckVatTestService1.Url = "http://ec.europa.eu/taxation_customs/vies/services/checkVatTestService"
|
||||
Me.CheckVatTestService1.UseDefaultCredentials = False
|
||||
'
|
||||
'cbxabwDatum
|
||||
'
|
||||
Me.cbxabwDatum.AutoSize = True
|
||||
Me.cbxabwDatum.Location = New System.Drawing.Point(15, 5)
|
||||
Me.cbxabwDatum.Name = "cbxabwDatum"
|
||||
Me.cbxabwDatum.Size = New System.Drawing.Size(129, 17)
|
||||
Me.cbxabwDatum.TabIndex = 18
|
||||
Me.cbxabwDatum.Text = "abweichendes Datum"
|
||||
Me.cbxabwDatum.UseVisualStyleBackColor = True
|
||||
'
|
||||
'lblBis
|
||||
'
|
||||
Me.lblBis.AutoSize = True
|
||||
Me.lblBis.Location = New System.Drawing.Point(134, 25)
|
||||
Me.lblBis.Name = "lblBis"
|
||||
Me.lblBis.Size = New System.Drawing.Size(20, 13)
|
||||
Me.lblBis.TabIndex = 20
|
||||
Me.lblBis.Text = "bis"
|
||||
Me.lblBis.Visible = False
|
||||
'
|
||||
'dtpBis
|
||||
'
|
||||
Me.dtpBis.CustomFormat = "yyyy/MM/dd"
|
||||
Me.dtpBis.Format = System.Windows.Forms.DateTimePickerFormat.Custom
|
||||
Me.dtpBis.Location = New System.Drawing.Point(137, 41)
|
||||
Me.dtpBis.Name = "dtpBis"
|
||||
Me.dtpBis.Size = New System.Drawing.Size(81, 20)
|
||||
Me.dtpBis.TabIndex = 19
|
||||
Me.dtpBis.Visible = False
|
||||
'
|
||||
'txtSummeAuszb
|
||||
'
|
||||
Me.txtSummeAuszb.Location = New System.Drawing.Point(110, 196)
|
||||
Me.txtSummeAuszb.Name = "txtSummeAuszb"
|
||||
Me.txtSummeAuszb.ReadOnly = True
|
||||
Me.txtSummeAuszb.Size = New System.Drawing.Size(49, 20)
|
||||
Me.txtSummeAuszb.TabIndex = 21
|
||||
Me.txtSummeAuszb.Text = "0"
|
||||
'
|
||||
'txtberAusz50
|
||||
'
|
||||
Me.txtberAusz50.Location = New System.Drawing.Point(291, 69)
|
||||
Me.txtberAusz50.Name = "txtberAusz50"
|
||||
Me.txtberAusz50.ReadOnly = True
|
||||
Me.txtberAusz50.Size = New System.Drawing.Size(54, 20)
|
||||
Me.txtberAusz50.TabIndex = 24
|
||||
Me.txtberAusz50.Text = "0"
|
||||
'
|
||||
'txtberAusz100
|
||||
'
|
||||
Me.txtberAusz100.Location = New System.Drawing.Point(291, 27)
|
||||
Me.txtberAusz100.Name = "txtberAusz100"
|
||||
Me.txtberAusz100.ReadOnly = True
|
||||
Me.txtberAusz100.Size = New System.Drawing.Size(54, 20)
|
||||
Me.txtberAusz100.TabIndex = 23
|
||||
Me.txtberAusz100.Text = "0"
|
||||
'
|
||||
'Label1
|
||||
'
|
||||
Me.Label1.AutoSize = True
|
||||
Me.Label1.Location = New System.Drawing.Point(289, 11)
|
||||
Me.Label1.Name = "Label1"
|
||||
Me.Label1.Size = New System.Drawing.Size(92, 13)
|
||||
Me.Label1.TabIndex = 25
|
||||
Me.Label1.Text = "bereits ausgezahlt"
|
||||
'
|
||||
'txtlfdSaldo
|
||||
'
|
||||
Me.txtlfdSaldo.Location = New System.Drawing.Point(17, 108)
|
||||
Me.txtlfdSaldo.Name = "txtlfdSaldo"
|
||||
Me.txtlfdSaldo.ReadOnly = True
|
||||
Me.txtlfdSaldo.Size = New System.Drawing.Size(49, 20)
|
||||
Me.txtlfdSaldo.TabIndex = 26
|
||||
Me.txtlfdSaldo.Text = "0"
|
||||
'
|
||||
'Label6
|
||||
'
|
||||
Me.Label6.AutoSize = True
|
||||
Me.Label6.Location = New System.Drawing.Point(18, 92)
|
||||
Me.Label6.Name = "Label6"
|
||||
Me.Label6.Size = New System.Drawing.Size(48, 13)
|
||||
Me.Label6.TabIndex = 27
|
||||
Me.Label6.Text = "lfd Saldo"
|
||||
'
|
||||
'picDel
|
||||
'
|
||||
Me.picDel.BackgroundImage = Global.VERAG_PROG_ALLGEMEIN.My.Resources.Resources.del
|
||||
Me.picDel.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom
|
||||
Me.picDel.Location = New System.Drawing.Point(387, 11)
|
||||
Me.picDel.Name = "picDel"
|
||||
Me.picDel.Size = New System.Drawing.Size(21, 16)
|
||||
Me.picDel.TabIndex = 28
|
||||
Me.picDel.TabStop = False
|
||||
'
|
||||
'txtAusz50vonSaldo
|
||||
'
|
||||
Me.txtAusz50vonSaldo.Location = New System.Drawing.Point(197, 108)
|
||||
Me.txtAusz50vonSaldo.Name = "txtAusz50vonSaldo"
|
||||
Me.txtAusz50vonSaldo.ReadOnly = True
|
||||
Me.txtAusz50vonSaldo.Size = New System.Drawing.Size(49, 20)
|
||||
Me.txtAusz50vonSaldo.TabIndex = 29
|
||||
Me.txtAusz50vonSaldo.Text = "0"
|
||||
'
|
||||
'Panel1
|
||||
'
|
||||
Me.Panel1.Controls.Add(Me.Label8)
|
||||
Me.Panel1.Controls.Add(Me.txt50x1)
|
||||
Me.Panel1.Controls.Add(Me.Label2)
|
||||
Me.Panel1.Controls.Add(Me.txtAusz50vonSaldo)
|
||||
Me.Panel1.Controls.Add(Me.Label3)
|
||||
Me.Panel1.Controls.Add(Me.picDel)
|
||||
Me.Panel1.Controls.Add(Me.Label4)
|
||||
Me.Panel1.Controls.Add(Me.Label6)
|
||||
Me.Panel1.Controls.Add(Me.txt100)
|
||||
Me.Panel1.Controls.Add(Me.txtlfdSaldo)
|
||||
Me.Panel1.Controls.Add(Me.txt50)
|
||||
Me.Panel1.Controls.Add(Me.Label1)
|
||||
Me.Panel1.Controls.Add(Me.txtMehr)
|
||||
Me.Panel1.Controls.Add(Me.txtberAusz50)
|
||||
Me.Panel1.Controls.Add(Me.Label5)
|
||||
Me.Panel1.Controls.Add(Me.txtberAusz100)
|
||||
Me.Panel1.Controls.Add(Me.txtAusz)
|
||||
Me.Panel1.Controls.Add(Me.txtSummeAuszb)
|
||||
Me.Panel1.Controls.Add(Me.Button1)
|
||||
Me.Panel1.Controls.Add(Me.txt100x2)
|
||||
Me.Panel1.Controls.Add(Me.txt50x15)
|
||||
Me.Panel1.Controls.Add(Me.txtAusz100)
|
||||
Me.Panel1.Controls.Add(Me.txtAusz50)
|
||||
Me.Panel1.Location = New System.Drawing.Point(15, 67)
|
||||
Me.Panel1.Name = "Panel1"
|
||||
Me.Panel1.Size = New System.Drawing.Size(421, 219)
|
||||
Me.Panel1.TabIndex = 30
|
||||
'
|
||||
'dgvUeberstunden
|
||||
'
|
||||
Me.dgvUeberstunden.AKTUALISIERUNGS_INTERVALL = -1
|
||||
Me.dgvUeberstunden.AllowUserToAddRows = False
|
||||
Me.dgvUeberstunden.AllowUserToDeleteRows = False
|
||||
Me.dgvUeberstunden.BackgroundColor = System.Drawing.Color.White
|
||||
Me.dgvUeberstunden.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize
|
||||
Me.dgvUeberstunden.Location = New System.Drawing.Point(381, 12)
|
||||
Me.dgvUeberstunden.Name = "dgvUeberstunden"
|
||||
Me.dgvUeberstunden.ReadOnly = True
|
||||
Me.dgvUeberstunden.Size = New System.Drawing.Size(32, 20)
|
||||
Me.dgvUeberstunden.TabIndex = 13
|
||||
Me.dgvUeberstunden.Visible = False
|
||||
'
|
||||
'txt50x1
|
||||
'
|
||||
Me.txt50x1.Location = New System.Drawing.Point(112, 108)
|
||||
Me.txt50x1.Name = "txt50x1"
|
||||
Me.txt50x1.ReadOnly = True
|
||||
Me.txt50x1.Size = New System.Drawing.Size(49, 20)
|
||||
Me.txt50x1.TabIndex = 32
|
||||
Me.txt50x1.Text = "0"
|
||||
'
|
||||
'Label8
|
||||
'
|
||||
Me.Label8.AutoSize = True
|
||||
Me.Label8.Location = New System.Drawing.Point(194, 179)
|
||||
Me.Label8.Name = "Label8"
|
||||
Me.Label8.Size = New System.Drawing.Size(56, 13)
|
||||
Me.Label8.TabIndex = 33
|
||||
Me.Label8.Text = "Auszahlen"
|
||||
'
|
||||
'frmUeberstundenauszahlen
|
||||
'
|
||||
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
||||
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
|
||||
Me.ClientSize = New System.Drawing.Size(463, 337)
|
||||
Me.Controls.Add(Me.Panel1)
|
||||
Me.Controls.Add(Me.lblBis)
|
||||
Me.Controls.Add(Me.dtpBis)
|
||||
Me.Controls.Add(Me.cbxabwDatum)
|
||||
Me.Controls.Add(Me.dgvUeberstunden)
|
||||
Me.Controls.Add(Me.Label7)
|
||||
Me.Controls.Add(Me.lblMA)
|
||||
Me.Controls.Add(Me.lblMonat)
|
||||
Me.Controls.Add(Me.dtpMonat)
|
||||
Me.Name = "frmUeberstundenauszahlen"
|
||||
Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
|
||||
Me.Text = "Überstunden auszahlen"
|
||||
CType(Me.picDel, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
Me.Panel1.ResumeLayout(False)
|
||||
Me.Panel1.PerformLayout()
|
||||
CType(Me.dgvUeberstunden, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
Me.ResumeLayout(False)
|
||||
Me.PerformLayout()
|
||||
|
||||
End Sub
|
||||
|
||||
Friend WithEvents dtpMonat As Windows.Forms.DateTimePicker
|
||||
Friend WithEvents lblMonat As Windows.Forms.Label
|
||||
Friend WithEvents Label2 As Windows.Forms.Label
|
||||
Friend WithEvents Label3 As Windows.Forms.Label
|
||||
Friend WithEvents Label4 As Windows.Forms.Label
|
||||
Friend WithEvents txt100 As Windows.Forms.TextBox
|
||||
Friend WithEvents txt50 As Windows.Forms.TextBox
|
||||
Friend WithEvents txtMehr As Windows.Forms.TextBox
|
||||
Friend WithEvents Label5 As Windows.Forms.Label
|
||||
Friend WithEvents txtAusz As Windows.Forms.TextBox
|
||||
Friend WithEvents lblMA As Windows.Forms.Label
|
||||
Friend WithEvents Label7 As Windows.Forms.Label
|
||||
Friend WithEvents Button1 As Windows.Forms.Button
|
||||
Friend WithEvents dgvUeberstunden As MyDatagridview
|
||||
Friend WithEvents txt100x2 As Windows.Forms.TextBox
|
||||
Friend WithEvents txt50x15 As Windows.Forms.TextBox
|
||||
Friend WithEvents txtAusz100 As Windows.Forms.TextBox
|
||||
Friend WithEvents txtAusz50 As Windows.Forms.TextBox
|
||||
Friend WithEvents CheckVatTestService1 As eu.europa.ec.checkVatTestService
|
||||
Friend WithEvents cbxabwDatum As Windows.Forms.CheckBox
|
||||
Friend WithEvents lblBis As Windows.Forms.Label
|
||||
Friend WithEvents dtpBis As Windows.Forms.DateTimePicker
|
||||
Friend WithEvents txtSummeAuszb As Windows.Forms.TextBox
|
||||
Friend WithEvents txtberAusz50 As Windows.Forms.TextBox
|
||||
Friend WithEvents txtberAusz100 As Windows.Forms.TextBox
|
||||
Friend WithEvents Label1 As Windows.Forms.Label
|
||||
Friend WithEvents txtlfdSaldo As Windows.Forms.TextBox
|
||||
Friend WithEvents Label6 As Windows.Forms.Label
|
||||
Friend WithEvents picDel As Windows.Forms.PictureBox
|
||||
Friend WithEvents txtAusz50vonSaldo As Windows.Forms.TextBox
|
||||
Friend WithEvents Panel1 As Windows.Forms.Panel
|
||||
Friend WithEvents txt50x1 As Windows.Forms.TextBox
|
||||
Friend WithEvents Label8 As Windows.Forms.Label
|
||||
End Class
|
||||
@@ -0,0 +1,123 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<metadata name="CheckVatTestService1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>17, 17</value>
|
||||
</metadata>
|
||||
</root>
|
||||
@@ -0,0 +1,439 @@
|
||||
Imports System.Runtime.InteropServices.ComTypes
|
||||
Imports System.Threading
|
||||
Imports System.Windows.Forms
|
||||
Imports Microsoft.Office.Interop.Outlook
|
||||
|
||||
Public Class frmUeberstundenauszahlen
|
||||
|
||||
Dim MA As cMitarbeiter = Nothing
|
||||
Dim timas As cTimasAPI = New cTimasAPI
|
||||
Dim dt As New DataTable
|
||||
Dim timeaccountdt As New DataTable
|
||||
Dim dtResult As New DataTable
|
||||
Dim tag As cFeiertage
|
||||
Dim auszahlugsdatum As New Date
|
||||
|
||||
Dim stunden100ausz, stunden50ausz, stunden100auszbere, stunden50auszbere, stunden100bereitsausbezahl, stunden50bereitsausbezahlt, mehrabeit, stundenlfdSaldo, stundenlfdSaldobere As Double
|
||||
|
||||
|
||||
Sub New(mit_id)
|
||||
|
||||
' Dieser Aufruf ist für den Designer erforderlich.
|
||||
InitializeComponent()
|
||||
|
||||
' Fügen Sie Initialisierungen nach dem InitializeComponent()-Aufruf hinzu.
|
||||
MA = New cMitarbeiter(mit_id)
|
||||
tag = New cFeiertage(DateTime.Parse(dtpMonat.Value).Year)
|
||||
Label7.Text = MA.mit_vname & " " & MA.mit_nname
|
||||
timas.getTimeaccountList(dt)
|
||||
|
||||
|
||||
Dim dv = New DataView(dt)
|
||||
dv.RowFilter = "info like '%zuschlag%' Or name = 'Mehrarbeit' Or name like 'Überstunden%' Or info like 'Auszahlungskonto%' Or name like '%01-Lfd Saldo%'"
|
||||
timeaccountdt = dv.ToTable
|
||||
|
||||
getUeberstunden(False)
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub DateTimePicker1_ValueChanged(sender As Object, e As EventArgs) Handles dtpMonat.ValueChanged, dtpBis.ValueChanged
|
||||
getUeberstunden(cbxabwDatum.Checked)
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub getUeberstunden(abwDatum As Boolean)
|
||||
|
||||
Dim startdate, enddate As Date
|
||||
If timeaccountdt IsNot Nothing Then
|
||||
|
||||
If abwDatum Then
|
||||
startdate = (dtpMonat.Value)
|
||||
enddate = (dtpBis.Value)
|
||||
auszahlugsdatum = enddate
|
||||
Else
|
||||
startdate = tag.GetFirstyDayYInxMonth(DateTime.Parse(dtpMonat.Value).DayOfWeek, DateTime.Parse(dtpMonat.Value).Month, DateTime.Parse(dtpMonat.Value).Year, True)
|
||||
enddate = tag.GetLastyDayYInxMonth(DateTime.Parse(dtpMonat.Value).DayOfWeek, DateTime.Parse(dtpMonat.Value).Month, DateTime.Parse(dtpMonat.Value).Year, True)
|
||||
auszahlugsdatum = enddate
|
||||
End If
|
||||
|
||||
timas.getTimeAccounts(startdate, enddate, MA.mit_timasId, timeaccountdt, dtResult)
|
||||
|
||||
If dtResult.Rows.Count < 1 Then
|
||||
MsgBox("Es konnten keine Stunden ermittelt werden!")
|
||||
Panel1.Enabled = False
|
||||
Exit Sub
|
||||
Else
|
||||
Panel1.Enabled = True
|
||||
End If
|
||||
|
||||
Dim dt = calcUeberstunden(timeaccountdt, dtResult)
|
||||
fillFields(dt)
|
||||
dgvUeberstunden.DataSource = dt
|
||||
|
||||
End If
|
||||
End Sub
|
||||
|
||||
|
||||
Private Function calcUeberstunden(dtAccouts As DataTable, dtSumUeberstunden As DataTable) As DataTable
|
||||
Dim dtmerged As DataTable
|
||||
If dtAccouts IsNot Nothing AndAlso dtSumUeberstunden IsNot Nothing Then
|
||||
|
||||
dtmerged = dtAccouts.Clone
|
||||
dtmerged.Merge(dtSumUeberstunden, False, MissingSchemaAction.Add)
|
||||
|
||||
If (dtmerged.Columns.Contains("accountType")) Then
|
||||
dtmerged.Columns.Remove("accountType")
|
||||
dtmerged.AcceptChanges()
|
||||
End If
|
||||
|
||||
If (dtmerged.Columns.Contains("info")) Then
|
||||
dtmerged.Columns.Remove("info")
|
||||
dtmerged.AcceptChanges()
|
||||
End If
|
||||
|
||||
If (dtmerged.Columns.Contains("number")) Then
|
||||
dtmerged.Columns.Remove("number")
|
||||
dtmerged.AcceptChanges()
|
||||
End If
|
||||
|
||||
If (dtmerged.Columns.Contains("date")) Then
|
||||
dtmerged.Columns.Remove("date")
|
||||
dtmerged.AcceptChanges()
|
||||
End If
|
||||
|
||||
|
||||
Dim groups = dtmerged.AsEnumerable().
|
||||
GroupBy(Function(row) New With {
|
||||
Key .Id = row.Field(Of Integer)("accountid"),
|
||||
Key .Multi = row.Field(Of String)("multiplier")
|
||||
})
|
||||
|
||||
Dim tableResult = dtmerged.Clone()
|
||||
For Each grp In groups
|
||||
|
||||
tableResult.Rows.Add(grp.Key.Id, grp.Key.Multi,
|
||||
grp.Sum(Function(row)
|
||||
Dim value = 0
|
||||
If Not IsDBNull(row.Item("value")) Then value = row.Item("value")
|
||||
Return value
|
||||
End Function))
|
||||
Next
|
||||
|
||||
|
||||
End If
|
||||
Return dtmerged
|
||||
End Function
|
||||
|
||||
Public Sub fillFields(dt As DataTable)
|
||||
|
||||
'69 10-Na 22-06
|
||||
'70 11-Sa 00-24 ===> 50%
|
||||
'72 13-So 00-24
|
||||
'73 14-FtN 00-24
|
||||
'1209 Mehrarbeit
|
||||
'1235 Überstunden 100% gesamt ===> 100%
|
||||
|
||||
picDel.Visible = False
|
||||
|
||||
For Each c As Control In Panel1.Controls
|
||||
If TypeOf c Is TextBox Then
|
||||
c.Text = "0"
|
||||
End If
|
||||
Next
|
||||
|
||||
stunden50bereitsausbezahlt = 0
|
||||
stunden100bereitsausbezahl = 0
|
||||
|
||||
|
||||
If dt IsNot Nothing AndAlso dt.Rows.Count > 0 Then
|
||||
Dim calc As Double = 0
|
||||
For Each r As DataRow In dt.Rows
|
||||
If Not IsDBNull(r.Item("value")) Then
|
||||
|
||||
If r.Item("accountid") = "1209" Then
|
||||
calc = CDbl(txtMehr.Text)
|
||||
calc += r.Item("value") * (r.Item("multiplier") & "1")
|
||||
txtMehr.Text = calc
|
||||
mehrabeit = calc
|
||||
End If
|
||||
|
||||
If r.Item("accountid") = "1235" Then
|
||||
calc = CDbl(txt100.Text)
|
||||
calc += r.Item("value") * (r.Item("multiplier") & "1")
|
||||
txt100.Text = calc
|
||||
stunden100ausz = calc
|
||||
End If
|
||||
|
||||
If r.Item("accountid") = "70" Then
|
||||
calc = CDbl(txt50.Text)
|
||||
calc += r.Item("value") * (r.Item("multiplier") & "1")
|
||||
txt50.Text = calc
|
||||
stunden50ausz = calc
|
||||
End If
|
||||
|
||||
|
||||
If r.Item("accountid") = "1550" Then
|
||||
calc = CDbl(txtberAusz100.Text)
|
||||
calc += r.Item("value") * (r.Item("multiplier") & "1")
|
||||
txtberAusz100.Text = calc
|
||||
stunden100bereitsausbezahl = calc
|
||||
End If
|
||||
|
||||
If r.Item("accountid") = "1551" Then
|
||||
calc = CDbl(txtberAusz50.Text)
|
||||
calc += r.Item("value") * (r.Item("multiplier") & "1")
|
||||
txtberAusz50.Text = calc
|
||||
stunden50bereitsausbezahlt = calc
|
||||
End If
|
||||
|
||||
'If r.Item("accountid") = "65" Then
|
||||
' calc = CDbl(txtlfdSaldo.Text)
|
||||
' calc += r.Item("value") * (r.Item("multiplier") & "1")
|
||||
' txtlfdSaldo.Text = calc
|
||||
'End If
|
||||
|
||||
End If
|
||||
Next
|
||||
|
||||
If (stunden100bereitsausbezahl + stunden50bereitsausbezahlt) > 0 Then
|
||||
picDel.Visible = True
|
||||
Button1.Enabled = False
|
||||
txtAusz.Enabled = False
|
||||
Else
|
||||
Button1.Enabled = True
|
||||
txtAusz.Enabled = True
|
||||
End If
|
||||
|
||||
stunden100auszbere = stunden100ausz * 2
|
||||
stunden50auszbere = stunden50ausz * 1.5
|
||||
|
||||
txt100x2.Text = stunden100auszbere
|
||||
txt50x15.Text = stunden50auszbere
|
||||
|
||||
txtlfdSaldo.Text = timas.getTimeSaldo(MA.mit_timasId, "", "overallBalance") 'Saldo zu Stichtag, nicht aktueller Saldo!!!
|
||||
|
||||
stundenlfdSaldo = CDbl(txtlfdSaldo.Text)
|
||||
stundenlfdSaldobere = stundenlfdSaldo
|
||||
|
||||
stundenlfdSaldobere -= stunden100auszbere
|
||||
stundenlfdSaldobere -= stunden50auszbere
|
||||
stundenlfdSaldobere = Math.Round(stundenlfdSaldobere, 2)
|
||||
|
||||
|
||||
If stundenlfdSaldo <= 0 Then Button1.Enabled = False
|
||||
|
||||
txtSummeAuszb.Text = stundenlfdSaldo
|
||||
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub txtAusz_TextChanged(sender As Object, e As EventArgs) Handles txtAusz.TextChanged
|
||||
|
||||
|
||||
|
||||
If txtAusz.Text <> "" AndAlso IsNumeric(txtAusz.Text) Then
|
||||
|
||||
Dim summeAusz = CDbl(txtAusz.Text)
|
||||
If summeAusz <= 0 Then
|
||||
txtAusz50vonSaldo.Text = "0"
|
||||
txtAusz50.Text = "0"
|
||||
txtAusz100.Text = "0"
|
||||
txtAusz.Text = "0"
|
||||
Button1.Enabled = False
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
txt100x2.Text = stunden100auszbere
|
||||
txt50x15.Text = stunden50auszbere
|
||||
txt50x1.Text = stundenlfdSaldobere
|
||||
|
||||
|
||||
|
||||
If stundenlfdSaldo >= summeAusz Then 'Prüfung, damit nicht zuviele ÜS ausbezahlt werden können!
|
||||
Button1.Enabled = True
|
||||
Else
|
||||
Button1.Enabled = False
|
||||
End If
|
||||
|
||||
|
||||
If summeAusz >= stunden100auszbere Then
|
||||
txtAusz100.Text = stunden100auszbere
|
||||
Else
|
||||
txtAusz100.Text = summeAusz
|
||||
End If
|
||||
|
||||
summeAusz = Math.Round(summeAusz - stunden100auszbere, 2)
|
||||
|
||||
If summeAusz >= stunden50auszbere Then
|
||||
txtAusz50.Text = stunden50auszbere
|
||||
summeAusz = Math.Round(summeAusz - stunden50auszbere, 2)
|
||||
ElseIf summeAusz < 0 Then
|
||||
txtAusz50.Text = "0"
|
||||
Else
|
||||
txtAusz50.Text = summeAusz
|
||||
summeAusz = Math.Round(summeAusz - stunden50auszbere, 2)
|
||||
End If
|
||||
|
||||
If summeAusz >= stundenlfdSaldo Then
|
||||
txtAusz50vonSaldo.Text = stundenlfdSaldo
|
||||
summeAusz = Math.Round(summeAusz - stundenlfdSaldo, 2)
|
||||
ElseIf summeAusz < 0 Then
|
||||
txtAusz50vonSaldo.Text = "0"
|
||||
Else
|
||||
txtAusz50vonSaldo.Text = summeAusz
|
||||
summeAusz = Math.Round(summeAusz - stundenlfdSaldo, 2)
|
||||
End If
|
||||
|
||||
|
||||
'Dim ausz100 As Double = (CDbl(txt100x2.Text))
|
||||
'Dim ausz50 As Double = (CDbl(txt50x15.Text))
|
||||
'Dim ausz50vonldfSaldo As Double = CDbl(txtlfdSaldo.Text)
|
||||
|
||||
'If ausz50 + ausz100 + ausz50vonldfSaldo >= summeAusz Then 'Prüfung, damit nicht zuviele ÜS ausbezahlt werden!
|
||||
' Button1.Enabled = True
|
||||
'Else
|
||||
' Button1.Enabled = False
|
||||
'End If
|
||||
|
||||
|
||||
'If summeAusz >= ausz100 Then
|
||||
' txtAusz100.Text = ausz100
|
||||
' summeAusz = summeAusz - ausz100
|
||||
'Else
|
||||
' txtAusz100.Text = summeAusz
|
||||
' summeAusz = summeAusz - ausz100
|
||||
'End If
|
||||
|
||||
'If summeAusz >= ausz50 Then
|
||||
' summeAusz = summeAusz - ausz50
|
||||
' txtAusz50.Text = ausz50
|
||||
'ElseIf summeAusz < 0 Then
|
||||
' txtAusz50.Text = "0"
|
||||
'Else
|
||||
' txtAusz50.Text = summeAusz
|
||||
' summeAusz = ausz50 - summeAusz
|
||||
'End If
|
||||
|
||||
'If summeAusz >= ausz50vonldfSaldo Then
|
||||
' summeAusz = summeAusz - ausz50vonldfSaldo
|
||||
' txtAusz50vonSaldo.Text = ausz50vonldfSaldo
|
||||
'ElseIf summeAusz < 0 Then
|
||||
' txtAusz50vonSaldo.Text = "0"
|
||||
'Else
|
||||
' txtAusz50vonSaldo.Text = summeAusz
|
||||
' summeAusz = ausz50vonldfSaldo - summeAusz
|
||||
'End If
|
||||
|
||||
|
||||
|
||||
|
||||
End If
|
||||
|
||||
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub cbxabwDatum_CheckedChanged(sender As Object, e As EventArgs) Handles cbxabwDatum.CheckedChanged
|
||||
If cbxabwDatum.Checked Then
|
||||
lblBis.Visible = True
|
||||
dtpBis.Visible = True
|
||||
lblMonat.Text = "bis"
|
||||
dtpMonat.CustomFormat = "yyyy/MM/dd"
|
||||
|
||||
Else
|
||||
lblBis.Visible = False
|
||||
dtpBis.Visible = False
|
||||
lblMonat.Text = "Monat"
|
||||
dtpMonat.CustomFormat = "yyyy/MM"
|
||||
|
||||
End If
|
||||
End Sub
|
||||
|
||||
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
|
||||
|
||||
|
||||
Dim sum100, sum50, gesamt As Double
|
||||
sum100 = Math.Round(CDbl(txtAusz100.Text) * 0.5, 2) 'Übergabe in ZE-System als heruntergerechnete 100%ige bzw. 50%ige ÜS!
|
||||
sum50 = Math.Round(CDbl(txtAusz50.Text) * 0.67, 2) + CDbl(txtAusz50vonSaldo.Text)
|
||||
gesamt = CDbl(txtAusz.Text)
|
||||
|
||||
Dim aksAuszahlung As MsgBoxResult = MsgBox("Überstunden für " & MA.mit_vname & " " & MA.mit_nname & " mit " & auszahlugsdatum.ToShortDateString() & " auszahlen?" & vbNewLine & sum100 & "x 100% ÜS :" & txtAusz100.Text & vbNewLine & sum50 & "x 50% ÜS: " & CDbl(txtAusz50.Text) + CDbl(txtAusz50vonSaldo.Text) & vbNewLine & "ÜS gesamt: " & gesamt, vbYesNo)
|
||||
|
||||
If aksAuszahlung = vbYes Then
|
||||
Dim dtsetEntries As New DataTable
|
||||
|
||||
dtsetEntries.Columns.Add("accountid", GetType(Integer))
|
||||
dtsetEntries.Columns.Add("value", GetType(String))
|
||||
|
||||
If sum100 >= 0 Then
|
||||
Dim row = dtsetEntries.NewRow
|
||||
row.Item("accountid") = 1550
|
||||
row.Item("value") = sum100.ToString.Replace(",", ".")
|
||||
dtsetEntries.Rows.InsertAt(row, dtsetEntries.Rows.Count)
|
||||
End If
|
||||
|
||||
If sum50 >= 0 Then
|
||||
Dim row = dtsetEntries.NewRow
|
||||
row.Item("accountid") = 1551
|
||||
row.Item("value") = sum50.ToString.Replace(",", ".")
|
||||
dtsetEntries.Rows.InsertAt(row, dtsetEntries.Rows.Count)
|
||||
End If
|
||||
|
||||
If gesamt >= 0 Then 'vom ldf Saldo, ev. über API Möglich monatliche Korrektur direkt zu befüllen, dann muss dieser If Zweig überarbeitet werden!!!!!!!!!!!!!!
|
||||
Dim row = dtsetEntries.NewRow
|
||||
row.Item("accountid") = 993
|
||||
row.Item("value") = gesamt.ToString.Replace(",", ".")
|
||||
dtsetEntries.Rows.InsertAt(row, dtsetEntries.Rows.Count)
|
||||
End If
|
||||
|
||||
|
||||
Dim info As String = ""
|
||||
If timas.setTimeAccountEntries(MA, dtsetEntries, auszahlugsdatum, info) Then
|
||||
|
||||
MsgBox("Erfolgreich in Timas eingetragen")
|
||||
Else
|
||||
MsgBox(info)
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
End Sub
|
||||
|
||||
Private Sub picDel_Click(sender As Object, e As EventArgs) Handles picDel.Click
|
||||
Dim aksAuszahlung As MsgBoxResult = MsgBox("Ausbezahlte Überstunden für " & MA.mit_vname & " " & MA.mit_nname & " mit " & auszahlugsdatum.ToShortDateString() & " zurücksetzen?" & vbNewLine & "100% ÜS: " & txtberAusz100.Text & vbNewLine & "50% ÜS: " & txtberAusz50.Text & vbNewLine & "ÜS gesamt: " & CDbl(txtberAusz100.Text) + CDbl(txtberAusz50.Text), vbYesNo)
|
||||
If aksAuszahlung = vbYes Then
|
||||
Dim dtdeleteEntries As New DataTable
|
||||
|
||||
dtdeleteEntries.Columns.Add("accountid", GetType(Integer))
|
||||
|
||||
|
||||
Dim rowNew = dtdeleteEntries.NewRow
|
||||
rowNew.Item("accountid") = 993
|
||||
dtdeleteEntries.Rows.InsertAt(rowNew, dtdeleteEntries.Rows.Count)
|
||||
|
||||
If txtAusz100.Text <> "" AndAlso IsNumeric(txtAusz100.Text) Then
|
||||
Dim row = dtdeleteEntries.NewRow
|
||||
row.Item("accountid") = 1550
|
||||
dtdeleteEntries.Rows.InsertAt(row, dtdeleteEntries.Rows.Count)
|
||||
End If
|
||||
|
||||
If txtAusz50.Text <> "" AndAlso IsNumeric(txtAusz50.Text) Then
|
||||
Dim row = dtdeleteEntries.NewRow
|
||||
row.Item("accountid") = 1551
|
||||
dtdeleteEntries.Rows.InsertAt(row, dtdeleteEntries.Rows.Count)
|
||||
End If
|
||||
|
||||
If timas.deleteTimeAccounts(auszahlugsdatum, auszahlugsdatum, MA.mit_timasId, dtdeleteEntries) Then
|
||||
|
||||
MsgBox("Erfolgreich aus Timas zurückgesetzt!")
|
||||
picDel.Visible = False
|
||||
Thread.Sleep(1000) 'warten bis Eintrag in Timas-DB
|
||||
getUeberstunden(cbxabwDatum.Checked)
|
||||
|
||||
End If
|
||||
|
||||
End If
|
||||
|
||||
End Sub
|
||||
End Class
|
||||
@@ -4,6 +4,7 @@ Imports System.Runtime.Remoting
|
||||
Imports System.Text
|
||||
Imports System.Threading
|
||||
Imports System.Windows.Forms
|
||||
Imports Microsoft.Office.Interop.Outlook
|
||||
|
||||
Public Class cTimasAPI
|
||||
|
||||
@@ -49,18 +50,19 @@ Public Class cTimasAPI
|
||||
|
||||
End Function
|
||||
|
||||
Public Sub getTimeSaldo(maid As Integer, ByRef info As String, ByRef Optional isEndpointRunning As Boolean = True)
|
||||
Public Function getTimeSaldo(maid As Integer, ByRef info As String, kindofbalance As String, ByRef Optional isEndpointRunning As Boolean = True) As Double
|
||||
Try
|
||||
Dim returnText As String = ""
|
||||
Dim failureText As String = ""
|
||||
Dim timesaldo As Double = -1
|
||||
|
||||
|
||||
If maid < 1 Then
|
||||
Exit Sub
|
||||
Return timesaldo
|
||||
End If
|
||||
|
||||
If Not checkConnectionTImas(failureText) Then
|
||||
Exit Sub
|
||||
Return timesaldo
|
||||
End If
|
||||
|
||||
|
||||
@@ -72,13 +74,13 @@ Public Class cTimasAPI
|
||||
Debug.WriteLine(rest.LastErrorText)
|
||||
isEndpointRunning = rest.LastMethodSuccess
|
||||
rest.IdleTimeoutMs = 30000 'defualt
|
||||
Exit Sub
|
||||
Return timesaldo
|
||||
End If
|
||||
|
||||
If (rest.ResponseStatusCode <> 200) Then
|
||||
Debug.WriteLine(rest.ResponseHeader)
|
||||
'lblTimas.Text = rest.ResponseStatusCode & " " & rest.ResponseStatusText
|
||||
Exit Sub
|
||||
Return timesaldo
|
||||
End If
|
||||
|
||||
Debug.WriteLine(responseJson)
|
||||
@@ -97,27 +99,30 @@ Public Class cTimasAPI
|
||||
'"monthlyBalance": -328380,
|
||||
'"actualTimeOfDay": 4260,
|
||||
|
||||
|
||||
Dim saldo = json.StringOf("dailyBalanceYesterday") 'Tagessaldo (gestern) in Sekunden
|
||||
|
||||
If saldo IsNot Nothing Then
|
||||
Dim saldoAsDouble = CDbl(saldo)
|
||||
saldoAsDouble = Math.Round(saldoAsDouble / 3600, 2)
|
||||
Dim infoBuilder As New StringBuilder
|
||||
'infoBuilder.Append("Vortag ")
|
||||
infoBuilder.Append(saldoAsDouble)
|
||||
infoBuilder.Append(" h")
|
||||
info = infoBuilder.ToString()
|
||||
If kindofbalance = "" Then
|
||||
info = "kindOfBalance nicht definiert! "
|
||||
Return timesaldo
|
||||
Else
|
||||
Dim saldo = json.StringOf(kindofbalance) 'Tagessaldo (gestern) in Sekunden
|
||||
If saldo IsNot Nothing Then
|
||||
Dim saldoAsDouble = CDbl(saldo)
|
||||
saldoAsDouble = Math.Round(saldoAsDouble / 3600, 2)
|
||||
Dim infoBuilder As New StringBuilder
|
||||
'infoBuilder.Append("Vortag ")
|
||||
infoBuilder.Append(saldoAsDouble)
|
||||
infoBuilder.Append(" h")
|
||||
info = infoBuilder.ToString()
|
||||
timesaldo = saldoAsDouble
|
||||
Return timesaldo
|
||||
End If
|
||||
Return timesaldo
|
||||
End If
|
||||
|
||||
|
||||
|
||||
|
||||
Catch ex As WebException
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
End Try
|
||||
|
||||
End Sub
|
||||
End Function
|
||||
|
||||
Public Function getTimeEntries(ByVal maid As Integer, ByRef dtZeiten As DataTable, Optional ByRef entryExistingToday As Boolean = True, Optional ByRef requestDone As Boolean = False, Optional ByRef isEndpointRunning As Boolean = True) As Boolean
|
||||
Try
|
||||
@@ -186,7 +191,7 @@ Public Class cTimasAPI
|
||||
Dim timeEntry As Chilkat.JsonObject = jsonArray.ObjectAt(j)
|
||||
|
||||
If IsDate(timeEntry.StringOf("stamp")) Then
|
||||
If CDate(timeEntry.StringOf("stamp")) >= CDate(Today()) Then
|
||||
If CDate(timeEntry.StringOf("stamp")) >= CDate(Today()) Or CDate(timeEntry.StringOf("stamp")) >= CDate(Today().AddDays(-1)) AndAlso CDate(timeEntry.StringOf("stamp")).Hour >= 16 Then 'entweder heute keine Stempelung oder gestern > 16 Uhr (wegen Nachtschicht!)
|
||||
|
||||
|
||||
Dim R As DataRow = dt.NewRow
|
||||
@@ -910,24 +915,22 @@ Public Class cTimasAPI
|
||||
dt.Columns.Add("Ausweis-Nr", GetType(Integer))
|
||||
dt.Columns.Add("Info", GetType(String))
|
||||
End If
|
||||
|
||||
dt.Clear()
|
||||
|
||||
Dim j As Integer = 0
|
||||
While j < num
|
||||
Dim j As Integer = 0
|
||||
While j < num
|
||||
|
||||
Dim employee As Chilkat.JsonObject = jsonArray.ObjectAt(j)
|
||||
|
||||
Dim R As DataRow = dt.NewRow
|
||||
R("Id") = employee.IntOf("id")
|
||||
'("externid") = employee.StringOf("externid")
|
||||
R("Personal-Nr (Lohn)") = employee.StringOf("pnr1")
|
||||
R("Vorname") = employee.StringOf("firstname")
|
||||
R("Nachname") = employee.StringOf("lastname")
|
||||
R("Geschlecht") = employee.StringOf("gender")
|
||||
R("Ausweis-Nr") = employee.IntOf("card")
|
||||
R("Info") = employee.StringOf("info")
|
||||
dt.Rows.Add(R)
|
||||
Dim employee As Chilkat.JsonObject = jsonArray.ObjectAt(j)
|
||||
Dim R As DataRow = dt.NewRow
|
||||
R("Id") = employee.IntOf("id")
|
||||
'("externid") = employee.StringOf("externid")
|
||||
R("Personal-Nr (Lohn)") = employee.StringOf("pnr1")
|
||||
R("Vorname") = employee.StringOf("firstname")
|
||||
R("Nachname") = employee.StringOf("lastname")
|
||||
R("Geschlecht") = employee.StringOf("gender")
|
||||
R("Ausweis-Nr") = employee.IntOf("card")
|
||||
R("Info") = employee.StringOf("info")
|
||||
dt.Rows.Add(R)
|
||||
j = j + 1
|
||||
End While
|
||||
|
||||
@@ -937,6 +940,274 @@ Public Class cTimasAPI
|
||||
End Try
|
||||
End Function
|
||||
|
||||
Public Sub getTimeAccounts(ByRef from As Date, ByRef toDate As Date, ByRef employeeNr As Integer, ByRef accountsdt As DataTable, ByRef dt As DataTable)
|
||||
|
||||
Try
|
||||
|
||||
Dim failureText As String = ""
|
||||
If Not checkConnectionTImas(failureText) Then
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
Dim success As Boolean
|
||||
|
||||
rest.ClearAllQueryParams()
|
||||
rest.AddQueryParam("from", from.Date.ToString("yyyy-MM-dd"))
|
||||
rest.AddQueryParam("to", toDate.Date.ToString("yyyy-MM-dd"))
|
||||
|
||||
Dim id As String = ""
|
||||
For Each row As DataRow In accountsdt.Rows
|
||||
id &= row("accountid") & ","
|
||||
Next
|
||||
rest.AddQueryParam("accounts", id)
|
||||
rest.AddQueryParam("employees", employeeNr)
|
||||
|
||||
Dim sbResponseBody As String
|
||||
|
||||
sbResponseBody = rest.FullRequestNoBody("GET", API_STRING & "/rest/web-api/accounts/values")
|
||||
If (rest.LastMethodSuccess <> True) Then
|
||||
Debug.WriteLine(rest.LastErrorText)
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
If (rest.ResponseStatusCode <> 200) Then
|
||||
Debug.WriteLine(rest.ResponseStatusCode & " " & rest.ResponseStatusText & sbResponseBody.ToString)
|
||||
End If
|
||||
|
||||
Debug.WriteLine(sbResponseBody)
|
||||
|
||||
Dim jsonArray As New Chilkat.JsonArray
|
||||
success = jsonArray.Load(sbResponseBody)
|
||||
If (success <> True) Then
|
||||
Debug.WriteLine(jsonArray.LastErrorText)
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
|
||||
Dim num As Integer = jsonArray.Size
|
||||
If num = -1 Then
|
||||
Exit Sub
|
||||
End If
|
||||
|
||||
If dt IsNot Nothing And Not dt.Columns.Contains("accountid") Then
|
||||
|
||||
dt.Columns.Add("accountid", GetType(Integer))
|
||||
dt.Columns.Add("date", GetType(String))
|
||||
dt.Columns.Add("value", GetType(Double))
|
||||
dt.Columns.Add("multiplier", GetType(String))
|
||||
Else
|
||||
dt.Clear()
|
||||
|
||||
End If
|
||||
|
||||
Dim j As Integer = 0
|
||||
While j < num
|
||||
|
||||
|
||||
Dim accounts As Chilkat.JsonObject = jsonArray.ObjectAt(j)
|
||||
If accounts.StringOf("value") <> "" Then
|
||||
Dim R As DataRow = dt.NewRow
|
||||
R("accountid") = accounts.IntOf("accountid")
|
||||
R("date") = accounts.StringOf("date")
|
||||
Dim timeToDouble = accounts.StringOf("value").Replace("-", "")
|
||||
Dim ts As TimeSpan = New TimeSpan(Integer.Parse(timeToDouble.Split(":"c)(0)), Integer.Parse(timeToDouble.Split(":"c)(1)), 0)
|
||||
R("value") = Math.Round(ts.TotalHours, 2)
|
||||
R("multiplier") = IIf(accounts.StringOf("value").Contains("-"), "-", "+")
|
||||
dt.Rows.Add(R)
|
||||
End If
|
||||
j = j + 1
|
||||
|
||||
End While
|
||||
|
||||
dt.DefaultView.Sort = " accountid asc, date asc"
|
||||
dt = dt.DefaultView.ToTable()
|
||||
|
||||
|
||||
Catch ex As WebException
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
End Try
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
Public Function getTimeaccountList(ByRef dt As DataTable) As String
|
||||
|
||||
Dim failureText As String = ""
|
||||
|
||||
Try
|
||||
|
||||
If Not checkConnectionTImas(failureText) Then
|
||||
Return failureText
|
||||
|
||||
End If
|
||||
|
||||
Dim responseJson As String = rest.FullRequestNoBody("GET", "/rest/web-api/accounts/")
|
||||
If (rest.LastMethodSuccess <> True) Then
|
||||
Debug.WriteLine(rest.LastErrorText)
|
||||
Return rest.LastErrorText
|
||||
End If
|
||||
|
||||
If (rest.ResponseStatusCode <> 200) Then
|
||||
Debug.WriteLine(rest.ResponseHeader)
|
||||
failureText = rest.ResponseStatusCode & " " & rest.ResponseStatusText
|
||||
Return rest.ResponseStatusCode & " " & rest.ResponseStatusText
|
||||
End If
|
||||
|
||||
Debug.WriteLine(responseJson)
|
||||
|
||||
Dim jsonArray As New Chilkat.JsonArray
|
||||
Dim success As Boolean = jsonArray.Load(responseJson)
|
||||
If (success <> True) Then
|
||||
Debug.WriteLine(jsonArray.LastErrorText)
|
||||
Return jsonArray.LastErrorText
|
||||
End If
|
||||
|
||||
|
||||
Dim num As Integer = jsonArray.Size
|
||||
If num = -1 Then
|
||||
Return "Array Failure"
|
||||
End If
|
||||
|
||||
If dt IsNot Nothing AndAlso Not dt.Columns.Contains("accountid") Then
|
||||
dt.Columns.Add("accountid", GetType(Integer))
|
||||
dt.Columns.Add("name", GetType(String))
|
||||
dt.Columns.Add("accountType", GetType(String))
|
||||
dt.Columns.Add("info", GetType(String))
|
||||
dt.Columns.Add("number", GetType(Integer))
|
||||
End If
|
||||
|
||||
dt.Clear()
|
||||
|
||||
Dim j As Integer = 0
|
||||
While j < num
|
||||
|
||||
Dim R As DataRow = dt.NewRow
|
||||
R("accountid") = jsonArray.ObjectAt(j).IntOf("id")
|
||||
R("name") = jsonArray.ObjectAt(j).StringOf("name")
|
||||
R("accountType") = jsonArray.ObjectAt(j).StringOf("accountType")
|
||||
R("info") = jsonArray.ObjectAt(j).StringOf("info")
|
||||
R("number") = jsonArray.ObjectAt(j).IntOf("number")
|
||||
dt.Rows.Add(R)
|
||||
j = j + 1
|
||||
End While
|
||||
|
||||
|
||||
Catch ex As WebException
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
End Try
|
||||
End Function
|
||||
|
||||
|
||||
|
||||
|
||||
Public Function setTimeAccountEntries(ByVal mitarbeiter As cMitarbeiter, ByVal accountEntrys As DataTable, ByVal accountdate As Date, ByRef info As String)
|
||||
Dim failureText As String = ""
|
||||
Dim timeEntryCreated As Boolean = False
|
||||
|
||||
If Not checkConnectionTImas(failureText) Then
|
||||
Return timeEntryCreated
|
||||
End If
|
||||
|
||||
If Not mitarbeiter.mit_timasId > 0 Then
|
||||
info = "Mitarbeiter besitzt keine Timas-Zuordnung"
|
||||
Return timeEntryCreated
|
||||
End If
|
||||
|
||||
Dim jsonArr As New Chilkat.JsonArray
|
||||
|
||||
For Each ae As DataRow In accountEntrys.Rows
|
||||
|
||||
jsonArr.AddObjectAt(-1)
|
||||
Dim Json As Chilkat.JsonObject = jsonArr.ObjectAt(jsonArr.Size - 1)
|
||||
Json.UpdateInt("accountid", ae.Item("accountid"))
|
||||
json.UpdateInt("employeeid", mitarbeiter.mit_timasId)
|
||||
json.UpdateString("date", accountdate.ToString("yyyy-MM-dd"))
|
||||
json.UpdateString("value", ae.Item("value"))
|
||||
|
||||
Next
|
||||
|
||||
|
||||
Dim sbRequestBody As New Chilkat.StringBuilder
|
||||
jsonArr.EmitSb(sbRequestBody)
|
||||
|
||||
Dim sbResponseBody As New Chilkat.StringBuilder
|
||||
Dim success = rest.FullRequestSb("POST", "/rest/web-api/accounts/values", sbRequestBody, sbResponseBody)
|
||||
If (success <> True) Then
|
||||
Debug.WriteLine(rest.LastErrorText)
|
||||
Return timeEntryCreated
|
||||
End If
|
||||
|
||||
|
||||
If (rest.LastMethodSuccess <> True) Then
|
||||
Debug.WriteLine(rest.LastErrorText)
|
||||
info = rest.LastErrorText
|
||||
Return timeEntryCreated
|
||||
End If
|
||||
|
||||
If (rest.ResponseStatusCode <> 200) Then
|
||||
Debug.WriteLine(rest.ResponseHeader)
|
||||
info = rest.ResponseStatusCode & " " & rest.ResponseStatusText
|
||||
If sbResponseBody.GetAsString <> "" Then
|
||||
info &= vbNewLine & sbResponseBody.GetAsString
|
||||
End If
|
||||
Return timeEntryCreated
|
||||
Else
|
||||
|
||||
timeEntryCreated = True
|
||||
|
||||
End If
|
||||
|
||||
Return timeEntryCreated
|
||||
|
||||
|
||||
End Function
|
||||
|
||||
Public Function deleteTimeAccounts(ByRef from As Date, ByRef toDate As Date, ByRef employeeNr As Integer, ByRef accountsdt As DataTable) As Boolean
|
||||
Dim timeEntryDeleted As Boolean = False
|
||||
Try
|
||||
|
||||
Dim failureText As String = ""
|
||||
If Not checkConnectionTImas(failureText) Then
|
||||
Return timeEntryDeleted
|
||||
End If
|
||||
|
||||
Dim success As Boolean
|
||||
|
||||
rest.ClearAllQueryParams()
|
||||
rest.AddQueryParam("from", from.Date.ToString("yyyy-MM-dd"))
|
||||
rest.AddQueryParam("to", toDate.Date.ToString("yyyy-MM-dd"))
|
||||
|
||||
Dim id As String = ""
|
||||
For Each row As DataRow In accountsdt.Rows
|
||||
id &= row("accountid") & ","
|
||||
Next
|
||||
rest.AddQueryParam("accounts", id)
|
||||
rest.AddQueryParam("employees", employeeNr)
|
||||
|
||||
Dim sbResponseBody As String
|
||||
|
||||
sbResponseBody = rest.FullRequestNoBody("DELETE", API_STRING & "/rest/web-api/accounts/values")
|
||||
If (rest.LastMethodSuccess <> True) Then
|
||||
Debug.WriteLine(rest.LastErrorText)
|
||||
Return timeEntryDeleted
|
||||
End If
|
||||
|
||||
If (rest.ResponseStatusCode <> 200) Then
|
||||
Debug.WriteLine(rest.ResponseStatusCode & " " & rest.ResponseStatusText & sbResponseBody.ToString)
|
||||
Return timeEntryDeleted
|
||||
Else
|
||||
timeEntryDeleted = True
|
||||
End If
|
||||
|
||||
Return timeEntryDeleted
|
||||
|
||||
Catch ex As WebException
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
End Try
|
||||
|
||||
End Function
|
||||
|
||||
|
||||
|
||||
End Class
|
||||
|
||||
@@ -988,6 +1259,4 @@ Public Class cTimasGruppe
|
||||
Me.empID = empId
|
||||
End Sub
|
||||
|
||||
|
||||
|
||||
End Class
|
||||
@@ -16,12 +16,12 @@
|
||||
<TargetFrameworkProfile />
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<PlatformTarget>x64</PlatformTarget>
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<DefineDebug>true</DefineDebug>
|
||||
<DefineTrace>true</DefineTrace>
|
||||
<OutputPath>..\..\..\VERAG_PROG_ALLGEMEIN\bin\Debug\</OutputPath>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DocumentationFile>VERAG_PROG_ALLGEMEIN.xml</DocumentationFile>
|
||||
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
|
||||
</PropertyGroup>
|
||||
@@ -380,6 +380,12 @@
|
||||
<Compile Include="frmErrorMeldung.vb">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="Mitarbeiterverzeichnis\frmUeberstundenauszahlen.Designer.vb">
|
||||
<DependentUpon>frmUeberstundenauszahlen.vb</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="Mitarbeiterverzeichnis\frmUeberstundenauszahlen.vb">
|
||||
<SubType>Form</SubType>
|
||||
</Compile>
|
||||
<Compile Include="My Project\Resources.Designer.vb">
|
||||
<DesignTime>True</DesignTime>
|
||||
<AutoGen>True</AutoGen>
|
||||
@@ -766,6 +772,9 @@
|
||||
<EmbeddedResource Include="Mitarbeiterverzeichnis\frmMitarbeitersuche.resx">
|
||||
<DependentUpon>frmMitarbeitersuche.vb</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="Mitarbeiterverzeichnis\frmUeberstundenauszahlen.resx">
|
||||
<DependentUpon>frmUeberstundenauszahlen.vb</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="My Project\Resources.resx">
|
||||
<Generator>VbMyResourcesResXFileCodeGenerator</Generator>
|
||||
<CustomToolNamespace>My.Resources</CustomToolNamespace>
|
||||
|
||||
Reference in New Issue
Block a user