Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
K
koko
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ops
koko
Commits
4b65f008
Commit
4b65f008
authored
Jun 21, 2019
by
Eric
Committed by
Eric_Lee
Jun 21, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix comment display bugs
parent
69cbd85c
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
12 additions
and
3 deletions
+12
-3
pagination.go
pkg/handler/pagination.go
+10
-3
transport.go
pkg/proxy/transport.go
+2
-0
No files found.
pkg/handler/pagination.go
View file @
4b65f008
...
...
@@ -145,7 +145,14 @@ func (p *AssetPagination) displayPageAssets() {
names
[
i
]
=
systemUser
[
i
]
.
Name
}
row
[
"systemUsers"
]
=
strings
.
Join
(
names
,
","
)
row
[
"comment"
]
=
j
.
Comment
comments
:=
make
([]
string
,
0
)
for
_
,
item
:=
range
strings
.
Split
(
strings
.
TrimSpace
(
j
.
Comment
),
"
\r\n
"
){
if
strings
.
TrimSpace
(
item
)
==
""
{
continue
}
comments
=
append
(
comments
,
strings
.
ReplaceAll
(
strings
.
TrimSpace
(
item
),
" "
,
","
))
}
row
[
"comment"
]
=
strings
.
Join
(
comments
,
"|"
)
data
[
i
]
=
row
}
w
,
_
:=
p
.
term
.
GetSize
()
...
...
@@ -159,9 +166,9 @@ func (p *AssetPagination) displayPageAssets() {
FieldsSize
:
map
[
string
][
3
]
int
{
"ID"
:
{
0
,
0
,
4
},
"hostname"
:
{
0
,
8
,
0
},
"IP"
:
{
15
,
0
,
0
},
"IP"
:
{
0
,
15
,
4
0
},
"systemUsers"
:
{
0
,
12
,
0
},
"comment"
:
{
0
,
0
,
0
},
"comment"
:
{
0
,
0
,
4
0
},
},
Data
:
data
,
TotalSize
:
w
,
...
...
pkg/proxy/transport.go
View file @
4b65f008
...
...
@@ -52,6 +52,8 @@ func (dt *DirectTransport) Keep() {
if
!
dt
.
closed
{
dt
.
ch
<-
buf
[
:
n
]
}
else
{
// 解决用户终端返回时, 数据丢失
_
,
_
=
dt
.
readWriter
.
Write
(
buf
[
:
n
])
logger
.
Debug
(
"Transport closed"
)
break
}
...
...
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