Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
蜕变的菜鸟
glances
提交
783b5d98
G
glances
项目概览
蜕变的菜鸟
/
glances
与 Fork 源项目一致
从无法访问的项目Fork
通知
1
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
G
glances
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
783b5d98
编写于
9月 08, 2015
作者:
F
Floran Brutel
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
WebUI : adds raid plugin
上级
1945db14
变更
6
隐藏空白更改
内联
并排
Showing
6 changed file
with
67 addition
and
0 deletion
+67
-0
glances/outputs/static/html/index.html
glances/outputs/static/html/index.html
+1
-0
glances/outputs/static/html/plugins/raid.html
glances/outputs/static/html/plugins/raid.html
+19
-0
glances/outputs/static/html/stats.html
glances/outputs/static/html/stats.html
+1
-0
glances/outputs/static/js/services/core/glances_stats.js
glances/outputs/static/js/services/core/glances_stats.js
+1
-0
glances/outputs/static/js/services/plugins/glances_raid.js
glances/outputs/static/js/services/plugins/glances_raid.js
+44
-0
glances/outputs/static/js/stats_controller.js
glances/outputs/static/js/stats_controller.js
+1
-0
未找到文件。
glances/outputs/static/html/index.html
浏览文件 @
783b5d98
...
...
@@ -35,6 +35,7 @@
<script
type=
"text/javascript"
src=
"services/plugins/glances_processcount.js"
></script>
<script
type=
"text/javascript"
src=
"services/plugins/glances_processlist.js"
></script>
<script
type=
"text/javascript"
src=
"services/plugins/glances_quicklook.js"
></script>
<script
type=
"text/javascript"
src=
"services/plugins/glances_raid.js"
></script>
<script
type=
"text/javascript"
src=
"services/plugins/glances_sensors.js"
></script>
<script
type=
"text/javascript"
src=
"services/plugins/glances_system.js"
></script>
<script
type=
"text/javascript"
src=
"services/plugins/glances_uptime.js"
></script>
...
...
glances/outputs/static/html/plugins/raid.html
0 → 100644
浏览文件 @
783b5d98
<div
class=
"table-row"
>
<div
class=
"table-cell text-left title"
>
RAID disks
</div>
<div
class=
"table-cell"
>
Used
</div>
<div
class=
"table-cell"
>
Total
</div>
</div>
<div
class=
"table-row"
ng-repeat=
"disk in statsRaid.disks | orderBy: 'name'"
>
<div
class=
"table-cell text-left"
>
{{ disk.type | uppercase }} {{ disk.name }}
<div
class=
"warning"
ng-show=
"disk.degraded"
>
└─ Degraded mode
</div>
<div
ng-show=
"disk.degraded"
>
└─ {{ disk.config }}
</div>
<div
class=
"critical"
ng-show=
"disk.inactive"
>
└─ Status {{ disk.status }}
</div>
<div
ng-show=
"disk.inactive"
ng-repeat=
"component in disk.components | orderBy: 'number'"
>
{{ $last ? '└─' : '├─' }} disk {{ component.number }}: {{ component.name }}
</div>
</div>
<div
class=
"table-cell"
ng-show=
"!disk.inactive"
ng-class=
"statsRaid.getAlert(disk)"
>
{{ disk.used }}
</div>
<div
class=
"table-cell"
ng-show=
"!disk.inactive"
ng-class=
"statsRaid.getAlert(disk)"
>
{{ disk.available }}
</div>
</div>
\ No newline at end of file
glances/outputs/static/html/stats.html
浏览文件 @
783b5d98
...
...
@@ -51,6 +51,7 @@
<section
id=
"network"
class=
"plugin table-row-group"
ng-show=
"show.network"
ng-include
src=
"'plugins/network.html'"
></section>
<section
id=
"diskio"
class=
"plugin table-row-group"
ng-show=
"show.diskio"
ng-include
src=
"'plugins/diskio.html'"
></section>
<section
id=
"fs"
class=
"plugin table-row-group"
ng-show=
"show.fs"
ng-include
src=
"'plugins/fs.html'"
></section>
<section
id=
"raid"
class=
"plugin table-row-group"
ng-show=
"show.fs"
ng-include
src=
"'plugins/raid.html'"
></section>
<section
id=
"sensors"
class=
"plugin table-row-group"
ng-show=
"show.sensors && statsSensors.sensors.length > 0"
ng-include
src=
"'plugins/sensors.html'"
></section>
</div>
</div>
...
...
glances/outputs/static/js/services/core/glances_stats.js
浏览文件 @
783b5d98
...
...
@@ -17,6 +17,7 @@ glancesApp.service('GlancesStats', function($http, $injector, $q, GlancesPlugin)
'
processcount
'
:
'
GlancesPluginProcessCount
'
,
'
processlist
'
:
'
GlancesPluginProcessList
'
,
'
quicklook
'
:
'
GlancesPluginQuicklook
'
,
'
raid
'
:
'
GlancesPluginRaid
'
,
'
sensors
'
:
'
GlancesPluginSensors
'
,
'
system
'
:
'
GlancesPluginSystem
'
,
'
uptime
'
:
'
GlancesPluginUptime
'
...
...
glances/outputs/static/js/services/plugins/glances_raid.js
0 → 100644
浏览文件 @
783b5d98
glancesApp
.
service
(
'
GlancesPluginRaid
'
,
function
()
{
var
_pluginName
=
"
raid
"
;
this
.
disks
=
[];
this
.
setData
=
function
(
data
,
views
)
{
this
.
disks
=
[];
data
=
data
[
_pluginName
];
_
.
forIn
(
data
,
function
(
diskData
,
diskKey
)
{
var
disk
=
{
'
name
'
:
diskKey
,
'
type
'
:
diskData
.
type
==
null
?
'
UNKNOWN
'
:
diskData
.
type
,
'
used
'
:
diskData
.
used
,
'
available
'
:
diskData
.
available
,
'
status
'
:
diskData
.
status
,
'
degraded
'
:
diskData
.
used
<
diskData
.
available
,
'
config
'
:
diskData
.
config
==
null
?
''
:
diskData
.
config
.
replace
(
'
_
'
,
'
A
'
),
'
inactive
'
:
diskData
.
status
==
'
inactive
'
,
'
components
'
:
[]
};
_
.
forEach
(
diskData
.
components
,
function
(
number
,
name
)
{
disk
.
components
.
push
({
'
number
'
:
number
,
'
name
'
:
name
});
});
this
.
disks
.
push
(
disk
);
},
this
);
};
this
.
getAlert
=
function
(
disk
)
{
if
(
disk
.
inactive
)
{
return
'
critical
'
;
}
if
(
disk
.
degraded
)
{
return
'
warning
'
;
}
return
'
ok
'
}
});
glances/outputs/static/js/stats_controller.js
浏览文件 @
783b5d98
...
...
@@ -73,6 +73,7 @@ glancesApp.controller('statsController', function ($scope, $interval, $routePara
$scope
.
statsProcessCount
=
GlancesStats
.
getPlugin
(
'
processcount
'
);
$scope
.
statsProcessList
=
GlancesStats
.
getPlugin
(
'
processlist
'
);
$scope
.
statsQuicklook
=
GlancesStats
.
getPlugin
(
'
quicklook
'
);
$scope
.
statsRaid
=
GlancesStats
.
getPlugin
(
'
raid
'
);
$scope
.
statsSensors
=
GlancesStats
.
getPlugin
(
'
sensors
'
);
$scope
.
statsSystem
=
GlancesStats
.
getPlugin
(
'
system
'
);
$scope
.
statsUptime
=
GlancesStats
.
getPlugin
(
'
uptime
'
);
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录