Skip to content

Commit

Permalink
Show online device count in web page
Browse files Browse the repository at this point in the history
Signed-off-by: Jianhui Zhao <jianhuizhao329@gmail.com>
  • Loading branch information
Jianhui Zhao committed Jun 14, 2018
1 parent c7a968b commit 5bb230c
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 3 deletions.
11 changes: 10 additions & 1 deletion assets/src/components/Home.vue
100755 → 100644
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
<template>
<div id="home">
<Input v-model="filterString" icon="search" size="large" @on-change="handleSearch" :placeholder="$t('Please enter the filter key...')" style="width: 400px" />
<Row type="flex" align="bottom">
<Col span="6">
<Input v-model="filterString" icon="search" size="large" @on-change="handleSearch" :placeholder="$t('Please enter the filter key...')" style="width: 400px" />
</Col>
<Col span="3" offset="15" class="counter">{{ $t('Online Device: {count}', {count: devlists.length}) }}</Col>
</Row>
<Table :loading="loading" :columns="devlistTitle" :data="filtered" style="margin-top: 10px; width: 100%" :no-data-text="$t('No devices connected')"></Table>
</div>
</template>
Expand Down Expand Up @@ -81,4 +86,8 @@ export default {
#home {
padding:10px;
}
.counter {
color: #3399ff;
font-size: 16px;
}
</style>
Empty file modified assets/src/components/Login.vue
100755 → 100644
Empty file.
Empty file modified assets/src/components/Rtty.vue
100755 → 100644
Empty file.
3 changes: 2 additions & 1 deletion assets/src/rtty-i18n.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ const RttyI18n = {
'Login': '登录',
'username is required': '用户名为必填',
'Login Fail! username or password wrong.': '登录失败,用户名或密码错误',
'Connect failed': '连接失败'
'Connect failed': '连接失败',
'Online Device: {count}': '在线设备数:{count}',
}
}

Expand Down
2 changes: 1 addition & 1 deletion statik/statik.go

Large diffs are not rendered by default.

0 comments on commit 5bb230c

Please sign in to comment.