Index: openacs-4/contrib/packages/classified-ads/tcl/ads-procs.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/contrib/packages/classified-ads/tcl/ads-procs.xql,v diff -u -r1.5 -r1.6 --- openacs-4/contrib/packages/classified-ads/tcl/ads-procs.xql 24 Jul 2003 01:14:44 -0000 1.5 +++ openacs-4/contrib/packages/classified-ads/tcl/ads-procs.xql 29 Jul 2003 09:10:42 -0000 1.6 @@ -9,14 +9,17 @@ ci.item_id, cr.title, to_char(cr.publish_date, 'Mon FMDD, YYYY') as pretty_publish_date + $custom_fields from cr_item_keyword_map cm, cr_revisions cr, - cr_items ci + cr_items ci, + cr_ca_ads ads where cm.item_id = cr.item_id and ci.latest_revision = cr.revision_id and ci.parent_id = :parent_id and - ci.content_type = 'ca_ad' - $condition_stub + ci.content_type = 'ca_ad' and + cm.keyword_id = :category_id and + ci.item_id = ads.ad_id order by cm.keyword_id asc, cr.title asc