20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
# File 'lib/elastic_record/index/mapping.rb', line 20
def mapping
@mapping ||= {
_source: {
enabled: false
},
properties: {
created_at: {type: "date", index: "not_analyzed", format: "dateOptionalTime"},
updated_at: {type: "date", index: "not_analyzed", format: "dateOptionalTime"}
},
dynamic_templates: [
{
no_string_analyzing: {
match: "*",
match_mapping_type: "string",
mapping: {
type: "string",
index: "not_analyzed"
}
}
}
]
}
end
|