Rhino Javascript
Budget: ₹600 – ₹1,500 INR
Hi,
I'm working on automating a flow and need some support in writing Rhino Javascript to process some data.
The data is coming in as XML, below is the sample :
<Data>
<AvailablePlanGroups>
<PlanGroupDetails>
<PlanGroup>ABC</PlanGroup>
<PlanGroupID>10A</PlanGroupID>
<PlanGroupSortOrder>670</PlanGroupSortOrder>
</PlanGroupDetails>
<PlanGroupDetails>
<PlanGroup>DEF</PlanGroup>
<PlanGroupID>15B</PlanGroupID>
<PlanGroupSortOrder>11</PlanGroupSortOrder>
</PlanGroupDetails>
<PlanGroupDetails>
<PlanGroup>GHI</PlanGroup>
<PlanGroupID>21C</PlanGroupID>
<PlanGroupSortOrder>200</PlanGroupSortOrder>
</PlanGroupDetails>
</AvailablePlanGroups>
</Data>
we need to write a Rhino Javascript to sort that data in ascending based on 'GroupSortOrder' & store the array index in a variable.
Example :
Current Array index = [0,1,2]
Array index after sorting = [1,2,0]
followed by we need to pass those value to create a JSON object.
It's a few lines of script but I'm not an expert.So looking for a expert to assist.
I'm working on automating a flow and need some support in writing Rhino Javascript to process some data.
The data is coming in as XML, below is the sample :
<Data>
<AvailablePlanGroups>
<PlanGroupDetails>
<PlanGroup>ABC</PlanGroup>
<PlanGroupID>10A</PlanGroupID>
<PlanGroupSortOrder>670</PlanGroupSortOrder>
</PlanGroupDetails>
<PlanGroupDetails>
<PlanGroup>DEF</PlanGroup>
<PlanGroupID>15B</PlanGroupID>
<PlanGroupSortOrder>11</PlanGroupSortOrder>
</PlanGroupDetails>
<PlanGroupDetails>
<PlanGroup>GHI</PlanGroup>
<PlanGroupID>21C</PlanGroupID>
<PlanGroupSortOrder>200</PlanGroupSortOrder>
</PlanGroupDetails>
</AvailablePlanGroups>
</Data>
we need to write a Rhino Javascript to sort that data in ascending based on 'GroupSortOrder' & store the array index in a variable.
Example :
Current Array index = [0,1,2]
Array index after sorting = [1,2,0]
followed by we need to pass those value to create a JSON object.
It's a few lines of script but I'm not an expert.So looking for a expert to assist.
Related categories:
PHP
Business, Accounting, Human Resources & Legal
JavaScript
AJAX
Software Architecture