4.10.1
This commit is contained in:
@@ -97,6 +97,55 @@ func dataSourceZoneSchemaMake() map[string]*schema.Schema {
|
||||
Type: schema.TypeInt,
|
||||
},
|
||||
},
|
||||
"account_ids": {
|
||||
Type: schema.TypeList,
|
||||
Computed: true,
|
||||
Elem: &schema.Schema{
|
||||
Type: schema.TypeInt,
|
||||
},
|
||||
},
|
||||
"compute_ids": {
|
||||
Type: schema.TypeList,
|
||||
Computed: true,
|
||||
Elem: &schema.Schema{
|
||||
Type: schema.TypeInt,
|
||||
},
|
||||
},
|
||||
"extnet_ids": {
|
||||
Type: schema.TypeList,
|
||||
Computed: true,
|
||||
Elem: &schema.Schema{
|
||||
Type: schema.TypeInt,
|
||||
},
|
||||
},
|
||||
"vins_ids": {
|
||||
Type: schema.TypeList,
|
||||
Computed: true,
|
||||
Elem: &schema.Schema{
|
||||
Type: schema.TypeInt,
|
||||
},
|
||||
},
|
||||
"lb_ids": {
|
||||
Type: schema.TypeList,
|
||||
Computed: true,
|
||||
Elem: &schema.Schema{
|
||||
Type: schema.TypeInt,
|
||||
},
|
||||
},
|
||||
"bservice_ids": {
|
||||
Type: schema.TypeList,
|
||||
Computed: true,
|
||||
Elem: &schema.Schema{
|
||||
Type: schema.TypeInt,
|
||||
},
|
||||
},
|
||||
"k8s_ids": {
|
||||
Type: schema.TypeList,
|
||||
Computed: true,
|
||||
Elem: &schema.Schema{
|
||||
Type: schema.TypeInt,
|
||||
},
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -52,6 +52,13 @@ func flattenZone(d *schema.ResourceData, item *zone.RecordZone) error {
|
||||
d.Set("created_time", item.CreatedTime)
|
||||
d.Set("updated_time", item.UpdatedTime)
|
||||
d.Set("node_ids", item.NodeIDs)
|
||||
d.Set("account_ids", item.AccountIDs)
|
||||
d.Set("compute_ids", item.ComputeIDs)
|
||||
d.Set("extnet_ids", item.ExtnetIDs)
|
||||
d.Set("vins_ids", item.VinsIDs)
|
||||
d.Set("lb_ids", item.LBIDs)
|
||||
d.Set("bservice_ids", item.BserviceIDs)
|
||||
d.Set("k8s_ids", item.K8SIDs)
|
||||
|
||||
log.Debugf("flattenZone: decoded RecordZone name %q / ID %d, complete",
|
||||
item.Name, item.ID)
|
||||
|
||||
@@ -113,7 +113,7 @@ func resourceZoneUpdate(ctx context.Context, d *schema.ResourceData, m interface
|
||||
|
||||
log.Debugf("resourceZoneUpdate: called Zone with id %d", zoneID)
|
||||
|
||||
if d.HasChanges("name,", "description", "node_ids") {
|
||||
if d.HasChanges("name", "description", "node_ids") {
|
||||
if err := utilityZoneUpdate(ctx, d, m, zoneID); err != nil {
|
||||
return diag.FromErr(err)
|
||||
}
|
||||
|
||||
@@ -65,7 +65,7 @@ func utilityZoneCheckPresence(ctx context.Context, d *schema.ResourceData, m int
|
||||
func utilityZoneUpdate(ctx context.Context, d *schema.ResourceData, m interface{}, zoneID uint64) error {
|
||||
c := m.(*controller.ControllerCfg)
|
||||
|
||||
if d.HasChanges("name,", "description") {
|
||||
if d.HasChanges("name", "description") {
|
||||
req := zone.UpdateRequest{
|
||||
ID: zoneID,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user