ModaltransAPI
This commit is contained in:
@@ -1,166 +0,0 @@
|
||||
Public Class cOregonNCTSDeclarations
|
||||
|
||||
Public Class PacksAttribute
|
||||
Public Property pack_count As Integer
|
||||
Public Property pack_type As String
|
||||
Public Property notes As String
|
||||
End Class
|
||||
|
||||
Public Class DocumentsAttribute
|
||||
Public Property doc_type As String
|
||||
Public Property doc_no As String
|
||||
Public Property pre_post As String
|
||||
End Class
|
||||
|
||||
Public Class ProducedDocumentsAttribute
|
||||
Public Property code As String
|
||||
Public Property reference As String
|
||||
Public Property status As String
|
||||
Public Property reason As String
|
||||
Public Property quantity As Integer
|
||||
End Class
|
||||
|
||||
Public Class AdditionalCodesAttribute
|
||||
Public Property code As String
|
||||
Public Property notes As String
|
||||
End Class
|
||||
|
||||
Public Class GoodsAttribute
|
||||
Public Property commodity As String
|
||||
Public Property gtip_code As String
|
||||
Public Property gtip_language As String
|
||||
Public Property brut_wg As Double
|
||||
Public Property net_wg As Double
|
||||
Public Property sender_name As String
|
||||
Public Property sender_address As String
|
||||
Public Property sender_city_name As String
|
||||
Public Property sender_country_id As String
|
||||
Public Property sender_postcode As String
|
||||
Public Property sender_eori_code As String
|
||||
Public Property consignee_name As String
|
||||
Public Property consignee_address As String
|
||||
Public Property consignee_city_name As String
|
||||
Public Property consignee_country_id As String
|
||||
Public Property consignee_postcode As String
|
||||
Public Property consignee_eori_code As String
|
||||
Public Property invoice_amount As String
|
||||
Public Property invoice_curr As String
|
||||
Public Property cpc_code As String
|
||||
Public Property additional_cpc_code As String
|
||||
Public Property container_no As String
|
||||
Public Property preferential_country_id As String
|
||||
Public Property cus_code As String
|
||||
Public Property nature_of_transaction As String
|
||||
Public Property additional_commodity_codes As String
|
||||
Public Property origin_country_id As String
|
||||
Public Property preference_request As String
|
||||
Public Property quota_desc As String
|
||||
Public Property valuation_method As String
|
||||
Public Property valuation_adjustment As String
|
||||
Public Property third_quantity_type As String
|
||||
Public Property third_quantity As String
|
||||
Public Property supplementary_unit As String
|
||||
Public Property packs_attributes As PacksAttribute()
|
||||
Public Property documents_attributes As DocumentsAttribute()
|
||||
Public Property produced_documents_attributes As ProducedDocumentsAttribute()
|
||||
Public Property additional_codes_attributes As AdditionalCodesAttribute()
|
||||
End Class
|
||||
|
||||
Public Class PartiesAttribute
|
||||
Public Property party_role As String
|
||||
Public Property party_code As String
|
||||
Public Property eori_code As String
|
||||
End Class
|
||||
|
||||
Public Class TraderAdditionsAttribute
|
||||
Public Property code As String
|
||||
Public Property amount As Integer
|
||||
Public Property curr As String
|
||||
Public Property rate_code As Integer
|
||||
End Class
|
||||
|
||||
Public Class DeclarationData
|
||||
Public Property auto_send As Boolean
|
||||
Public Property badge_code As String
|
||||
Public Property service_code As String
|
||||
Public Property doc_type As String
|
||||
Public Property declaration_type As String
|
||||
Public Property commercial_ref As String
|
||||
Public Property ducr As String
|
||||
Public Property mucr As String
|
||||
Public Property ducr_part As String
|
||||
Public Property declarant_eori As String
|
||||
Public Property declarant_name As String
|
||||
Public Property declarant_address As String
|
||||
Public Property declarant_city_name As String
|
||||
Public Property declarant_country_id As String
|
||||
Public Property declarant_postcode As String
|
||||
Public Property declarant_rep As String
|
||||
Public Property export_country_id As String
|
||||
Public Property consignor_eori As String
|
||||
Public Property consignor_name As String
|
||||
Public Property consignor_address As String
|
||||
Public Property consignor_city_name As String
|
||||
Public Property consignor_country_id As String
|
||||
Public Property consignor_postcode As String
|
||||
Public Property multiple_consignor As Boolean
|
||||
Public Property import_country_id As String
|
||||
Public Property consignee_eori As String
|
||||
Public Property consignee_name As String
|
||||
Public Property consignee_address As String
|
||||
Public Property consignee_city_name As String
|
||||
Public Property consignee_country_id As String
|
||||
Public Property consignee_postcode As String
|
||||
Public Property multiple_consignee As Boolean
|
||||
Public Property invoice_amount As String
|
||||
Public Property invoice_curr As String
|
||||
Public Property goods_location As String
|
||||
Public Property border_transport_type As String
|
||||
Public Property border_vehicle_code As String
|
||||
Public Property border_vehicle_coun As String
|
||||
Public Property inland_transport_type As String
|
||||
Public Property container_no As String
|
||||
Public Property gvms_interested As Boolean
|
||||
Public Property freight_amount As String
|
||||
Public Property freight_curr As String
|
||||
Public Property payment_method As String
|
||||
Public Property carrier_eori As String
|
||||
Public Property carrier_name As String
|
||||
Public Property carrier_address As String
|
||||
Public Property carrier_city_name As String
|
||||
Public Property carrier_country_id As String
|
||||
Public Property carrier_postcode As String
|
||||
Public Property total_packages As Integer
|
||||
Public Property nature_of_transaction As String
|
||||
Public Property premises_code As String
|
||||
Public Property first_dan_no As String
|
||||
Public Property second_dan_no As String
|
||||
Public Property insurance_amount As String
|
||||
Public Property insurance_curr As String
|
||||
Public Property other_amounts As String
|
||||
Public Property other_amounts_curr As String
|
||||
Public Property apportment_indicator As String
|
||||
Public Property total_gross_weight As String
|
||||
Public Property total_net_weight As String
|
||||
Public Property airfreight_cost As String
|
||||
Public Property vat_adjustment As String
|
||||
Public Property vat_adjustment_curr As String
|
||||
Public Property discount_amount As String
|
||||
Public Property discount_curr As String
|
||||
Public Property discount_rate As String
|
||||
Public Property incoterm As String
|
||||
Public Property incoterm_location As String
|
||||
Public Property trader_ref As String
|
||||
Public Property arrival_transport_type As String
|
||||
Public Property guarantee_code As Integer
|
||||
Public Property guarantee_reference As String
|
||||
Public Property goods_attributes As GoodsAttribute()
|
||||
Public Property parties_attributes As PartiesAttribute()
|
||||
Public Property trader_additions_attributes As TraderAdditionsAttribute()
|
||||
End Class
|
||||
|
||||
Public Class CustomsDeclaration
|
||||
Public Property declaration_data As DeclarationData
|
||||
End Class
|
||||
|
||||
End Class
|
||||
@@ -29,8 +29,11 @@ Partial Class frmMitarbeitersuche
|
||||
Me.PictureBox2 = New System.Windows.Forms.PictureBox()
|
||||
Me.pnlMain = New System.Windows.Forms.Panel()
|
||||
Me.pnl = New System.Windows.Forms.Panel()
|
||||
Me.btnSettings = New System.Windows.Forms.Button()
|
||||
Me.PictureBox9 = New System.Windows.Forms.PictureBox()
|
||||
Me.lblTimasSaldo = New System.Windows.Forms.Label()
|
||||
Me.lblTimasZeiten = New System.Windows.Forms.Label()
|
||||
Me.pnlWohnadresse = New System.Windows.Forms.Panel()
|
||||
Me.btnSettings = New System.Windows.Forms.Button()
|
||||
Me.lblWohnadresse = New System.Windows.Forms.Label()
|
||||
Me.Label6 = New System.Windows.Forms.Label()
|
||||
Me.lblSpitzname = New System.Windows.Forms.Label()
|
||||
@@ -54,8 +57,6 @@ Partial Class frmMitarbeitersuche
|
||||
Me.lblGeburtstag = New System.Windows.Forms.Label()
|
||||
Me.PictureBox1 = New System.Windows.Forms.PictureBox()
|
||||
Me.Panel1 = New System.Windows.Forms.Panel()
|
||||
Me.lblTimasZeiten = New System.Windows.Forms.Label()
|
||||
Me.lblTimasSaldo = New System.Windows.Forms.Label()
|
||||
Me.MyPanel1 = New VERAG_PROG_ALLGEMEIN.MyPanel()
|
||||
Me.lblPosition = New System.Windows.Forms.Label()
|
||||
Me.Label8 = New System.Windows.Forms.Label()
|
||||
@@ -70,6 +71,7 @@ Partial Class frmMitarbeitersuche
|
||||
CType(Me.PictureBox2, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.pnlMain.SuspendLayout()
|
||||
Me.pnl.SuspendLayout()
|
||||
CType(Me.PictureBox9, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.pnlWohnadresse.SuspendLayout()
|
||||
CType(Me.PictureBox3, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.pnlMotto.SuspendLayout()
|
||||
@@ -148,8 +150,9 @@ Partial Class frmMitarbeitersuche
|
||||
'pnl
|
||||
'
|
||||
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.lblTimasSaldo)
|
||||
Me.pnl.Controls.Add(Me.btnSettings)
|
||||
Me.pnl.Controls.Add(Me.PictureBox9)
|
||||
Me.pnl.Controls.Add(Me.lblTimasSaldo)
|
||||
Me.pnl.Controls.Add(Me.lblTimasZeiten)
|
||||
Me.pnl.Controls.Add(Me.pnlWohnadresse)
|
||||
Me.pnl.Controls.Add(Me.lblSpitzname)
|
||||
@@ -175,20 +178,33 @@ Partial Class frmMitarbeitersuche
|
||||
Me.pnl.Size = New System.Drawing.Size(774, 437)
|
||||
Me.pnl.TabIndex = 24
|
||||
'
|
||||
'btnSettings
|
||||
'PictureBox9
|
||||
'
|
||||
Me.btnSettings.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom
|
||||
Me.btnSettings.FlatStyle = System.Windows.Forms.FlatStyle.Flat
|
||||
Me.btnSettings.Image = Global.VERAG_PROG_ALLGEMEIN.My.Resources.Resources.wheel_s
|
||||
Me.btnSettings.ImageAlign = System.Drawing.ContentAlignment.TopLeft
|
||||
Me.btnSettings.Location = New System.Drawing.Point(647, 385)
|
||||
Me.btnSettings.Name = "btnSettings"
|
||||
Me.btnSettings.Size = New System.Drawing.Size(125, 35)
|
||||
Me.btnSettings.TabIndex = 29
|
||||
Me.btnSettings.Text = "Einstellungen"
|
||||
Me.btnSettings.TextAlign = System.Drawing.ContentAlignment.MiddleRight
|
||||
Me.btnSettings.UseVisualStyleBackColor = True
|
||||
Me.btnSettings.Visible = False
|
||||
Me.PictureBox9.Image = Global.VERAG_PROG_ALLGEMEIN.My.Resources.Resources.uhr_green
|
||||
Me.PictureBox9.Location = New System.Drawing.Point(7, 393)
|
||||
Me.PictureBox9.Name = "PictureBox9"
|
||||
Me.PictureBox9.Size = New System.Drawing.Size(34, 27)
|
||||
Me.PictureBox9.SizeMode = System.Windows.Forms.PictureBoxSizeMode.StretchImage
|
||||
Me.PictureBox9.TabIndex = 120
|
||||
Me.PictureBox9.TabStop = False
|
||||
'
|
||||
'lblTimasSaldo
|
||||
'
|
||||
Me.lblTimasSaldo.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!)
|
||||
Me.lblTimasSaldo.Location = New System.Drawing.Point(45, 396)
|
||||
Me.lblTimasSaldo.Name = "lblTimasSaldo"
|
||||
Me.lblTimasSaldo.Size = New System.Drawing.Size(157, 24)
|
||||
Me.lblTimasSaldo.TabIndex = 30
|
||||
Me.lblTimasSaldo.Visible = False
|
||||
'
|
||||
'lblTimasZeiten
|
||||
'
|
||||
Me.lblTimasZeiten.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!)
|
||||
Me.lblTimasZeiten.Location = New System.Drawing.Point(203, 396)
|
||||
Me.lblTimasZeiten.Name = "lblTimasZeiten"
|
||||
Me.lblTimasZeiten.Size = New System.Drawing.Size(563, 25)
|
||||
Me.lblTimasZeiten.TabIndex = 12
|
||||
Me.lblTimasZeiten.Visible = False
|
||||
'
|
||||
'pnlWohnadresse
|
||||
'
|
||||
@@ -199,6 +215,21 @@ Partial Class frmMitarbeitersuche
|
||||
Me.pnlWohnadresse.Size = New System.Drawing.Size(701, 34)
|
||||
Me.pnlWohnadresse.TabIndex = 20
|
||||
'
|
||||
'btnSettings
|
||||
'
|
||||
Me.btnSettings.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom
|
||||
Me.btnSettings.FlatStyle = System.Windows.Forms.FlatStyle.Flat
|
||||
Me.btnSettings.Image = Global.VERAG_PROG_ALLGEMEIN.My.Resources.Resources.wheel_s
|
||||
Me.btnSettings.ImageAlign = System.Drawing.ContentAlignment.TopLeft
|
||||
Me.btnSettings.Location = New System.Drawing.Point(650, 386)
|
||||
Me.btnSettings.Name = "btnSettings"
|
||||
Me.btnSettings.Size = New System.Drawing.Size(125, 35)
|
||||
Me.btnSettings.TabIndex = 29
|
||||
Me.btnSettings.Text = "Einstellungen"
|
||||
Me.btnSettings.TextAlign = System.Drawing.ContentAlignment.MiddleRight
|
||||
Me.btnSettings.UseVisualStyleBackColor = True
|
||||
Me.btnSettings.Visible = False
|
||||
'
|
||||
'lblWohnadresse
|
||||
'
|
||||
Me.lblWohnadresse.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Bold)
|
||||
@@ -426,24 +457,6 @@ Partial Class frmMitarbeitersuche
|
||||
Me.Panel1.Size = New System.Drawing.Size(553, 1)
|
||||
Me.Panel1.TabIndex = 29
|
||||
'
|
||||
'lblTimasZeiten
|
||||
'
|
||||
Me.lblTimasZeiten.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!)
|
||||
Me.lblTimasZeiten.Location = New System.Drawing.Point(203, 396)
|
||||
Me.lblTimasZeiten.Name = "lblTimasZeiten"
|
||||
Me.lblTimasZeiten.Size = New System.Drawing.Size(563, 25)
|
||||
Me.lblTimasZeiten.TabIndex = 12
|
||||
Me.lblTimasZeiten.Visible = False
|
||||
'
|
||||
'lblTimasSaldo
|
||||
'
|
||||
Me.lblTimasSaldo.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!)
|
||||
Me.lblTimasSaldo.Location = New System.Drawing.Point(6, 396)
|
||||
Me.lblTimasSaldo.Name = "lblTimasSaldo"
|
||||
Me.lblTimasSaldo.Size = New System.Drawing.Size(196, 24)
|
||||
Me.lblTimasSaldo.TabIndex = 30
|
||||
Me.lblTimasSaldo.Visible = False
|
||||
'
|
||||
'MyPanel1
|
||||
'
|
||||
Me.MyPanel1.BackColor = System.Drawing.Color.FromArgb(CType(CType(250, Byte), Integer), CType(CType(254, Byte), Integer), CType(CType(255, Byte), Integer))
|
||||
@@ -593,6 +606,7 @@ Partial Class frmMitarbeitersuche
|
||||
CType(Me.PictureBox2, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
Me.pnlMain.ResumeLayout(False)
|
||||
Me.pnl.ResumeLayout(False)
|
||||
CType(Me.PictureBox9, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
Me.pnlWohnadresse.ResumeLayout(False)
|
||||
CType(Me.PictureBox3, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
Me.pnlMotto.ResumeLayout(False)
|
||||
@@ -649,4 +663,5 @@ Partial Class frmMitarbeitersuche
|
||||
Friend WithEvents btnSettings As Windows.Forms.Button
|
||||
Friend WithEvents lblTimasZeiten As Windows.Forms.Label
|
||||
Friend WithEvents lblTimasSaldo As Windows.Forms.Label
|
||||
Friend WithEvents PictureBox9 As Windows.Forms.PictureBox
|
||||
End Class
|
||||
|
||||
@@ -383,6 +383,8 @@ Public Class frmMitarbeitersuche
|
||||
|
||||
End Sub
|
||||
|
||||
|
||||
|
||||
Private Sub PictureBox9_Click(sender As Object, e As EventArgs) Handles PictureBox9.Click
|
||||
Dim webAddress As String = "https://zeit.verag.ag/webterminal/"
|
||||
Process.Start(webAddress)
|
||||
End Sub
|
||||
End Class
|
||||
@@ -470,6 +470,16 @@ Namespace My.Resources
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Ressource vom Typ System.Drawing.Bitmap.
|
||||
'''</summary>
|
||||
Friend ReadOnly Property TiMaS_Paket_Time() As System.Drawing.Bitmap
|
||||
Get
|
||||
Dim obj As Object = ResourceManager.GetObject("TiMaS-Paket-Time", resourceCulture)
|
||||
Return CType(obj,System.Drawing.Bitmap)
|
||||
End Get
|
||||
End Property
|
||||
|
||||
'''<summary>
|
||||
''' Sucht eine lokalisierte Ressource vom Typ System.Drawing.Bitmap.
|
||||
'''</summary>
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
BIN
VERAG_PROG_ALLGEMEIN/Resources/TiMaS-Paket-Time.png
Normal file
BIN
VERAG_PROG_ALLGEMEIN/Resources/TiMaS-Paket-Time.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 11 KiB |
@@ -527,14 +527,6 @@ Public Class cATEZ_NCTS_IN
|
||||
Dim sbResponseBody As New Chilkat.StringBuilder
|
||||
success = rest.FullRequestSb("POST", "/api/integrations/verag", sbRequestBody, sbResponseBody)
|
||||
|
||||
'Dim bdRequest As New Chilkat.BinData
|
||||
'success = rest.GetLastDebugRequest(bdRequest)
|
||||
'Debug.WriteLine("----")
|
||||
'Debug.WriteLine(bdRequest.GetString("utf-8"))
|
||||
'Debug.WriteLine("----")
|
||||
|
||||
|
||||
|
||||
If (rest.LastMethodSuccess <> True) Then
|
||||
Debug.WriteLine(rest.LastErrorText)
|
||||
failureDesc = rest.LastErrorText
|
||||
@@ -556,9 +548,6 @@ Public Class cATEZ_NCTS_IN
|
||||
End If
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Catch ex As WebException
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
End Try
|
||||
@@ -606,7 +595,6 @@ Public Class cATEZ_NCTS_IN
|
||||
Next
|
||||
|
||||
|
||||
|
||||
For Each r As DataGridViewRow In dgv.Rows
|
||||
Dim isSelected = IIf(DBNull.Value Is r.Cells("anh_selekt").Value, False, r.Cells("anh_selekt").Value)
|
||||
If isSelected Then
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -6,7 +6,6 @@ Public Class cTimasAPI
|
||||
Dim rest As New Chilkat.Rest
|
||||
|
||||
|
||||
|
||||
Sub New()
|
||||
VERAG_PROG_ALLGEMEIN.cChilkat_Helper.UnlockCilkat()
|
||||
End Sub
|
||||
@@ -201,7 +200,7 @@ Public Class cTimasAPI
|
||||
|
||||
End Sub
|
||||
|
||||
Public Function createMA(ByVal mitarbeiter As cMitarbeiter, ByRef info As String, ByRef dgvData As MyDatagridview, Optional ByRef requestDone As Boolean = False)
|
||||
Public Function createMA(ByVal mitarbeiter As cMitarbeiter, ByRef info As String, ByRef datatableTimas As DataTable, Optional ByRef requestDone As Boolean = False)
|
||||
Try
|
||||
|
||||
rest.ClearAllHeaders()
|
||||
@@ -229,31 +228,34 @@ Public Class cTimasAPI
|
||||
success = json.UpdateString("lastname", mitarbeiter.mit_nname)
|
||||
success = json.UpdateString("gender", IIf(mitarbeiter.mit_geschlecht = "m", "male", "female"))
|
||||
'success = json.UpdateInt("card", 42)
|
||||
'success = json.UpdateString("info", "Gebäude 2, 1. OG, Büro 54")
|
||||
success = json.UpdateString("info", mitarbeiter.mit_firma & " - " & mitarbeiter.mit_abteilung)
|
||||
'success = json.UpdateString("clientNumber", "5600-02")
|
||||
'success = json.UpdateInt("rfid", 178230359)
|
||||
success = json.UpdateString("birthday", CDate(mitarbeiter.mit_gebdat).ToString("yyyy-MM-dd"))
|
||||
If mitarbeiter.mit_gebdat <> "" And IsDate(mitarbeiter.mit_gebdat) Then
|
||||
success = json.UpdateString("birthday", CDate(mitarbeiter.mit_gebdat).ToString("yyyy-MM-dd"))
|
||||
End If
|
||||
|
||||
success = json.UpdateString("entry", CDate(mitarbeiter.mit_einstiegsdatum).ToString("yyyy-MM-dd"))
|
||||
success = json.UpdateNull("exit")
|
||||
success = json.UpdateString("importSign", "AX-034511")
|
||||
success = json.UpdateString("importSign", "Iimport from Aviso")
|
||||
success = json.UpdateString("login", mitarbeiter.mit_AliasAD_Username)
|
||||
success = json.UpdateBool("loginActive", 0)
|
||||
success = json.UpdateBool("loginActive", 1)
|
||||
success = json.UpdateString("email", mitarbeiter.mit_email)
|
||||
success = json.UpdateString("street", mitarbeiter.mit_strasse)
|
||||
success = json.UpdateString("city", mitarbeiter.mit_ort)
|
||||
success = json.UpdateString("zipcode", mitarbeiter.mit_plz)
|
||||
success = json.UpdateString("phone1", mitarbeiter.mit_telefonnr & " " & mitarbeiter.mit_durchwahl)
|
||||
success = json.UpdateString("phone2", mitarbeiter.mit_mobiltel)
|
||||
success = json.UpdateString("password", "password")
|
||||
success = json.UpdateBool("resetPassword", 1)
|
||||
success = json.UpdateString("password", mitarbeiter.mit_pwd)
|
||||
success = json.UpdateBool("resetPassword", 0)
|
||||
|
||||
For Each r In dgvData.Rows
|
||||
Dim i As Integer = 0
|
||||
If r.Cells("set").Value = True Then
|
||||
success = json.UpdateInt("groups[" & i & "]", r.Cells("id").Value)
|
||||
Dim i As Integer = 0
|
||||
For Each r As DataRow In datatableTimas.Rows
|
||||
If r("set") = True Then
|
||||
success = json.UpdateInt("groups[" & i & "]", r("id"))
|
||||
i = i + 1
|
||||
End If
|
||||
|
||||
|
||||
Next
|
||||
|
||||
Debug.WriteLine(json.Emit())
|
||||
@@ -283,7 +285,7 @@ Public Class cTimasAPI
|
||||
End If
|
||||
Return timasEmployeeCreated
|
||||
Else
|
||||
info = "Mitarbeiter angelegt!"
|
||||
info = "Mitarbeiter angelegt!" & vbNewLine
|
||||
|
||||
Dim jsonResult As New Chilkat.JsonObject
|
||||
success = jsonResult.LoadSb(sbResponseBody)
|
||||
@@ -355,7 +357,7 @@ Public Class cTimasAPI
|
||||
info &= IIf(json.StringOf("info") <> "", "Info: " & json.StringOf("info") & vbNewLine, "")
|
||||
info &= IIf(json.StringOf("id") <> "", "Timas-ID: " & json.StringOf("id") & vbNewLine, "")
|
||||
If json.BoolOf("loginActive") Then
|
||||
info &= IIf(json.StringOf("login") <> "", "Login: " & vbNewLine & json.StringOf("login") & vbNewLine, "")
|
||||
info &= IIf(json.StringOf("login") <> "", "Login: " & json.StringOf("login") & vbNewLine, "")
|
||||
info &= IIf(json.StringOf("password") <> "", "PW: " & json.StringOf("password"), "")
|
||||
End If
|
||||
|
||||
@@ -376,11 +378,6 @@ Public Class cTimasAPI
|
||||
End If
|
||||
|
||||
|
||||
dt.Columns.Add("id", GetType(Integer))
|
||||
dt.Columns.Add("name", GetType(String))
|
||||
dt.Columns.Add("info", GetType(String))
|
||||
dt.Columns.Add("set", GetType(Boolean))
|
||||
|
||||
Dim responseBody As String = rest.FullRequestNoBody("GET", API_STRING & "/rest/web-api/groups3")
|
||||
If (rest.LastMethodSuccess <> True) Then
|
||||
Debug.WriteLine(rest.LastErrorText)
|
||||
@@ -407,22 +404,37 @@ Public Class cTimasAPI
|
||||
|
||||
|
||||
Dim j As Integer = 0
|
||||
While j < num
|
||||
|
||||
Dim groups As Chilkat.JsonObject = jsonArray.ObjectAt(j)
|
||||
If dt IsNot Nothing And Not dt.Columns.Contains("id") Then
|
||||
|
||||
Dim R As DataRow = dt.NewRow
|
||||
R("id") = groups.IntOf("id")
|
||||
R("name") = groups.StringOf("name")
|
||||
R("info") = groups.StringOf("info")
|
||||
If R("id") = "19" Or R("id") = "129" Then 'Typ Mitarbeiter und Standardgruppe für Mitarbeiter Default true
|
||||
R("set") = True
|
||||
Else
|
||||
R("set") = False
|
||||
End If
|
||||
dt.Rows.Add(R)
|
||||
j = j + 1
|
||||
End While
|
||||
dt.Columns.Add("id", GetType(Integer))
|
||||
dt.Columns.Add("name", GetType(String))
|
||||
dt.Columns.Add("groupType", GetType(String))
|
||||
dt.Columns.Add("info", GetType(String))
|
||||
dt.Columns.Add("set", GetType(Boolean))
|
||||
|
||||
While j < num
|
||||
|
||||
Dim groups As Chilkat.JsonObject = jsonArray.ObjectAt(j)
|
||||
|
||||
Dim R As DataRow = dt.NewRow
|
||||
R("id") = groups.IntOf("id")
|
||||
R("name") = groups.StringOf("name")
|
||||
R("groupType") = groups.StringOf("groupType")
|
||||
R("info") = groups.StringOf("info")
|
||||
If R("id") = "19" Or R("id") = "129" Then 'Typ Mitarbeiter und Standardgruppe für Mitarbeiter Default true
|
||||
R("set") = True
|
||||
Else
|
||||
R("set") = False
|
||||
End If
|
||||
dt.Rows.Add(R)
|
||||
j = j + 1
|
||||
End While
|
||||
|
||||
dt.DefaultView.Sort = " groupType asc, name asc"
|
||||
dt = dt.DefaultView.ToTable()
|
||||
|
||||
End If
|
||||
|
||||
|
||||
Catch ex As WebException
|
||||
@@ -492,7 +504,7 @@ Public Class cTimasAPI
|
||||
Return timeEntryCreated
|
||||
Else
|
||||
|
||||
info = "Zeiteintrag " & entryType & " angelegt!"
|
||||
info = "Zeiteintrag " & entryType & " angelegt!" & timeEntry.ToString("HH:mm:ss")
|
||||
|
||||
'Dim jsonResult As New Chilkat.JsonObject
|
||||
'success = jsonResult.LoadSb(sbResponseBody)
|
||||
@@ -506,5 +518,79 @@ Public Class cTimasAPI
|
||||
|
||||
End Function
|
||||
|
||||
Public Function getEmployeeList(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/employees/")
|
||||
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 And Not dt.Columns.Contains("id") Then
|
||||
dt.Columns.Add("id", GetType(Integer))
|
||||
dt.Columns.Add("externid", GetType(String))
|
||||
dt.Columns.Add("pnr1", GetType(String))
|
||||
dt.Columns.Add("firstname", GetType(String))
|
||||
dt.Columns.Add("lastname", GetType(String))
|
||||
dt.Columns.Add("gender", GetType(String))
|
||||
dt.Columns.Add("card", GetType(Integer))
|
||||
dt.Columns.Add("info", GetType(String))
|
||||
|
||||
|
||||
|
||||
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")
|
||||
R("externid") = employee.StringOf("externid")
|
||||
R("pnr1") = employee.StringOf("pnr1")
|
||||
R("firstname") = employee.StringOf("firstname")
|
||||
R("lastname") = employee.StringOf("lastname")
|
||||
R("gender") = employee.StringOf("gender")
|
||||
R("card") = employee.IntOf("card")
|
||||
R("info") = employee.StringOf("info")
|
||||
dt.Rows.Add(R)
|
||||
j = j + 1
|
||||
End While
|
||||
End If
|
||||
|
||||
Catch ex As WebException
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
|
||||
End Try
|
||||
End Function
|
||||
|
||||
|
||||
End Class
|
||||
@@ -366,7 +366,7 @@
|
||||
<Compile Include="Classes\cNCTS_TR_Nachrichten.vb" />
|
||||
<Compile Include="Classes\cOffene_Posten.vb" />
|
||||
<Compile Include="Classes\cOffene_Posten_DVO.vb" />
|
||||
<Compile Include="Classes\cOregonNCTSDeclarations.vb" />
|
||||
<Compile Include="Schnittstellen\Modaltrans\cOregonNCTSDeclarations.vb" />
|
||||
<Compile Include="Classes\cParameter.vb" />
|
||||
<Compile Include="Classes\cProgrammeUpdate.vb" />
|
||||
<Compile Include="Classes\cQSTeam.vb" />
|
||||
@@ -575,18 +575,18 @@
|
||||
<Compile Include="RKSV_DE\cServerClient_RKSV_DE.vb" />
|
||||
<Compile Include="Schnittstellen\ATEZ\ATEZ_OUT_VERAG_IN\cATEZ_NCTS.vb" />
|
||||
<Compile Include="Schnittstellen\ATEZ\VERAG_OUT_ATEZ_IN\cATEZ_NCTS_IN.vb" />
|
||||
<Compile Include="Schnittstellen\cBMD_Interface.vb" />
|
||||
<Compile Include="Schnittstellen\cCreditSafeAPI.vb" />
|
||||
<Compile Include="Schnittstellen\BMD\cBMD_Interface.vb" />
|
||||
<Compile Include="Schnittstellen\Creditsafe\cCreditSafeAPI.vb" />
|
||||
<Compile Include="Schnittstellen\cDatev_Interface.vb" />
|
||||
<Compile Include="Schnittstellen\cDeeplAPI.vb" />
|
||||
<Compile Include="Schnittstellen\cDVO_Interface.vb" />
|
||||
<Compile Include="Schnittstellen\cJsonPost.vb" />
|
||||
<Compile Include="Schnittstellen\cLDV_Interface.vb" />
|
||||
<Compile Include="Schnittstellen\cNCTS_Helper.vb" />
|
||||
<Compile Include="Schnittstellen\cNorsware.vb" />
|
||||
<Compile Include="Schnittstellen\Norsware\cNorsware.vb" />
|
||||
<Compile Include="Schnittstellen\cSyska_Interface.vb" />
|
||||
<Compile Include="Schnittstellen\cTherefore.vb" />
|
||||
<Compile Include="Schnittstellen\cTimasAPI.vb" />
|
||||
<Compile Include="Schnittstellen\TIMAS\cTimasAPI.vb" />
|
||||
<Compile Include="Schnittstellen\Finanzonline\cFinanzOnlineWebService.vb" />
|
||||
<Compile Include="Schnittstellen\GASTON_SCHUL\agsCustomsExchange.Designer.vb" />
|
||||
<Compile Include="Schnittstellen\IDEV_Intrastat\instat6.2.Designer.vb" />
|
||||
@@ -1297,6 +1297,9 @@
|
||||
<LastGenOutput>Reference.vb</LastGenOutput>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="Resources\TiMaS-Paket-Time.png" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
|
||||
<ProjectExtensions />
|
||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
|
||||
Reference in New Issue
Block a user