Re: Users - bsh List Interface from Arralist ?
Posted by
oceatoon on
Mar 01, 2006; 5:22pm
URL: http://ofbiz.116.s1.nabble.com/Users-bsh-List-Interface-from-Arralist-tp137676p137698.html
Yes you're right
I followed it up and it's simply an µArrayList of searchResult.getString("productId")
where searchResult is the GenericValue.
should I overload this method to return the whole GenericValue or is this too heavy of a technique ? Should I just make an ArrayList of pairs productid, parentCategory ?
thanks for your help Andrew
Tibor
On 3/1/06, Andrew Sykes <[hidden email]> wrote:
Tibor,
It looks like my guess was right, prodL isn't a List of GenericValues
On Wed, 2006-03-01 at 17:59 +0100, tibor katelbach wrote:
> Maybe this can help :
> This what I do in catalog/keywordSearch.bsh
>
> Map result = ProductSearchSession.getProductSearchResult(session,
> delegator, prodCatalogId);
>
> List prodL = new ArrayList(result.get("productIds"));
> nList = CategoryWorker.filterProductsInCategory(delegator,prodL ,
> "COMBI");
>
> On 3/1/06, tibor katelbach <[hidden email]> wrote:
> Nop
>
> I still get this , but don't really know where the problems
> is ?>
> Error: The application script threw an exception: Sourced
> file: C:\X_Dev\prodemo\components\ecommerce\webapp\ecommerce
> \WEB-INF\actions\catalog\keywordsearch.bsh : Method Invocation
> CategoryWorker.filterProductsInCategory : at Line: 47 : in
> file: C:\X_Dev\prodemo\components\ecommerce\webapp\ecommerce
> \WEB-INF\actions\catalog\keywordsearch.bsh :
> CategoryWorker .filterProductsInCategory ( delegator , prodL ,
> "COMBI" ) Target exception: java.lang.ClassCastException BSF
> info: C:\X_Dev\prodemo\components\ecommerce\webapp\ecommerce
> \WEB-INF\actions\catalog\keywordsearch.bsh at line: 0 column:
> 0
>
>
> _______________________________________________
> Users mailing list
>
[hidden email]>
http://lists.ofbiz.org/mailman/listinfo/users --
Kind Regards
Andrew Sykes <[hidden email]>
Sykes Development Ltd
http://www.sykesdevelopment.com
_______________________________________________
Users mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/users
_______________________________________________
Users mailing list
[hidden email]
http://lists.ofbiz.org/mailman/listinfo/users