Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nexpie-grafana-theme
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Registry
Registry
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kornkitt Poolsup
nexpie-grafana-theme
Commits
fcdc2974
Unverified
Commit
fcdc2974
authored
Jul 05, 2019
by
Ryan McKinley
Committed by
GitHub
Jul 05, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
@grafana/data: export dateMath and rangeUtil (#17971)
parent
3f151709
Show whitespace changes
Inline
Side-by-side
Showing
23 changed files
with
27 additions
and
25 deletions
+27
-25
packages/grafana-data/src/utils/index.ts
+4
-2
packages/grafana-ui/src/components/TimePicker/TimePicker.tsx
+1
-1
packages/grafana-ui/src/components/TimePicker/time.ts
+1
-1
public/app/core/directives/ng_model_on_blur.ts
+1
-1
public/app/core/specs/rangeutil.test.ts
+1
-1
public/app/core/utils/explore.ts
+1
-1
public/app/features/dashboard/services/DashboardLoaderSrv.ts
+1
-1
public/app/features/dashboard/services/TimeSrv.ts
+1
-1
public/app/features/dashboard/state/PanelQueryState.ts
+1
-1
public/app/features/dashboard/utils/panel.ts
+2
-2
public/app/features/explore/Logs.tsx
+1
-1
public/app/features/explore/state/epics/runQueriesBatchEpic.ts
+1
-1
public/app/features/plugins/plugin_loader.ts
+1
-1
public/app/plugins/datasource/cloudwatch/datasource.ts
+1
-1
public/app/plugins/datasource/cloudwatch/specs/datasource.test.ts
+1
-1
public/app/plugins/datasource/elasticsearch/specs/datasource.test.ts
+1
-1
public/app/plugins/datasource/graphite/datasource.ts
+1
-1
public/app/plugins/datasource/influxdb/datasource.ts
+1
-1
public/app/plugins/datasource/loki/datasource.ts
+1
-1
public/app/plugins/datasource/opentsdb/datasource.ts
+1
-1
public/app/plugins/datasource/prometheus/datasource.ts
+1
-1
public/app/plugins/panel/alertlist/module.ts
+1
-1
public/test/specs/helpers.ts
+1
-1
No files found.
packages/grafana-data/src/utils/index.ts
View file @
fcdc2974
...
...
@@ -10,5 +10,7 @@ export * from './object';
export
*
from
'./fieldCache'
;
export
*
from
'./moment_wrapper'
;
// Names are too general to export
// rangeutils, datemath
// Names are too general to export globally
import
*
as
dateMath
from
'./datemath'
;
import
*
as
rangeUtil
from
'./rangeutil'
;
export
{
dateMath
,
rangeUtil
};
packages/grafana-ui/src/components/TimePicker/TimePicker.tsx
View file @
fcdc2974
...
...
@@ -9,7 +9,7 @@ import { ClickOutsideWrapper } from '../ClickOutsideWrapper/ClickOutsideWrapper'
// Utils & Services
import
{
isDateTime
}
from
'@grafana/data'
;
import
*
as
rangeUtil
from
'@grafana/data/src/utils/rangeutil
'
;
import
{
rangeUtil
}
from
'@grafana/data
'
;
import
{
rawToTimeRange
}
from
'./time'
;
// Types
...
...
packages/grafana-ui/src/components/TimePicker/time.ts
View file @
fcdc2974
import
{
TimeRange
,
TIME_FORMAT
,
RawTimeRange
,
TimeZone
}
from
'@grafana/data'
;
import
{
describeTimeRange
}
from
'@grafana/data/src/utils/rangeutil'
;
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
import
{
isDateTime
,
dateTime
,
DateTime
,
toUtc
}
from
'@grafana/data'
;
export
const
rawToTimeRange
=
(
raw
:
RawTimeRange
,
timeZone
?:
TimeZone
):
TimeRange
=>
{
...
...
public/app/core/directives/ng_model_on_blur.ts
View file @
fcdc2974
import
coreModule
from
'../core_module'
;
import
*
as
rangeUtil
from
'@grafana/data/src/utils/rangeutil
'
;
import
{
rangeUtil
}
from
'@grafana/data
'
;
function
ngModelOnBlur
()
{
return
{
...
...
public/app/core/specs/rangeutil.test.ts
View file @
fcdc2974
import
*
as
rangeUtil
from
'@grafana/data/src/utils/rangeutil
'
;
import
{
rangeUtil
}
from
'@grafana/data
'
;
import
_
from
'lodash'
;
import
{
dateTime
}
from
'@grafana/data'
;
...
...
public/app/core/utils/explore.ts
View file @
fcdc2974
...
...
@@ -4,7 +4,7 @@ import { from } from 'rxjs';
import
{
isLive
}
from
'@grafana/ui/src/components/RefreshPicker/RefreshPicker'
;
// Services & Utils
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
import
{
renderUrl
}
from
'app/core/utils/url'
;
import
kbn
from
'app/core/utils/kbn'
;
import
store
from
'app/core/store'
;
...
...
public/app/features/dashboard/services/DashboardLoaderSrv.ts
View file @
fcdc2974
...
...
@@ -4,7 +4,7 @@ import moment from 'moment';
import
_
from
'lodash'
;
import
$
from
'jquery'
;
import
kbn
from
'app/core/utils/kbn'
;
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
import
impressionSrv
from
'app/core/services/impression_srv'
;
export
class
DashboardLoaderSrv
{
...
...
public/app/features/dashboard/services/TimeSrv.ts
View file @
fcdc2974
...
...
@@ -4,7 +4,7 @@ import _ from 'lodash';
// Utils
import
kbn
from
'app/core/utils/kbn'
;
import
coreModule
from
'app/core/core_module'
;
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
// Types
import
{
TimeRange
,
RawTimeRange
,
TimeZone
}
from
'@grafana/data'
;
...
...
public/app/features/dashboard/state/PanelQueryState.ts
View file @
fcdc2974
...
...
@@ -4,7 +4,7 @@ import isEqual from 'lodash/isEqual';
// Utils & Services
import
{
getBackendSrv
}
from
'app/core/services/backend_srv'
;
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
import
{
guessFieldTypes
,
LoadingState
,
...
...
public/app/features/dashboard/utils/panel.ts
View file @
fcdc2974
...
...
@@ -8,8 +8,8 @@ import { TimeRange } from '@grafana/data';
// Utils
import
{
isString
as
_isString
}
from
'lodash'
;
import
*
as
rangeUtil
from
'@grafana/data/src/utils/rangeutil
'
;
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
rangeUtil
}
from
'@grafana/data
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
import
appEvents
from
'app/core/app_events'
;
import
config
from
'app/core/config'
;
...
...
public/app/features/explore/Logs.tsx
View file @
fcdc2974
import
_
from
'lodash'
;
import
React
,
{
PureComponent
}
from
'react'
;
import
*
as
rangeUtil
from
'@grafana/data/src/utils/rangeutil
'
;
import
{
rangeUtil
}
from
'@grafana/data
'
;
import
{
Switch
}
from
'@grafana/ui'
;
import
{
RawTimeRange
,
...
...
public/app/features/explore/state/epics/runQueriesBatchEpic.ts
View file @
fcdc2974
...
...
@@ -6,7 +6,7 @@ import { isLive } from '@grafana/ui/src/components/RefreshPicker/RefreshPicker';
import
{
DataStreamState
,
DataQueryResponse
,
DataQueryResponseData
}
from
'@grafana/ui'
;
import
{
LoadingState
,
DataFrame
,
AbsoluteTimeRange
}
from
'@grafana/data'
;
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
import
{
ActionOf
}
from
'app/core/redux/actionCreatorFactory'
;
import
{
StoreState
}
from
'app/types/store'
;
...
...
public/app/features/plugins/plugin_loader.ts
View file @
fcdc2974
...
...
@@ -19,7 +19,7 @@ import TimeSeries from 'app/core/time_series2';
import
TableModel
from
'app/core/table_model'
;
import
{
coreModule
,
appEvents
,
contextSrv
}
from
'app/core/core'
;
import
{
DataSourcePlugin
,
AppPlugin
,
PanelPlugin
,
PluginMeta
,
DataSourcePluginMeta
}
from
'@grafana/ui'
;
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
import
*
as
fileExport
from
'app/core/utils/file_export'
;
import
*
as
flatten
from
'app/core/utils/flatten'
;
import
*
as
ticks
from
'app/core/utils/ticks'
;
...
...
public/app/plugins/datasource/cloudwatch/datasource.ts
View file @
fcdc2974
import
angular
from
'angular'
;
import
_
from
'lodash'
;
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
import
kbn
from
'app/core/utils/kbn'
;
import
{
CloudWatchQuery
}
from
'./types'
;
import
{
DataSourceApi
,
DataQueryRequest
,
DataSourceInstanceSettings
}
from
'@grafana/ui'
;
...
...
public/app/plugins/datasource/cloudwatch/specs/datasource.test.ts
View file @
fcdc2974
import
'../datasource'
;
import
CloudWatchDatasource
from
'../datasource'
;
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
import
{
TemplateSrv
}
from
'app/features/templating/template_srv'
;
import
{
CustomVariable
}
from
'app/features/templating/all'
;
import
_
from
'lodash'
;
...
...
public/app/plugins/datasource/elasticsearch/specs/datasource.test.ts
View file @
fcdc2974
import
angular
,
{
IQService
}
from
'angular'
;
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
import
_
from
'lodash'
;
import
{
ElasticDatasource
,
getMaxConcurrenShardRequestOrDefault
}
from
'../datasource'
;
import
{
toUtc
,
dateTime
}
from
'@grafana/data'
;
...
...
public/app/plugins/datasource/graphite/datasource.ts
View file @
fcdc2974
import
_
from
'lodash'
;
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
import
{
isVersionGtOrEq
,
SemVersion
}
from
'app/core/utils/version'
;
import
gfunc
from
'./gfunc'
;
import
{
IQService
}
from
'angular'
;
...
...
public/app/plugins/datasource/influxdb/datasource.ts
View file @
fcdc2974
import
_
from
'lodash'
;
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
import
InfluxSeries
from
'./influx_series'
;
import
InfluxQueryModel
from
'./influx_query_model'
;
import
ResponseParser
from
'./response_parser'
;
...
...
public/app/plugins/datasource/loki/datasource.ts
View file @
fcdc2974
...
...
@@ -5,7 +5,7 @@ import { webSocket } from 'rxjs/webSocket';
import
{
catchError
,
map
}
from
'rxjs/operators'
;
// Services & Utils
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
import
{
addLabelToSelector
}
from
'app/plugins/datasource/prometheus/add_label_to_query'
;
import
LanguageProvider
from
'./language_provider'
;
import
{
logStreamToDataFrame
}
from
'./result_transformer'
;
...
...
public/app/plugins/datasource/opentsdb/datasource.ts
View file @
fcdc2974
import
angular
,
{
IQService
}
from
'angular'
;
import
_
from
'lodash'
;
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
import
{
BackendSrv
}
from
'app/core/services/backend_srv'
;
import
{
TemplateSrv
}
from
'app/features/templating/template_srv'
;
import
{
DataQueryRequest
}
from
'@grafana/ui'
;
...
...
public/app/plugins/datasource/prometheus/datasource.ts
View file @
fcdc2974
...
...
@@ -6,7 +6,7 @@ import { single, map, filter, catchError } from 'rxjs/operators';
// Services & Utils
import
kbn
from
'app/core/utils/kbn'
;
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
import
PrometheusMetricFindQuery
from
'./metric_find_query'
;
import
{
ResultTransformer
}
from
'./result_transformer'
;
import
PrometheusLanguageProvider
from
'./language_provider'
;
...
...
public/app/plugins/panel/alertlist/module.ts
View file @
fcdc2974
...
...
@@ -2,7 +2,7 @@ import _ from 'lodash';
import
alertDef
from
'../../../features/alerting/state/alertDef'
;
import
{
PanelCtrl
}
from
'app/plugins/sdk'
;
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
import
{
dateTime
}
from
'@grafana/data'
;
import
{
auto
}
from
'angular'
;
import
{
BackendSrv
}
from
'@grafana/runtime'
;
...
...
public/test/specs/helpers.ts
View file @
fcdc2974
import
_
from
'lodash'
;
import
config
from
'app/core/config'
;
import
*
as
dateMath
from
'@grafana/data/src/utils/datemath
'
;
import
{
dateMath
}
from
'@grafana/data
'
;
import
{
angularMocks
,
sinon
}
from
'../lib/common'
;
import
{
PanelModel
}
from
'app/features/dashboard/state/PanelModel'
;
import
{
RawTimeRange
}
from
'@grafana/data'
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment