tabellenproblem gelöst dass zu viele Zeile hinzugefügt und keine gelöscht werden.
This commit is contained in:
@@ -41,7 +41,7 @@
|
|||||||
#tableSearch {
|
#tableSearch {
|
||||||
width: 53%;
|
width: 53%;
|
||||||
border: 1px solid grey;
|
border: 1px solid grey;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
</asp:Content>
|
</asp:Content>
|
||||||
@@ -69,7 +69,7 @@
|
|||||||
<div class="col-9">
|
<div class="col-9">
|
||||||
<div class="col-9"style="height:10px;"></div>
|
<div class="col-9"style="height:10px;"></div>
|
||||||
<div class="flex-col-9">
|
<div class="flex-col-9">
|
||||||
<asp:Table ID="tbl_sidemenue" runat="server" CssClass="table table-striped" style="width:310px;margin-left:-32px;">
|
<asp:Table ID="tbl_sidemenue" runat="server" CssClass="table table-striped" style="width:310px;margin-left:-32px;cursor:default">
|
||||||
<asp:TableHeaderRow style="background-color:#043381;color:#fff;font-size:0.86em"><asp:TableHeaderCell ID="tbhc_KFZKennz">KFZ-Kennzeichen</asp:TableHeaderCell><asp:TableHeaderCell ID="tbhc_Nat">Nat.</asp:TableHeaderCell><asp:TableHeaderCell ID="tblhc_Verk">Verk</asp:TableHeaderCell><asp:TableHeaderCell ID="tblhc_Kz">KZ-An</asp:TableHeaderCell><asp:TableHeaderCell ID="tblhc_Verm">Vermerk</asp:TableHeaderCell></asp:TableHeaderRow>
|
<asp:TableHeaderRow style="background-color:#043381;color:#fff;font-size:0.86em"><asp:TableHeaderCell ID="tbhc_KFZKennz">KFZ-Kennzeichen</asp:TableHeaderCell><asp:TableHeaderCell ID="tbhc_Nat">Nat.</asp:TableHeaderCell><asp:TableHeaderCell ID="tblhc_Verk">Verk</asp:TableHeaderCell><asp:TableHeaderCell ID="tblhc_Kz">KZ-An</asp:TableHeaderCell><asp:TableHeaderCell ID="tblhc_Verm">Vermerk</asp:TableHeaderCell></asp:TableHeaderRow>
|
||||||
</asp:Table>
|
</asp:Table>
|
||||||
</div>
|
</div>
|
||||||
@@ -145,31 +145,32 @@
|
|||||||
<!-- Popper.JS -->
|
<!-- Popper.JS -->
|
||||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.0/umd/popper.min.js" integrity="sha384-cs/chFZiN24E4KMATLdqdvsezGxaGsi4hLGOzlXwp5UZB1LY//20VyM2taTB4QvJ" crossorigin="anonymous"></script>
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.0/umd/popper.min.js" integrity="sha384-cs/chFZiN24E4KMATLdqdvsezGxaGsi4hLGOzlXwp5UZB1LY//20VyM2taTB4QvJ" crossorigin="anonymous"></script>
|
||||||
<script type="text/javascript">
|
<script type="text/javascript">
|
||||||
function TableRowClick(listtemp, Kennzeichen, Nat) {
|
function TableRowClick(listtemp, Kennzeichen, Nat) {
|
||||||
let Table1 = document.getElementById("<%=tbl_mainpage%>")
|
|
||||||
let Speditionslabel = document.getElementById("<%=lbl_sped_Placeholder.ClientID%>")
|
let Speditionslabel = document.getElementById("<%=lbl_sped_Placeholder.ClientID%>")
|
||||||
let natplaceholder = document.getElementById("<%=lbl_Placeholder.ClientID%>")
|
let natplaceholder = document.getElementById("<%=lbl_Placeholder.ClientID%>")
|
||||||
|
|
||||||
Speditionslabel.textContent = Kennzeichen
|
Speditionslabel.textContent = Kennzeichen
|
||||||
natplaceholder.textContent = Nat
|
natplaceholder.textContent = Nat
|
||||||
const arr2 = Array.from(listtemp.split(","));
|
|
||||||
for (let i = 0; i < arr2.length; i++) {
|
var tb = document.getElementById("<%=tbl_mainpage.ClientID%>");
|
||||||
//alert(arr2.length)
|
while (tb.rows.length > 1) {
|
||||||
const Arr = Array.from(listtemp(i).split(";"));
|
tb.deleteRow(1);
|
||||||
debugger
|
|
||||||
alert(Arr)
|
|
||||||
for (let arrint of Arr) {
|
|
||||||
let SDLNr = arrint[0]
|
|
||||||
let Bez = arrint[1]
|
|
||||||
let Gueltigbis = arrint[2]
|
|
||||||
let KartenNr = arrint[3]
|
|
||||||
alert(SDLNr)
|
|
||||||
alert(Bez)
|
|
||||||
alert(Gueltigbis)
|
|
||||||
alert(KartenNr)
|
|
||||||
addRow(Table1,SDLNr, Bez, Gueltigbis, KartenNr)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const arr2 = Array.from(listtemp.split(";"));
|
||||||
|
//debugger
|
||||||
|
//alert(Arr)
|
||||||
|
for (let arrint of arr2) {
|
||||||
|
let SDLNr = arrint
|
||||||
|
let Bez = arrint
|
||||||
|
let Gueltigbis = arrint
|
||||||
|
let KartenNr = arrint
|
||||||
|
//alert(SDLNr)
|
||||||
|
//alert(Bez)
|
||||||
|
//alert(Gueltigbis)
|
||||||
|
//alert(KartenNr)
|
||||||
|
addRow(<%=tbl_mainpage.ClientID%>,SDLNr, Bez, Gueltigbis, KartenNr)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
function addRow(table1,par1,par2,par3,par4) {
|
function addRow(table1,par1,par2,par3,par4) {
|
||||||
let tableRef = table1;
|
let tableRef = table1;
|
||||||
@@ -186,8 +187,8 @@
|
|||||||
newCell2.innerHTML = par3
|
newCell2.innerHTML = par3
|
||||||
newCell3.innerHTML = par4
|
newCell3.innerHTML = par4
|
||||||
}
|
}
|
||||||
function addRow_tab2(par1, par2, par3, par4) {
|
function addRow_tab2(tab1,par1, par2, par3, par4) {
|
||||||
let tableRef = document.getElementById(<%=tbl_mainpage_M.ClientID%>);
|
let tableRef = tab1;
|
||||||
|
|
||||||
let newRow = tableRef.insertRow(-1);
|
let newRow = tableRef.insertRow(-1);
|
||||||
|
|
||||||
@@ -207,20 +208,23 @@
|
|||||||
|
|
||||||
Speditionslabel.textContent = Kennzeichen
|
Speditionslabel.textContent = Kennzeichen
|
||||||
natplaceholder.textContent = Nat
|
natplaceholder.textContent = Nat
|
||||||
const arr2 = Array.from(listtemp_M.split(","));
|
|
||||||
for (let i = 0; i < arr2.length; i++) {
|
var tb = document.getElementById("<%=tbl_mainpage_M.ClientID%>");
|
||||||
const Arr = Array.from(listtemp_M(i).split(";"));
|
while (tb.rows.length > 1) {
|
||||||
for (let arrint of Arr) {
|
tb.deleteRow(1);
|
||||||
let SDLNr = arrint[0];
|
}
|
||||||
let Bez = arrint[1];
|
|
||||||
let Gueltigbis = arrint[2];
|
const arr2 = Array.from(listtemp_M.split(";"));
|
||||||
let KartenNr = arrint[3];
|
for (let i = 0; i < arr2.length; i++) {
|
||||||
alert(SDLNr)
|
let SDLNr = arrint[i];
|
||||||
alert(Bez)
|
let Bez = arrint[i++];
|
||||||
alert(Gueltigbis)
|
let Gueltigbis = arrint[i++];
|
||||||
alert(KartenNr)
|
let KartenNr = arrint[i++];
|
||||||
addRow(SDLNr, Bez, Gueltigbis, KartenNr)
|
//alert(SDLNr)
|
||||||
}
|
//alert(Bez)
|
||||||
|
//alert(Gueltigbis)
|
||||||
|
//alert(KartenNr)
|
||||||
|
addRow(<%=tbl_mainpage_M%>,SDLNr, Bez, Gueltigbis, KartenNr)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -109,16 +109,17 @@ Partial Class LKWS
|
|||||||
For Each l3 In list3
|
For Each l3 In list3
|
||||||
list3.Add(l2.SDLNr.ToString + ";" + Stringtemp + ";" + l2.GültigBis.ToString + ";" + l2.KartenNr.ToString)
|
list3.Add(l2.SDLNr.ToString + ";" + Stringtemp + ";" + l2.GültigBis.ToString + ";" + l2.KartenNr.ToString)
|
||||||
Next
|
Next
|
||||||
|
Dim strtemp2 As String = String.Empty
|
||||||
|
If String.IsNullOrEmpty(l1.Nationalität) = True Then
|
||||||
|
strtemp2 = "Keine Angabe"
|
||||||
|
Else
|
||||||
|
strtemp2 = l1.Nationalität
|
||||||
|
End If
|
||||||
|
tr1.Attributes.Add("OnClick", "Javascript:TableRowClick(""" & list3.ToString & """,""" & l1.KfzKennzeichen & """,""" & strtemp2 & """)")
|
||||||
Next
|
Next
|
||||||
Dim strtemp2 As String = String.Empty
|
|
||||||
|
|
||||||
If String.IsNullOrEmpty(l1.Nationalität) Then
|
|
||||||
strtemp2 = "Keine Angabe"
|
|
||||||
Else
|
|
||||||
strtemp2 = l1.Nationalität
|
|
||||||
End If
|
|
||||||
|
|
||||||
tr1.Attributes.Add("OnClick", "Javascript:TableRowClick(""" & list3.ToString & """,""" & l1.KfzKennzeichen & """,""" & strtemp2 & """)")
|
|
||||||
cnt += 1
|
cnt += 1
|
||||||
tbl_sidemenue.Rows.Add(tr1)
|
tbl_sidemenue.Rows.Add(tr1)
|
||||||
Next
|
Next
|
||||||
@@ -138,16 +139,12 @@ Partial Class LKWS
|
|||||||
th3.ForeColor = Drawing.Color.White
|
th3.ForeColor = Drawing.Color.White
|
||||||
th4.ForeColor = Drawing.Color.White
|
th4.ForeColor = Drawing.Color.White
|
||||||
th5.ForeColor = Drawing.Color.White
|
th5.ForeColor = Drawing.Color.White
|
||||||
|
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Protected Sub btn_Suchen_Click(sender As Object, e As EventArgs)
|
Protected Sub btn_Suchen_Click(sender As Object, e As EventArgs)
|
||||||
'MsgBox("Test0")
|
|
||||||
Dim txt_LkwNr As TextBox = txt_lkw
|
Dim txt_LkwNr As TextBox = txt_lkw
|
||||||
'list = VERAG_PROG_ALLGEMEIN.cSDL.GET_LIST_WEB(401940, "COOPER8")
|
'list = VERAG_PROG_ALLGEMEIN.cSDL.GET_LIST_WEB(401940, "COOPER8")
|
||||||
list = VERAG_PROG_ALLGEMEIN.cSDL_LKW.GET_LIST_WEB(401940)
|
list = VERAG_PROG_ALLGEMEIN.cSDL_LKW.GET_LIST_WEB(401940)
|
||||||
|
|
||||||
Dim tblhrow As TableHeaderRow = New TableHeaderRow()
|
Dim tblhrow As TableHeaderRow = New TableHeaderRow()
|
||||||
Dim cnt As Integer = 0
|
Dim cnt As Integer = 0
|
||||||
|
|
||||||
@@ -157,10 +154,10 @@ Partial Class LKWS
|
|||||||
tblhrow.Cells.Add(tblhc_Kz)
|
tblhrow.Cells.Add(tblhc_Kz)
|
||||||
tblhrow.Cells.Add(tblhc_Verm)
|
tblhrow.Cells.Add(tblhc_Verm)
|
||||||
|
|
||||||
tbl_sidemenue.Rows.Clear()
|
|
||||||
tbl_sidemenue.Height = Unit.Pixel(150)
|
tbl_sidemenue.Height = Unit.Pixel(150)
|
||||||
|
tbl_sidemenue.Rows.Clear()
|
||||||
tbl_sidemenue.Rows.Add(tblhrow)
|
tbl_sidemenue.Rows.Add(tblhrow)
|
||||||
'MsgBox("Test1")
|
|
||||||
For Each l2 In list
|
For Each l2 In list
|
||||||
Dim tr2 As TableRow = New TableRow()
|
Dim tr2 As TableRow = New TableRow()
|
||||||
Dim tc_KfzKennz As TableCell = New TableCell()
|
Dim tc_KfzKennz As TableCell = New TableCell()
|
||||||
@@ -201,7 +198,6 @@ Partial Class LKWS
|
|||||||
tbl_sidemenue.Rows.Add(tr2)
|
tbl_sidemenue.Rows.Add(tr2)
|
||||||
cnt += 1
|
cnt += 1
|
||||||
Next
|
Next
|
||||||
'MsgBox("Test2")
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Protected Sub TableRowClick(ByVal sender As TableRow, e As EventArgs)
|
Protected Sub TableRowClick(ByVal sender As TableRow, e As EventArgs)
|
||||||
@@ -213,7 +209,7 @@ Partial Class LKWS
|
|||||||
Else
|
Else
|
||||||
VERAG_PROG_ALLGEMEIN.cAllgemein.TESTSYSTEM = False
|
VERAG_PROG_ALLGEMEIN.cAllgemein.TESTSYSTEM = False
|
||||||
End If
|
End If
|
||||||
|
tbl_2.Rows.Clear()
|
||||||
list_M = VERAG_PROG_ALLGEMEIN.cSDL_LKW.GET_LIST_WEB(401940)
|
list_M = VERAG_PROG_ALLGEMEIN.cSDL_LKW.GET_LIST_WEB(401940)
|
||||||
Dim cnt As Integer = 0
|
Dim cnt As Integer = 0
|
||||||
|
|
||||||
@@ -273,7 +269,7 @@ Partial Class LKWS
|
|||||||
Else
|
Else
|
||||||
VERAG_PROG_ALLGEMEIN.cAllgemein.TESTSYSTEM = False
|
VERAG_PROG_ALLGEMEIN.cAllgemein.TESTSYSTEM = False
|
||||||
End If
|
End If
|
||||||
|
tbl_2.Rows.Clear()
|
||||||
Dim cnt As Integer = 0
|
Dim cnt As Integer = 0
|
||||||
list_M = VERAG_PROG_ALLGEMEIN.cSDL_LKW.GET_LIST_WEB(401940)
|
list_M = VERAG_PROG_ALLGEMEIN.cSDL_LKW.GET_LIST_WEB(401940)
|
||||||
Dim tblhrow_M As TableHeaderRow = New TableHeaderRow
|
Dim tblhrow_M As TableHeaderRow = New TableHeaderRow
|
||||||
@@ -285,8 +281,6 @@ Partial Class LKWS
|
|||||||
tblhrow_M.Cells.Add(tbhc_Verm_M)
|
tblhrow_M.Cells.Add(tbhc_Verm_M)
|
||||||
tbl_2.Rows.Add(tblhrow_M)
|
tbl_2.Rows.Add(tblhrow_M)
|
||||||
|
|
||||||
'tbl_sidemenue.Rows.Clear()
|
|
||||||
'MsgBox("Test2")
|
|
||||||
For Each l3 In list_M
|
For Each l3 In list_M
|
||||||
Dim tr1_M As TableRow = New TableRow()
|
Dim tr1_M As TableRow = New TableRow()
|
||||||
Dim tc_KfzKennz_M As TableCell = New TableCell()
|
Dim tc_KfzKennz_M As TableCell = New TableCell()
|
||||||
@@ -355,6 +349,5 @@ Partial Class LKWS
|
|||||||
tbl_2.Rows.Add(tr1_M)
|
tbl_2.Rows.Add(tr1_M)
|
||||||
cnt += 1
|
cnt += 1
|
||||||
Next
|
Next
|
||||||
'MsgBox("Test3")
|
|
||||||
End Sub
|
End Sub
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
Reference in New Issue
Block a user