--
Petr Vobornik
From d4f0851d528628ec25592e901e8ddef18ecbf6e9 Mon Sep 17 00:00:00 2001
From: Petr Vobornik <pvobo...@redhat.com>
Date: Thu, 29 Oct 2015 19:01:09 +0100
Subject: [PATCH] topology: treat server suffix as multivalued attribute in API

---
 API.txt                            | 2 +-
 VERSION                            | 4 ++--
 install/ui/src/freeipa/topology.js | 2 +-
 ipalib/plugins/server.py           | 2 +-
 4 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/API.txt b/API.txt
index 0976c97213775d79da43ee382a0badbe029b7960..43048874b79e239f9ff86046c86dc0d79ee783da 100644
--- a/API.txt
+++ b/API.txt
@@ -3827,7 +3827,7 @@ option: Flag('all', autofill=True, cli_name='all', default=False, exclude='webui
 option: Str('cn', attribute=True, autofill=False, cli_name='name', multivalue=False, primary_key=True, query=True, required=False)
 option: Int('ipamaxdomainlevel', attribute=True, autofill=False, cli_name='maxlevel', multivalue=False, query=True, required=False)
 option: Int('ipamindomainlevel', attribute=True, autofill=False, cli_name='minlevel', multivalue=False, query=True, required=False)
-option: Str('iparepltopomanagedsuffix', attribute=True, autofill=False, cli_name='suffix', multivalue=False, query=True, required=False)
+option: Str('iparepltopomanagedsuffix', attribute=True, autofill=False, cli_name='suffix', multivalue=True, query=True, required=False)
 option: Flag('pkey_only?', autofill=True, default=False)
 option: Flag('raw', autofill=True, cli_name='raw', default=False, exclude='webui')
 option: Int('sizelimit?', autofill=False, minvalue=0)
diff --git a/VERSION b/VERSION
index 064e98cb46a084b9f87f4fb52c8cd6033be171a4..2c5979ad1daaa337b504d2d6aed0c726ffb877bc 100644
--- a/VERSION
+++ b/VERSION
@@ -90,5 +90,5 @@ IPA_DATA_VERSION=20100614120000
 #                                                      #
 ########################################################
 IPA_API_VERSION_MAJOR=2
-IPA_API_VERSION_MINOR=158
-# Last change: mbasti - allow multiple managers: (stage)user-{add|remove}-manager commands
+IPA_API_VERSION_MINOR=159
+# Last change: pvoborni - treat server's suffix as multivalued attribute in API
diff --git a/install/ui/src/freeipa/topology.js b/install/ui/src/freeipa/topology.js
index 4d585947bf0574ac74bbd94e0d3069701cba85d0..740498bf9d88459f69e82f62f1bd99301ea07cd4 100644
--- a/install/ui/src/freeipa/topology.js
+++ b/install/ui/src/freeipa/topology.js
@@ -204,7 +204,7 @@ return {
                         { name: 'cn', read_only: true },
                         { name: 'ipamindomainlevel', read_only: true },
                         { name: 'ipamaxdomainlevel', read_only: true },
-                        { name: 'iparepltopomanagedsuffix', read_only: true }
+                        { $type: 'multivalued', name: 'iparepltopomanagedsuffix', read_only: true }
                     ]
                 }
             ]
diff --git a/ipalib/plugins/server.py b/ipalib/plugins/server.py
index 5808c9c5ea78fce4a15cd2e49740fbe20bca8358..af7f102043f145c109f3c09e741a6520e4db2f42 100644
--- a/ipalib/plugins/server.py
+++ b/ipalib/plugins/server.py
@@ -54,7 +54,7 @@ class server(LDAPObject):
             doc=_('IPA server hostname'),
         ),
         Str(
-            'iparepltopomanagedsuffix',
+            'iparepltopomanagedsuffix*',
             cli_name='suffix',
             label=_('Managed suffix'),
         ),
-- 
2.4.3

-- 
Manage your subscription for the Freeipa-devel mailing list:
https://www.redhat.com/mailman/listinfo/freeipa-devel
Contribute to FreeIPA: http://www.freeipa.org/page/Contribute/Code

Reply via email to