I am upgrading a super old webpage to use Angular and I have a webpage that is loading data from an XML document. The XML document is currently laid out like so:
<xml>
<PREMout>
<PolicyNumber>12345</PolicyNumber>
<ModeCode>ANN</ModeCode>
<PremFromDate>11/10/2015</PremFromDate>
<PremToDate>12/12/2020</PremToDate>
<AnnualPremium>400.00</AnnualPremium>
<ModePremium>400.00</ModePremium>
<PremFromDate>12/31/2020</PremFromDate>
<PremToDate>12/12/2027</PremToDate>
<AnnualPremium>5000.00</AnnualPremium>
<ModePremium>5000.00</ModePremium>
etc
Those four columns (PremFromDate
, PremToDate
, AnnualPremium
, and ModePremium
) are repeated many times. Since they are not grouped within a node...how would I group these fields together?
Currently, the old page is grabbing all of the PremFromDate
fields and pushing them into a DataGrid
bound column. It does this for the other fields, too. That seems like a very risky way of displaying data because what happens if something gets out of order?
Does anyone have an idea on how to group those four columns with them not being in a node together? Ideally speaking...the xml would be rewritten to not completely suck but that is not an option for this case :(