+++ This bug was initially created as a clone of Bug #426786 +++ --- Additional comment from tao on 2007-12-26 06:22:38 EDT --- Description of problem: The "Filter by Kickstart Profile" under provisioning tab of system doesn't work. on RHN Satellite 5.0.1 For more details refer Steps to Reproduce section mentioned below. How reproducible: Always Steps to Reproduce: Create a couple of kickstart profiles with names as repro-1786760 reproduce-1765948 test-reproduce1 rhel4reproduce rhel5testrepro Select a system with Provisioning entitlement. Click on Provisioning -> Under "Filter by Kickstart Profile: " Enter repro - this would display only repro-1786760 reproduce-1765948 Actual results: repro-1786760 reproduce-1765948 Expected results: repro-1786760 reproduce-1765948 test-reproduce1 rhel4reproduce rhel5testrepro Let me know if any other details are required. Thanks ! Paresh --- Additional comment from tao on 2007-12-26 06:22:39 EDT --- Hello Paresh, This seems to be a bug, looking at the List filtering code it seems that we check the start of the string with the specified prefix. The following patch should correct the behavior: --- frontend/taglibs/helpers/ListViewHelper.java.patch 2007-06-21 02:31:40.000000000 +0530 +++ frontend/taglibs/helpers/ListViewHelper.java 2007-12-26 16:27:36.000000000 +0530 @@ -195,7 +195,7 @@ for (Iterator iter = this.result.iterator(); iter.hasNext();) { Map row = (Map) iter.next(); String value = (String) row.get(this.filterByField); - if (value != null && value.startsWith(filterValue)) { + if (value != null && value.contentEquals(filterValue)) { accum.add(row); } }
Commited to git as a043e005792492a25e5bf5b4a4646cbd8859b0b2
Verified in Spacewalk 0.2
Spacewalk is released for long time.