peg
2010-02-18 15:17:16 UTC
Hi,
I wanted to get a parent property value that exists in the current
context:
{
id: "parentId",
...
child: { id: "childId", ... }
}
and produce in a template
{.section child }
child id: {id} parentId: {?}
{.end}
perhaps a specific sign 'a la ' xpath could be used to indicate parent
navigation:
../id or ^id
don't know.
Or it could be done by formatter accessing the current context, but
need then a way to get parent's context ...
It could be done (in the code) the same way the {@index} is
treated ...
that's where I put it for my needs for now
Phil
I wanted to get a parent property value that exists in the current
context:
{
id: "parentId",
...
child: { id: "childId", ... }
}
and produce in a template
{.section child }
child id: {id} parentId: {?}
{.end}
perhaps a specific sign 'a la ' xpath could be used to indicate parent
navigation:
../id or ^id
don't know.
Or it could be done by formatter accessing the current context, but
need then a way to get parent's context ...
It could be done (in the code) the same way the {@index} is
treated ...
that's where I put it for my needs for now
Phil
--
You received this message because you are subscribed to the Google Groups "JSON Template" group.
To post to this group, send email to json-template-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
To unsubscribe from this group, send email to json-template+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
For more options, visit this group at http://groups.google.com/group/json-template?hl=en.
You received this message because you are subscribed to the Google Groups "JSON Template" group.
To post to this group, send email to json-template-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
To unsubscribe from this group, send email to json-template+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/***@public.gmane.org
For more options, visit this group at http://groups.google.com/group/json-template?hl=en.