Skip to content

Commit

Permalink
Added functions to remove skills/jobs
Browse files Browse the repository at this point in the history
  • Loading branch information
zolrath committed Sep 16, 2011
1 parent 6d71525 commit 19af267
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/andrew_site/models/db.clj
Expand Up @@ -34,9 +34,18 @@
(defn add-lesser-skill [skill]
(insert! :skills {:level "lesser" :skill skill}))

(defn remove-skill [name]
(let [skill (fetch-one :skills :where {:skill name})]
(destroy! :skills skill)))

(defn add-job [{:keys [name start-year end-year url description]}]
(insert! :jobs {:name name :start-year start-year :end-year end-year :url url :description description}))

(defn remove-job [name]
(let [job (fetch-one :jobs :where {:name name})]
(destroy! :jobs job)))


(defn jobs []
(fetch :jobs))

Expand Down

0 comments on commit 19af267

Please sign in to comment.