Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

140
Views
Unable to Update data in Form.io column

This scenario is for Formio platform. Once the formio form is submitted, I want to update the column in the formio using partial update. Postman request for Partial update -> https://documenter.getpostman.com/view/684631/formio-api/2Jvuks#17612070-b85b-427a-8f41-ce45c46d5865

When i try to run the code then I am getting error. Kindly let me know why error is coming and how to resolve it.

let submID = submission2._id;
              console.log('Sub id is', submID);
              var product_title = localStorage.getItem("recom");
              var settings = {
                "url": "https://foms.abc.com/user/login",
                "method": "POST",
                "timeout": 0,
                "headers": {
                  "Content-Type": "application/json"
                },
                "data": JSON.stringify({
                  "data": {
                    "email": "abc@test.in",
                    "password": "Test123"
                  }}),
                  success:  function(data, status, req){
                    console.log(req.getResponseHeader("x-jwt-token"))
                    
                    var JWTToken = req.getResponseHeader("x-jwt-token");
                    console.log('token is', JWTToken);
                  }
              };
//               $.ajax(settings);
            
            $.ajax(settings).done(function (data, status, req) {
              var JWTToken = req.getResponseHeader("x-jwt-token");
                    console.log('token outside is', JWTToken);
              
              var settings1 = {
              "url": "https://foms.abc.com/form2/submission/submID",
              "method": "PATCH",
              "timeout": 0,
              "headers": {
                "x-jwt-token": JWTToken,
                "Content-Type": "application/json"
              },
              "data": JSON.stringify([
                {
                  "op": "replace",
                  "path": "/form2/page1Recommended",
                  "value": product_title
                }
              ]),
            };

            $.ajax(settings1).done(function (response) {
              console.log('change in data', response);
            });
            });

Error [1]: https://i.stack.imgur.com/ZPWLT.png

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!