Skip to content

Commit 883b10e

Browse files
committed
replaced dateOptionalTime as strict_date_optional_time||epoch_millis
https://www.elastic.co/guide/en/elasticsearch/reference/2.4/mapping-date -format.html
1 parent 6816b5f commit 883b10e

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

lib/document.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -385,7 +385,7 @@
385385
break;
386386
case properties.DateProperty:
387387
field.type = 'date';
388-
field.format = 'dateOptionalTime';
388+
field.format = 'strict_date_optional_time||epoch_millis';
389389
break;
390390
case properties.ReferenceProperty:
391391
field.type = 'string';
@@ -407,7 +407,7 @@
407407
break;
408408
case properties.DateProperty:
409409
field.type = 'date';
410-
field.format = 'dateOptionalTime';
410+
field.format = 'strict_date_optional_time||epoch_millis';
411411
break;
412412
case properties.ReferenceProperty:
413413
field.type = 'string';

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "enju",
3-
"version": "0.2.6",
3+
"version": "0.2.8",
44
"description": "An elasticsearch on node.js written in CoffeeScript.",
55
"main": "index.js",
66
"scripts": {

src/lib/document.coffee

+2-2
Original file line numberDiff line numberDiff line change
@@ -273,7 +273,7 @@ module.exports = class Document
273273
field.type = 'double'
274274
when properties.DateProperty
275275
field.type = 'date'
276-
field.format = 'dateOptionalTime'
276+
field.format = 'strict_date_optional_time||epoch_millis'
277277
when properties.ReferenceProperty
278278
field.type = 'string'
279279
field.analyzer = 'keyword'
@@ -289,7 +289,7 @@ module.exports = class Document
289289
field.type = 'double'
290290
when properties.DateProperty
291291
field.type = 'date'
292-
field.format = 'dateOptionalTime'
292+
field.format = 'strict_date_optional_time||epoch_millis'
293293
when properties.ReferenceProperty
294294
field.type = 'string'
295295
field.analyzer = 'keyword'

0 commit comments

Comments
 (0)