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
b37444f3
Unverified
Commit
b37444f3
authored
Oct 16, 2019
by
Torkel Ödegaard
Committed by
GitHub
Oct 16, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
InputDataSource: Fixed issue with config editor (#19818)
parent
945b815f
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
1 deletions
+13
-1
packages/grafana-data/src/utils/csv.ts
+8
-0
public/app/features/manage-dashboards/DashboardImportCtrl.ts
+4
-0
public/app/plugins/datasource/input/utils.ts
+1
-1
No files found.
packages/grafana-data/src/utils/csv.ts
View file @
b37444f3
...
...
@@ -271,6 +271,12 @@ export function toCSV(data: DataFrame[], config?: CSVConfig): string {
for
(
const
series
of
data
)
{
const
{
fields
}
=
series
;
// ignore frames with no fields
if
(
fields
.
length
===
0
)
{
continue
;
}
if
(
config
.
headerStyle
===
CSVHeaderStyle
.
full
)
{
csv
=
csv
+
...
...
@@ -287,7 +293,9 @@ export function toCSV(data: DataFrame[], config?: CSVConfig): string {
}
csv
+=
config
.
newline
;
}
const
length
=
fields
[
0
].
values
.
length
;
if
(
length
>
0
)
{
const
writers
=
fields
.
map
(
field
=>
makeFieldWriter
(
field
,
config
!
));
for
(
let
i
=
0
;
i
<
length
;
i
++
)
{
...
...
public/app/features/manage-dashboards/DashboardImportCtrl.ts
View file @
b37444f3
...
...
@@ -141,6 +141,10 @@ export class DashboardImportCtrl {
this
.
autoGenerateUidValue
=
'value set'
;
}
if
(
!
this
.
dash
.
uid
)
{
return
;
}
this
.
backendSrv
// @ts-ignore
.
getDashboardByUid
(
this
.
dash
.
uid
)
...
...
public/app/plugins/datasource/input/utils.ts
View file @
b37444f3
...
...
@@ -4,5 +4,5 @@ export function dataFrameToCSV(dto?: DataFrameDTO[]) {
if
(
!
dto
||
!
dto
.
length
)
{
return
''
;
}
return
toCSV
(
dto
.
map
(
v
=>
toDataFrame
(
dto
)));
return
toCSV
(
dto
.
map
(
v
=>
toDataFrame
(
v
)));
}
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