mirror of
https://github.com/TeaOSLab/EdgeAdmin.git
synced 2025-11-03 12:20:28 +08:00
阶段性提交
This commit is contained in:
9
web/public/js/components/api-node/api-node-selector.js
Normal file
9
web/public/js/components/api-node/api-node-selector.js
Normal file
@@ -0,0 +1,9 @@
|
||||
Vue.component("api-node-selector", {
|
||||
props: [],
|
||||
data: function () {
|
||||
return {}
|
||||
},
|
||||
template: `<div>
|
||||
暂未实现
|
||||
</div>`
|
||||
})
|
||||
23
web/public/js/components/common/inner-menu-item.js
Normal file
23
web/public/js/components/common/inner-menu-item.js
Normal file
@@ -0,0 +1,23 @@
|
||||
/**
|
||||
* 菜单项
|
||||
*/
|
||||
Vue.component("inner-menu-item", {
|
||||
props: ["href", "active", "code"],
|
||||
data: function () {
|
||||
var active = this.active;
|
||||
if (typeof(active) =="undefined") {
|
||||
var itemCode = "";
|
||||
if (typeof (window.TEA.ACTION.data.firstMenuItem) != "undefined") {
|
||||
itemCode = window.TEA.ACTION.data.firstMenuItem;
|
||||
}
|
||||
active = (itemCode == this.code);
|
||||
}
|
||||
return {
|
||||
vHref: (this.href == null) ? "" : this.href,
|
||||
vActive: active
|
||||
};
|
||||
},
|
||||
template: '\
|
||||
<a :href="vHref" class="item right" style="color:#4183c4" :class="{active:vActive}">[<slot></slot>]</a> \
|
||||
'
|
||||
});
|
||||
11
web/public/js/components/common/inner-menu.js
Normal file
11
web/public/js/components/common/inner-menu.js
Normal file
@@ -0,0 +1,11 @@
|
||||
/**
|
||||
* 二级菜单
|
||||
*/
|
||||
Vue.component("inner-menu", {
|
||||
template: `
|
||||
<div class="second-menu" style="width:80%;position: absolute;top:-8px;right:1em">
|
||||
<div class="ui menu text blue small">
|
||||
<slot></slot>
|
||||
</div>
|
||||
</div>`
|
||||
});
|
||||
16
web/public/js/components/common/page-box.js
Normal file
16
web/public/js/components/common/page-box.js
Normal file
@@ -0,0 +1,16 @@
|
||||
Vue.component("page-box", {
|
||||
data: function () {
|
||||
return {
|
||||
page: ""
|
||||
}
|
||||
},
|
||||
created: function () {
|
||||
let that = this;
|
||||
setTimeout(function () {
|
||||
that.page = Tea.Vue.page;
|
||||
})
|
||||
},
|
||||
template: `<div>
|
||||
<div class="page" v-html="page"></div>
|
||||
</div>`
|
||||
})
|
||||
63
web/public/js/components/grant/grant-selector.js
Normal file
63
web/public/js/components/grant/grant-selector.js
Normal file
@@ -0,0 +1,63 @@
|
||||
Vue.component("grant-selector", {
|
||||
props: ["vGrant"],
|
||||
data: function () {
|
||||
return {
|
||||
grantId: (this.vGrant == null) ? 0 : this.vGrant.id,
|
||||
grant: this.vGrant
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
// 选择授权
|
||||
select: function () {
|
||||
let that = this;
|
||||
teaweb.popup("/nodes/grants/selectPopup", {
|
||||
callback: (resp) => {
|
||||
that.grantId = resp.data.grant.id;
|
||||
if (that.grantId > 0) {
|
||||
that.grant = resp.data.grant;
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
// 创建授权
|
||||
create: function () {
|
||||
teaweb.popup("/nodes/grants/createPopup", {
|
||||
height: "31em",
|
||||
callback: (resp) => {
|
||||
this.grantId = resp.data.grant.id;
|
||||
if (this.grantId > 0) {
|
||||
this.grant = resp.data.grant;
|
||||
}
|
||||
}
|
||||
});
|
||||
},
|
||||
|
||||
// 修改授权
|
||||
update: function () {
|
||||
if (this.grant == null) {
|
||||
window.location.reload();
|
||||
return;
|
||||
}
|
||||
teaweb.popup("/nodes/grants/updatePopup?grantId=" + this.grant.id, {
|
||||
height: "31em",
|
||||
callback: (resp) => {
|
||||
this.grant = resp.data.grant;
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
// 删除已选择授权
|
||||
remove: function () {
|
||||
this.grant = null;
|
||||
this.grantId = 0;
|
||||
}
|
||||
},
|
||||
template: `<div>
|
||||
<input type="hidden" name="grantId" :value="grantId"/>
|
||||
<div class="ui label small" v-if="grant != null">{{grant.name}}<span class="small">({{grant.methodName}})</span> <a href="" title="修改" @click.prevent="update()"><i class="icon pencil small"></i></a> <a href="" title="删除" @click.prevent="remove()"><i class="icon remove"></i></a> </div>
|
||||
<div v-if="grant == null">
|
||||
<a href="" @click.prevent="select()">[选择已有认证]</a> <a href="" @click.prevent="create()">[添加新认证]</a>
|
||||
</div>
|
||||
</div>`
|
||||
})
|
||||
51
web/public/js/components/node/node-ip-addresses-box.js
Normal file
51
web/public/js/components/node/node-ip-addresses-box.js
Normal file
@@ -0,0 +1,51 @@
|
||||
Vue.component("node-ip-addresses-box", {
|
||||
props: ["vIpAddresses"],
|
||||
data: function () {
|
||||
return {
|
||||
ipAddresses: (this.vIpAddresses == null) ? [] : this.vIpAddresses
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
// 添加IP地址
|
||||
addIPAddress: function () {
|
||||
let that = this;
|
||||
teaweb.popup("/nodes/ipAddresses/createPopup", {
|
||||
callback: function (resp) {
|
||||
that.ipAddresses.push(resp.data.ipAddress);
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
// 修改地址
|
||||
updateIPAddress: function (index, address) {
|
||||
let that = this;
|
||||
teaweb.popup("/nodes/ipAddresses/updatePopup?addressId=" + address.id, {
|
||||
callback: function (resp) {
|
||||
Vue.set(that.ipAddresses, index, resp.data.ipAddress);
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
// 删除IP地址
|
||||
removeIPAddress: function (index) {
|
||||
this.ipAddresses.$remove(index);
|
||||
}
|
||||
},
|
||||
template: `<div>
|
||||
<input type="hidden" name="ipAddresses" :value="JSON.stringify(ipAddresses)"/>
|
||||
<div v-if="ipAddresses.length > 0">
|
||||
<div>
|
||||
<div v-for="(address, index) in ipAddresses" class="ui label small">
|
||||
{{address.ip}}<span class="small" v-if="address.name.length > 0">({{address.name}})</span>
|
||||
<a href="" title="修改" @click.prevent="updateIPAddress(index, address)"><i class="icon pencil small"></i></a>
|
||||
<a href="" title="删除" @click.prevent="removeIPAddress(index)"><i class="icon remove"></i></a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="ui divider"></div>
|
||||
</div>
|
||||
<div>
|
||||
<button class="ui button small" type="button" @click.prevent="addIPAddress()">+</button>
|
||||
</div>
|
||||
<p class="comment">添加已经绑定的IP地址,仅做记录用。</p>
|
||||
</div>`
|
||||
})
|
||||
@@ -1,3 +1,54 @@
|
||||
.left-box {
|
||||
width: 8em;
|
||||
position: fixed;
|
||||
top: 7.5em;
|
||||
bottom: 0.5em;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
border-right: 1px #ddd solid;
|
||||
}
|
||||
.left-box .menu {
|
||||
width: 90% !important;
|
||||
}
|
||||
.left-box .menu .item {
|
||||
line-height: 1.2;
|
||||
position: relative;
|
||||
padding-left: 1em !important;
|
||||
}
|
||||
.left-box .menu .item .icon {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 0;
|
||||
margin-top: -0.4em !important;
|
||||
}
|
||||
.left-box .menu .item.separator {
|
||||
border-bottom: 1px #eee solid !important;
|
||||
padding-top: 0;
|
||||
padding-bottom: 0;
|
||||
margin-top: 0 !important;
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
.left-box .menu .header {
|
||||
border-bottom: 1px #ddd solid;
|
||||
padding-left: 0 !important;
|
||||
padding-bottom: 1em !important;
|
||||
}
|
||||
.left-box::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
}
|
||||
.right-box {
|
||||
position: fixed;
|
||||
top: 7.5em;
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
left: 18em;
|
||||
padding-right: 2em;
|
||||
padding-bottom: 1em;
|
||||
overflow-y: auto;
|
||||
}
|
||||
.right-box::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
}
|
||||
/** 通用 **/
|
||||
.clear {
|
||||
clear: both;
|
||||
@@ -235,6 +286,7 @@ body.expanded .main {
|
||||
.main h3 {
|
||||
font-weight: normal;
|
||||
margin-top: 1em !important;
|
||||
position: relative;
|
||||
}
|
||||
.main h3 span {
|
||||
font-size: 0.8em;
|
||||
@@ -247,12 +299,6 @@ body.expanded .main {
|
||||
font-size: 14px !important;
|
||||
right: 1em;
|
||||
}
|
||||
.main h3 a::before {
|
||||
content: "[";
|
||||
}
|
||||
.main h3 a::after {
|
||||
content: "]";
|
||||
}
|
||||
.main h4 {
|
||||
font-weight: normal;
|
||||
}
|
||||
@@ -601,4 +647,7 @@ var.dash {
|
||||
.swal2-cancel {
|
||||
margin-left: 2em !important;
|
||||
}
|
||||
form .fields {
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
/*# sourceMappingURL=@layout.css.map */
|
||||
File diff suppressed because one or more lines are too long
@@ -67,6 +67,14 @@ window.NotifySuccess = function (message, url, params) {
|
||||
};
|
||||
};
|
||||
|
||||
window.NotifyReloadSuccess = function (message) {
|
||||
return function () {
|
||||
teaweb.success(message, function () {
|
||||
window.location.reload()
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
window.NotifyDelete = function (message, url, params) {
|
||||
teaweb.confirm(message, function () {
|
||||
Tea.Vue.$post(url)
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
@import "./@left_menu";
|
||||
|
||||
/** 通用 **/
|
||||
.clear {
|
||||
clear: both;
|
||||
@@ -283,6 +285,7 @@ body.expanded .main {
|
||||
.main h3 {
|
||||
font-weight: normal;
|
||||
margin-top: 1em !important;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.main h3 span {
|
||||
@@ -299,14 +302,6 @@ body.expanded .main {
|
||||
right: 1em;
|
||||
}
|
||||
|
||||
.main h3 a::before {
|
||||
content: "[";
|
||||
}
|
||||
|
||||
.main h3 a::after {
|
||||
content: "]";
|
||||
}
|
||||
|
||||
.main h4 {
|
||||
font-weight: normal;
|
||||
}
|
||||
@@ -725,3 +720,10 @@ var.dash {
|
||||
.swal2-cancel {
|
||||
margin-left: 2em !important;
|
||||
}
|
||||
|
||||
// fields
|
||||
form {
|
||||
.fields {
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
}
|
||||
@@ -48,5 +48,16 @@
|
||||
}
|
||||
|
||||
.right-box {
|
||||
margin-left: 9em;
|
||||
position: fixed;
|
||||
top: 7.5em;
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
left: 18em;
|
||||
padding-right: 2em;
|
||||
padding-bottom: 1em;
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.right-box::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
}
|
||||
4
web/views/@default/api/@menu.html
Normal file
4
web/views/@default/api/@menu.html
Normal file
@@ -0,0 +1,4 @@
|
||||
<first-menu>
|
||||
<menu-item href="/api" code="index">节点列表</menu-item>
|
||||
<menu-item href="/api/node/create" code="create">创建节点</menu-item>
|
||||
</first-menu>
|
||||
26
web/views/@default/api/index.html
Normal file
26
web/views/@default/api/index.html
Normal file
@@ -0,0 +1,26 @@
|
||||
{$layout}
|
||||
{$template "menu"}
|
||||
|
||||
<p class="comment" v-if="nodes.length == 0">暂时还没有节点。</p>
|
||||
|
||||
|
||||
<table class="ui table selectable" v-if="nodes.length > 0">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>节点名称</th>
|
||||
<th>主机地址</th>
|
||||
<th>端口</th>
|
||||
<th class="two op">操作</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tr v-for="node in nodes">
|
||||
<td>{{node.name}}</td>
|
||||
<td>{{node.host}}</td>
|
||||
<td>{{node.port}}</td>
|
||||
<td>
|
||||
<a :href="'/api/node/settings?nodeId=' + node.id">设置</a>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<div class="page" v-html="page"></div>
|
||||
40
web/views/@default/api/node/create.html
Normal file
40
web/views/@default/api/node/create.html
Normal file
@@ -0,0 +1,40 @@
|
||||
{$layout}
|
||||
{$template "../menu"}
|
||||
<div class="margin"></div>
|
||||
<form class="ui form" data-tea-action="$" data-tea-success="success">
|
||||
<table class="ui table selectable definition">
|
||||
<tr>
|
||||
<td class="title">节点名称 *</td>
|
||||
<td>
|
||||
<input type="text" name="name" maxlength="100" ref="focus"/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>主机地址 *</td>
|
||||
<td>
|
||||
<input type="text" name="host" maxlength="100"/>
|
||||
<p class="comment">IP地址或者域名。</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>端口 *</td>
|
||||
<td>
|
||||
<input type="text" name="port" maxlength="5" style="width:6em"/>
|
||||
<p class="comment">1-65535之间。</p>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td colspan="2"><more-options-indicator></more-options-indicator></td>
|
||||
</tr>
|
||||
<tbody v-show="moreOptionsVisible">
|
||||
<tr>
|
||||
<td>描述</td>
|
||||
<td>
|
||||
<textarea name="description" maxlength="200" rows="3"></textarea>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<submit-btn></submit-btn>
|
||||
</form>
|
||||
3
web/views/@default/api/node/create.js
Normal file
3
web/views/@default/api/node/create.js
Normal file
@@ -0,0 +1,3 @@
|
||||
Tea.context(function () {
|
||||
this.success = NotifySuccess("保存成功", "/api")
|
||||
})
|
||||
43
web/views/@default/api/node/settings.html
Normal file
43
web/views/@default/api/node/settings.html
Normal file
@@ -0,0 +1,43 @@
|
||||
{$layout}
|
||||
{$template "/left_menu"}
|
||||
|
||||
<div class="right-box">
|
||||
<form class="ui form" data-tea-action="$" data-tea-success="success">
|
||||
<input type="hidden" name="nodeId" :value="node.id"/>
|
||||
<table class="ui table selectable definition">
|
||||
<tr>
|
||||
<td class="title">节点名称 *</td>
|
||||
<td>
|
||||
<input type="text" name="name" maxlength="100" ref="focus" v-model="node.name"/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>主机地址 *</td>
|
||||
<td>
|
||||
<input type="text" name="host" maxlength="100" v-model="node.host"/>
|
||||
<p class="comment">IP地址或者域名。</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>端口 *</td>
|
||||
<td>
|
||||
<input type="text" name="port" maxlength="5" style="width:6em" v-model="node.port"/>
|
||||
<p class="comment">1-65535之间。</p>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td colspan="2"><more-options-indicator></more-options-indicator></td>
|
||||
</tr>
|
||||
<tbody v-show="moreOptionsVisible">
|
||||
<tr>
|
||||
<td>描述</td>
|
||||
<td>
|
||||
<textarea name="description" maxlength="200" rows="3" v-model="node.description"></textarea>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<submit-btn></submit-btn>
|
||||
</form>
|
||||
</div>
|
||||
3
web/views/@default/api/node/settings.js
Normal file
3
web/views/@default/api/node/settings.js
Normal file
@@ -0,0 +1,3 @@
|
||||
Tea.context(function () {
|
||||
this.success = NotifySuccess("保存成功", "/api/node/settings?nodeId=" + this.node.id)
|
||||
})
|
||||
4
web/views/@default/clusters/@menu.html
Normal file
4
web/views/@default/clusters/@menu.html
Normal file
@@ -0,0 +1,4 @@
|
||||
<first-menu>
|
||||
<menu-item href="/clusters" code="index">集群列表</menu-item>
|
||||
<menu-item href="/clusters/create" code="create">创建集群</menu-item>
|
||||
</first-menu>
|
||||
4
web/views/@default/clusters/cluster/index.css
Normal file
4
web/views/@default/clusters/cluster/index.css
Normal file
@@ -0,0 +1,4 @@
|
||||
.table .label {
|
||||
margin-bottom: 0.5em;
|
||||
}
|
||||
/*# sourceMappingURL=index.css.map */
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"sources":["index.less"],"names":[],"mappings":"AAAA,YACC;EACC,cAAA;EACA,oBAAA","file":"index.css"}
|
||||
{"version":3,"sources":["index.less"],"names":[],"mappings":"AAAA,MAAO;EACN,oBAAA","file":"index.css"}
|
||||
87
web/views/@default/clusters/cluster/index.html
Normal file
87
web/views/@default/clusters/cluster/index.html
Normal file
@@ -0,0 +1,87 @@
|
||||
{$layout}
|
||||
{$template "/left_menu"}
|
||||
|
||||
<div class="right-box">
|
||||
<second-menu>
|
||||
<menu-item :href="'/clusters/cluster/node/create?clusterId=' + clusterId">添加节点</menu-item>
|
||||
<menu-item>安装节点</menu-item>
|
||||
</second-menu>
|
||||
|
||||
<h3>节点列表</h3>
|
||||
|
||||
<p class="comment" v-if="nodes.length == 0">暂时还没有节点。</p>
|
||||
|
||||
<div v-show="nodes.length > 0">
|
||||
<form class="ui form segment" action="/clusters/cluster">
|
||||
<input type="hidden" name="clusterId" :value="clusterId"/>
|
||||
<div class="ui fields inline">
|
||||
<div class="ui field">
|
||||
安装状态:
|
||||
</div>
|
||||
<div class="ui field">
|
||||
<select class="ui dropdown" name="installedState">
|
||||
<option value="0">[全部]</option>
|
||||
<option value="1">已安装</option>
|
||||
<option value="2">未安装</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="ui field">
|
||||
<button class="ui button" type="submit">搜索</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
<table class="ui table selectable" v-if="nodes.length > 0">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>ID</th>
|
||||
<th>节点名称</th>
|
||||
<th>主机名</th>
|
||||
<th>IP</th>
|
||||
<th>CPU</th>
|
||||
<th>内存</th>
|
||||
<!--<th>流量</th>
|
||||
<th>连接数</th>-->
|
||||
<th>状态</th>
|
||||
<th class="two op">操作</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tr v-for="node in nodes">
|
||||
<td>{{node.id}}</td>
|
||||
<td>{{node.name}}</td>
|
||||
<td>
|
||||
<span v-if="node.status.hostname != null && node.status.hostname.length > 0">{{node.status.hostname}}</span>
|
||||
<span v-else>-</span>
|
||||
</td>
|
||||
<td>
|
||||
<span v-if="node.ipAddresses.length == 0">-</span>
|
||||
<div v-else class="address-box">
|
||||
<div v-for="addr in node.ipAddresses" class="ui label small">{{addr.ip}} <span class="small">({{addr.name}})</span></div>
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
<span v-if="node.status.isActive" :class="{red:node.status.cpuUsage > 0.80}">{{node.status.cpuUsageText}}</span>
|
||||
<span v-else>-</span>
|
||||
</td>
|
||||
<td>
|
||||
<span v-if="node.status.isActive" :class="{red:node.status.memUsage > 0.80}">{{node.status.memUsageText}}</span>
|
||||
<span v-else>-</span>
|
||||
</td>
|
||||
<td>
|
||||
<div v-if="node.isInstalled">
|
||||
<span v-if="node.status.isActive"><span class="green">运行中</span></span>
|
||||
<span v-else-if="node.status.updatedAt > 0" class="red">已断开</span>
|
||||
<span v-else-if="node.status.updatedAt == 0" class="red">未连接</span>
|
||||
</div>
|
||||
<span v-else class="red">未安装</span>
|
||||
</td>
|
||||
<td>
|
||||
<a :href="'/clusters/cluster/node?clusterId=' + clusterId + '&nodeId=' + node.id">详情</a> <a href="" @click.prevent="deleteNode(node.id)">删除</a>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
|
||||
<div class="page" v-html="page"></div>
|
||||
</div>
|
||||
@@ -1,7 +1,7 @@
|
||||
Tea.context(function () {
|
||||
this.deleteNode = function (nodeId) {
|
||||
teaweb.confirm("确定要删除这个节点吗?", function () {
|
||||
this.$post(".delete")
|
||||
this.$post("/nodes/delete")
|
||||
.params({
|
||||
nodeId: nodeId
|
||||
})
|
||||
3
web/views/@default/clusters/cluster/index.less
Normal file
3
web/views/@default/clusters/cluster/index.less
Normal file
@@ -0,0 +1,3 @@
|
||||
.table .label {
|
||||
margin-bottom: 0.5em;
|
||||
}
|
||||
5
web/views/@default/clusters/cluster/node/@node_menu.html
Normal file
5
web/views/@default/clusters/cluster/node/@node_menu.html
Normal file
@@ -0,0 +1,5 @@
|
||||
<second-menu>
|
||||
<menu-item :href="'/clusters/cluster/node?clusterId=' + clusterId + '&nodeId=' + nodeId" code="node">节点详情</menu-item>
|
||||
<menu-item :href="'/clusters/cluster/node/update?clusterId=' + clusterId + '&nodeId=' + nodeId" code="update">修改节点</menu-item>
|
||||
<menu-item :href="'/clusters/cluster/node/install?clusterId=' + clusterId + '&nodeId=' + nodeId" code="install">安装节点</menu-item>
|
||||
</second-menu>
|
||||
45
web/views/@default/clusters/cluster/node/create.html
Normal file
45
web/views/@default/clusters/cluster/node/create.html
Normal file
@@ -0,0 +1,45 @@
|
||||
{$layout}
|
||||
{$template "/left_menu"}
|
||||
|
||||
<div class="right-box">
|
||||
<h3>添加节点</h3>
|
||||
|
||||
<form class="ui form" data-tea-action="$" data-tea-success="success">
|
||||
<input type="hidden" name="clusterId" :value="clusterId"/>
|
||||
<table class="ui table definition selectable">
|
||||
<tr>
|
||||
<td class="title">节点名称 *</td>
|
||||
<td>
|
||||
<input type="text" name="name" maxlength="50" ref="focus"/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>IP地址</td>
|
||||
<td>
|
||||
<node-ip-addresses-box></node-ip-addresses-box>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH主机地址</td>
|
||||
<td>
|
||||
<input type="text" name="sshHost" maxlength="64"/>
|
||||
<p class="comment">比如192.168.1.100</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH主机端口</td>
|
||||
<td>
|
||||
<input type="text" name="sshPort" maxlength="5"/>
|
||||
<p class="comment">常见的比如22。</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH登录认证</td>
|
||||
<td>
|
||||
<grant-selector></grant-selector>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<submit-btn></submit-btn>
|
||||
</form>
|
||||
</div>
|
||||
3
web/views/@default/clusters/cluster/node/create.js
Normal file
3
web/views/@default/clusters/cluster/node/create.js
Normal file
@@ -0,0 +1,3 @@
|
||||
Tea.context(function () {
|
||||
this.success = NotifySuccess("保存成功", "/clusters/cluster?clusterId=" + this.clusterId);
|
||||
});
|
||||
37
web/views/@default/clusters/cluster/node/install.html
Normal file
37
web/views/@default/clusters/cluster/node/install.html
Normal file
@@ -0,0 +1,37 @@
|
||||
{$layout}
|
||||
{$template "/left_menu"}
|
||||
|
||||
<div class="right-box">
|
||||
{$template "node_menu"}
|
||||
|
||||
<!-- 已安装 -->
|
||||
<div v-if="node.isInstalled">
|
||||
<div class="ui message green">当前节点为已安装状态。</div>
|
||||
<a href="" @click.prevent="updateNodeIsInstalled(false)">[修改为未安装状态]</a>
|
||||
</div>
|
||||
|
||||
<!-- 未安装 -->
|
||||
<div v-if="!node.isInstalled">
|
||||
<h3>方法1:自动安装</h3>
|
||||
|
||||
<h3>方法2:手动安装</h3>
|
||||
<table class="ui table definition selectable">
|
||||
<tr>
|
||||
<td>配置文件<em>(configs/api.yaml)</em></td>
|
||||
<td>
|
||||
<pre>rpc:
|
||||
endpoints: [ "${endpoint}" ]
|
||||
nodeId: "{{node.uniqueId}}"
|
||||
secret: "{{node.secret}}"</pre>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="title">安装目录</td>
|
||||
<td>
|
||||
<div v-if="node.installDir.length == 0">使用集群设置<span v-if="node.cluster != null && node.cluster.installDir.length > 0">({{node.cluster.installDir}})</span></div>
|
||||
<span v-else>{{node.installDir}}</span>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
12
web/views/@default/clusters/cluster/node/install.js
Normal file
12
web/views/@default/clusters/cluster/node/install.js
Normal file
@@ -0,0 +1,12 @@
|
||||
Tea.context(function () {
|
||||
this.updateNodeIsInstalled = function (isInstalled) {
|
||||
teaweb.confirm("确定要将当前节点修改为未安装状态?", function () {
|
||||
this.$post("/clusters/cluster/node/updateInstallStatus")
|
||||
.params({
|
||||
nodeId: this.nodeId,
|
||||
isInstalled: isInstalled ? 1 : 0
|
||||
})
|
||||
.refresh()
|
||||
})
|
||||
}
|
||||
})
|
||||
4
web/views/@default/clusters/cluster/node/node.css
Normal file
4
web/views/@default/clusters/cluster/node/node.css
Normal file
@@ -0,0 +1,4 @@
|
||||
a.underline {
|
||||
border-bottom: 1px #db2828 dashed;
|
||||
}
|
||||
/*# sourceMappingURL=node.css.map */
|
||||
1
web/views/@default/clusters/cluster/node/node.css.map
Normal file
1
web/views/@default/clusters/cluster/node/node.css.map
Normal file
@@ -0,0 +1 @@
|
||||
{"version":3,"sources":["node.less"],"names":[],"mappings":"AAAA,CAAC;EACA,iCAAA","file":"node.css"}
|
||||
90
web/views/@default/clusters/cluster/node/node.html
Normal file
90
web/views/@default/clusters/cluster/node/node.html
Normal file
@@ -0,0 +1,90 @@
|
||||
{$layout}
|
||||
{$template "/left_menu"}
|
||||
|
||||
<div class="right-box">
|
||||
{$template "node_menu"}
|
||||
|
||||
<h3>节点详情</h3>
|
||||
<table class="ui table definition selectable">
|
||||
<tr>
|
||||
<td class="title">节点名称</td>
|
||||
<td>{{node.name}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>IP地址</td>
|
||||
<td>
|
||||
<div v-if="node.ipAddresses.length > 0">
|
||||
<div>
|
||||
<div v-for="(address, index) in node.ipAddresses" class="ui label small">
|
||||
{{address.ip}}<span class="small">({{address.name}})</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div v-else>
|
||||
<span class="disabled">暂时还没有填写IP地址。</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH主机地址</td>
|
||||
<td>
|
||||
<div v-if="node.login != null && node.login.params != null && node.login.params.host != null">
|
||||
<span v-if="node.login.params.host.length > 0">{{node.login.params.host}}</span>
|
||||
<span v-else class="disabled">尚未设置</span>
|
||||
</div>
|
||||
<div v-else class="disabled">
|
||||
尚未设置
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH主机端口</td>
|
||||
<td>
|
||||
<div v-if="node.login != null && node.login.params != null && node.login.params.host != null">
|
||||
<span v-if="node.login.params.port > 0">{{node.login.params.port}}</span>
|
||||
<span v-else class="disabled">尚未设置</span>
|
||||
</div>
|
||||
<span v-else class="disabled">
|
||||
尚未设置
|
||||
</span>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH登录认证</td>
|
||||
<td>
|
||||
<div v-if="node.login != null && node.login.grant != null && node.login.grant.id > 0">
|
||||
{{node.login.grant.name}}<span class="small">({{node.login.grant.methodName}})</span>
|
||||
</div>
|
||||
<span v-else class="disabled">
|
||||
尚未设置
|
||||
</span>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<h3>安装信息</h3>
|
||||
<table class="ui table definition selectable">
|
||||
<tr>
|
||||
<td>节点ID<em>(id)</em></td>
|
||||
<td>{{node.uniqueId}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>密钥<em>(secret)</em></td>
|
||||
<td>{{node.secret}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="title">安装目录</td>
|
||||
<td>
|
||||
<div v-if="node.installDir.length == 0">使用集群设置<span v-if="node.cluster != null && node.cluster.installDir.length > 0">({{node.cluster.installDir}})</span></div>
|
||||
<span v-else>{{node.installDir}}</span>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>是否已安装</td>
|
||||
<td>
|
||||
<span v-if="node.isInstalled" class="green">已安装</span>
|
||||
<a v-else :href="'/clusters/cluster/installNode?clusterId=' + clusterId + '&nodeId=' + nodeId" class="underline" title="点击进入安装界面"><span class="red">未安装</span></a>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
3
web/views/@default/clusters/cluster/node/node.less
Normal file
3
web/views/@default/clusters/cluster/node/node.less
Normal file
@@ -0,0 +1,3 @@
|
||||
a.underline {
|
||||
border-bottom: 1px #db2828 dashed;
|
||||
}
|
||||
55
web/views/@default/clusters/cluster/node/update.html
Normal file
55
web/views/@default/clusters/cluster/node/update.html
Normal file
@@ -0,0 +1,55 @@
|
||||
{$layout}
|
||||
{$template "/left_menu"}
|
||||
|
||||
<div class="right-box">
|
||||
{$template "node_menu"}
|
||||
|
||||
<h3>修改节点</h3>
|
||||
<form class="ui form" data-tea-action="$" data-tea-success="success">
|
||||
<input type="hidden" name="nodeId" :value="node.id"/>
|
||||
<input type="hidden" name="loginId" :value="loginId"/>
|
||||
<table class="ui table definition selectable">
|
||||
<tr>
|
||||
<td class="title">节点名称 *</td>
|
||||
<td>
|
||||
<input type="text" name="name" maxlength="50" ref="focus" v-model="node.name"/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>IP地址</td>
|
||||
<td>
|
||||
<node-ip-addresses-box :v-ip-addresses="ipAddresses"></node-ip-addresses-box>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>所属集群</td>
|
||||
<td>
|
||||
<select class="ui dropdown" name="clusterId" style="width:10em" v-model="clusterId">
|
||||
<option v-for="cluster in clusters" :value="cluster.id">{{cluster.name}}</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH主机地址</td>
|
||||
<td>
|
||||
<input type="text" name="sshHost" maxlength="64" v-model="sshHost"/>
|
||||
<p class="comment">比如192.168.1.100</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH主机端口</td>
|
||||
<td>
|
||||
<input type="text" name="sshPort" maxlength="5" v-model="sshPort"/>
|
||||
<p class="comment">比如22。</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH登录认证</td>
|
||||
<td>
|
||||
<grant-selector :v-grant="grant"></grant-selector>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<submit-btn></submit-btn>
|
||||
</form>
|
||||
</div>
|
||||
@@ -4,7 +4,7 @@ Tea.context(function () {
|
||||
this.clusterId = this.node.cluster.id;
|
||||
}
|
||||
|
||||
this.success = NotifySuccess("保存成功", "/nodes/node?nodeId=" + this.node.id);
|
||||
this.success = NotifySuccess("保存成功", "/clusters/cluster/node?clusterId=" + this.clusterId + "&nodeId=" + this.node.id);
|
||||
|
||||
// IP地址相关
|
||||
this.ipAddresses = this.node.ipAddresses;
|
||||
@@ -33,7 +33,6 @@ Tea.context(function () {
|
||||
};
|
||||
|
||||
// 认证相关
|
||||
this.grantId = 0;
|
||||
this.grant = null;
|
||||
|
||||
this.sshHost = "";
|
||||
@@ -44,11 +43,12 @@ Tea.context(function () {
|
||||
|
||||
if (this.node.login.params != null) {
|
||||
this.sshHost = this.node.login.params.host;
|
||||
this.sshPort = this.node.login.params.port;
|
||||
if (this.node.login.params.port > 0) {
|
||||
this.sshPort = this.node.login.params.port;
|
||||
}
|
||||
}
|
||||
|
||||
if (this.node.login.grant != null) {
|
||||
this.grantId = this.node.login.grant.id;
|
||||
if (this.node.login.grant != null && typeof this.node.login.grant.id != "undefined") {
|
||||
this.grant = {
|
||||
id: this.node.login.grant.id,
|
||||
name: this.node.login.grant.name,
|
||||
@@ -57,48 +57,4 @@ Tea.context(function () {
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
this.selectGrant = function () {
|
||||
var that = this;
|
||||
teaweb.popup("/nodes/grants/selectPopup", {
|
||||
callback: function (resp) {
|
||||
that.grantId = resp.data.grant.id;
|
||||
if (that.grantId > 0) {
|
||||
that.grant = resp.data.grant;
|
||||
}
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
// 修改授权
|
||||
this.updateGrant = function () {
|
||||
if (this.grant == null) {
|
||||
window.location.reload();
|
||||
return;
|
||||
}
|
||||
teaweb.popup("/nodes/grants/updatePopup?grantId=" + this.grant.id, {
|
||||
height: "31em",
|
||||
callback: function (resp) {
|
||||
this.grant = resp.data.grant;
|
||||
}
|
||||
})
|
||||
};
|
||||
|
||||
this.createGrant = function () {
|
||||
var that = this;
|
||||
teaweb.popup("/nodes/grants/createPopup", {
|
||||
height: "31em",
|
||||
callback: function (resp) {
|
||||
that.grantId = resp.data.grant.id;
|
||||
if (that.grantId > 0) {
|
||||
that.grant = resp.data.grant;
|
||||
}
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
this.removeGrant = function () {
|
||||
this.grant = null;
|
||||
this.grantId = 0;
|
||||
};
|
||||
});
|
||||
30
web/views/@default/clusters/cluster/settings/index.html
Normal file
30
web/views/@default/clusters/cluster/settings/index.html
Normal file
@@ -0,0 +1,30 @@
|
||||
{$layout}
|
||||
{$template "/left_menu"}
|
||||
|
||||
<div class="right-box">
|
||||
<h3>基础设置</h3>
|
||||
<form class="ui form" data-tea-action="$" data-tea-success="success">
|
||||
<input type="hidden" name="clusterId" :value="cluster.id"/>
|
||||
<table class="ui table selectable definition">
|
||||
<tr>
|
||||
<td class="title">集群名称 *</td>
|
||||
<td><input type="text" name="name" maxlength="50" ref="focus" v-model="cluster.name"/></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>默认SSH登录方式</td>
|
||||
<td>
|
||||
<grant-selector :v-grant="grant"></grant-selector>
|
||||
<p class="comment">当节点没有单独设置SSH登录方式时,默认使用此设置。</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>默认安装目录</td>
|
||||
<td>
|
||||
<input type="text" name="installDir" maxlength="100" v-model="cluster.installDir"/>
|
||||
<p class="comment">当节点没有单独设置安装目录时,默认使用此设置。如果集群和节点都没有设置安装目录,则使用<span class="ui label tiny">/$登录用户/edge-node</span> 目录。</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<submit-btn></submit-btn>
|
||||
</form>
|
||||
</div>
|
||||
3
web/views/@default/clusters/cluster/settings/index.js
Normal file
3
web/views/@default/clusters/cluster/settings/index.js
Normal file
@@ -0,0 +1,3 @@
|
||||
Tea.context(function () {
|
||||
this.success = NotifyReloadSuccess("保存成功")
|
||||
})
|
||||
28
web/views/@default/clusters/create.html
Normal file
28
web/views/@default/clusters/create.html
Normal file
@@ -0,0 +1,28 @@
|
||||
{$layout}
|
||||
{$template "menu"}
|
||||
|
||||
<div class="margin"></div>
|
||||
|
||||
<form class="ui form" data-tea-action="$" data-tea-success="success">
|
||||
<table class="ui table selectable definition">
|
||||
<tr>
|
||||
<td class="title">集群名称 *</td>
|
||||
<td><input type="text" name="name" maxlength="50" ref="focus"/></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>默认SSH登录方式</td>
|
||||
<td>
|
||||
<grant-selector></grant-selector>
|
||||
<p class="comment">当节点没有单独设置SSH登录方式时,默认使用此设置。</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>默认安装目录</td>
|
||||
<td>
|
||||
<input type="text" name="installDir" maxlength="100"/>
|
||||
<p class="comment">当节点没有单独设置安装目录时,默认使用此设置。如果集群和节点都没有设置安装目录,则使用<span class="ui label tiny">/$登录用户/edge-node</span> 目录。</p>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<submit-btn></submit-btn>
|
||||
</form>
|
||||
3
web/views/@default/clusters/create.js
Normal file
3
web/views/@default/clusters/create.js
Normal file
@@ -0,0 +1,3 @@
|
||||
Tea.context(function () {
|
||||
this.success = NotifySuccess("保存成功", "/clusters")
|
||||
})
|
||||
28
web/views/@default/clusters/index.html
Normal file
28
web/views/@default/clusters/index.html
Normal file
@@ -0,0 +1,28 @@
|
||||
{$layout}
|
||||
{$template "menu"}
|
||||
|
||||
<p class="comment" v-if="clusters.length == 0">暂时还没有集群。</p>
|
||||
|
||||
<table class="ui table selectable" v-if="clusters.length > 0">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>集群名称</th>
|
||||
<th>节点数量</th>
|
||||
<th>默认认证</th>
|
||||
<th class="two op">操作</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tr v-for="cluster in clusters">
|
||||
<td>{{cluster.name}}</td>
|
||||
<td>{{cluster.countNodes}}</td>
|
||||
<td>
|
||||
<span v-if="cluster.hasGrant" class="green">Y</span>
|
||||
<span v-else class="disabled">N</span>
|
||||
</td>
|
||||
<td>
|
||||
<a :href="'/clusters/cluster?clusterId=' + cluster.id">详情</a>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<page-box></page-box>
|
||||
@@ -1,4 +0,0 @@
|
||||
<first-menu>
|
||||
<menu-item href="/nodes" code="index">节点列表</menu-item>
|
||||
<menu-item href="/nodes/create" code="create">创建节点</menu-item>
|
||||
</first-menu>
|
||||
@@ -1,66 +0,0 @@
|
||||
{$layout}
|
||||
{$template "menu"}
|
||||
<div class="margin"></div>
|
||||
<form class="ui form" data-tea-action="$" data-tea-success="success">
|
||||
<input type="hidden" name="grantId" :value="grantId"/>
|
||||
<table class="ui table definition selectable">
|
||||
<tr>
|
||||
<td class="title">节点名称 *</td>
|
||||
<td>
|
||||
<input type="text" name="name" maxlength="50" ref="focus"/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>IP地址</td>
|
||||
<td>
|
||||
<input type="hidden" name="ipAddresses" :value="JSON.stringify(ipAddresses)"/>
|
||||
<div v-if="ipAddresses.length > 0">
|
||||
<div>
|
||||
<div v-for="(address, index) in ipAddresses" class="ui label small">
|
||||
{{address.ip}}<span class="small">({{address.name}})</span>
|
||||
<a href="" title="修改" @click.prevent="updateIPAddress(index, address)"><i class="icon pencil small"></i></a>
|
||||
<a href="" title="删除" @click.prevent="removeIPAddress(index)"><i class="icon remove"></i></a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="ui divider"></div>
|
||||
</div>
|
||||
<div>
|
||||
<button class="ui button small" type="button" @click.prevent="addIPAddress()">+</button>
|
||||
</div>
|
||||
<p class="comment">添加已经绑定的IP地址,仅做记录用。</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>所属集群</td>
|
||||
<td>
|
||||
<select class="ui dropdown" name="clusterId" style="width:10em">
|
||||
<option v-for="cluster in clusters" :value="cluster.id">{{cluster.name}}</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH主机地址</td>
|
||||
<td>
|
||||
<input type="text" name="sshHost" maxlength="64"/>
|
||||
<p class="comment">比如192.168.1.100</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH主机端口</td>
|
||||
<td>
|
||||
<input type="text" name="sshPort" maxlength="5"/>
|
||||
<p class="comment">常见的比如22。</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH登录认证</td>
|
||||
<td>
|
||||
<div class="ui label small" v-if="grant != null">{{grant.name}}<span class="small">({{grant.methodName}})</span> <a href="" title="修改" @click.prevent="updateGrant()"><i class="icon pencil small"></i></a> <a href="" title="删除" @click.prevent="removeGrant()"><i class="icon remove"></i></a> </div>
|
||||
<div v-if="grant == null">
|
||||
<a href="" @click.prevent="selectGrant()">[选择已有认证]</a> <a href="" @click.prevent="createGrant()">[添加新认证]</a>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<submit-btn></submit-btn>
|
||||
</form>
|
||||
@@ -1,79 +0,0 @@
|
||||
Tea.context(function () {
|
||||
this.success = NotifySuccess("保存成功", "/nodes");
|
||||
|
||||
// IP地址相关
|
||||
this.ipAddresses = [];
|
||||
|
||||
// 添加IP地址
|
||||
this.addIPAddress = function () {
|
||||
teaweb.popup("/nodes/ipAddresses/createPopup", {
|
||||
callback: function (resp) {
|
||||
this.ipAddresses.push(resp.data.ipAddress);
|
||||
}
|
||||
})
|
||||
};
|
||||
|
||||
// 修改地址
|
||||
this.updateIPAddress = function (index, address) {
|
||||
teaweb.popup("/nodes/ipAddresses/updatePopup?addressId=" + address.id, {
|
||||
callback: function (resp) {
|
||||
Vue.set(this.ipAddresses, index, resp.data.ipAddress);
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
// 删除IP地址
|
||||
this.removeIPAddress = function (index) {
|
||||
this.ipAddresses.$remove(index);
|
||||
};
|
||||
|
||||
// 授权相关
|
||||
this.grantId = 0;
|
||||
this.grant = null;
|
||||
|
||||
// 选择授权
|
||||
this.selectGrant = function () {
|
||||
var that = this;
|
||||
teaweb.popup("/nodes/grants/selectPopup", {
|
||||
callback: function (resp) {
|
||||
that.grantId = resp.data.grant.id;
|
||||
if (that.grantId > 0) {
|
||||
that.grant = resp.data.grant;
|
||||
}
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
// 创建授权
|
||||
this.createGrant = function () {
|
||||
teaweb.popup("/nodes/grants/createPopup", {
|
||||
height: "31em",
|
||||
callback: function (resp) {
|
||||
this.grantId = resp.data.grant.id;
|
||||
if (this.grantId > 0) {
|
||||
this.grant = resp.data.grant;
|
||||
}
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
// 修改授权
|
||||
this.updateGrant = function () {
|
||||
if (this.grant == null) {
|
||||
window.location.reload();
|
||||
return;
|
||||
}
|
||||
teaweb.popup("/nodes/grants/updatePopup?grantId=" + this.grant.id, {
|
||||
height: "31em",
|
||||
callback: function (resp) {
|
||||
this.grant = resp.data.grant;
|
||||
}
|
||||
})
|
||||
};
|
||||
|
||||
// 删除已选择授权
|
||||
this.removeGrant = function () {
|
||||
this.grant = null;
|
||||
this.grantId = 0;
|
||||
};
|
||||
});
|
||||
@@ -6,7 +6,7 @@
|
||||
<tr>
|
||||
<td>名称 *</td>
|
||||
<td>
|
||||
<input type="text" name="name" maxlength="100" ref="focus" value="认证"/>
|
||||
<input type="text" name="name" maxlength="100" ref="focus" value=""/>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
|
||||
@@ -1,5 +0,0 @@
|
||||
.address-box .label {
|
||||
display: block;
|
||||
margin-bottom: 0.6em;
|
||||
}
|
||||
/*# sourceMappingURL=index.css.map */
|
||||
@@ -1,56 +0,0 @@
|
||||
{$layout}
|
||||
{$template "menu"}
|
||||
|
||||
<p class="comment" v-if="nodes.length == 0">暂时还没有节点。</p>
|
||||
|
||||
<table class="ui table selectable" v-if="nodes.length > 0">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>ID</th>
|
||||
<th>节点名称</th>
|
||||
<th>主机名</th>
|
||||
<th>IP</th>
|
||||
<th>所属集群</th>
|
||||
<th>状态</th>
|
||||
<th>CPU</th>
|
||||
<th>内存</th>
|
||||
<!--<th>流量</th>
|
||||
<th>连接数</th>-->
|
||||
<th class="two op">操作</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tr v-for="node in nodes">
|
||||
<td>{{node.id}}</td>
|
||||
<td>{{node.name}}</td>
|
||||
<td>
|
||||
<span v-if="node.status.hostname != null && node.status.hostname.length > 0">{{node.status.hostname}}</span>
|
||||
<span v-else>-</span>
|
||||
</td>
|
||||
<td>
|
||||
<span v-if="node.ipAddresses.length == 0">-</span>
|
||||
<div v-else class="address-box">
|
||||
<div v-for="addr in node.ipAddresses" class="ui label small">{{addr.ip}} <span class="small">({{addr.name}})</span></div>
|
||||
</div>
|
||||
</td>
|
||||
<td>{{node.cluster.name}}</td>
|
||||
<td>
|
||||
<span v-if="node.status.isActive"><span class="green">运行中</span></span>
|
||||
<span v-else-if="node.status.updatedAt > 0" class="red">已断开</span>
|
||||
<span v-else-if="node.status.updatedAt == 0" class="red">未连接</span>
|
||||
</td>
|
||||
<td>
|
||||
<span v-if="node.status.isActive" :class="{red:node.status.cpuUsage > 0.80}">{{node.status.cpuUsageText}}</span>
|
||||
<span v-else>-</span>
|
||||
</td>
|
||||
<td>
|
||||
<span v-if="node.status.isActive" :class="{red:node.status.memUsage > 0.80}">{{node.status.memUsageText}}</span>
|
||||
<span v-else>-</span>
|
||||
</td>
|
||||
<td>
|
||||
<a :href="'/nodes/node?nodeId=' + node.id">详情</a> <a href="" @click.prevent="deleteNode(node.id)">删除</a>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
|
||||
<div class="page" v-html="page"></div>
|
||||
@@ -1,6 +0,0 @@
|
||||
.address-box {
|
||||
.label {
|
||||
display: block;
|
||||
margin-bottom: 0.6em;
|
||||
}
|
||||
}
|
||||
@@ -11,7 +11,7 @@
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="title">简介</td>
|
||||
<td class="title">备注</td>
|
||||
<td>
|
||||
<input type="text" name="name" maxlength="50"/>
|
||||
</td>
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="title">简介</td>
|
||||
<td class="title">备注</td>
|
||||
<td>
|
||||
<input type="text" name="name" maxlength="50" v-model="address.name"/>
|
||||
</td>
|
||||
|
||||
@@ -1,72 +0,0 @@
|
||||
{$layout}
|
||||
|
||||
<second-menu>
|
||||
<menu-item :href="'/nodes/node?nodeId=' + nodeId" active="true">详情</menu-item>
|
||||
<menu-item :href="'/nodes/update?nodeId=' + nodeId">修改</menu-item>
|
||||
</second-menu>
|
||||
|
||||
<table class="ui table definition selectable">
|
||||
<tr>
|
||||
<td class="title">节点名称</td>
|
||||
<td>{{node.name}}</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>IP地址</td>
|
||||
<td>
|
||||
<div v-if="node.ipAddresses.length > 0">
|
||||
<div>
|
||||
<div v-for="(address, index) in node.ipAddresses" class="ui label small">
|
||||
{{address.ip}}<span class="small">({{address.name}})</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div v-else>
|
||||
<span class="disabled">暂时还没有填写IP地址。</span>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>所属集群</td>
|
||||
<td>
|
||||
<span v-if="node.cluster == null">还没有设置集群。</span>
|
||||
<div v-if="node.cluster != null">
|
||||
{{node.cluster.name}}
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH主机地址</td>
|
||||
<td>
|
||||
<div v-if="node.login != null && node.login.params != null && node.login.params.host != null">
|
||||
<span v-if="node.login.params.host.length > 0">{{node.login.params.host}}</span>
|
||||
<span v-if="node.login.params.host.length == 0">尚未设置</span>
|
||||
</div>
|
||||
<div v-if="!(node.login != null && node.login.params != null && node.login.params.host != null)">
|
||||
尚未设置
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH主机端口</td>
|
||||
<td>
|
||||
<div v-if="node.login != null && node.login.params != null && node.login.params.host != null">
|
||||
<span v-if="node.login.params.port > 0">{{node.login.params.port}}</span>
|
||||
<span v-if="node.login.params.port <= 0">尚未设置</span>
|
||||
</div>
|
||||
<div v-if="!(node.login != null && node.login.params != null && node.login.params.port != null)">
|
||||
尚未设置
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH登录认证</td>
|
||||
<td>
|
||||
<div v-if="node.login != null && node.login.grant != null && node.login.grant.id > 0">
|
||||
{{node.login.grant.name}}<span class="small">({{node.login.grant.methodName}})</span>
|
||||
</div>
|
||||
<div v-if="!(node.login != null && node.login.grant != null && node.login.grant.id > 0)">
|
||||
尚未设置
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
@@ -1,74 +0,0 @@
|
||||
{$layout}
|
||||
{$template "menu"}
|
||||
|
||||
<second-menu>
|
||||
<menu-item :href="'/nodes/node?nodeId=' + nodeId">详情</menu-item>
|
||||
<menu-item :href="'/nodes/update?nodeId=' + nodeId" active="true">修改</menu-item>
|
||||
</second-menu>
|
||||
|
||||
<div class="margin"></div>
|
||||
<form class="ui form" data-tea-action="$" data-tea-success="success">
|
||||
<input type="hidden" name="nodeId" :value="node.id"/>
|
||||
<input type="hidden" name="loginId" :value="loginId"/>
|
||||
<input type="hidden" name="grantId" :value="grantId"/>
|
||||
<table class="ui table definition selectable">
|
||||
<tr>
|
||||
<td class="title">节点名称 *</td>
|
||||
<td>
|
||||
<input type="text" name="name" maxlength="50" ref="focus" v-model="node.name"/>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>IP地址</td>
|
||||
<td>
|
||||
<input type="hidden" name="ipAddresses" :value="JSON.stringify(ipAddresses)"/>
|
||||
<div v-if="ipAddresses.length > 0">
|
||||
<div>
|
||||
<div v-for="(address, index) in ipAddresses" class="ui label small">
|
||||
{{address.ip}}<span class="small">({{address.name}})</span>
|
||||
<a href="" title="修改" @click.prevent="updateIPAddress(index, address)"><i class="icon pencil small"></i></a>
|
||||
<a href="" title="删除" @click.prevent="removeIPAddress(index)"><i class="icon remove"></i></a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="ui divider"></div>
|
||||
</div>
|
||||
<div>
|
||||
<button class="ui button small" type="button" @click.prevent="addIPAddress()">+</button>
|
||||
</div>
|
||||
<p class="comment">添加已经绑定的IP地址,仅做记录用。</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>所属集群</td>
|
||||
<td>
|
||||
<select class="ui dropdown" name="clusterId" style="width:10em" v-model="clusterId">
|
||||
<option v-for="cluster in clusters" :value="cluster.id">{{cluster.name}}</option>
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH主机地址</td>
|
||||
<td>
|
||||
<input type="text" name="sshHost" maxlength="64" v-model="sshHost"/>
|
||||
<p class="comment">比如192.168.1.100</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH主机端口</td>
|
||||
<td>
|
||||
<input type="text" name="sshPort" maxlength="5" v-model="sshPort"/>
|
||||
<p class="comment">比如22。</p>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>SSH登录认证</td>
|
||||
<td>
|
||||
<div class="ui label small" v-if="grant != null && grant.id != null">{{grant.name}}<span class="small">({{grant.methodName}})</span> <a href="" title="修改" @click.prevent="updateGrant()"><i class="icon pencil small"></i></a> <a href="" title="删除" @click.prevent="removeGrant()"><i class="icon remove"></i></a> </div>
|
||||
<div v-else>
|
||||
<a href="" @click.prevent="selectGrant()">[选择已有认证]</a> <a href="" @click.prevent="createGrant()">[添加新认证]</a>
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
<submit-btn></submit-btn>
|
||||
</form>
|
||||
@@ -1,45 +0,0 @@
|
||||
.left-box {
|
||||
width: 8em;
|
||||
position: fixed;
|
||||
top: 7.5em;
|
||||
bottom: 0.5em;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
border-right: 1px #ddd solid;
|
||||
}
|
||||
.left-box .menu {
|
||||
width: 90% !important;
|
||||
}
|
||||
.left-box .menu .item {
|
||||
line-height: 1.2;
|
||||
position: relative;
|
||||
padding-left: 1em !important;
|
||||
}
|
||||
.left-box .menu .item .icon {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 0;
|
||||
margin-top: -0.4em !important;
|
||||
}
|
||||
.left-box .menu .item.separator {
|
||||
border-bottom: 1px #eee solid !important;
|
||||
padding-top: 0;
|
||||
padding-bottom: 0;
|
||||
margin-top: 0 !important;
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
.left-box .menu .header {
|
||||
border-bottom: 1px #ddd solid;
|
||||
padding-left: 0 !important;
|
||||
padding-bottom: 1em !important;
|
||||
}
|
||||
.left-box::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
}
|
||||
.right-box {
|
||||
margin-left: 9em;
|
||||
}
|
||||
.label em {
|
||||
font-style: italic !important;
|
||||
}
|
||||
/*# sourceMappingURL=index.css.map */
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"sources":["/Users/liuxiangchao/Documents/projects/Edge/EdgeAdmin/web/views/@default/servers/server/@left_menu.less","index.less"],"names":[],"mappings":"AAAA;EACC,UAAA;EACA,eAAA;EACA,UAAA;EACA,aAAA;EACA,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAPD,SASC;EACC,qBAAA;;AAVF,SASC,MAGC;EACC,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAfH,SASC,MAGC,MAKC;EACC,kBAAA;EACA,QAAA;EACA,OAAA;EACA,kBAAA;;AArBJ,SASC,MAgBC,MAAK;EACJ,wCAAA;EACA,cAAA;EACA,iBAAA;EACA,wBAAA;EACA,2BAAA;;AA9BH,SASC,MAyBC;EACC,6BAAA;EACA,0BAAA;EACA,8BAAA;;AAQH,SAAS;EACR,UAAA;;AAGD;EACC,gBAAA;;AChDD,MAAO;EACN,6BAAA","file":"index.css"}
|
||||
undefined
|
||||
@@ -1,6 +1,6 @@
|
||||
{$layout}
|
||||
|
||||
{$template "/servers/server/left_menu"}
|
||||
{$template "/left_menu"}
|
||||
<div class="right-box">
|
||||
<div class="ui message">此功能暂未开放,敬请期待。</div>
|
||||
</div>
|
||||
@@ -1,5 +0,0 @@
|
||||
@import "../@left_menu";
|
||||
|
||||
.label em {
|
||||
font-style: italic !important;
|
||||
}
|
||||
@@ -1,45 +0,0 @@
|
||||
.left-box {
|
||||
width: 8em;
|
||||
position: fixed;
|
||||
top: 7.5em;
|
||||
bottom: 0.5em;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
border-right: 1px #ddd solid;
|
||||
}
|
||||
.left-box .menu {
|
||||
width: 90% !important;
|
||||
}
|
||||
.left-box .menu .item {
|
||||
line-height: 1.2;
|
||||
position: relative;
|
||||
padding-left: 1em !important;
|
||||
}
|
||||
.left-box .menu .item .icon {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 0;
|
||||
margin-top: -0.4em !important;
|
||||
}
|
||||
.left-box .menu .item.separator {
|
||||
border-bottom: 1px #eee solid !important;
|
||||
padding-top: 0;
|
||||
padding-bottom: 0;
|
||||
margin-top: 0 !important;
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
.left-box .menu .header {
|
||||
border-bottom: 1px #ddd solid;
|
||||
padding-left: 0 !important;
|
||||
padding-bottom: 1em !important;
|
||||
}
|
||||
.left-box::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
}
|
||||
.right-box {
|
||||
margin-left: 9em;
|
||||
}
|
||||
.label em {
|
||||
font-style: italic !important;
|
||||
}
|
||||
/*# sourceMappingURL=index.css.map */
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"sources":["/Users/liuxiangchao/Documents/projects/Edge/EdgeAdmin/web/views/@default/servers/server/@left_menu.less","index.less"],"names":[],"mappings":"AAAA;EACC,UAAA;EACA,eAAA;EACA,UAAA;EACA,aAAA;EACA,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAPD,SASC;EACC,qBAAA;;AAVF,SASC,MAGC;EACC,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAfH,SASC,MAGC,MAKC;EACC,kBAAA;EACA,QAAA;EACA,OAAA;EACA,kBAAA;;AArBJ,SASC,MAgBC,MAAK;EACJ,wCAAA;EACA,cAAA;EACA,iBAAA;EACA,wBAAA;EACA,2BAAA;;AA9BH,SASC,MAyBC;EACC,6BAAA;EACA,0BAAA;EACA,8BAAA;;AAQH,SAAS;EACR,UAAA;;AAGD;EACC,gBAAA;;AChDD,MAAO;EACN,6BAAA","file":"index.css"}
|
||||
undefined
|
||||
@@ -1,6 +1,6 @@
|
||||
{$layout}
|
||||
|
||||
{$template "/servers/server/left_menu"}
|
||||
{$template "/left_menu"}
|
||||
<div class="right-box">
|
||||
<div class="ui message">此功能暂未开放,敬请期待。</div>
|
||||
</div>
|
||||
@@ -1,5 +0,0 @@
|
||||
@import "../@left_menu";
|
||||
|
||||
.label em {
|
||||
font-style: italic !important;
|
||||
}
|
||||
@@ -1,45 +0,0 @@
|
||||
.left-box {
|
||||
width: 8em;
|
||||
position: fixed;
|
||||
top: 7.5em;
|
||||
bottom: 0.5em;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
border-right: 1px #ddd solid;
|
||||
}
|
||||
.left-box .menu {
|
||||
width: 90% !important;
|
||||
}
|
||||
.left-box .menu .item {
|
||||
line-height: 1.2;
|
||||
position: relative;
|
||||
padding-left: 1em !important;
|
||||
}
|
||||
.left-box .menu .item .icon {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 0;
|
||||
margin-top: -0.4em !important;
|
||||
}
|
||||
.left-box .menu .item.separator {
|
||||
border-bottom: 1px #eee solid !important;
|
||||
padding-top: 0;
|
||||
padding-bottom: 0;
|
||||
margin-top: 0 !important;
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
.left-box .menu .header {
|
||||
border-bottom: 1px #ddd solid;
|
||||
padding-left: 0 !important;
|
||||
padding-bottom: 1em !important;
|
||||
}
|
||||
.left-box::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
}
|
||||
.right-box {
|
||||
margin-left: 9em;
|
||||
}
|
||||
.label em {
|
||||
font-style: italic !important;
|
||||
}
|
||||
/*# sourceMappingURL=index.css.map */
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"sources":["@left_menu.less","index.less"],"names":[],"mappings":"AAAA;EACC,UAAA;EACA,eAAA;EACA,UAAA;EACA,aAAA;EACA,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAPD,SASC;EACC,qBAAA;;AAVF,SASC,MAGC;EACC,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAfH,SASC,MAGC,MAKC;EACC,kBAAA;EACA,QAAA;EACA,OAAA;EACA,kBAAA;;AArBJ,SASC,MAgBC,MAAK;EACJ,wCAAA;EACA,cAAA;EACA,iBAAA;EACA,wBAAA;EACA,2BAAA;;AA9BH,SASC,MAyBC;EACC,6BAAA;EACA,0BAAA;EACA,8BAAA;;AAQH,SAAS;EACR,UAAA;;AAGD;EACC,gBAAA;;AChDD,MAAO;EACN,6BAAA","file":"index.css"}
|
||||
undefined
|
||||
@@ -1,6 +1,6 @@
|
||||
{$layout}
|
||||
|
||||
{$template "left_menu"}
|
||||
{$template "/left_menu"}
|
||||
|
||||
<div class="right-box">
|
||||
<table class="ui table selectable definition">
|
||||
|
||||
@@ -1,5 +0,0 @@
|
||||
@import "@left_menu";
|
||||
|
||||
.label em {
|
||||
font-style: italic !important;
|
||||
}
|
||||
@@ -1,45 +0,0 @@
|
||||
.left-box {
|
||||
width: 8em;
|
||||
position: fixed;
|
||||
top: 7.5em;
|
||||
bottom: 0.5em;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
border-right: 1px #ddd solid;
|
||||
}
|
||||
.left-box .menu {
|
||||
width: 90% !important;
|
||||
}
|
||||
.left-box .menu .item {
|
||||
line-height: 1.2;
|
||||
position: relative;
|
||||
padding-left: 1em !important;
|
||||
}
|
||||
.left-box .menu .item .icon {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 0;
|
||||
margin-top: -0.4em !important;
|
||||
}
|
||||
.left-box .menu .item.separator {
|
||||
border-bottom: 1px #eee solid !important;
|
||||
padding-top: 0;
|
||||
padding-bottom: 0;
|
||||
margin-top: 0 !important;
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
.left-box .menu .header {
|
||||
border-bottom: 1px #ddd solid;
|
||||
padding-left: 0 !important;
|
||||
padding-bottom: 1em !important;
|
||||
}
|
||||
.left-box::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
}
|
||||
.right-box {
|
||||
margin-left: 9em;
|
||||
}
|
||||
.label em {
|
||||
font-style: italic !important;
|
||||
}
|
||||
/*# sourceMappingURL=index.css.map */
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"sources":["/Users/liuxiangchao/Documents/projects/Edge/EdgeAdmin/web/views/@default/servers/server/@left_menu.less","index.less"],"names":[],"mappings":"AAAA;EACC,UAAA;EACA,eAAA;EACA,UAAA;EACA,aAAA;EACA,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAPD,SASC;EACC,qBAAA;;AAVF,SASC,MAGC;EACC,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAfH,SASC,MAGC,MAKC;EACC,kBAAA;EACA,QAAA;EACA,OAAA;EACA,kBAAA;;AArBJ,SASC,MAgBC,MAAK;EACJ,wCAAA;EACA,cAAA;EACA,iBAAA;EACA,wBAAA;EACA,2BAAA;;AA9BH,SASC,MAyBC;EACC,6BAAA;EACA,0BAAA;EACA,8BAAA;;AAQH,SAAS;EACR,UAAA;;AAGD;EACC,gBAAA;;AChDD,MAAO;EACN,6BAAA","file":"index.css"}
|
||||
undefined
|
||||
@@ -1,6 +1,6 @@
|
||||
{$layout}
|
||||
|
||||
{$template "/servers/server/left_menu"}
|
||||
{$template "/left_menu"}
|
||||
<div class="right-box">
|
||||
<div class="ui message">此功能暂未开放,敬请期待。</div>
|
||||
</div>
|
||||
@@ -1,5 +0,0 @@
|
||||
@import "../@left_menu";
|
||||
|
||||
.label em {
|
||||
font-style: italic !important;
|
||||
}
|
||||
@@ -1,42 +0,0 @@
|
||||
.left-box {
|
||||
width: 8em;
|
||||
position: fixed;
|
||||
top: 7.5em;
|
||||
bottom: 0.5em;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
border-right: 1px #ddd solid;
|
||||
}
|
||||
.left-box .menu {
|
||||
width: 90% !important;
|
||||
}
|
||||
.left-box .menu .item {
|
||||
line-height: 1.2;
|
||||
position: relative;
|
||||
padding-left: 1em !important;
|
||||
}
|
||||
.left-box .menu .item .icon {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 0;
|
||||
margin-top: -0.4em !important;
|
||||
}
|
||||
.left-box .menu .item.separator {
|
||||
border-bottom: 1px #eee solid !important;
|
||||
padding-top: 0;
|
||||
padding-bottom: 0;
|
||||
margin-top: 0 !important;
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
.left-box .menu .header {
|
||||
border-bottom: 1px #ddd solid;
|
||||
padding-left: 0 !important;
|
||||
padding-bottom: 1em !important;
|
||||
}
|
||||
.left-box::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
}
|
||||
.right-box {
|
||||
margin-left: 9em;
|
||||
}
|
||||
/*# sourceMappingURL=index.css.map */
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"sources":["/Users/liuxiangchao/Documents/projects/Edge/EdgeAdmin/web/views/@default/servers/server/@left_menu.less"],"names":[],"mappings":"AAAA;EACC,UAAA;EACA,eAAA;EACA,UAAA;EACA,aAAA;EACA,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAPD,SASC;EACC,qBAAA;;AAVF,SASC,MAGC;EACC,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAfH,SASC,MAGC,MAKC;EACC,kBAAA;EACA,QAAA;EACA,OAAA;EACA,kBAAA;;AArBJ,SASC,MAgBC,MAAK;EACJ,wCAAA;EACA,cAAA;EACA,iBAAA;EACA,wBAAA;EACA,2BAAA;;AA9BH,SASC,MAyBC;EACC,6BAAA;EACA,0BAAA;EACA,8BAAA;;AAQH,SAAS;EACR,UAAA;;AAGD;EACC,gBAAA","file":"index.css"}
|
||||
undefined
|
||||
@@ -1,6 +1,6 @@
|
||||
{$layout}
|
||||
|
||||
{$template "/servers/server/left_menu"}
|
||||
{$template "/left_menu"}
|
||||
|
||||
<div class="right-box">
|
||||
<p class="ui message">此功能暂未开放,敬请期待。</p>
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
@import "../../@left_menu";
|
||||
@@ -1,42 +0,0 @@
|
||||
.left-box {
|
||||
width: 8em;
|
||||
position: fixed;
|
||||
top: 7.5em;
|
||||
bottom: 0.5em;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
border-right: 1px #ddd solid;
|
||||
}
|
||||
.left-box .menu {
|
||||
width: 90% !important;
|
||||
}
|
||||
.left-box .menu .item {
|
||||
line-height: 1.2;
|
||||
position: relative;
|
||||
padding-left: 1em !important;
|
||||
}
|
||||
.left-box .menu .item .icon {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 0;
|
||||
margin-top: -0.4em !important;
|
||||
}
|
||||
.left-box .menu .item.separator {
|
||||
border-bottom: 1px #eee solid !important;
|
||||
padding-top: 0;
|
||||
padding-bottom: 0;
|
||||
margin-top: 0 !important;
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
.left-box .menu .header {
|
||||
border-bottom: 1px #ddd solid;
|
||||
padding-left: 0 !important;
|
||||
padding-bottom: 1em !important;
|
||||
}
|
||||
.left-box::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
}
|
||||
.right-box {
|
||||
margin-left: 9em;
|
||||
}
|
||||
/*# sourceMappingURL=index.css.map */
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"sources":["/Users/liuxiangchao/Documents/projects/Edge/EdgeAdmin/web/views/@default/servers/server/@left_menu.less"],"names":[],"mappings":"AAAA;EACC,UAAA;EACA,eAAA;EACA,UAAA;EACA,aAAA;EACA,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAPD,SASC;EACC,qBAAA;;AAVF,SASC,MAGC;EACC,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAfH,SASC,MAGC,MAKC;EACC,kBAAA;EACA,QAAA;EACA,OAAA;EACA,kBAAA;;AArBJ,SASC,MAgBC,MAAK;EACJ,wCAAA;EACA,cAAA;EACA,iBAAA;EACA,wBAAA;EACA,2BAAA;;AA9BH,SASC,MAyBC;EACC,6BAAA;EACA,0BAAA;EACA,8BAAA;;AAQH,SAAS;EACR,UAAA;;AAGD;EACC,gBAAA","file":"index.css"}
|
||||
undefined
|
||||
@@ -1,6 +1,6 @@
|
||||
{$layout}
|
||||
|
||||
{$template "/servers/server/left_menu"}
|
||||
{$template "/left_menu"}
|
||||
|
||||
<div class="right-box">
|
||||
<p class="ui message">此功能暂未开放,敬请期待。</p>
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
@import "../../@left_menu";
|
||||
@@ -1,42 +0,0 @@
|
||||
.left-box {
|
||||
width: 8em;
|
||||
position: fixed;
|
||||
top: 7.5em;
|
||||
bottom: 0.5em;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
border-right: 1px #ddd solid;
|
||||
}
|
||||
.left-box .menu {
|
||||
width: 90% !important;
|
||||
}
|
||||
.left-box .menu .item {
|
||||
line-height: 1.2;
|
||||
position: relative;
|
||||
padding-left: 1em !important;
|
||||
}
|
||||
.left-box .menu .item .icon {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 0;
|
||||
margin-top: -0.4em !important;
|
||||
}
|
||||
.left-box .menu .item.separator {
|
||||
border-bottom: 1px #eee solid !important;
|
||||
padding-top: 0;
|
||||
padding-bottom: 0;
|
||||
margin-top: 0 !important;
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
.left-box .menu .header {
|
||||
border-bottom: 1px #ddd solid;
|
||||
padding-left: 0 !important;
|
||||
padding-bottom: 1em !important;
|
||||
}
|
||||
.left-box::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
}
|
||||
.right-box {
|
||||
margin-left: 9em;
|
||||
}
|
||||
/*# sourceMappingURL=index.css.map */
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"sources":["/Users/liuxiangchao/Documents/projects/Edge/EdgeAdmin/web/views/@default/servers/server/@left_menu.less"],"names":[],"mappings":"AAAA;EACC,UAAA;EACA,eAAA;EACA,UAAA;EACA,aAAA;EACA,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAPD,SASC;EACC,qBAAA;;AAVF,SASC,MAGC;EACC,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAfH,SASC,MAGC,MAKC;EACC,kBAAA;EACA,QAAA;EACA,OAAA;EACA,kBAAA;;AArBJ,SASC,MAgBC,MAAK;EACJ,wCAAA;EACA,cAAA;EACA,iBAAA;EACA,wBAAA;EACA,2BAAA;;AA9BH,SASC,MAyBC;EACC,6BAAA;EACA,0BAAA;EACA,8BAAA;;AAQH,SAAS;EACR,UAAA;;AAGD;EACC,gBAAA","file":"index.css"}
|
||||
undefined
|
||||
@@ -1,6 +1,6 @@
|
||||
{$layout}
|
||||
|
||||
{$template "/servers/server/left_menu"}
|
||||
{$template "/left_menu"}
|
||||
|
||||
<div class="right-box">
|
||||
<p class="ui message">此功能暂未开放,敬请期待。</p>
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
@import "../../@left_menu";
|
||||
@@ -1,42 +0,0 @@
|
||||
.left-box {
|
||||
width: 8em;
|
||||
position: fixed;
|
||||
top: 7.5em;
|
||||
bottom: 0.5em;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
border-right: 1px #ddd solid;
|
||||
}
|
||||
.left-box .menu {
|
||||
width: 90% !important;
|
||||
}
|
||||
.left-box .menu .item {
|
||||
line-height: 1.2;
|
||||
position: relative;
|
||||
padding-left: 1em !important;
|
||||
}
|
||||
.left-box .menu .item .icon {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 0;
|
||||
margin-top: -0.4em !important;
|
||||
}
|
||||
.left-box .menu .item.separator {
|
||||
border-bottom: 1px #eee solid !important;
|
||||
padding-top: 0;
|
||||
padding-bottom: 0;
|
||||
margin-top: 0 !important;
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
.left-box .menu .header {
|
||||
border-bottom: 1px #ddd solid;
|
||||
padding-left: 0 !important;
|
||||
padding-bottom: 1em !important;
|
||||
}
|
||||
.left-box::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
}
|
||||
.right-box {
|
||||
margin-left: 9em;
|
||||
}
|
||||
/*# sourceMappingURL=index.css.map */
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"sources":["/Users/liuxiangchao/Documents/projects/Edge/EdgeAdmin/web/views/@default/servers/server/@left_menu.less"],"names":[],"mappings":"AAAA;EACC,UAAA;EACA,eAAA;EACA,UAAA;EACA,aAAA;EACA,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAPD,SASC;EACC,qBAAA;;AAVF,SASC,MAGC;EACC,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAfH,SASC,MAGC,MAKC;EACC,kBAAA;EACA,QAAA;EACA,OAAA;EACA,kBAAA;;AArBJ,SASC,MAgBC,MAAK;EACJ,wCAAA;EACA,cAAA;EACA,iBAAA;EACA,wBAAA;EACA,2BAAA;;AA9BH,SASC,MAyBC;EACC,6BAAA;EACA,0BAAA;EACA,8BAAA;;AAQH,SAAS;EACR,UAAA;;AAGD;EACC,gBAAA","file":"index.css"}
|
||||
undefined
|
||||
@@ -1,6 +1,6 @@
|
||||
{$layout}
|
||||
|
||||
{$template "/servers/server/left_menu"}
|
||||
{$template "/left_menu"}
|
||||
|
||||
<div class="right-box">
|
||||
<p class="ui message">此功能暂未开放,敬请期待。</p>
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
@import "../../@left_menu";
|
||||
@@ -1,42 +0,0 @@
|
||||
.left-box {
|
||||
width: 8em;
|
||||
position: fixed;
|
||||
top: 7.5em;
|
||||
bottom: 0.5em;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
border-right: 1px #ddd solid;
|
||||
}
|
||||
.left-box .menu {
|
||||
width: 90% !important;
|
||||
}
|
||||
.left-box .menu .item {
|
||||
line-height: 1.2;
|
||||
position: relative;
|
||||
padding-left: 1em !important;
|
||||
}
|
||||
.left-box .menu .item .icon {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 0;
|
||||
margin-top: -0.4em !important;
|
||||
}
|
||||
.left-box .menu .item.separator {
|
||||
border-bottom: 1px #eee solid !important;
|
||||
padding-top: 0;
|
||||
padding-bottom: 0;
|
||||
margin-top: 0 !important;
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
.left-box .menu .header {
|
||||
border-bottom: 1px #ddd solid;
|
||||
padding-left: 0 !important;
|
||||
padding-bottom: 1em !important;
|
||||
}
|
||||
.left-box::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
}
|
||||
.right-box {
|
||||
margin-left: 9em;
|
||||
}
|
||||
/*# sourceMappingURL=index.css.map */
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"sources":["/Users/liuxiangchao/Documents/projects/Edge/EdgeAdmin/web/views/@default/servers/server/@left_menu.less"],"names":[],"mappings":"AAAA;EACC,UAAA;EACA,eAAA;EACA,UAAA;EACA,aAAA;EACA,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAPD,SASC;EACC,qBAAA;;AAVF,SASC,MAGC;EACC,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAfH,SASC,MAGC,MAKC;EACC,kBAAA;EACA,QAAA;EACA,OAAA;EACA,kBAAA;;AArBJ,SASC,MAgBC,MAAK;EACJ,wCAAA;EACA,cAAA;EACA,iBAAA;EACA,wBAAA;EACA,2BAAA;;AA9BH,SASC,MAyBC;EACC,6BAAA;EACA,0BAAA;EACA,8BAAA;;AAQH,SAAS;EACR,UAAA;;AAGD;EACC,gBAAA","file":"index.css"}
|
||||
undefined
|
||||
@@ -1,6 +1,6 @@
|
||||
{$layout}
|
||||
|
||||
{$template "/servers/server/left_menu"}
|
||||
{$template "/left_menu"}
|
||||
|
||||
<div class="right-box">
|
||||
<p class="ui message">此功能暂未开放,敬请期待。</p>
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
@import "../../@left_menu";
|
||||
@@ -1,42 +0,0 @@
|
||||
.left-box {
|
||||
width: 8em;
|
||||
position: fixed;
|
||||
top: 7.5em;
|
||||
bottom: 0.5em;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
border-right: 1px #ddd solid;
|
||||
}
|
||||
.left-box .menu {
|
||||
width: 90% !important;
|
||||
}
|
||||
.left-box .menu .item {
|
||||
line-height: 1.2;
|
||||
position: relative;
|
||||
padding-left: 1em !important;
|
||||
}
|
||||
.left-box .menu .item .icon {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 0;
|
||||
margin-top: -0.4em !important;
|
||||
}
|
||||
.left-box .menu .item.separator {
|
||||
border-bottom: 1px #eee solid !important;
|
||||
padding-top: 0;
|
||||
padding-bottom: 0;
|
||||
margin-top: 0 !important;
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
.left-box .menu .header {
|
||||
border-bottom: 1px #ddd solid;
|
||||
padding-left: 0 !important;
|
||||
padding-bottom: 1em !important;
|
||||
}
|
||||
.left-box::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
}
|
||||
.right-box {
|
||||
margin-left: 9em;
|
||||
}
|
||||
/*# sourceMappingURL=index.css.map */
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"sources":["/Users/liuxiangchao/Documents/projects/Edge/EdgeAdmin/web/views/@default/servers/server/@left_menu.less"],"names":[],"mappings":"AAAA;EACC,UAAA;EACA,eAAA;EACA,UAAA;EACA,aAAA;EACA,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAPD,SASC;EACC,qBAAA;;AAVF,SASC,MAGC;EACC,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAfH,SASC,MAGC,MAKC;EACC,kBAAA;EACA,QAAA;EACA,OAAA;EACA,kBAAA;;AArBJ,SASC,MAgBC,MAAK;EACJ,wCAAA;EACA,cAAA;EACA,iBAAA;EACA,wBAAA;EACA,2BAAA;;AA9BH,SASC,MAyBC;EACC,6BAAA;EACA,0BAAA;EACA,8BAAA;;AAQH,SAAS;EACR,UAAA;;AAGD;EACC,gBAAA","file":"index.css"}
|
||||
undefined
|
||||
@@ -1,6 +1,6 @@
|
||||
{$layout}
|
||||
|
||||
{$template "/servers/server/left_menu"}
|
||||
{$template "/left_menu"}
|
||||
|
||||
<div class="right-box">
|
||||
<p class="ui message">此功能暂未开放,敬请期待。</p>
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
@import "../../@left_menu";
|
||||
@@ -1,42 +0,0 @@
|
||||
.left-box {
|
||||
width: 8em;
|
||||
position: fixed;
|
||||
top: 7.5em;
|
||||
bottom: 0.5em;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
border-right: 1px #ddd solid;
|
||||
}
|
||||
.left-box .menu {
|
||||
width: 90% !important;
|
||||
}
|
||||
.left-box .menu .item {
|
||||
line-height: 1.2;
|
||||
position: relative;
|
||||
padding-left: 1em !important;
|
||||
}
|
||||
.left-box .menu .item .icon {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 0;
|
||||
margin-top: -0.4em !important;
|
||||
}
|
||||
.left-box .menu .item.separator {
|
||||
border-bottom: 1px #eee solid !important;
|
||||
padding-top: 0;
|
||||
padding-bottom: 0;
|
||||
margin-top: 0 !important;
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
.left-box .menu .header {
|
||||
border-bottom: 1px #ddd solid;
|
||||
padding-left: 0 !important;
|
||||
padding-bottom: 1em !important;
|
||||
}
|
||||
.left-box::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
}
|
||||
.right-box {
|
||||
margin-left: 9em;
|
||||
}
|
||||
/*# sourceMappingURL=index.css.map */
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"sources":["/Users/liuxiangchao/Documents/projects/Edge/EdgeAdmin/web/views/@default/servers/server/@left_menu.less"],"names":[],"mappings":"AAAA;EACC,UAAA;EACA,eAAA;EACA,UAAA;EACA,aAAA;EACA,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAPD,SASC;EACC,qBAAA;;AAVF,SASC,MAGC;EACC,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAfH,SASC,MAGC,MAKC;EACC,kBAAA;EACA,QAAA;EACA,OAAA;EACA,kBAAA;;AArBJ,SASC,MAgBC,MAAK;EACJ,wCAAA;EACA,cAAA;EACA,iBAAA;EACA,wBAAA;EACA,2BAAA;;AA9BH,SASC,MAyBC;EACC,6BAAA;EACA,0BAAA;EACA,8BAAA;;AAQH,SAAS;EACR,UAAA;;AAGD;EACC,gBAAA","file":"index.css"}
|
||||
undefined
|
||||
@@ -1,6 +1,6 @@
|
||||
{$layout}
|
||||
|
||||
{$template "/servers/server/left_menu"}
|
||||
{$template "/left_menu"}
|
||||
|
||||
<div class="right-box">
|
||||
<p class="ui message">此功能暂未开放,敬请期待。</p>
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
@import "../../@left_menu";
|
||||
@@ -1,42 +0,0 @@
|
||||
.left-box {
|
||||
width: 8em;
|
||||
position: fixed;
|
||||
top: 7.5em;
|
||||
bottom: 0.5em;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
border-right: 1px #ddd solid;
|
||||
}
|
||||
.left-box .menu {
|
||||
width: 90% !important;
|
||||
}
|
||||
.left-box .menu .item {
|
||||
line-height: 1.2;
|
||||
position: relative;
|
||||
padding-left: 1em !important;
|
||||
}
|
||||
.left-box .menu .item .icon {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 0;
|
||||
margin-top: -0.4em !important;
|
||||
}
|
||||
.left-box .menu .item.separator {
|
||||
border-bottom: 1px #eee solid !important;
|
||||
padding-top: 0;
|
||||
padding-bottom: 0;
|
||||
margin-top: 0 !important;
|
||||
margin-bottom: 0 !important;
|
||||
}
|
||||
.left-box .menu .header {
|
||||
border-bottom: 1px #ddd solid;
|
||||
padding-left: 0 !important;
|
||||
padding-bottom: 1em !important;
|
||||
}
|
||||
.left-box::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
}
|
||||
.right-box {
|
||||
margin-left: 9em;
|
||||
}
|
||||
/*# sourceMappingURL=index.css.map */
|
||||
@@ -1 +1 @@
|
||||
{"version":3,"sources":["/Users/liuxiangchao/Documents/projects/Edge/EdgeAdmin/web/views/@default/servers/server/@left_menu.less"],"names":[],"mappings":"AAAA;EACC,UAAA;EACA,eAAA;EACA,UAAA;EACA,aAAA;EACA,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAPD,SASC;EACC,qBAAA;;AAVF,SASC,MAGC;EACC,gBAAA;EACA,kBAAA;EACA,4BAAA;;AAfH,SASC,MAGC,MAKC;EACC,kBAAA;EACA,QAAA;EACA,OAAA;EACA,kBAAA;;AArBJ,SASC,MAgBC,MAAK;EACJ,wCAAA;EACA,cAAA;EACA,iBAAA;EACA,wBAAA;EACA,2BAAA;;AA9BH,SASC,MAyBC;EACC,6BAAA;EACA,0BAAA;EACA,8BAAA;;AAQH,SAAS;EACR,UAAA;;AAGD;EACC,gBAAA","file":"index.css"}
|
||||
undefined
|
||||
@@ -1,6 +1,6 @@
|
||||
{$layout}
|
||||
|
||||
{$template "/servers/server/left_menu"}
|
||||
{$template "/left_menu"}
|
||||
|
||||
<div class="right-box">
|
||||
<p class="ui message">此功能暂未开放,敬请期待。</p>
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user