/*! grafana - v4.2.0 - 2017-03-24
 * Copyright (c) 2017 Torkel Ödegaard; Licensed Apache-2.0 */

System.register(["lodash"],function(a,b){"use strict";var c,d;b&&b.id;return{setters:[function(a){c=a}],execute:function(){d=function(){function a(a){this.indexPatternTypes=[{name:"No pattern",value:void 0},{name:"Hourly",value:"Hourly",example:"[logstash-]YYYY.MM.DD.HH"},{name:"Daily",value:"Daily",example:"[logstash-]YYYY.MM.DD"},{name:"Weekly",value:"Weekly",example:"[logstash-]GGGG.WW"},{name:"Monthly",value:"Monthly",example:"[logstash-]YYYY.MM"},{name:"Yearly",value:"Yearly",example:"[logstash-]YYYY"}],this.esVersions=[{name:"2.x",value:2},{name:"5.x",value:5}],this.current.jsonData.timeField=this.current.jsonData.timeField||"@timestamp"}return a.$inject=["$scope"],a.prototype.indexPatternTypeChanged=function(){var a=c.default.find(this.indexPatternTypes,{value:this.current.jsonData.interval});this.current.database=a.example||"es-index-name"},a}(),d.templateUrl="public/app/plugins/datasource/elasticsearch/partials/config.html",a("ElasticConfigCtrl",d)}}});