diff options
author | Michael DeHaan <mdehaan@redhat.com> | 2009-03-05 17:59:10 -0500 |
---|---|---|
committer | Michael DeHaan <mdehaan@redhat.com> | 2009-03-05 17:59:10 -0500 |
commit | 1dee14556a2e8b5bb7046a56731490a95245b441 (patch) | |
tree | bd7f641dd2251396c1031f453ecf920f18e101b6 /cobbler/api.py | |
parent | dbcfc5a2f0d191001cd8000a543e41eddefd20f7 (diff) | |
download | cobbler-1dee14556a2e8b5bb7046a56731490a95245b441.tar.gz cobbler-1dee14556a2e8b5bb7046a56731490a95245b441.tar.xz cobbler-1dee14556a2e8b5bb7046a56731490a95245b441.zip |
Add search to the webapp. Currently all areas are implemented on the backend though we need to tweak out the search forms to allow searching on simulatenous fields and prepopulate the options with fields folks will want to search against.
Diffstat (limited to 'cobbler/api.py')
-rw-r--r-- | cobbler/api.py | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/cobbler/api.py b/cobbler/api.py index 655bb413..ffc62644 100644 --- a/cobbler/api.py +++ b/cobbler/api.py @@ -22,6 +22,7 @@ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA """ +import yaml import config import utils import action_sync @@ -48,7 +49,6 @@ import logging import time import random import os -import yaml import xmlrpclib import traceback @@ -209,14 +209,16 @@ class BootAPI: version_tuple -- something like [ 1, 3, 2 ] """ fd = open("/var/lib/cobbler/version") - data = yaml.load(fd.read()) + ydata = fd.read() fd.close() + data = yaml.load(ydata) if not extended: # for backwards compatibility and use with koan's comparisons elems = data["version_tuple"] + print elems return int(elems[0]) + 0.1*int(elems[1]) + 0.001*int(elems[2]) else: - return data + return data def clear(self): """ |