diff options
author | Sandeep Shah <sandeeplinux1068@gmail.com> | 2019-12-17 11:21:38 -0600 |
---|---|---|
committer | Sandeep Shah <sandeeplinux1068@gmail.com> | 2019-12-19 06:03:30 -0600 |
commit | 3b13ec30b442b68fd757065fa65d049e7db26774 (patch) | |
tree | dffd48159a9f3cefc744b053dd5bc2c01c928771 /platform-logic/restapi-templates/src/main/velocity/a1-policy-instance-property-payload-template.vtl | |
parent | f5a63c57879141bd9e1054de41a901cdbd802e7f (diff) |
Velocity templates for A1 Adapter DG's
Velocity templates used in DG's for A1 policy type
and policy instance creation
Issue-ID: SDNC-1011
Signed-off-by: SandeepLinux <Sandeep.Shah@ibm.com>
Change-Id: Ie16d89271a9ce058e47f879ad107545df8da03c8
Former-commit-id: febc82515ae59dc9247d78914fc1a00066d20568
Diffstat (limited to 'platform-logic/restapi-templates/src/main/velocity/a1-policy-instance-property-payload-template.vtl')
-rw-r--r-- | platform-logic/restapi-templates/src/main/velocity/a1-policy-instance-property-payload-template.vtl | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/platform-logic/restapi-templates/src/main/velocity/a1-policy-instance-property-payload-template.vtl b/platform-logic/restapi-templates/src/main/velocity/a1-policy-instance-property-payload-template.vtl new file mode 100644 index 00000000..c743d2b5 --- /dev/null +++ b/platform-logic/restapi-templates/src/main/velocity/a1-policy-instance-property-payload-template.vtl @@ -0,0 +1,10 @@ +## Velocity template for creating payload for creating A1 Policy instance +#set($begCntr=0) +#set($endCntr=0) +#set($entries=$ctx.getAttribute("create-policy-instance-input.properties_length")) +#set($endCntr=$endCntr.parseInt($entries)) +#set( $endCntr = $endCntr - 1) +{#foreach($no in [$begCntr..$endCntr]) +"$ctx.getAttribute("create-policy-instance-input.properties[$no].property-name")" : +$ctx.getAttribute("create-policy-instance-input.properties[$no].property-value") +#if( $foreach.count < $endCntr+1), #end #end} |