diff options
author | Holger Weiß <holger@zedat.fu-berlin.de> | 2011-05-01 23:50:09 +0200 |
---|---|---|
committer | Sol Jerome <sol.jerome@gmail.com> | 2011-05-13 07:43:28 -0500 |
commit | f6992b7308dca8d9dc74d380f881470e228797d8 (patch) | |
tree | 3fed39b099933e9fc53f48c9cc9b33bd460f91a4 | |
parent | 777981eaed3900d1083dabf789cafb47135d8261 (diff) | |
download | bcfg2-f6992b7308dca8d9dc74d380f881470e228797d8.tar.gz bcfg2-f6992b7308dca8d9dc74d380f881470e228797d8.tar.bz2 bcfg2-f6992b7308dca8d9dc74d380f881470e228797d8.zip |
Fix bcfg2-reports --badentry and --extraentry
The reporting system schema has been changed. This change lead to
exceptions such as
| AttributeError: 'Entries_interactions' object has no attribute 'name'
when running bcfg2-reports with the --badentry or --extraentry options.
(cherry picked from commit b8b7e45c83df9f5951dd8faeb83347d920942cef)
-rwxr-xr-x | src/sbin/bcfg2-reports | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/sbin/bcfg2-reports b/src/sbin/bcfg2-reports index f3e60d89e..d8c3947d5 100755 --- a/src/sbin/bcfg2-reports +++ b/src/sbin/bcfg2-reports @@ -227,7 +227,7 @@ else: for c_inst in c_list: baditems = c_inst.current_interaction.bad() for item in baditems: - if item.name == badentry[1] and item.kind == badentry[0]: + if item.entry.name == badentry[1] and item.entry.kind == badentry[0]: result.append(c_inst) if c_inst in entrydict: entrydict.get(c_inst).append(badentry[1]) @@ -238,7 +238,7 @@ else: for c_inst in c_list: baditems = c_inst.current_interaction.bad() for item in baditems: - if item.name == badentry[1] and item.kind == badentry[0]: + if item.entry.name == badentry[1] and item.entry.kind == badentry[0]: result.append(c_inst) break elif extraentry != "": @@ -249,7 +249,7 @@ else: for c_inst in c_list: extraitems = c_inst.current_interaction.extra() for item in extraitems: - if item.name == extraentry[1] and item.kind == extraentry[0]: + if item.entry.name == extraentry[1] and item.entry.kind == extraentry[0]: result.append(c_inst) if c_inst in entrydict: entrydict.get(c_inst).append(extraentry[1]) @@ -260,7 +260,7 @@ else: for c_inst in c_list: extraitems = c_inst.current_interaction.extra() for item in extraitems: - if item.name == extraentry[1] and item.kind == extraentry[0]: + if item.entry.name == extraentry[1] and item.entry.kind == extraentry[0]: result.append(c_inst) break |