Commit fe5bb6cc authored by S Anand's avatar S Anand

BUG: formhandler should parse dates as UTC. Fixes #159

parent 9a77826d
Pipeline #81016 passed with stage
in 2 minutes and 31 seconds
......@@ -140,7 +140,7 @@ Each template receives these variables:
fmt === "string" && colinfo.type === "number" ?
numeral(val).format(colinfo.format) :
fmt === "string" && colinfo.type === "date" ?
moment(val).format(colinfo.format):
moment.utc(val).format(colinfo.format):
val,
col_link
%>
......@@ -395,7 +395,7 @@ Each template receives these variables:
val = row[colinfo.name],
disp = (fmt == "function" ? colinfo.format({index: rowIndex, name: colinfo.name, value: val, row: row, data:data }) :
fmt === "string" && colinfo.type === "number" ? numeral(val).format(colinfo.format) :
fmt === "string" && colinfo.type === "date" ? moment(val).format(colinfo.format) :
fmt === "string" && colinfo.type === "date" ? moment.utc(val).format(colinfo.format) :
val) %>
<div>
<strong><%= colinfo.name %></strong>:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment