Skip to content

Commit

Permalink
Refactor vpn list policy object resource and data source
Browse files Browse the repository at this point in the history
  • Loading branch information
danischm committed Jul 25, 2023
1 parent eaa6fdd commit 807e94a
Show file tree
Hide file tree
Showing 9 changed files with 97 additions and 63 deletions.
8 changes: 4 additions & 4 deletions docs/data-sources/vpn_list_policy_object.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
page_title: "sdwan_vpn_list_policy_object Data Source - terraform-provider-sdwan"
subcategory: "Policy Objects"
description: |-
This data source can read the VPN List policy object.
This data source can read the VPN List Policy Object .
---

# sdwan_vpn_list_policy_object (Data Source)

This data source can read the VPN List policy object.
This data source can read the VPN List Policy Object .

## Example Usage

Expand All @@ -23,13 +23,13 @@ data "sdwan_vpn_list_policy_object" "example" {

### Required

- `id` (String) The id of the policy object
- `id` (String) The id of the object

### Read-Only

- `entries` (Attributes List) List of entries (see [below for nested schema](#nestedatt--entries))
- `name` (String) The name of the policy object
- `version` (Number) The version of the policy object
- `version` (Number) The version of the object

<a id="nestedatt--entries"></a>
### Nested Schema for `entries`
Expand Down
8 changes: 4 additions & 4 deletions docs/resources/vpn_list_policy_object.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
page_title: "sdwan_vpn_list_policy_object Resource - terraform-provider-sdwan"
subcategory: "Policy Objects"
description: |-
This resource can manage a VPN List policy object.
This resource can manage a VPN List Policy Object .
---

# sdwan_vpn_list_policy_object (Resource)

This resource can manage a VPN List policy object.
This resource can manage a VPN List Policy Object .

## Example Usage

Expand All @@ -33,8 +33,8 @@ resource "sdwan_vpn_list_policy_object" "example" {

### Read-Only

- `id` (String) The id of the policy object
- `version` (Number) The version of the feature template
- `id` (String) The id of the object
- `version` (Number) The version of the object

<a id="nestedatt--entries"></a>
### Nested Schema for `entries`
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,18 @@
---
name: VPN List
type: vpn
name: VPN List Policy Object
rest_endpoint: /template/policy/list/vpn/
has_version: true
id_attribute: listId
doc_category: Policy Objects
attributes:
- model_name: type
value: vpn
- model_name: name
tf_name: name
type: String
mandatory: true
description: The name of the policy object
example: Example
- model_name: entries
type: List
mandatory: true
Expand Down
8 changes: 4 additions & 4 deletions internal/provider/data_source_sdwan_vpn_list_policy_object.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

48 changes: 32 additions & 16 deletions internal/provider/model_sdwan_vpn_list_policy_object.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions internal/provider/provider.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

44 changes: 24 additions & 20 deletions internal/provider/resource_sdwan_vpn_list_policy_object.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

21 changes: 11 additions & 10 deletions internal/provider/resource_sdwan_vpn_list_policy_object_test.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 807e94a

Please sign in to comment.