             [hiccup.form :as form]
             [mdr2.db :as db]
             [mdr2.layout :as layout]
-            [mdr2.dtbook :refer [dtbook]]))
+            [mdr2.dtbook :refer [dtbook]]
+            [mdr2.pipeline1 :as pipeline]))
 
 (defn home []
   (layout/common 

      (form/submit-button "Upload")))))

(defn production-add-xml [id file]
  (let [{tempfile :tempfile} file]
    (println id)
    (println tempfile)
    (ring/redirect "/")))


        (ring/response)
        (ring/content-type "text/xml"))))

(defn file-upload-form [id & [errors]]
  (let [p (db/get-production id)]
    (layout/common
     [:h1 "Upload"]
     [:p (str "Upload structure for " (:title p))]
     (when (seq? errors)
       [:p [:ul.alert.alert-danger (for [e errors] [:li e])]])
     (form/form-to
      {:enctype "multipart/form-data"}
      [:post (str "/production/" id "/upload")]
