     (filter #(= taskId (:task %)) log)
     log))
 
+
+(def line-num (atom 0))
+
+(defn- filter-logs
+  [taskId log]
+  (->> log
+       (filter-by-task taskId)
+       (map #(assoc-in % [:key] (swap! line-num inc)))))
+
 (defn- log-handler
   [service-id task-id]
   (ajax/get

                 mixin-refresh-form
                 {:did-mount  (fn [state] (auto-scroll!) state)
                  :did-update (fn [state] (auto-scroll!) state)} [{{:keys [id]} :params}]
  (let [{:keys [filter autoscroll timestamp initialized error service]} (state/react state/form-state-cursor)
        logs (state/react state/form-value-cursor)
        filtered-logs (filter-items logs (:predicate filter))]
    (comp/mui

(defn- auto-scroll!
  []
  (when (true? (:autoscroll (state/get-value state/form-state-cursor)))
    (let [el (.getElementById js/document "autoscroll")]
      (.scrollTo js/window 0 (.-scrollHeight el)))))

(defn form-search-fn
