E9.2 How To Update Multiple Lines into Order Detail

cazzafed

cazzafed

Active Member
Hello, in advance sorry for my English.
i am using EnterpriseOne 9.2.4.5
I am working on an orchestration to be able to copy sales orders.
When copying these orders, I want to change some values in the grid, but the problem is when there are several lines within the detail, how can I change the value of all the lines and not just one?

I leave attached my data request that brings an order with more than one line
and also the Form Request;
 

Attachments

  • DataRequest.png
    DataRequest.png
    63.6 KB · Views: 74
  • ORCHCHANGEDATA.png
    ORCHCHANGEDATA.png
    75.1 KB · Views: 71
This is a tough one! Someone with more experience than me might have a better solution. My suggestion, since you don't have logic extensions:

1) Form request that simply copies and enters the order, and returns the new order #
2) Data request that returns a dataset of the lines on the new order
3) New form request that iterates over the data request in 2) and finds, and updates, each line on the order with whatever you want. One order line at a time

Other options would be to just execute a SQL against the new order #, this could be done via a scripting component.
 
Hi Dave, thank you very much for your answer. I have not been able to change the values line by line, only the first one changes. I will continue researching and studying how to do it.
 

Attachments

  • dreq.png
    dreq.png
    36.4 KB · Views: 24
  • freq.png
    freq.png
    69.8 KB · Views: 22
Hi @federicocazzaniga I am saying to add a new form request, which you could record using process recorder, where you update an individual line on an existing order. So you record your process where you use QBE to search for <order number> AND <line number>, then make a change to the line.

Next you add a data request prior to that form request, where you make sure you pull order # and line #, and specify a data set name. Lastly, you iterate over that data set name on the individual order line update form request.

It's a looong way to get to something you could much easier do with a SQL statement for instance.
 
Achieved the goal, but I think it would be better to learn how to do this with scripts as you suggest. Even though I just started in the Oracle world with JD Edwards, I think it's too interesting and great things can be created with Orchestrator. Thank you so much @DaveWagoner for your patience in explaining.
 
Achieved the goal, but I think it would be better to learn how to do this with scripts as you suggest. Even though I just started in the Oracle world with JD Edwards, I think it's too interesting and great things can be created with Orchestrator. Thank you so much @DaveWagoner for your patience in explaining.
It is my pleasure! And I'm rather new to actually working on Orchestrator myself. We can help each other moving forward! I agree that Orchestrator is a very very strong tool.
 
You can call the orchestration and update multiple lines at once with the following JSON string:

{
"Order Number": "20330447",
"Order Type": "ST",
"Select Row": "1",
"GridData": [
{
"Row Number for Update": "5",
"Quantity Ordered": "7"
},
{
"Row Number for Update": "6",
"Quantity Ordered": "22"
}
],
"P4210_Version": "PRD0012"
}
 
an orchestration to be able to copy sales orders.
When copying these orders, I want to change
Hello, in advance sorry for my English.
i am using EnterpriseOne 9.2.4.5
I am working on an orchestration to be able to copy sales orders.
When copying these orders, I want to change some values in the grid, but the problem is when there are several lines within the detail, how can I change the value of all the lines and not just one?

I leave attached my data request that brings an order with more than one line
and also the Form Request;
Editable Grid (Headerless Detail Form) updates require some Groovy logic to identify the right line as they are not sortable or filterable. The design pattern, roughly, is to use a form request to capture the Detail Revisions form's grid and return the raw JSON, then a Groovy custom request to parse the JSON to find the grid row number for the detail line required, then you can call a form request passing the row number to update for its Select Row step.

If there are multiple detail lines per order you will probably want to input an array to the orchestration and iterate over it so the above process is run once per line.
 
HI folks

Sorry to ressurect this, but how can you do this in the detail screen where this is no QBE?
As in P4210 W4210A, it has no QBE to allow me to to filter by DOCO and a passed in LNID, which in my case will be 1.000 1.001 etc
So I need to update rows 1, row 2 row 3 etc

I was thinking of a DR and a record count and iterate over the DR and use loopcounter as Row for Update (solid number not LNID), but has anyone tried this on detail screens with no QBE?

So this kind of thing
Get the count of SO lines and loop until my loop counter matches the count
1706718718740.png

Thanks

John
 
Last edited:
Update
This approach works just fine :)

My SO had 3 lines and all 3 have updated to the same price

Here is my ORCH response

Code:
{
  "ServiceRequest1": {
    "fs_DATABROWSE_V4211C": {
      "title": "Data Browser - V4211C [Sales Order Detail - Revisions (Subset)]",
      "data": {
        "gridData": {
          "id": 52,
          "fullGridId": "52",
          "columns": {
            "F4211_LNID": "Line Number"
          },
          "rowset": [
            {
              "F4211_LNID": 1
            },
            {
              "F4211_LNID": 2
            },
            {
              "F4211_LNID": 3
            }
          ],
          "summary": {
            "records": 3,
            "moreRecords": false
          }
        }
      },
      "errors": [],
      "warnings": []
    },
    "currentApp": "DATABROWSE_V4211C",
    "timeStamp": "2024-01-31:12.10.06",
    "sysErrors": []
  },
  "RRD_RL_CompareLineNumber_Repeating": [
    {
      "ServiceRequest2": {
        "forms": [
          {
            "fs_P4210_W4210A": {
              "title": "Sales Order Detail Revisions",
              "data": {},
              "errors": [],
              "warnings": []
            },
            "stackId": 17,
            "stateId": 1,
            "rid": "698d4e79c39dfabd",
            "currentApp": "P4210_W4210A_VJDE0099",
            "timeStamp": "2024-01-31:12.10.13",
            "sysErrors": []
          },
          {
            "fs_P4210_W4210E": {
              "title": "Customer Service Inquiry",
              "data": {},
              "errors": [],
              "warnings": []
            },
            "stackId": 17,
            "stateId": 2,
            "rid": "698d4e79c39dfabd",
            "currentApp": "P4210_W4210E_VJDE0099",
            "timeStamp": "2024-01-31:12.10.19",
            "sysErrors": []
          }
        ]
      },
      "ServiceRequest3": {
        "loopCounter": 2
      }
    },
    {
      "ServiceRequest4": {
        "forms": [
          {
            "fs_P4210_W4210A": {
              "title": "Sales Order Detail Revisions",
              "data": {},
              "errors": [],
              "warnings": []
            },
            "stackId": 18,
            "stateId": 1,
            "rid": "698d4e79c39dfabd",
            "currentApp": "P4210_W4210A_VJDE0099",
            "timeStamp": "2024-01-31:12.10.20",
            "sysErrors": []
          },
          {
            "fs_P4210_W4210E": {
              "title": "Customer Service Inquiry",
              "data": {},
              "errors": [],
              "warnings": []
            },
            "stackId": 18,
            "stateId": 2,
            "rid": "698d4e79c39dfabd",
            "currentApp": "P4210_W4210E_VJDE0099",
            "timeStamp": "2024-01-31:12.10.20",
            "sysErrors": []
          }
        ]
      },
      "ServiceRequest5": {
        "loopCounter": 3
      }
    },
    {
      "ServiceRequest6": {
        "forms": [
          {
            "fs_P4210_W4210A": {
              "title": "Sales Order Detail Revisions",
              "data": {},
              "errors": [],
              "warnings": []
            },
            "stackId": 19,
            "stateId": 1,
            "rid": "698d4e79c39dfabd",
            "currentApp": "P4210_W4210A_VJDE0099",
            "timeStamp": "2024-01-31:12.10.21",
            "sysErrors": []
          },
          {
            "fs_P4210_W4210E": {
              "title": "Customer Service Inquiry",
              "data": {},
              "errors": [],
              "warnings": []
            },
            "stackId": 19,
            "stateId": 2,
            "rid": "698d4e79c39dfabd",
            "currentApp": "P4210_W4210E_VJDE0099",
            "timeStamp": "2024-01-31:12.10.22",
            "sysErrors": []
          }
        ]
      },
      "ServiceRequest7": {
        "loopCounter": 4
      }
    }
  ],
  "jde__status": "SUCCESS",
  "jde__startTimestamp": "2024-01-31T12:10:06.202-0600",
  "jde__endTimestamp": "2024-01-31T12:10:22.676-0600",
  "jde__serverExecutionSeconds": 16.474
}
 
In your form request, after you open the sales order, add a Select Row for Update, and click the Filter checkbox. You will see the filter icon in the Input column. Populate the filter criteria with whatever criteria you wish to use for selecting rows. You can then update all of the records that match your criteria with the value you want.
 
If anyone wants it, here is a zip of all the objects
 

Attachments

  • RRD_ORCH_UpdateForeignPriceMultipleP4210Lines.zip
    5.5 KB · Views: 2
In your form request, after you open the sales order, add a Select Row for Update, and click the Filter checkbox. You will see the filter icon in the Input column. Populate the filter criteria with whatever criteria you wish to use for selecting rows. You can then update all of the records that match your criteria with the value you want.

Thanks Kevin, I tried that but it appears to be grid columns only and DOCO wasn't one of them sadly. But it's good to see you can do that on occasion yes.
My main issue was no QBE
So I did it like this with loopCounter (which incremented each time)
1706725458638.png
 
Back
Top