Skip to content
This repository was archived by the owner on Oct 31, 2023. It is now read-only.

Commit c7f02ef

Browse files
committed
Merge pull request #4 from ryokdy/v0.4
change not to sort columns
2 parents 3b6c918 + 7163f51 commit c7f02ef

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

export.go

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import (
66
"os"
77
"strings"
88
"time"
9-
"sort"
9+
//"sort"
1010
"github.com/kintone/go-kintone"
1111
"golang.org/x/text/transform"
1212
)
@@ -92,6 +92,10 @@ func makePartialColumns(fields map[string]*kintone.FieldInfo, partialFields []st
9292

9393
for _, val := range partialFields {
9494
column := getColumn(val, fields)
95+
96+
if column.Type == "UNKNOWN" || column.IsSubField {
97+
continue
98+
}
9599
if column.Type == kintone.FT_SUBTABLE {
96100
// append all sub fields
97101
field := fields[val]
@@ -160,7 +164,7 @@ func writeCsv(app *kintone.App) error {
160164
} else {
161165
columns = makePartialColumns(fields, config.fields)
162166
}
163-
sort.Sort(columns)
167+
//sort.Sort(columns)
164168
j := 0
165169
hasTable = hasSubTable(columns)
166170
if hasTable {

0 commit comments

Comments
 (0)