           :fields
           {:* {}}}
          }
+      ;; (and do-aggs (not-empty (:post-filter q))) (assoc :post-filter (first (:post_filter q)))
+      post-filter? (assoc :post_filter (first (:post-filter q)))
       do-aggs (assoc :aggregations
-                  {:category-path   {:terms {:field "category-path" :min_doc_count 1 :size 4000}}
-                   :manufacturer-id {:terms {:field "manufacturer-id" :min_doc_count 1 :size 100}}
-                   })
+                     (cond->
+                         {:manufacturer-id {:terms {:field "manufacturer-id" :min_doc_count 1 :size 100}}}
+                       post-filter? (assoc :category-path
+                                           {:filter (first (:post-filter q))
+                                            :aggs {:filter-cat-path {:terms {:field "category-path" :min_doc_count 1 :size 4000}}}})
+                       (not post-filter?) (assoc :category-path {:terms {:field "category-path" :min_doc_count 1 :size 4000}})
+                       ))
       )))
 ;; (build-search-query query-map)
 

  [query-map response]
  (let [aggs (:aggregations response)
        cats (-> aggs :category-path :buckets)
        manuf (-> aggs :manufacturer-id :buckets)
        cat-path (:category-path query-map)
        cat-path-level (inc (slash-count cat-path))

      (not-empty upcs) (update-in [:should] conj {:query {:term {:upc (stringify-seq upcs)}}})
      ;; service-center-count -- boost? filter?
      )))

(defn build-search-query
  "build elasticsearch json query from query-map"
  [query-map]
  (let [q (transform-search-query query-map)
        paging (extract-paging query-map nil)
        do-aggs (not (:total-hits-only query-map))
        post-filter? (not-empty (:post-filter q))]
    (if do-aggs
      (println "\n\npost-filter" (:post-filter q) "\n\n"))
    (cond->
        {:from (* (:num-per-page paging) (dec (:page-num paging)))
         :size (:num-per-page paging)
