diff options
author | Santhosh Thottingal <santhosh.thottingal@gmail.com> | 2009-04-22 23:42:35 +0530 |
---|---|---|
committer | Santhosh Thottingal <santhosh.thottingal@gmail.com> | 2009-04-22 23:42:35 +0530 |
commit | 550f1ef9f4cd12f6a75090fa14490effc1230631 (patch) | |
tree | 74fddb746c0b849e88ca375a3fa5fabb246ff82d /silpa/common | |
parent | 39d12a4a44fe0a2b386ba9562833f8bf6f6275f2 (diff) | |
download | Rachana.git-550f1ef9f4cd12f6a75090fa14490effc1230631.tar.gz Rachana.git-550f1ef9f4cd12f6a75090fa14490effc1230631.tar.xz Rachana.git-550f1ef9f4cd12f6a75090fa14490effc1230631.zip |
Bug Fixes
Diffstat (limited to 'silpa/common')
-rw-r--r-- | silpa/common/modulemanager.py | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/silpa/common/modulemanager.py b/silpa/common/modulemanager.py index 8f9c79d..a3e9f1b 100644 --- a/silpa/common/modulemanager.py +++ b/silpa/common/modulemanager.py @@ -18,6 +18,7 @@ class ModuleManager: return obj def getModuleInstance(self,action): + action=action.replace(" ","_") module_name = self.find_module(action) if(module_name): try: @@ -37,8 +38,12 @@ class ModuleManager: response = response+"<table class=\"table1\"><tr><th>Module</th><th>Description</th><th>Status</th></tr>" for action in module_dict: module_instance=self.getModuleInstance(action) - response = response+"<tr><td><a href='?action="+ action +"'>"+module_instance.get_module_name()+"</a></td>" - response = response+"<td>"+module_instance.get_info()+"</td><td>OK</td></tr>" + if(module_instance!=None): + response = response+"<tr><td><a href='?action="+ action +"'>"+module_instance.get_module_name()+"</a></td>" + response = response+"<td>"+module_instance.get_info()+"</td><td>OK</td></tr>" + else: + response = response+"<tr><td>"+action.replace("_"," ")+"</td>" + response = response+"<td>Error while retrieving module details</td><td>Fail</td></tr>" return response+"</table>" if __name__ == '__main__': mm=ModuleManager() |