   (if (= nil (form-validator @data-set))
     (let [onres (fn[data]
                   (secretary/dispatch! "/"))]
+      (when (and (not (nil? (:senddate @data-set)))
+                 (nil? (:receiveddate @data-set))) (swap! data-set assoc :racknumber ""))
       (http-put (str serverhost "mutations/" (:id @data-set))
                 onres (.serialize (Serializer.) (clj->js (map-mutation-data @data-set))))))
   (reset! focus "on"))

          [form-input-element :remarks "Remarks" "text" data-set focus]
          ])])))



(defn add-mutation-template [doc-name data-set focus save-function]

       [add-check-input-element :senddate "Send Date" data-set focus]
       ]
      [:div.box-footer
       [:div.col-sm-12.col-md-offset-5 
        [button-tool-bar
         [button {:bs-style "default" :on-click form-cancel } "Cancel"]
         [button {:bs-style "info" :on-click save-function} "Save"] 
         (when (nil? (:id @data-set)) [button {:bs-style "info" :on-click #((reset! data-set {:isactive true})
                                                                            (reset-mut-combo-boxes))} "Refresh"])]]
       ;;[:span (str @data-set)]
       ]]]]])

