         icon-class [:i.button-icon {:class icon-class}])
       [:span.button-text text]])])
 
-(defn build-row [build owner {:keys [show-actions? show-branch? show-project?]}]
+(defn build-row [{:keys [build project]} owner {:keys [show-actions? show-branch? show-project?]}]
   (let [url (build-model/path-for (select-keys build [:vcs_url]) build)
         raise-build-action! (fn [event] (raise! owner [event (build-model/build-args build)]))
         raise-merge-action! (fn [] (raise! owner [:merge-pull-request-clicked (build-model/merge-args build)]))
         status-words (build-model/status-words build)
-        should-show-rebuild? (#{"timedout" "failed"} (:outcome build))
+        should-show-cancel? (and (project-model/can-trigger-builds? project)
+                                 (build-model/can-cancel? build))
+        should-show-rebuild? (and (project-model/can-trigger-builds? project)
+                                  (#{"timedout" "failed"} (:outcome build)))
         should-show-merge? (and (feature/enabled? :merge-pull-request)
+                                (project-model/can-write-settings? project)
                                 (build-model/can-merge-at-least-one-pr? build))]
     [:div.build {:class (cond-> [(build-model/status-class build)]
                           (:dont_build build) (conj "dont_build"))}

                                                                             :org (:username build)}})}
            (build-model/github-revision build)])]]]]))

(defn builds-table [{:keys [builds]} owner {:keys [show-actions? show-branch? show-project?]
                                            :or {show-branch? true
                                                 show-project? true}}]
  (reify
    om/IDisplayName (display-name [_] "Builds Table V2")
    om/IRender
    (render [_]
      (html
        [:div.container-fluid
         (map #(build-row % owner {:show-actions? show-actions?
                                   :show-branch? show-branch?
                                   :show-project? show-project?})
              builds)]))))

            [frontend.components.svg :refer [svg]]
            [frontend.models.build :as build-model]
            [frontend.models.feature :as feature]
            [frontend.models.project :as project-model]
            [frontend.utils.vcs-url :as vcs-url]
            [frontend.utils :as utils :include-macros true]
            [om.core :as om :include-macros true]
