You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@isis.apache.org by Arturo Ulises Castañeda Estrada <ar...@sisorg.com.mx> on 2016/02/26 20:16:41 UTC

"invalidReason":"Expected a link (because this object's type is not a value)

HI Dan

I have the problem trying to persist in the DB,  i send this

shoppingCart:{href: "http://192.168.0.20:8080/restful/objects/simple.ShoppingCart/140"}

but returns the next error:
{"shoppingCart":{"value":"{\"href\":\"http://192.168.0.20:8080/restful/objects/simple.ShoppingCart/140\"}","invalidReason":"Expected a link (because this object's type is not a value) but found no 'href'"}

I find the thread where you talk about json-node:

http://permalink.gmane.org/gmane.comp.apache.incubator.isis.devel/4010

Could you explain me how to use or how can i resolve this, thank's



Re: "invalidReason":"Expected a link (because this object's type is not a value)

Posted by Arturo Ulises Castañeda Estrada <ar...@sisorg.com.mx>.
Im using angularJS and this only past when i try consume the WS with angular but with the wicket and postman all done, by any reason does not recognize as JSON only as text.
________________________________________
De: Arturo Ulises Castañeda Estrada <ar...@sisorg.com.mx>
Enviado: viernes, 26 de febrero de 2016 02:01 p. m.
Para: users@isis.apache.org
Asunto: Re: "invalidReason":"Expected a link (because this object's type is not a value)

I tried with

shoppingCart:{ value: { href: "
http://192.168.0.20:8080/restful/objects/simple.ShoppingCart/140"} }

But the application does not run i understand the solution could be a ENTER or spaces so i tried this too

shoppingCart:{ value: { href: "\nhttp://192.168.0.20:8080/restful/objects/simple.ShoppingCart/140"} }

And i get the same error:

"shoppingCart":{"value":"{\"value\":{\"href\":\"\\nhttp://192.168.0.20:8080/restful/objects/simple.ShoppingCart/140\"}}","invalidReason":"Expected a link (because this object's type is not a value) but found no 'href'"



________________________________________
De: Dan Haywood <da...@haywood-associates.co.uk>
Enviado: viernes, 26 de febrero de 2016 01:26 p. m.
Para: users
Asunto: Re: "invalidReason":"Expected a link (because this object's type is not a value)

Use:

shoppingCart:{ value: { href: "
http://192.168.0.20:8080/restful/objects/simple.ShoppingCart/140"} }

ie, the "href" is within a "value".

The error message you received is actually showing the structure required.

HTH
Dan




On 26 February 2016 at 19:16, Arturo Ulises Castañeda Estrada <
arturo.castaneda@sisorg.com.mx> wrote:

> HI Dan
>
> I have the problem trying to persist in the DB,  i send this
>
> shoppingCart:{href: "
> http://192.168.0.20:8080/restful/objects/simple.ShoppingCart/140"}
>
> but returns the next error:
> {"shoppingCart":{"value":"{\"href\":\"
> http://192.168.0.20:8080/restful/objects/simple.ShoppingCart/140\"}","invalidReason":"Expected
> a link (because this object's type is not a value) but found no 'href'"}
>
> I find the thread where you talk about json-node:
>
> http://permalink.gmane.org/gmane.comp.apache.incubator.isis.devel/4010
>
> Could you explain me how to use or how can i resolve this, thank's
>
>
>

Re: "invalidReason":"Expected a link (because this object's type is not a value)

Posted by Arturo Ulises Castañeda Estrada <ar...@sisorg.com.mx>.
I tried with

shoppingCart:{ value: { href: "
http://192.168.0.20:8080/restful/objects/simple.ShoppingCart/140"} }

But the application does not run i understand the solution could be a ENTER or spaces so i tried this too

shoppingCart:{ value: { href: "\nhttp://192.168.0.20:8080/restful/objects/simple.ShoppingCart/140"} }

And i get the same error:

"shoppingCart":{"value":"{\"value\":{\"href\":\"\\nhttp://192.168.0.20:8080/restful/objects/simple.ShoppingCart/140\"}}","invalidReason":"Expected a link (because this object's type is not a value) but found no 'href'"



________________________________________
De: Dan Haywood <da...@haywood-associates.co.uk>
Enviado: viernes, 26 de febrero de 2016 01:26 p. m.
Para: users
Asunto: Re: "invalidReason":"Expected a link (because this object's type is not a value)

Use:

shoppingCart:{ value: { href: "
http://192.168.0.20:8080/restful/objects/simple.ShoppingCart/140"} }

ie, the "href" is within a "value".

The error message you received is actually showing the structure required.

HTH
Dan




On 26 February 2016 at 19:16, Arturo Ulises Castañeda Estrada <
arturo.castaneda@sisorg.com.mx> wrote:

> HI Dan
>
> I have the problem trying to persist in the DB,  i send this
>
> shoppingCart:{href: "
> http://192.168.0.20:8080/restful/objects/simple.ShoppingCart/140"}
>
> but returns the next error:
> {"shoppingCart":{"value":"{\"href\":\"
> http://192.168.0.20:8080/restful/objects/simple.ShoppingCart/140\"}","invalidReason":"Expected
> a link (because this object's type is not a value) but found no 'href'"}
>
> I find the thread where you talk about json-node:
>
> http://permalink.gmane.org/gmane.comp.apache.incubator.isis.devel/4010
>
> Could you explain me how to use or how can i resolve this, thank's
>
>
>

Re: "invalidReason":"Expected a link (because this object's type is not a value)

Posted by Dan Haywood <da...@haywood-associates.co.uk>.
Use:

shoppingCart:{ value: { href: "
http://192.168.0.20:8080/restful/objects/simple.ShoppingCart/140"} }

ie, the "href" is within a "value".

The error message you received is actually showing the structure required.

HTH
Dan




On 26 February 2016 at 19:16, Arturo Ulises Castañeda Estrada <
arturo.castaneda@sisorg.com.mx> wrote:

> HI Dan
>
> I have the problem trying to persist in the DB,  i send this
>
> shoppingCart:{href: "
> http://192.168.0.20:8080/restful/objects/simple.ShoppingCart/140"}
>
> but returns the next error:
> {"shoppingCart":{"value":"{\"href\":\"
> http://192.168.0.20:8080/restful/objects/simple.ShoppingCart/140\"}","invalidReason":"Expected
> a link (because this object's type is not a value) but found no 'href'"}
>
> I find the thread where you talk about json-node:
>
> http://permalink.gmane.org/gmane.comp.apache.incubator.isis.devel/4010
>
> Could you explain me how to use or how can i resolve this, thank's
>
>
>