From mboxrd@z Thu Jan 1 00:00:00 1970 From: rmccabe@sourceware.org Date: 6 Dec 2006 22:11:21 -0000 Subject: [Cluster-devel] conga/luci cluster/form-macros site/luci/Exten ... Message-ID: <20061206221121.25843.qmail@sourceware.org> List-Id: To: cluster-devel.redhat.com MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit CVSROOT: /cvs/cluster Module name: conga Changes by: rmccabe at sourceware.org 2006-12-06 22:11:20 Modified files: luci/cluster : form-macros luci/site/luci/Extensions: cluster_adapters.py Log message: - Fix an IP corner case for setting/editing services - Fix the autostart setting and its display Patches: http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/cluster/form-macros.diff?cvsroot=cluster&r1=1.123&r2=1.124 http://sourceware.org/cgi-bin/cvsweb.cgi/conga/luci/site/luci/Extensions/cluster_adapters.py.diff?cvsroot=cluster&r1=1.174&r2=1.175 --- conga/luci/cluster/form-macros 2006/12/06 21:16:35 1.123 +++ conga/luci/cluster/form-macros 2006/12/06 22:11:20 1.124 @@ -2825,7 +2825,7 @@ This service is stopped -

Autostart is enabled for this service

+

Autostart is enabled for this service

--- conga/luci/site/luci/Extensions/cluster_adapters.py 2006/12/06 21:16:35 1.174 +++ conga/luci/site/luci/Extensions/cluster_adapters.py 2006/12/06 22:11:20 1.175 @@ -468,6 +468,13 @@ return (False, {'errors': [ 'An invalid resource type was specified' ]}) try: + if res_type == 'ip': + dummy_form['resourceName'] = dummy_form['ip_address'] + except Exception, e: + luci_log.debug_verbose('vSA3a: type is ip but no addr: %s' % str(e)) + return (False, {'errors': [ 'No IP address was given.' ]}) + + try: if dummy_form.has_key('immutable'): newRes = getResource(model, dummy_form['resourceName']) resObj = RefObject(newRes) @@ -493,7 +500,7 @@ autostart = "1" try: - if not request.form.has_key('autostart'): + if request.form['autostart'] == "0": autostart = "0" except: pass