On 13 March 2014 13:52, Tomoloju, Ola <[email protected]> wrote:

> Thanks Dan.
> I guessed as much,  it is a bit of a learning curve for the developers
> involved (included myself).
>
> We will change the updateVan() definition and implementation as you've
> adviced.
>
> Please, could you review the JSON request for me or better still, which
> JSON data will be required for the first argument (van reference) of the
> revised updateVan() method?
>


assuming:

updateVan(@Named("Van") *final* Van van,

            @Named("van Number") *final* String vanNumber,

            @Named("Category") *final*  Constants.CATEGORY category,

            @Named("van Type") *final*  Constants.VAN_TYPES type,

            @Named("van Status") *final*  Constants.STATUS status,

            @Named("Expiry Date") *final* LocalDate expiryDate,

            @Named("van Id") *final* Integer vanId)  {  ... }

then the HTTP body will be something like:

{
  "van": { "value": { "href": "..../Van/XXX" } },
  "vanNumber": { "value":  "1234" } },
  "category": { "value":  "..." },
  "vanType": { "value":  "..." },
   "expiryDate": { "value":  "2014-09-01" },
   "vanId": { "value": 123 }
}

but test this in Chrome (Postman) first [1].




[1]
http://isis.apache.org/components/viewers/restfulobjects/using-chrome-tools.html

Reply via email to