Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
DiDi
nightingale
提交
a30e6d6b
N
nightingale
项目概览
DiDi
/
nightingale
11 个月 前同步成功
通知
46
Star
7053
Fork
1161
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
N
nightingale
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
a30e6d6b
编写于
4月 27, 2020
作者:
J
jsers
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
fix: type and query filter does not work (#104)
上级
8b0e2b80
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
9 addition
and
17 deletion
+9
-17
web/src/locales/en.ts
web/src/locales/en.ts
+1
-0
web/src/locales/zh.ts
web/src/locales/zh.ts
+1
-0
web/src/pages/Monitor/History/List.tsx
web/src/pages/Monitor/History/List.tsx
+7
-17
未找到文件。
web/src/locales/en.ts
浏览文件 @
a30e6d6b
...
...
@@ -106,6 +106,7 @@ export default {
'
7天
'
:
'
7days
'
,
'
30天
'
:
'
30days
'
,
'
其它
'
:
'
other
'
,
'
自定义
'
:
'
custom
'
,
'
menu.endpoints
'
:
'
Endpoints
'
,
'
menu.endpoints.all
'
:
'
All endpoints
'
,
...
...
web/src/locales/zh.ts
浏览文件 @
a30e6d6b
...
...
@@ -106,6 +106,7 @@ export default {
'
7天
'
:
'
7天
'
,
'
30天
'
:
'
30天
'
,
'
其它
'
:
'
其它
'
,
'
自定义
'
:
'
自定义
'
,
'
menu.endpoints
'
:
'
监控对象
'
,
'
menu.endpoints.all
'
:
'
全部对象
'
,
...
...
web/src/pages/Monitor/History/List.tsx
浏览文件 @
a30e6d6b
...
...
@@ -89,9 +89,9 @@ class index extends Component<Props & WrappedComponentProps, State> {
getQuery
()
{
const
{
nodepath
}
=
this
.
props
;
const
{
stime
,
etime
,
priorities
}
=
this
.
state
;
const
{
stime
,
etime
,
priorities
,
type
,
searchValue
}
=
this
.
state
;
return
{
stime
,
etime
,
priorities
,
nodepath
};
return
{
stime
,
etime
,
priorities
,
nodepath
,
type
,
query
:
searchValue
};
}
updateTime
=
(
cbk
?:
()
=>
void
)
=>
{
...
...
@@ -268,9 +268,7 @@ class index extends Component<Props & WrappedComponentProps, State> {
const
now
=
moment
();
const
nStime
=
now
.
clone
().
subtract
(
val
,
'
hours
'
).
unix
();
const
nEtime
=
now
.
clone
().
unix
();
this
.
setState
({
customTime
:
false
,
stime
:
nStime
,
etime
:
nEtime
},
()
=>
{
this
.
fetchTable
.
reload
();
});
this
.
setState
({
customTime
:
false
,
stime
:
nStime
,
etime
:
nEtime
});
}
else
{
this
.
setState
({
customTime
:
true
});
}
...
...
@@ -293,9 +291,7 @@ class index extends Component<Props & WrappedComponentProps, State> {
placeholder
=
"Start"
onChange
=
{
(
val
)
=>
{
if
(
val
)
{
this
.
setState
({
stime
:
val
.
unix
()
},
()
=>
{
this
.
fetchTable
.
reload
();
});
this
.
setState
({
stime
:
val
.
unix
()
});
}
}
}
/>
...
...
@@ -307,9 +303,7 @@ class index extends Component<Props & WrappedComponentProps, State> {
placeholder
=
"End"
onChange
=
{
(
val
)
=>
{
if
(
val
)
{
this
.
setState
({
etime
:
val
.
unix
()
},
()
=>
{
this
.
fetchTable
.
reload
();
});
this
.
setState
({
etime
:
val
.
unix
()
});
}
}
}
/>
...
...
@@ -324,9 +318,7 @@ class index extends Component<Props & WrappedComponentProps, State> {
value
=
{
type
}
onChange
=
{
(
value
:
string
)
=>
{
this
.
updateTime
(()
=>
{
this
.
setState
({
type
:
value
},
()
=>
{
this
.
fetchTable
.
reload
();
});
this
.
setState
({
type
:
value
});
});
}
}
>
...
...
@@ -345,9 +337,7 @@ class index extends Component<Props & WrappedComponentProps, State> {
value
=
{
priorities
?
_
.
map
(
_
.
split
(
priorities
,
'
,
'
),
_
.
toNumber
)
:
[]
}
onChange
=
{
(
value
:
number
)
=>
{
this
.
updateTime
(()
=>
{
this
.
setState
({
priorities
:
!
_
.
isEmpty
(
value
)
?
_
.
join
(
value
,
'
,
'
)
:
undefined
},
()
=>
{
this
.
fetchTable
.
reload
();
});
this
.
setState
({
priorities
:
!
_
.
isEmpty
(
value
)
?
_
.
join
(
value
,
'
,
'
)
:
undefined
});
});
}
}
>
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录