support for new templates.
This commit is contained in:
@@ -14,6 +14,17 @@
|
||||
(str/replace value #"," "")
|
||||
)
|
||||
|
||||
(defmethod parse-value :trim-commas-and-negate
|
||||
[_ _ value]
|
||||
(let [[_ raw-value] (re-find #"([\d\.]+)"
|
||||
(-> value
|
||||
(str/replace #"," "")
|
||||
(str/replace #"-" "")))]
|
||||
(if (or (str/includes? value "-")
|
||||
(str/includes? value "CR"))
|
||||
(str (- (Double/parseDouble raw-value)))
|
||||
(str raw-value))))
|
||||
|
||||
(defmethod parse-value :clj-time
|
||||
[_ format value]
|
||||
(time/from-time-zone (f/parse (f/formatter format) value)
|
||||
|
||||
Reference in New Issue
Block a user