Skip to main content
1-Visitor
December 30, 2020
Solved

Getting error while developing service:org.mozilla.javascript.UniqueTag@10bb9ddd: NOT_FOUND

  • December 30, 2020
  • 4 replies
  • 4281 views
I am trying here to get child for Site1_ITHENA SITE-A (custom site) which work fine and I get the correct output showing LineA and LineB.

In the next part, I am passing the lines in array to GetEquipmentNetworkForKPIs_Copy so that I can filter only those line which has LineA and LineB. My agenda for this entire service to filter lines of a specific Site and pass it to tree grid. the output of this entire service is an infotable with Datashape PTC.Factory.EquipmentStatusTreeDataShape. (This is the same Datashape as used by the service GetEquipmentNetworkForKPIs which is used by the tree grid)

 
Best answer by smainente

Hello @ankitag,

 

Your code is building the query from the latest row in the Network InfoTable.

 

Maybe try something like below (this is non-tested pseudo code ) :

let to_arr = [];
getChild.rows.toArray().forEach(row => { to_arr.push(row.to) };

let query = {
 "filters": {
 "type": "IN",
 "fieldName": "name",
 "values": to_arr 
};

 

4 replies

16-Pearl
December 30, 2020

Hello @ankitag ,

 

Try to remove the let keyword on the result line.

The result variable is automatically defined in a Script service, you just have to set it.

ankitag1-VisitorAuthor
1-Visitor
December 31, 2020

Thank you @smainente . I am trying to get the the output for the LINE-A and LINE-B. But, instead of that I am a

getting output related to LINE-B only inside  infotable. Could you please help me getting this out.

 

 

smainente16-PearlAnswer
16-Pearl
December 31, 2020

Hello @ankitag,

 

Your code is building the query from the latest row in the Network InfoTable.

 

Maybe try something like below (this is non-tested pseudo code ) :

let to_arr = [];
getChild.rows.toArray().forEach(row => { to_arr.push(row.to) };

let query = {
 "filters": {
 "type": "IN",
 "fieldName": "name",
 "values": to_arr 
};