@@ -111,7 +111,7 @@
@@ -120,17 +120,17 @@
-
Bitte Spedition wählen...!
+
Bitte Spedition wählen...!
-
Placeholder
+
Placeholder
-
+
SDL_NrBezeichnungGültig BisKarten-Nummer
@@ -333,7 +333,38 @@
//addNewRow(SDL,Bez,Datguenstig,KartNr)
// Pagemethods.filltable2(<%' =tbl_mainpage %> , SDL, Bez, Datguenstig, KartNr)
//}
- Pagemethods.filltable2(id.split(',')[0])
+ let booleansuccess = false
+ $.ajax({
+ type: "POST",
+ url: "LKWs.aspx/filltable2",
+ contentType: "application/json; charset=utf-8",
+ dataType: "json",
+ data: '{"format":"' + id.split(',')[0] + '"}',
+ success: function (result) {
+ OnSuccess(result.d);
+ booleansuccess = true
+ },
+ error: function (result) {
+ OnFailure(result);
+ booleansuccess = false
+ }
+ });
+ function OnSuccess(success) {
+ alert('horray! 200 status code!');
+ alert(success)
+
+ }
+ function OnFailure(error) {
+ alert(error);
+ //get the status code
+ if (code == 400) {
+ alert('400 status code! user error');
+ }
+ if (code == 500) {
+ alert('500 status code! server error');
+ }
+ }
+ //filltable2(id.split(',')[0])
}
function doPostBack_M(id_M) {
let Speditionslabel = document.getElementById('<%=lbl_sped_Placeholder_M.ClientID%>');
@@ -344,7 +375,7 @@
for (let i = rowCount - 1; i > 0; i--) {
table_M.deleteRow(i);
- }
+ }
Speditionslabel.textContent = id_M.split(',')[0];
natplaceholder.textContent = id_M.split(',')[1];
addheader_M();
@@ -358,7 +389,31 @@
//addNewRow(SDL,Bez,Datguenstig,KartNr)
// Pagemethods.filltable2(<%' =tbl_mainpage_M%> , SDL, Bez, Datguenstig, KartNr)
//}
- Pagemethods.filltable2_M(id_M.split(',')[0])
+ let booleansuccess_M = false
+ //debugger
+ $.ajax({
+ type: "POST",
+ url: "LKWs.aspx/filltable2_M",
+ contentType: "application/json; charset=utf-8",
+ dataType: "json",
+ data: '{"format":"' + id_M.split(',')[0] + '"}',
+ success: function (result) {
+ booleansuccess_M = true;
+ OnSuccess(result.d);
+ },
+ error: function (xhr, status, error) {
+ booleansuccess_M = false;
+ OnFailure(error);
+ }
+ });
+ function OnSuccess(booleansuccess_M) {
+ if (booleansuccess_M) {
+ alert("Success")
+ }
+ }
+ function OnFailure(error) {
+ alert(error);
+ }
}
\ No newline at end of file
diff --git a/Customers/LKWs.aspx.vb b/Customers/LKWs.aspx.vb
index 51b8440..a73df5a 100644
--- a/Customers/LKWs.aspx.vb
+++ b/Customers/LKWs.aspx.vb
@@ -254,7 +254,7 @@ Partial Class LKWS
tr2.Cells.Add(tc_Vermerk)
initcells(tblhrow, tbhc_KFZKennz, tbhc_Nat, tblhc_Verk, tblhc_Kz, tblhc_Verm, tr2, tc_KfzKennz, tc_Nationalitaet, tc_Verk, tc_KZ_An, tc_Vermerk, cnt)
- tr2.Attributes.Add("onclick", "Javascript:doPostBack('""" + tr2.Cells.Item(0).Text + """,""" + strtempnat + """')")
+ tr2.Attributes.Add("OnClientClick", "Javascript:doPostBack('""" + tr2.Cells.Item(0).Text + """,""" + strtempnat + """')")
tbl_sidemenue.Rows.Add(tr2)
cnt += 1
Next
@@ -392,15 +392,15 @@ Partial Class LKWS
strtemp2 = l3.Nationalität
End If
tbl_mainpage_M.Rows.Clear()
- tr1_M.Attributes.Add("OnClick", "Javascript:doPostBack_M('""" & tr1_M.Cells.Item(0).Text & """,""" & strtemp2 & """')")
+ tr1_M.Attributes.Add("OnClientClick", "Javascript:doPostBack_M('""" & tr1_M.Cells.Item(0).Text & """,""" & strtemp2 & """')")
cnt += 1
tbl_2.Rows.Add(tr1_M)
Next
End Sub
-
- Public Sub filltable2(Kennzeichen As String)
+
+ Public Shared Sub filltable2(Kennzeichen As String)
Dim tbl As Table = New Table
Dim list2 As List(Of VERAG_PROG_ALLGEMEIN.cSDL) = VERAG_PROG_ALLGEMEIN.cSDL.GET_LIST_WEB_LKW(401940, Kennzeichen)
For Each l2 In list2
@@ -423,8 +423,8 @@ Partial Class LKWS
Next
End Sub
-
- Public Sub filltable_M(Kennzeichen As String)
+
+ Public Shared Sub filltable_M(Kennzeichen As String)
Dim list2 As List(Of VERAG_PROG_ALLGEMEIN.cSDL) = VERAG_PROG_ALLGEMEIN.cSDL.GET_LIST_WEB_LKW(401940, Kennzeichen)
Dim Tbl As New Table
For Each l2 In list2