Announcement

Collapse
No announcement yet.

JSON API Customer_Update - updating address fields not working?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    JSON API Customer_Update - updating address fields not working?

    Hi, I'm not sure if anyone can help me figure out if I'm doing something wrong or if there is a bug here. Basically I'm playing around with the Customer_Insert and Customer_Update JSON API functions in our dev store and there seems to be an issue with updating address fields.

    If I insert a Customer using Customer_Insert with BillAddress1 = "address1", BillAddress2 = "address2", and then go view the Customer in our Miva dev store, the addresses look fine, e.g:

    Address: "address1"
    Address2: "address2"

    However, if I then update the address using Customer_Update, e.g. change "address1" to "address1UPDATED", then go view it in the store again, it looks like the address1 and address2 fields have both jumped into Address 1 for some reason, and it hasn't picked up on the updated address1 text. I can't upload an image here but it basically looks like this in the store:

    Address: "address1 address2"
    Address2: ""

    Please see sample JSON below for the insert and update:

    Insert JSON:
    Code:
    {
    "Store_Code":"xxxxx",
    "Customer_Login":"xxxxxxx",
    "Function":"Customer_Insert",
    "Customer_PasswordEmail":"[email protected]",
    "Customer_Password":"xxxxxxx",
    "Customer_ShipResidential":true,
    "Customer_ShipFirstName":"Test",
    "Customer_ShipLastName":"Customer4",
    "Customer_ShipEmail":"[email protected]",
    "Customer_ShipCompany":null,
    "Customer_ShipPhone":"",
    "Customer_ShipFax":"",
    "Customer_ShipAddress1":"address1",
    "Customer_ShipAddress2":"address2 ",
    "Customer_ShipCity":"Stephensport",
    "Customer_ShipState":"KY",
    "Customer_ShipZip":"40170",
    "Customer_BillFirstName":"Test",
    "Customer_BillLastName":"Customer4",
    "Customer_BillEmail":"[email protected]",
    "Customer_BillCompany":null,
    "Customer_BillPhone":"",
    "Customer_BillFax":"",
    "Customer_BillAddress1":"address1",
    "Customer_BillAddress2":"address2 ",
    "Customer_BillCity":"Stephensport",
    "Customer_BillState":"KY",
    "Customer_BillZip":"40170",
    "Customer_Tax_Exempt":false,
    "Miva_Request_Timestamp":"1617979145"
    }


    Update JSON:
    Code:
    {
    "Store_Code":"xxxxx",
    "Customer_Login":"xxxxxxx",
    "Function":"Customer_Update",
    "Customer_PasswordEmail":"[email protected]",
    "Customer_ShipResidential":true,
    "Customer_ShipFirstName":"Test",
    "Customer_ShipLastName":"Customer4",
    "Customer_ShipEmail":"[email protected]",
    "Customer_ShipCompany":null,
    "Customer_ShipPhone":"",
    "Customer_ShipFax":"",
    "Customer_ShipAddress1":"address1UPDATED",
    "Customer_ShipAddress2":"address2 ",
    "Customer_ShipCity":"Stephensport",
    "Customer_ShipState":"KY",
    "Customer_ShipZip":"40170",
    "Customer_BillFirstName":"Test",
    "Customer_BillLastName":"Customer4",
    "Customer_BillEmail":"[email protected]",
    "Customer_BillCompany":null,
    "Customer_BillPhone":"",
    "Customer_BillFax":"",
    "Customer_BillAddress1":"address1UPDATED",
    "Customer_BillAddress2":"address2 ",
    "Customer_BillCity":"Stephensport",
    "Customer_BillState":"KY",
    "Customer_BillZip":"40170",
    "Customer_Tax_Exempt":false,
    "Miva_Request_Timestamp":"1617979391"
    }




    #2
    I just did some testing with this and it appears to be a bug in the customer_update function. I was able to recreate the same issue via the API and in the admin (they use the same function call). I'll get this filed as a bug and it should be fixed in the next update to the software.

    Brennan Heyde
    VP Product
    Miva, Inc.
    [email protected]
    https://www.miva.com

    Comment


      #3
      Originally posted by Brennan View Post
      I just did some testing with this and it appears to be a bug in the customer_update function. I was able to recreate the same issue via the API and in the admin (they use the same function call). I'll get this filed as a bug and it should be fixed in the next update to the software.
      Great, thank you

      Comment

      Working...
      X