mirror of
https://github.com/MCSManager/MCSManager.git
synced 2025-03-25 16:50:22 +08:00
commit
e0b9512e98
public
@ -1,64 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>public</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
<buildCommand>
|
||||
<name>com.aptana.ide.core.unifiedBuilder</name>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
<nature>com.aptana.projects.webnature</nature>
|
||||
</natures>
|
||||
<filteredResources>
|
||||
<filter>
|
||||
<id>1499743882632</id>
|
||||
<name></name>
|
||||
<type>26</type>
|
||||
<matcher>
|
||||
<id>org.eclipse.ui.ide.multiFilter</id>
|
||||
<arguments>1.0-name-matches-false-false-node_modules</arguments>
|
||||
</matcher>
|
||||
</filter>
|
||||
<filter>
|
||||
<id>1500517213634</id>
|
||||
<name></name>
|
||||
<type>26</type>
|
||||
<matcher>
|
||||
<id>org.eclipse.ui.ide.multiFilter</id>
|
||||
<arguments>1.0-name-matches-false-false-node_modules</arguments>
|
||||
</matcher>
|
||||
</filter>
|
||||
<filter>
|
||||
<id>1500951989738</id>
|
||||
<name></name>
|
||||
<type>26</type>
|
||||
<matcher>
|
||||
<id>org.eclipse.ui.ide.multiFilter</id>
|
||||
<arguments>1.0-name-matches-false-false-node_modules</arguments>
|
||||
</matcher>
|
||||
</filter>
|
||||
<filter>
|
||||
<id>1507186835727</id>
|
||||
<name></name>
|
||||
<type>26</type>
|
||||
<matcher>
|
||||
<id>org.eclipse.ui.ide.multiFilter</id>
|
||||
<arguments>1.0-name-matches-false-false-node_modules</arguments>
|
||||
</matcher>
|
||||
</filter>
|
||||
<filter>
|
||||
<id>1510878182053</id>
|
||||
<name></name>
|
||||
<type>26</type>
|
||||
<matcher>
|
||||
<id>org.eclipse.ui.ide.multiFilter</id>
|
||||
<arguments>1.0-name-matches-false-false-node_modules</arguments>
|
||||
</matcher>
|
||||
</filter>
|
||||
</filteredResources>
|
||||
</projectDescription>
|
@ -1,6 +1,11 @@
|
||||
//标准的URL定位器
|
||||
//如果你的程序不在根目录,可以考虑更改这里,或者你有什么其他姿势。
|
||||
//保证 99% 的可用性,因为代码历史遗留问题,不能保证所有请求都能通过此 URL 定位器
|
||||
|
||||
//某些 login 页面没有 MCSERVER 全局变量,在此实例化
|
||||
if (window.MCSERVER == undefined) window.MCSERVER = {};
|
||||
|
||||
//URL定位器
|
||||
MCSERVER.URL = function (url, protocol) {
|
||||
var _protocol = protocol || 'http://';
|
||||
var hostName = window.location.host;
|
||||
|
@ -1,3 +1,6 @@
|
||||
//依附于 Tools 工具
|
||||
//Charts 的图表封装模块
|
||||
|
||||
TOOLS.charts = {};
|
||||
|
||||
TOOLS.charts.bulider = function (dom, len, config, callback, chartOption) {
|
||||
|
@ -1,8 +1,5 @@
|
||||
//Debug
|
||||
//(function() {
|
||||
// var _consoleObj = console;
|
||||
//// window.console.log = function(){};
|
||||
//})();
|
||||
//初始化公共层
|
||||
//用于各类程序初始化
|
||||
|
||||
(function () {
|
||||
window.MS = {};
|
||||
|
@ -1,4 +1,4 @@
|
||||
;
|
||||
//响应层
|
||||
(function () {
|
||||
var DEBUG = false;
|
||||
var TOKEN_NAME = '_T0K_N';
|
||||
|
@ -1,3 +1,4 @@
|
||||
//Tools 工具模块
|
||||
(function () {
|
||||
//全局TOOLS
|
||||
window.TOOLS = {};
|
||||
@ -87,12 +88,7 @@
|
||||
}
|
||||
|
||||
TOOLS.setCookie = function (name, value) {
|
||||
// var strsec = getsec(time);
|
||||
document.cookie = name + "=" + escape(value) + ";expires=" + new Date(Date.now() + 10000 * 60 * 60 * 4).toGMTString();
|
||||
}
|
||||
|
||||
// TOOLS.onResize = function($dom,callback){
|
||||
//
|
||||
// }
|
||||
|
||||
})();
|
@ -5,6 +5,7 @@
|
||||
|
||||
var DEBUG = false;
|
||||
|
||||
//ws 链接事件
|
||||
MI.listener('ws/open', function (ws) {
|
||||
VIEW_MODEL['websocketStatus'] = {};
|
||||
var webscoketStatus = VIEW_MODEL['websocketStatus'];
|
||||
@ -33,12 +34,14 @@
|
||||
webscoketStatus['color'] = '#f5ea6c';
|
||||
});
|
||||
|
||||
//单页生命周期替换事件
|
||||
MI.listener('page/live', function (ws) {
|
||||
for (var tmp in PAGE) delete PAGE[tmp];
|
||||
delete PAGE;
|
||||
PAGE = new Object();
|
||||
});
|
||||
|
||||
//菜单获取
|
||||
MI.routeListener('ws/muem', function (data) {
|
||||
DEBUG && console.log('--- 系统菜单获取成功 ---')
|
||||
MCSERVER.username = data.obj.username;
|
||||
@ -104,8 +107,7 @@
|
||||
//服务器控制台
|
||||
MI.routeListener('server/console', function (data) {
|
||||
if (data.obj == null) {
|
||||
//alert('你无权访问此服务器');
|
||||
TOOLS.pushMsgWindow('您并不拥有这个服务器的所有权,需要管理员设定')
|
||||
TOOLS.pushMsgWindow('您并不拥有这个服务器的所有权,需要管理员设定');
|
||||
VIEW_MODEL['ConsolePanel'].serverData.name = null;
|
||||
}
|
||||
MI.routeCopy('ConsolePanel', data.obj);
|
||||
@ -119,8 +121,6 @@
|
||||
var terminalEncode = function (text) {
|
||||
var ify = '[_b_r_]';
|
||||
var txt = text;
|
||||
// if(txt == '')return;
|
||||
|
||||
txt = txt.replace(/<br \/>/igm, '[_b_r_]');
|
||||
var consoleSafe = TOOLS.encode(txt);
|
||||
consoleSafe = consoleSafe.replace(/\[_b_r_\]/igm, '<br>');
|
||||
@ -134,23 +134,17 @@
|
||||
console.log('NULL')
|
||||
}
|
||||
MinecraftConsole.innerHTML += consoleSafe;
|
||||
// if(MinecraftConsole.children.length > 612)MinecraftConsole.innerHTML = '';
|
||||
// MinecraftConsole.scrollIntoView();
|
||||
// MinecraftConsole.scrollTop = MinecraftConsole.scrollHeight;
|
||||
var BUFF_FONTIER_SIZE_DOWN = MinecraftConsole.scrollHeight - MinecraftConsole.clientHeight;
|
||||
// console.log('scrollTop:', $(MinecraftConsole).scrollTop())
|
||||
|
||||
if (MinecraftConsole.scrollTop + 354 >= BUFF_FONTIER_SIZE_DOWN) {
|
||||
MinecraftConsole.scrollTop = MinecraftConsole.scrollHeight;
|
||||
}
|
||||
});
|
||||
|
||||
//获取控制台历史记录
|
||||
MI.routeListener('server/console/history', function (data) {
|
||||
var consoleSafe = terminalEncode(data.body);
|
||||
|
||||
var MinecraftConsole = document.getElementById('TerminalMinecraft');
|
||||
// if(MinecraftConsole == undefined) {console.log('NULL')}
|
||||
// var teButton = "<div class='TerminalLoad' onclick='PAGE.terminalLoad()'> [ 单击加载更多历史记录 ]</div>"
|
||||
var ifyLoad =
|
||||
'<span style="color:#3af138;">[历史日志] </span>' +
|
||||
'<span style="color:rgb(212, 136, 30);">================<br></span>';
|
||||
@ -164,11 +158,6 @@
|
||||
|
||||
var resVTopLac = newHeightV - oldHeightV;
|
||||
MinecraftConsole.scrollTop = resVTopLac - 60;
|
||||
// console.log('NewTop:', resVTopLac, newHeightV, oldHeightV)
|
||||
// if(MinecraftConsole.children.length > 612)MinecraftConsole.innerHTML = '';
|
||||
// MinecraftConsole.scrollIntoView();
|
||||
// MinecraftConsole.scrollTop = MinecraftConsole.scrollHeight;\n
|
||||
|
||||
});
|
||||
|
||||
//普通用户主页
|
||||
|
@ -1,4 +1,4 @@
|
||||
;
|
||||
//Websocket 层
|
||||
(function () {
|
||||
|
||||
var DEBUG = false; //Websocket DEBUG
|
||||
@ -28,10 +28,10 @@
|
||||
try {
|
||||
obj = JSON.parse(header);
|
||||
if (DEBUG) {
|
||||
console.log('--------------- Websocket收到触发 ---------------')
|
||||
console.log('=== Websocket 收到触发 ===');
|
||||
console.log(obj);
|
||||
console.log('Body:' + body);
|
||||
console.log('--------------- Websocket收到结束 ---------------')
|
||||
console.log('=== Websocket 收到结束 ===');
|
||||
}
|
||||
obj.body = body;
|
||||
MI.on('ws/response', obj, body);
|
||||
@ -60,10 +60,10 @@
|
||||
RequestValue: value
|
||||
}
|
||||
if (DEBUG) {
|
||||
console.log('--------------- Websocket发送触发 ---------------');
|
||||
console.log('=== Websocket 发送触发 ===');
|
||||
console.log(obj);
|
||||
console.log(body);
|
||||
console.log('--------------- Websocket发送结束 ---------------');
|
||||
console.log('=== Websocket 发送结束 ===');
|
||||
}
|
||||
var headerStr = JSON.stringify(obj);
|
||||
body = body || '';
|
||||
|
@ -1,82 +1,83 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1" />
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<meta http-equiv="Content-Language" content="zh-CN" />
|
||||
<meta name="renderer" content="webkit" />
|
||||
<meta name="viewport" content="initial-scale=1, maximum-scale=3, minimum-scale=1, user-scalable=no" />
|
||||
|
||||
<title>Mcserver 验证</title>
|
||||
|
||||
<link href="./static/template/bootstrap/css/bootstrap.min.css" rel="stylesheet">
|
||||
<link href="./static/login/css/style.css" rel="stylesheet">
|
||||
<link href="./static/common/image/icon.ico" rel="shortcut icon">
|
||||
<!--[if lt IE 9]>
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1" />
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<meta http-equiv="Content-Language" content="zh-CN" />
|
||||
<meta name="renderer" content="webkit" />
|
||||
<meta name="viewport" content="initial-scale=1, maximum-scale=3, minimum-scale=1, user-scalable=no" />
|
||||
|
||||
<title>Mcserver 验证</title>
|
||||
|
||||
<link href="./static/template/bootstrap/css/bootstrap.min.css" rel="stylesheet">
|
||||
<link href="./static/login/css/style.css" rel="stylesheet">
|
||||
<link href="./static/common/image/icon.ico" rel="shortcut icon">
|
||||
<!--[if lt IE 9]>
|
||||
<div id='Not_' class="show-ui" style="height: 40px;background-color: rgb(221,79,67);text-align:center;line-height: 40px;color: white;">
|
||||
<b>无法访问! 您的浏览器版本过低或是兼容模式,请使用最新/更高版本的浏览器: IE10+ chrome FireFox 等,如果是国内浏览器请打开极速浏览模式(webkit内核)。</b>
|
||||
</div>
|
||||
<![endif]-->
|
||||
</head>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<body>
|
||||
|
||||
<div id='view-bg'>
|
||||
<img src="./static/login/img/background.jpg" height="100%" width="100%" />
|
||||
</div>
|
||||
<div id='login-view' class="show-ui">
|
||||
<div id='login-sub'>
|
||||
<div class="container-fluid">
|
||||
<div class="row">
|
||||
<img id='logo' src="static/common/logo.png">
|
||||
<br>
|
||||
<span class="ft-size-12 ft-color-black ft-text-index">登录到 Mcserver。</span>
|
||||
</div>
|
||||
<div id='login-form' class="row">
|
||||
<!-- 表单开始 -->
|
||||
<form class="form-horizontal" role="form">
|
||||
<div class="form-group has-feedback">
|
||||
<div class="col-sm-12">
|
||||
<input type="text" class="form-control border-1" id="login-userid" placeholder="账号">
|
||||
<span class="glyphicon glyphicon-user form-control-feedback" aria-hidden="true"></span>
|
||||
<div id='view-bg'>
|
||||
<img src="./static/login/img/background.jpg" height="100%" width="100%" />
|
||||
</div>
|
||||
<div id='login-view' class="show-ui">
|
||||
<div id='login-sub'>
|
||||
<div class="container-fluid">
|
||||
<div class="row">
|
||||
<img id='logo' src="static/common/logo.png">
|
||||
<br>
|
||||
<span class="ft-size-12 ft-color-black ft-text-index">登录到 Mcserver。</span>
|
||||
</div>
|
||||
<div id='login-form' class="row">
|
||||
<!-- 表单开始 -->
|
||||
<form class="form-horizontal" role="form">
|
||||
<div class="form-group has-feedback">
|
||||
<div class="col-sm-12">
|
||||
<input type="text" class="form-control border-1" id="login-userid" placeholder="账号">
|
||||
<span class="glyphicon glyphicon-user form-control-feedback" aria-hidden="true"></span>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group has-feedback">
|
||||
<div class="col-sm-12">
|
||||
<input type="password" class="form-control border-1" id="login-passwd" placeholder="密码">
|
||||
<span class="glyphicon glyphicon-th form-control-feedback" aria-hidden="true"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<div class="col-xs-4 col-sm-6"></div>
|
||||
<div class="col-xs-8 col-sm-6">
|
||||
<a href="/" id="form-help" class="text-right help-text" onclick="alert('请联系管理员更改密码,如果您是管理员,请删除user/文件夹下的所有#开头的管理用户')">忘记密码?</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<div class="col-sm-12">
|
||||
<div id='login-button' class="btn btn-default btn-info border-1" onclick="MCSERVER.btnLogin()">
|
||||
<b>验证</b>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group has-feedback">
|
||||
<div class="col-sm-12">
|
||||
<input type="password" class="form-control border-1" id="login-passwd" placeholder="密码">
|
||||
<span class="glyphicon glyphicon-th form-control-feedback" aria-hidden="true"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<div class="col-xs-4 col-sm-6"></div>
|
||||
<div class="col-xs-8 col-sm-6">
|
||||
<a href="/" id="form-help" class="text-right help-text" onclick="alert('请联系管理员更改密码,如果您是管理员,请删除user/文件夹下的所有#开头的管理用户')">忘记密码?</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<div class="col-sm-12">
|
||||
<div id='login-button' class="btn btn-default btn-info border-1" onclick="MCSERVER.btnLogin()"><b>验证</b></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
<!-- 表单结束 -->
|
||||
</div>
|
||||
<div id="copyright" class="row text-justify">
|
||||
<span>©2013-2017 Suwings. All rights reserved.</span>
|
||||
</div>
|
||||
</form>
|
||||
<!-- 表单结束 -->
|
||||
</div>
|
||||
<div id="copyright" class="row text-justify">
|
||||
<span>©2013-2018 Suwings. All rights reserved.</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id='view-info' class="alert alert-info show-ui tools-info">默认信息框</div>
|
||||
</body>
|
||||
<script src="./static/template/jq/jq.min.js"></script>
|
||||
<script type="text/javascript" src="../common/URL.js" ></script>
|
||||
<script type="text/javascript" src="../common/md5.js" ></script>
|
||||
<script src="../common/js/login.js"></script>
|
||||
<!--<script type="text/javascript" src="../common/URL.js" ></script>-->
|
||||
</div>
|
||||
<div id='view-info' class="alert alert-info show-ui tools-info">默认信息框</div>
|
||||
</body>
|
||||
<script src="./static/template/jq/jq.min.js"></script>
|
||||
<script type="text/javascript" src="../common/URL.js"></script>
|
||||
<script type="text/javascript" src="../common/md5.js"></script>
|
||||
<script src="../common/js/login.js"></script>
|
||||
|
||||
</html>
|
@ -140,25 +140,25 @@
|
||||
|
||||
<script>
|
||||
//创建
|
||||
MI.rListener('onload', function() {
|
||||
PAGE.time = function(value) {
|
||||
return function() {
|
||||
MI.rListener('onload', function () {
|
||||
PAGE.time = function (value) {
|
||||
return function () {
|
||||
var theTime = parseInt(Math.floor(this.uptime)); // 秒
|
||||
var theTime1 = 0; // 分
|
||||
var theTime2 = 0; // 小时
|
||||
if(theTime > 60) {
|
||||
if (theTime > 60) {
|
||||
theTime1 = parseInt(theTime / 60);
|
||||
theTime = parseInt(theTime % 60);
|
||||
if(theTime1 > 60) {
|
||||
if (theTime1 > 60) {
|
||||
theTime2 = parseInt(theTime1 / 60);
|
||||
theTime1 = parseInt(theTime1 % 60);
|
||||
}
|
||||
}
|
||||
var result = "";
|
||||
if(theTime1 > 0) {
|
||||
if (theTime1 > 0) {
|
||||
result = "" + parseInt(theTime1) + "分";
|
||||
}
|
||||
if(theTime2 > 0) {
|
||||
if (theTime2 > 0) {
|
||||
result = "" + parseInt(theTime2) + "时" + result;
|
||||
}
|
||||
return result;
|
||||
@ -172,14 +172,13 @@
|
||||
}
|
||||
});
|
||||
|
||||
PAGE.time = setInterval(function() {
|
||||
PAGE.time = setInterval(function () {
|
||||
WS.sendMsg('center/show', '');
|
||||
}, 2100);
|
||||
})
|
||||
|
||||
//关闭
|
||||
MI.rListener('onend', function() {
|
||||
MI.rListener('onend', function () {
|
||||
clearInterval(PAGE.time);
|
||||
console.log('页面关闭')
|
||||
})
|
||||
</script>
|
@ -41,10 +41,11 @@
|
||||
</div>
|
||||
|
||||
<div class="PanelItem">
|
||||
<span class="glyphicon glyphicon-th-list" aria-hidden="true"> </span> 端口: {{ FTP_port }}
|
||||
<span class="glyphicon glyphicon-th-list" aria-hidden="true"> </span> 端口: {{ FTP_port }}
|
||||
</div>
|
||||
<div class="PanelItem">
|
||||
<span class="glyphicon glyphicon-lock" aria-hidden="true"></span> 密码: <span style="color: #666666;"><与登陆密码相同></span>
|
||||
<span class="glyphicon glyphicon-lock" aria-hidden="true"></span> 密码:
|
||||
<span style="color: #666666;"><与登陆密码相同></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -56,13 +57,17 @@
|
||||
<div class="row">
|
||||
<div class="col-md-3 col-sm-6" v-on:click="RES.redirectPage('./template/component/terminal.html', null, '')">
|
||||
<div class="PanelItemBlock">
|
||||
<div class="LogV"><span class="glyphicon glyphicon-console" aria-hidden="true"> </span> </div>
|
||||
<div class="LogV">
|
||||
<span class="glyphicon glyphicon-console" aria-hidden="true"> </span>
|
||||
</div>
|
||||
<div class="LogK">命令控制台</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-3 col-sm-6" v-on:click="toProperties()">
|
||||
<div class="PanelItemBlock">
|
||||
<div class="LogV"><span class="glyphicon glyphicon-cog" aria-hidden="true"> </span> </div>
|
||||
<div class="LogV">
|
||||
<span class="glyphicon glyphicon-cog" aria-hidden="true"> </span>
|
||||
</div>
|
||||
<div class="LogK">服务器配置</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -117,57 +122,50 @@
|
||||
</div>
|
||||
|
||||
<script>
|
||||
MI.rListener('onload', function() {
|
||||
//默认隐藏控制台
|
||||
MCSERVER.colmDo();
|
||||
MI.rListener('onload', function () {
|
||||
|
||||
// PAGE.MinecraftConsole = document.getElementById('MinecraftConsole');
|
||||
// MCSERVER.colmSet(); //不自动调整,则边栏继承父类情况
|
||||
|
||||
var serverName = VIEW_MODEL['ConsolePanel'].serverData.name;
|
||||
MCSERVER.listenServername = serverName;
|
||||
// WS.sendMsg('server/console/ws', serverName);
|
||||
|
||||
VIEW_MODEL.newVue('ConsolePanel', {
|
||||
el: '#ConsolePanel',
|
||||
methods: {
|
||||
toOpenServer: function() {
|
||||
toOpenServer: function () {
|
||||
this.allowedStart = !this.allowedStart;
|
||||
WS.sendMsg('server/console/open', serverName);
|
||||
},
|
||||
toCommand: function(parCommand) {
|
||||
if(parCommand && typeof(parCommand) == 'string') this.command = parCommand;
|
||||
toCommand: function (parCommand) {
|
||||
if (parCommand && typeof (parCommand) == 'string') this.command = parCommand;
|
||||
var data = {
|
||||
command: this.command,
|
||||
serverName: serverName
|
||||
};
|
||||
if(this.command.length >= 1 || typeof(parCommand) == 'string') {
|
||||
if (this.command.length >= 1 || typeof (parCommand) == 'string') {
|
||||
WS.sendMsg('server/console/command', JSON.stringify(data));
|
||||
}
|
||||
this.command = '';
|
||||
},
|
||||
toProperties: function() {
|
||||
toProperties: function () {
|
||||
RES.redirectPage('./template/component/properties.html', 'server/properties', serverName);
|
||||
},
|
||||
toTerminal: function() {
|
||||
// RES.redirectPage('./template/component/console.html', 'server/console', this.oldServerName );
|
||||
toTerminal: function () {
|
||||
RES.redirectPage('./template/component/terminal.html', 'server/console', serverName);
|
||||
}
|
||||
},
|
||||
data: {
|
||||
// MinecraftConsoleBuff: 'Minecraft 控制台,您可以在这里实时监听到这个Minecraft服务器的内容:',
|
||||
command: "",
|
||||
allowedStart: true,
|
||||
runStatusClass: '',
|
||||
username : MCSERVER.username
|
||||
username: MCSERVER.username
|
||||
},
|
||||
watch: {
|
||||
run: function(cur, old) {
|
||||
//if(cur == true)this.toCommand('list')
|
||||
}
|
||||
run: function (cur, old) {}
|
||||
}
|
||||
});
|
||||
|
||||
PAGE.timerR = setInterval(function() {
|
||||
PAGE.timerR = setInterval(function () {
|
||||
WS.sendMsg('server/console', serverName);
|
||||
}, 2000);
|
||||
|
||||
@ -179,32 +177,31 @@
|
||||
var ChartCPU = null;
|
||||
var ChartRAM = null;
|
||||
PAGE.ChartLogIs = true;
|
||||
TOOLS.charts.bulider('ChartCPU', 16, {}, function(chart) {
|
||||
TOOLS.charts.bulider('ChartCPU', 16, {}, function (chart) {
|
||||
ChartCPU = chart;
|
||||
|
||||
function doing() {
|
||||
chart.replaceData(VIEW_MODEL['ConsolePanel'].CPUlog);
|
||||
//chart.pushData(getNowFormatDate(), GetRandomNum(1, 40));
|
||||
chart.reOption();
|
||||
if(PAGE.ChartLogIs) setTimeout(doing, 2000);
|
||||
if (PAGE.ChartLogIs) setTimeout(doing, 2000);
|
||||
}
|
||||
doing();
|
||||
}, CPUoption);
|
||||
//ChartRAM
|
||||
TOOLS.charts.bulider('ChartRAM', 16, {}, function(chart) {
|
||||
TOOLS.charts.bulider('ChartRAM', 16, {}, function (chart) {
|
||||
ChartRAM = chart;
|
||||
|
||||
function doing() {
|
||||
chart.replaceData(VIEW_MODEL['ConsolePanel'].RAMlog);
|
||||
//chart.pushData(getNowFormatDate(), GetRandomNum(1, 40));
|
||||
chart.reOption();
|
||||
if(PAGE.ChartLogIs) setTimeout(doing, 2000);
|
||||
if (PAGE.ChartLogIs) setTimeout(doing, 2000);
|
||||
}
|
||||
doing();
|
||||
}, CPUoption);
|
||||
|
||||
PAGE.chartResizeFunc = function() {
|
||||
console.log('图表改变')
|
||||
|
||||
PAGE.chartResizeFunc = function () {
|
||||
ChartCPU.chart.resize();
|
||||
ChartRAM.chart.resize();
|
||||
}
|
||||
@ -214,10 +211,7 @@
|
||||
|
||||
});
|
||||
|
||||
MI.rListener('onend', function() {
|
||||
console.log('页面关闭');
|
||||
// WS.sendMsg('server/console/remove', '');
|
||||
// PAGE[chartResizeFunc] = undefined;
|
||||
MI.rListener('onend', function () {
|
||||
MI.onDestroy('colmchangeEnd', PAGE.chartResizeFunc);
|
||||
MI.onDestroy('resize', PAGE.chartResizeFunc);
|
||||
PAGE.ChartLogIs = false;
|
||||
|
@ -71,7 +71,7 @@
|
||||
|
||||
<!--js-->
|
||||
<script>
|
||||
MI.rListener('onload', function() {
|
||||
MI.rListener('onload', function () {
|
||||
console.log('页面开始')
|
||||
MCSERVER.colmSet(false);
|
||||
new Vue({
|
||||
@ -82,11 +82,11 @@
|
||||
newPassword2: ''
|
||||
},
|
||||
methods: {
|
||||
toBack: function() {
|
||||
toBack: function () {
|
||||
RES.redirectPage('./template/gen_home.html', 'genuser/home', '');
|
||||
},
|
||||
toRePassword: function() {
|
||||
if(this.newPassword1 != this.newPassword2) {
|
||||
toRePassword: function () {
|
||||
if (this.newPassword1 != this.newPassword2) {
|
||||
TOOLS.pushMsgWindow('新密码与新的确认密码不一致');
|
||||
return;
|
||||
}
|
||||
@ -101,7 +101,7 @@
|
||||
});
|
||||
})
|
||||
|
||||
MI.rListener('onend', function() {
|
||||
MI.rListener('onend', function () {
|
||||
console.log('页面关闭')
|
||||
})
|
||||
</script>
|
@ -36,21 +36,21 @@
|
||||
<span class="input-group-addon">服务端文件根目录</span>
|
||||
<input type="text" class="form-control" v-model="cwd">
|
||||
<span class="input-group-btn">
|
||||
<button class="btn btn-success" v-on:click="toCreaterDir()"> 确认创建目录 </button>
|
||||
</span>
|
||||
<button class="btn btn-success" v-on:click="toCreaterDir()"> 确认创建目录 </button>
|
||||
</span>
|
||||
|
||||
</div>
|
||||
<p>[选填] 根据您的需求或计算机内存大小填写,默认自动,需要在数字后加单位</p>
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
<div class="input-group input-group-sm">
|
||||
<span class="input-group-addon"> 最大内存堆 </span>
|
||||
<span class="input-group-addon"> 最大内存堆 </span>
|
||||
<input type="text" class="form-control" v-model="Xmx">
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-sm-6">
|
||||
<div class="input-group input-group-sm">
|
||||
<span class="input-group-addon"> 初始内存堆 </span>
|
||||
<span class="input-group-addon"> 初始内存堆 </span>
|
||||
<input type="text" class="form-control" v-model="Xms">
|
||||
</div>
|
||||
</div>
|
||||
@ -86,12 +86,12 @@
|
||||
</div>
|
||||
|
||||
<script>
|
||||
MI.rListener('onload', function() {
|
||||
MI.rListener('onload', function () {
|
||||
console.log('页面开始')
|
||||
VIEW_MODEL.newVue('CreateServerView', {
|
||||
el: '#CreateServerView',
|
||||
data: {
|
||||
name: 'NewServer_' + ((Date.parse(new Date()) + "").substr( 6)),
|
||||
name: 'NewServer_' + ((Date.parse(new Date()) + "").substr(6)),
|
||||
jarName: '',
|
||||
cwd: '<默认标准位置>',
|
||||
Xmx: '',
|
||||
@ -100,7 +100,7 @@
|
||||
java: 'java'
|
||||
},
|
||||
methods: {
|
||||
toCreateServer: function() {
|
||||
toCreateServer: function () {
|
||||
var addCmdList = this.addCmd.split(' ');
|
||||
var obj = {
|
||||
addCmd: addCmdList,
|
||||
@ -112,10 +112,9 @@
|
||||
java: this.Java
|
||||
};
|
||||
WS.sendMsg('server/create', JSON.stringify(obj));
|
||||
// console.log(this.name)
|
||||
RES.redirectPage('./template/server.html', 'server/view');
|
||||
},
|
||||
toCreaterDir: function() {
|
||||
toCreaterDir: function () {
|
||||
var obj = {
|
||||
serverName: this.name,
|
||||
cwd: this.cwd
|
||||
@ -124,8 +123,8 @@
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
serverCwd: function() {
|
||||
if(this.cwd == '<默认标准位置>' || this.cwd == '') return './server/server_core/' + this.name;
|
||||
serverCwd: function () {
|
||||
if (this.cwd == '<默认标准位置>' || this.cwd == '') return './server/server_core/' + this.name;
|
||||
return this.cwd;
|
||||
}
|
||||
}
|
||||
@ -133,7 +132,7 @@
|
||||
|
||||
});
|
||||
|
||||
MI.rListener('onend', function() {
|
||||
MI.rListener('onend', function () {
|
||||
console.log('页面关闭')
|
||||
});
|
||||
</script>
|
@ -36,13 +36,13 @@
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
<div class="input-group input-group-sm">
|
||||
<span class="input-group-addon"> 最大内存堆 </span>
|
||||
<span class="input-group-addon"> 最大内存堆 </span>
|
||||
<input type="text" class="form-control" v-model="Xmx">
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-sm-6">
|
||||
<div class="input-group input-group-sm">
|
||||
<span class="input-group-addon"> 初始内存堆 </span>
|
||||
<span class="input-group-addon"> 初始内存堆 </span>
|
||||
<input type="text" class="form-control" v-model="Xms">
|
||||
</div>
|
||||
</div>
|
||||
@ -64,7 +64,8 @@
|
||||
<div class="PanelTitle">[必做] 第五步,移动你的服务端文件</div>
|
||||
<p>现在您只需要将您的服务端文件移到下面的 “服务端根目录”,这个目录是您刚刚创建或自定义的。</p>
|
||||
<p>如果您没有服务端文件,您可以下载: </p>
|
||||
<p><span style="color: #3278B3">服务端根目录:</span> “{{ serverCwd }}” </p>
|
||||
<p>
|
||||
<span style="color: #3278B3">服务端根目录:</span> “{{ serverCwd }}” </p>
|
||||
|
||||
<br>
|
||||
<div class="PanelTitle">[必填] 第六步,填写刚刚移动的服务端名字 (请记得加上后戳,如.jar)</div>
|
||||
@ -86,9 +87,7 @@
|
||||
</div>
|
||||
|
||||
<script>
|
||||
MI.rListener('onload', function() {
|
||||
//有木有发现一样的~ 好吧其实是生成的
|
||||
console.log('页面开始')
|
||||
MI.rListener('onload', function () {
|
||||
VIEW_MODEL.newVue('CreateServerViewx', {
|
||||
el: '#CreateServerViewx',
|
||||
data: {
|
||||
@ -101,7 +100,7 @@
|
||||
java: 'java'
|
||||
},
|
||||
methods: {
|
||||
toCreateServer: function() {
|
||||
toCreateServer: function () {
|
||||
var addCmdList = this.addCmd.split(' ');
|
||||
var obj = {
|
||||
addCmd: addCmdList,
|
||||
@ -116,7 +115,7 @@
|
||||
// console.log(this.name)
|
||||
RES.redirectPage('./template/server.html', 'server/view');
|
||||
},
|
||||
toCreaterDir: function() {
|
||||
toCreaterDir: function () {
|
||||
var obj = {
|
||||
serverName: this.name,
|
||||
cwd: this.cwd
|
||||
@ -125,8 +124,8 @@
|
||||
}
|
||||
},
|
||||
computed: {
|
||||
serverCwd: function() {
|
||||
if(this.cwd == '<默认标准位置>' || this.cwd == '') return '控制面板目录/server/server_core/' + this.name;
|
||||
serverCwd: function () {
|
||||
if (this.cwd == '<默认标准位置>' || this.cwd == '') return '控制面板目录/server/server_core/' + this.name;
|
||||
return this.cwd;
|
||||
}
|
||||
}
|
||||
@ -134,7 +133,5 @@
|
||||
|
||||
});
|
||||
|
||||
MI.rListener('onend', function() {
|
||||
console.log('页面关闭')
|
||||
});
|
||||
MI.rListener('onend', function () {});
|
||||
</script>
|
@ -71,7 +71,6 @@
|
||||
<script src="./common/js/properties.js"></script>
|
||||
<script>
|
||||
MI.rListener('onload', function () {
|
||||
console.log('页面开始');
|
||||
MCSERVER.autoColmDo();
|
||||
|
||||
VIEW_MODEL.newVue('ServerProperties', {
|
||||
@ -105,6 +104,5 @@
|
||||
|
||||
MI.rListener('onend', function () {
|
||||
VIEW_MODEL['ServerProperties'] = null;
|
||||
console.log('页面关闭')
|
||||
});
|
||||
</script>
|
@ -9,7 +9,9 @@
|
||||
<div class="col-md-12">
|
||||
<div class="PanelItem">标识名: {{ name }}</div>
|
||||
<div class="PanelItem">创建时间: {{ createDate }}</div>
|
||||
<div class="PanelItem" v-if="run">状况: <span class="color-green">正在运行</span></div>
|
||||
<div class="PanelItem" v-if="run">状况:
|
||||
<span class="color-green">正在运行</span>
|
||||
</div>
|
||||
<div class="PanelItem" v-else="run">状况: 未运行</div>
|
||||
<div class="PanelItem">最后启动: {{ lastDate }}</div>
|
||||
</div>
|
||||
@ -45,14 +47,14 @@
|
||||
</div>
|
||||
<div class="input-group input-group-sm">
|
||||
<span class="input-group-addon">服务器根目录</span>
|
||||
<input type="text" class="form-control" v-model="cwd">
|
||||
<input type="text" class="form-control" v-model="cwd">
|
||||
</div>
|
||||
<div class="input-group input-group-sm">
|
||||
<span class="input-group-addon"> 最大内存堆 </span>
|
||||
<span class="input-group-addon"> 最大内存堆 </span>
|
||||
<input v-bind:disabled="isHighCommande" type="text" class="form-control" v-model="Xmx" placeholder="<自动>">
|
||||
</div>
|
||||
<div class="input-group input-group-sm" >
|
||||
<span class="input-group-addon"> 初始内存堆 </span>
|
||||
<div class="input-group input-group-sm">
|
||||
<span class="input-group-addon"> 初始内存堆 </span>
|
||||
<input v-bind:disabled="isHighCommande" type="text" class="form-control" v-model="Xms" placeholder="<自动>">
|
||||
</div>
|
||||
</div>
|
||||
@ -66,9 +68,8 @@
|
||||
<li>一旦使用这个自定义参数,将会忽略您上面所设置的所有选项</li>
|
||||
<li>您设定的自定义启动参数依然会将服务端根目录作为工作目录来执行命令</li>
|
||||
<li>甚至可以运行 bash shell 或 cmd.exe 程序,谨慎设置</li>
|
||||
<li>列如: java -xxx -yyy Xmx4g Xms2g <span class="color-red">-Djline.terminal=jline.UnsupportedTerminal</span> -jar test.jar --xxx 这类高级需求</li>
|
||||
|
||||
|
||||
<li>列如: java -xxx -yyy Xmx4g Xms2g
|
||||
<span class="color-red">-Djline.terminal=jline.UnsupportedTerminal</span> -jar test.jar --xxx 这类高级需求</li>
|
||||
</ul>
|
||||
<div class="input-group input-group-sm">
|
||||
<span class="input-group-addon"> 自定义参数 </span>
|
||||
@ -104,21 +105,20 @@
|
||||
|
||||
</div>
|
||||
<script>
|
||||
MI.rListener('onload', function() {
|
||||
console.log('页面开始')
|
||||
MI.rListener('onload', function () {
|
||||
VIEW_MODEL.newVue('ServerPanel', {
|
||||
el: '#ServerPanel',
|
||||
data: {
|
||||
oldServerName: '',
|
||||
isHighCommande : false
|
||||
isHighCommande: false
|
||||
},
|
||||
methods: {
|
||||
toConsole: function(serverName) {
|
||||
toConsole: function (serverName) {
|
||||
RES.redirectPage('./template/component/console.html', 'server/console', this.oldServerName);
|
||||
},
|
||||
toRebulider: function() {
|
||||
toRebulider: function () {
|
||||
var addCmdList = this.addCmd.split(' ');
|
||||
if(this.oldServerName.trim() == '' || this.name.trim() == '') {
|
||||
if (this.oldServerName.trim() == '' || this.name.trim() == '') {
|
||||
TOOLS.pushMsgWindow("服务器唯一标识名不能为空,请取一个名字!");
|
||||
return;
|
||||
}
|
||||
@ -130,21 +130,20 @@
|
||||
Xmx: this.Xmx,
|
||||
Xms: this.Xms,
|
||||
java: this.java,
|
||||
highCommande : this.highCommande,
|
||||
highCommande: this.highCommande,
|
||||
oldServerName: this.oldServerName
|
||||
};
|
||||
WS.sendMsg('server/rebulider', JSON.stringify(obj));
|
||||
setTimeout(function() {
|
||||
setTimeout(function () {
|
||||
RES.redirectPage('./template/server.html', 'server/view');
|
||||
}, 100);
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
// 如果 question 发生改变,这个函数就会运行
|
||||
highCommande: function(newQuestion) {
|
||||
if(this.highCommande){
|
||||
highCommande: function (newQuestion) {
|
||||
if (this.highCommande) {
|
||||
this.isHighCommande = true;
|
||||
}else{
|
||||
} else {
|
||||
this.isHighCommande = false;
|
||||
}
|
||||
}
|
||||
@ -152,10 +151,8 @@
|
||||
});
|
||||
VIEW_MODEL['ServerPanel'].addCmd = VIEW_MODEL['ServerPanel'].addCmd.toString().replace(/,/gim, ' ');
|
||||
VIEW_MODEL['ServerPanel'].oldServerName = VIEW_MODEL['ServerPanel'].name + "";
|
||||
|
||||
|
||||
});
|
||||
|
||||
MI.rListener('onend', function() {
|
||||
console.log('页面关闭')
|
||||
});
|
||||
MI.rListener('onend', function () {});
|
||||
</script>
|
@ -23,23 +23,20 @@
|
||||
<!--<div id='' v-if="historyIf" v-on:click="loadHistory()">更多历史日志</div>-->
|
||||
<div class="" style="border-top: 1px solid #585858;">
|
||||
<!--<span class="glyphicon glyphicon-alert" aria-hidden="true"></span>-->
|
||||
<input id='TerminalCommand' @keyup.up="toCommandhi(1)" @keyup.down="toCommandhi(-1)" @keyup.enter="toCommand" v-model="command" type="text" class="TerminalCommand" placeholder="[命令输入框] 操作 ↑ 和 ↓ 可以查看历史命令记录,输入 help 或 ? 可以查看帮助信息." aria-describedby="sizing-addon3">
|
||||
<input id='TerminalCommand' @keyup.up="toCommandhi(1)" @keyup.down="toCommandhi(-1)" @keyup.enter="toCommand" v-model="command"
|
||||
type="text" class="TerminalCommand" placeholder="[命令输入框] 操作 ↑ 和 ↓ 可以查看历史命令记录,输入 help 或 ? 可以查看帮助信息." aria-describedby="sizing-addon3">
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
MI.rListener('onload', function() {
|
||||
|
||||
console.log('页面开始')
|
||||
MI.rListener('onload', function () {
|
||||
//默认隐藏控制台
|
||||
MCSERVER.colmSet(false);
|
||||
|
||||
PAGE.nowPage = 0; //当前最低页
|
||||
PAGE.serverName = MCSERVER.listenServername;
|
||||
|
||||
// var BUFF_BLOCK_SIZE = 70;
|
||||
|
||||
$('#MainContainer').css('background-color', 'rgb(60,60,60)');
|
||||
|
||||
WS.sendMsg('server/console/ws', PAGE.serverName);
|
||||
@ -47,7 +44,7 @@
|
||||
PAGE.TerminalMinecraft = $('#TerminalMinecraft');
|
||||
PAGE.TerminalMinecraft.css('height', (document.body.clientHeight - 50 - 45) + 'px')
|
||||
|
||||
PAGE.tmp_onresize = function() {
|
||||
PAGE.tmp_onresize = function () {
|
||||
console.log('改变 --- TerminalMinecraft')
|
||||
$('#TerminalMinecraft').css('height', (document.body.clientHeight - 50 - 45) + 'px');
|
||||
};
|
||||
@ -57,26 +54,26 @@
|
||||
VIEW_MODEL.newVue('Terminal', {
|
||||
el: '#Terminal',
|
||||
methods: {
|
||||
goBttom: function() {
|
||||
goBttom: function () {
|
||||
var ele = document.getElementById('TerminalMinecraft');
|
||||
ele.scrollTop = ele.scrollHeight;
|
||||
},
|
||||
loadHistory: function() {
|
||||
loadHistory: function () {
|
||||
console.log('loading');
|
||||
var obj = {};
|
||||
obj.serverName = PAGE.serverName;
|
||||
WS.sendMsg('server/console/history', JSON.stringify(obj));
|
||||
},
|
||||
toOpenServer: function() {
|
||||
toOpenServer: function () {
|
||||
WS.sendMsg('server/console/open', PAGE.serverName);
|
||||
},
|
||||
toCommand: function(parCommand) {
|
||||
if(parCommand && typeof(parCommand) == 'string') this.command = parCommand;
|
||||
toCommand: function (parCommand) {
|
||||
if (parCommand && typeof (parCommand) == 'string') this.command = parCommand;
|
||||
var data = {
|
||||
command: this.command,
|
||||
serverName: PAGE.serverName
|
||||
};
|
||||
if(this.command.length >= 1 || typeof(parCommand) == 'string') {
|
||||
if (this.command.length >= 1 || typeof (parCommand) == 'string') {
|
||||
//压入命令栈 并 发送
|
||||
this.commandList.unshift(this.command);
|
||||
WS.sendMsg('server/console/command', JSON.stringify(data));
|
||||
@ -85,15 +82,15 @@
|
||||
this.commandListPrint = 0;
|
||||
|
||||
},
|
||||
toCommandhi: function(fl) {
|
||||
if(this.commandListPrint > (this.commandList.length - 1)) this.commandListPrint = this.commandList.length - 1;
|
||||
if(this.commandListPrint < 0) this.commandListPrint = 0;
|
||||
toCommandhi: function (fl) {
|
||||
if (this.commandListPrint > (this.commandList.length - 1)) this.commandListPrint = this.commandList.length -
|
||||
1;
|
||||
if (this.commandListPrint < 0) this.commandListPrint = 0;
|
||||
console.log('commandListPrint', this.commandListPrint, 'vlaue', this.commandList[this.commandListPrint]);
|
||||
if(fl == 1) { //up
|
||||
if (fl == 1) { //up
|
||||
this.command = this.commandList[this.commandListPrint];
|
||||
this.commandListPrint++;
|
||||
} else { //down
|
||||
//console.log(11111111111111111111)
|
||||
this.command = this.commandList[this.commandListPrint];
|
||||
this.commandListPrint--;
|
||||
}
|
||||
@ -111,16 +108,16 @@
|
||||
});
|
||||
PAGE.mainC = document.getElementById('TerminalMinecraft');
|
||||
var jl = true;
|
||||
PAGE.mainC.onscroll = function() {
|
||||
PAGE.mainC.onscroll = function () {
|
||||
VIEW_MODEL['Terminal'].historyIf = (PAGE.mainC.scrollTop - 100 <= 0);
|
||||
}
|
||||
|
||||
PAGE.maskTerminalLoad = function() {
|
||||
if(PAGE.mainC.scrollTop - 300 <= 0 && jl == true) {
|
||||
PAGE.maskTerminalLoad = function () {
|
||||
if (PAGE.mainC.scrollTop - 300 <= 0 && jl == true) {
|
||||
jl = false;
|
||||
var obj = {};
|
||||
obj.serverName = PAGE.serverName;
|
||||
WS.sendMsg('server/console/history', JSON.stringify(obj), function() {
|
||||
WS.sendMsg('server/console/history', JSON.stringify(obj), function () {
|
||||
jl = true;
|
||||
});
|
||||
}
|
||||
@ -128,20 +125,20 @@
|
||||
}
|
||||
// setInterval(PAGE.maskTerminalLoad, 500);
|
||||
|
||||
PAGE.terminalLoad = function(callback) {
|
||||
PAGE.terminalLoad = function (callback) {
|
||||
jl = false;
|
||||
var obj = {};
|
||||
obj.serverName = PAGE.serverName;
|
||||
WS.sendMsg('server/console/history', JSON.stringify(obj), function() {
|
||||
WS.sendMsg('server/console/history', JSON.stringify(obj), function () {
|
||||
jl = true;
|
||||
callback && callback();
|
||||
});
|
||||
// $(this).css('display', 'none');
|
||||
}
|
||||
|
||||
PAGE.terminalLoad(function() {
|
||||
PAGE.terminalLoad(function () {
|
||||
//由于DOM插入时间不一定,所以此功能只能靠猜~
|
||||
setTimeout(function() {
|
||||
setTimeout(function () {
|
||||
$("#TerminalMinecraft")[0].scrollTop = $("#TerminalMinecraft")[0].scrollHeight;
|
||||
// console.log('fuck!!!!!!!!', $("#TerminalMinecraft")[0].scrollTop)
|
||||
}, 800);
|
||||
@ -152,10 +149,10 @@
|
||||
|
||||
});
|
||||
|
||||
MI.rListener('onend', function() {
|
||||
MI.rListener('onend', function () {
|
||||
console.log('页面关闭');
|
||||
WS.sendMsg('server/console/remove', '');
|
||||
PAGE.mainC.onscroll = function() {};
|
||||
PAGE.mainC.onscroll = function () {};
|
||||
|
||||
MI.onDestroy('resize', PAGE.tmp_onresize);
|
||||
// $('#MainContainer').css('background-color', 'rgb(220,218,218)');
|
||||
|
@ -14,14 +14,14 @@
|
||||
<div class="col-sm-5">
|
||||
<p>用户名 [字母 数字 下划线] (6~18位)</p>
|
||||
<div class="input-group input-group-sm">
|
||||
<span class="input-group-addon"> 用户名 </span>
|
||||
<span class="input-group-addon"> 用户名 </span>
|
||||
<input type="text" class="form-control" v-model="username">
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-sm-7">
|
||||
<p>密码 [字母 数字 下划线] (6~18位) 注意* 显示 “未更改” 代表不改动本身密码</p>
|
||||
<div class="input-group input-group-sm">
|
||||
<span class="input-group-addon"> 密码 </span>
|
||||
<span class="input-group-addon"> 密码 </span>
|
||||
<input type="text" class="form-control" v-model="password">
|
||||
</div>
|
||||
</div>
|
||||
@ -30,14 +30,16 @@
|
||||
<p>准许的服务器,输入服务器名字,分别以空格分割</p>
|
||||
<p>注意,如果是以#开头的最高权限账号,则可以无条件访问任何服务器</p>
|
||||
<div class="input-group input-group-sm">
|
||||
<span class="input-group-addon"> 准许的服务器 </span>
|
||||
<span class="input-group-addon"> 准许的服务器 </span>
|
||||
<input type="text" class="form-control" v-model="allowedServer">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
<br><br><br>
|
||||
<br>
|
||||
<br>
|
||||
<br>
|
||||
<p>您可以重新配置这个用户</p>
|
||||
<p>警告:修改用户名时请务必减少此类操作,如果当前用户在线的话,很有可能会导致意外的错误,因为用户已经使用原用户名登陆,请确保用户不在线的情况下修改用户名.</p>
|
||||
<div class="Line"></div>
|
||||
@ -52,34 +54,33 @@
|
||||
</div>
|
||||
|
||||
<script>
|
||||
MI.rListener('onload', function() {
|
||||
console.log('页面开始')
|
||||
MI.rListener('onload', function () {
|
||||
VIEW_MODEL.newVue('OneUserView', {
|
||||
el: '#OneUserView',
|
||||
data: {
|
||||
ServerLen: 0,
|
||||
password : '<未更改>',
|
||||
oldUsername : ''
|
||||
password: '<未更改>',
|
||||
oldUsername: ''
|
||||
},
|
||||
methods: {
|
||||
toUpdate : function(){
|
||||
toUpdate: function () {
|
||||
var allowedServers = this.allowedServer.trim().split(' ');
|
||||
var obj = {
|
||||
newUsername : this.username,
|
||||
newPassword : this.password,
|
||||
allowedServer : allowedServers,
|
||||
username : this.oldUsername
|
||||
newUsername: this.username,
|
||||
newPassword: this.password,
|
||||
allowedServer: allowedServers,
|
||||
username: this.oldUsername
|
||||
}
|
||||
WS.sendMsg('userset/upinfo', JSON.stringify(obj));
|
||||
//返回到上层
|
||||
RES.redirectPage('./template/userset.html','userset/update');
|
||||
RES.redirectPage('./template/userset.html', 'userset/update');
|
||||
},
|
||||
toDeleteUser:function(itemUsername){
|
||||
var obj ={
|
||||
username : this.oldUsername
|
||||
toDeleteUser: function (itemUsername) {
|
||||
var obj = {
|
||||
username: this.oldUsername
|
||||
};
|
||||
WS.sendMsg('userset/delete',JSON.stringify(obj),function(){
|
||||
RES.redirectPage('./template/userset.html','userset/update');
|
||||
WS.sendMsg('userset/delete', JSON.stringify(obj), function () {
|
||||
RES.redirectPage('./template/userset.html', 'userset/update');
|
||||
});
|
||||
}
|
||||
},
|
||||
@ -91,7 +92,5 @@
|
||||
viewModel.allowedServer = viewModel.allowedServer.toString().replace(/,/gim, ' ');
|
||||
});
|
||||
|
||||
MI.rListener('onend', function() {
|
||||
console.log('页面关闭')
|
||||
});
|
||||
MI.rListener('onend', function () {});
|
||||
</script>
|
@ -8,11 +8,12 @@
|
||||
<br>
|
||||
<p>邮箱: Suwings@outlook.com</p>
|
||||
<p>平台:
|
||||
<a target="_blank" href="https://wj.qq.com/s/1494129/b8b5">调查问卷</a>
|
||||
<a target="_blank" href="https://wj.qq.com/s/1494129/b8b5">调查问卷</a>
|
||||
</p>
|
||||
<br>
|
||||
<p>我们将快速更新,加快版本更新周期。</p>
|
||||
<br><br>
|
||||
<br>
|
||||
<br>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -24,13 +25,13 @@
|
||||
<p>当然您也可以不资助资金帮助我们,为我们的宣传资料提供支持.</p>
|
||||
<br>
|
||||
<p>资助唯一支付宝二维码:
|
||||
<a target="_blank" href="template/other/sponsor.html">二维码地址</a>
|
||||
<a target="_blank" href="template/other/sponsor.html">二维码地址</a>
|
||||
</p>
|
||||
<p>Mcbbs.net 宣传贴:
|
||||
<a target="_blank" href="http://www.mcbbs.net/thread-140678-1-1.html">http://www.mcbbs.net/thread-140678-1-1.html</a>
|
||||
<a target="_blank" href="http://www.mcbbs.net/thread-140678-1-1.html">http://www.mcbbs.net/thread-140678-1-1.html</a>
|
||||
</p>
|
||||
<p>Zuimc.com 宣传贴:
|
||||
<a target="_blank" href="http://www.zuimc.com/thread-52079-1-2.html">http://www.zuimc.com/thread-52079-1-2.html</a>
|
||||
<a target="_blank" href="http://www.zuimc.com/thread-52079-1-2.html">http://www.zuimc.com/thread-52079-1-2.html</a>
|
||||
</p>
|
||||
<p>我们欢迎您转载本软件,使用次数越高,便越有可能更早的更新后续版本.</p>
|
||||
</div>
|
||||
@ -42,11 +43,13 @@
|
||||
<div class="Panel PanelRed">
|
||||
<div class="PanelTitle">源代码开放协议</div>
|
||||
<div class="PanelBody">
|
||||
<p>本项目完全开源: <a href="https://github.com/Suwings/MCSManager" target="_blank">https://github.com/Suwings/MCSManager </a></p>
|
||||
<p>本项目完全开源:
|
||||
<a href="https://github.com/Suwings/MCSManager" target="_blank">https://github.com/Suwings/MCSManager </a>
|
||||
</p>
|
||||
<p>欢迎参观,欢迎 pull request , issues,或 star</p>
|
||||
<small>开源协议: GNU Affero General Public License v3.0</small>
|
||||
<br>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -55,12 +58,9 @@
|
||||
|
||||
</div>
|
||||
<script>
|
||||
MI.rListener('onload', function() {
|
||||
console.log('页面开始')
|
||||
MI.rListener('onload', function () {
|
||||
|
||||
})
|
||||
|
||||
MI.rListener('onend', function() {
|
||||
console.log('页面关闭')
|
||||
})
|
||||
MI.rListener('onend', function () {})
|
||||
</script>
|
@ -24,14 +24,11 @@
|
||||
|
||||
</div>
|
||||
<script>
|
||||
MI.rListener('onload', function() {
|
||||
console.log('页面开始')
|
||||
//自動調整菜單
|
||||
MI.rListener('onload', function () {
|
||||
//自動調整菜單
|
||||
MCSERVER.autoColmDo();
|
||||
|
||||
})
|
||||
|
||||
MI.rListener('onend', function() {
|
||||
console.log('页面关闭')
|
||||
})
|
||||
MI.rListener('onend', function () {})
|
||||
</script>
|
@ -50,7 +50,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -64,11 +64,15 @@
|
||||
<div class="row">
|
||||
<div class="col-md-7">
|
||||
<div class="PanelItemInfo">
|
||||
<h4><span v-text="item.serverName"></span > | <span v-text="item.jarName"></span ></h4> 状态:
|
||||
<span v-if="item.run" class="color-green"> 正在运行 </span>
|
||||
<span v-else="item.run" class="color-red"> 关闭 </span>
|
||||
<h4>
|
||||
<span v-text="item.serverName"></span> |
|
||||
<span v-text="item.jarName"></span>
|
||||
</h4> 状态:
|
||||
<span v-if="item.run" class="color-green"> 正在运行 </span>
|
||||
<span v-else="item.run" class="color-red"> 关闭 </span>
|
||||
<!-- <br>创建时间 :<span v-text="item.createDate"></span>-->
|
||||
<br>最后启动:<span v-text="item.lastDate"></span>
|
||||
<br>最后启动:
|
||||
<span v-text="item.lastDate"></span>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@ -91,24 +95,23 @@
|
||||
|
||||
<!--js-->
|
||||
<script>
|
||||
MI.rListener('onload', function() {
|
||||
MI.rListener('onload', function () {
|
||||
console.log('页面开始')
|
||||
MCSERVER.colmSet(false);
|
||||
VIEW_MODEL.newVue('GenHome', {
|
||||
el: '#GenHome',
|
||||
methods: {
|
||||
toConsole: function(serverName) {
|
||||
//onRedirect('./template/component/console.html', 'server/console', item.serverName );
|
||||
toConsole: function (serverName) {
|
||||
RES.redirectPage('./template/component/console.html', 'server/console', serverName);
|
||||
},
|
||||
toRePassword : function(){
|
||||
toRePassword: function () {
|
||||
RES.redirectPage('./template/component/gen_repassword.html');
|
||||
}
|
||||
}
|
||||
});
|
||||
})
|
||||
|
||||
MI.rListener('onend', function() {
|
||||
MI.rListener('onend', function () {
|
||||
console.log('页面关闭')
|
||||
})
|
||||
</script>
|
@ -1,31 +1,11 @@
|
||||
<div id='IndexApp'>
|
||||
<div class="OneContainer">
|
||||
<!--<div class="row">
|
||||
<div class="col-xs-12">
|
||||
<div class="Panel PanelBlue">
|
||||
<div class="PanelTitle">Mcserver 控制面板信息</div>
|
||||
<div class="PanelBody">
|
||||
<small>如果您使用中遇到任何问题或发现BUG错误,您可以反馈给我们:</small>
|
||||
<br><br>
|
||||
<a class="Link" href="/">技术问题基本解答</a> |
|
||||
<a class="Link" href="/">反馈问题</a>
|
||||
<br><br>
|
||||
<small>或者您想做一些其他的:</small>
|
||||
<br><br>
|
||||
<a class="Link" href="/">访问官方站点</a> |
|
||||
<a class="Link" href="/">加入QQ群</a> |
|
||||
<a class="Link" href="/">后期版本的开发</a>
|
||||
<br><br>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>-->
|
||||
<div class="row">
|
||||
<div id='News' class="col-md-6">
|
||||
<div class="Panel PanelGreen">
|
||||
<div class="PanelTitle">最新动态与 BUG 通知</div>
|
||||
<div class="PanelBody">
|
||||
<p>关注这里,如果出现BUG/新版本我们会立即通告 (面板重启获取一次)</p>
|
||||
<p>关注这里,如果出现BUG/新版本我们会立即通告 (面板重启时自动更新)</p>
|
||||
<div class="news" v-for="item of items">
|
||||
<p class="color-gray" v-text="item.time"></p>
|
||||
<p v-text="item.msg"></p>
|
||||
@ -37,18 +17,24 @@
|
||||
<div class="Panel PanelGreen">
|
||||
<div class="PanelTitle">当前版本</div>
|
||||
<div class="PanelBody">
|
||||
<p>当前版本号: <span class="color-gray">8.1.0.0</span></p>
|
||||
<p>当前版本号:
|
||||
<span class="color-gray">8.1.0.0</span>
|
||||
</p>
|
||||
<br>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="Panel PanelGreen">
|
||||
<div class="PanelTitle">操作系统</div>
|
||||
<div class="PanelBody">
|
||||
<div id="SystemUp">
|
||||
<p>平台: <span class="color-gray" v-text="system"></span></p>
|
||||
<p>进程根目录: <span class="color-gray" v-text="root"></span></p>
|
||||
<br>
|
||||
<p>平台:
|
||||
<span class="color-gray" v-text="system"></span>
|
||||
</p>
|
||||
<p>进程根目录:
|
||||
<span class="color-gray" v-text="root"></span>
|
||||
</p>
|
||||
<br>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -60,7 +46,7 @@
|
||||
<p>3.不准出售本软件,但可以用于合法的商业用途。</p>
|
||||
<p>4.注意,不要在 64 位系统上运行 32 位的控制面板,否则无法正确启动服务器</p>
|
||||
<br>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -70,14 +56,12 @@
|
||||
|
||||
</div>
|
||||
<script>
|
||||
MI.rListener('onload', function() {
|
||||
MI.rListener('onload', function () {
|
||||
console.log('页面开始')
|
||||
RES.ajax({
|
||||
type: 'GET',
|
||||
///public/news.json
|
||||
url: './public/news.json',
|
||||
// url: 'http://mcservermanager.oss-cn-beijing.aliyuncs.com/news.json',
|
||||
success: function(data) {
|
||||
success: function (data) {
|
||||
VIEW_MODEL['News'] = data;
|
||||
console.log(data)
|
||||
VIEW_MODEL.newVue('News', {
|
||||
@ -91,7 +75,7 @@
|
||||
});
|
||||
})
|
||||
|
||||
MI.rListener('onend', function() {
|
||||
MI.rListener('onend', function () {
|
||||
console.log('页面关闭')
|
||||
})
|
||||
</script>
|
@ -1,21 +1,26 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>支持开发团队</title>
|
||||
<style>
|
||||
html,body{
|
||||
margin: 0;padding: 0;
|
||||
height: 100%;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div style="margin-bottom: 8px; background-color: #0D6AAD;height: 60px;line-height: 60px;font-size: 18px;color: white;padding-left: 8px;">
|
||||
支持开发团队
|
||||
</div>
|
||||
<div style="overflow: scroll;word-break: break-word;text-align: center;">
|
||||
<img src="../../common/get_alipay.png" />
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<title>支持开发团队</title>
|
||||
<style>
|
||||
html,
|
||||
body {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
height: 100%;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div style="margin-bottom: 8px; background-color: #0D6AAD;height: 60px;line-height: 60px;font-size: 18px;color: white;padding-left: 8px;">
|
||||
支持开发团队
|
||||
</div>
|
||||
<div style="overflow: scroll;word-break: break-word;text-align: center;">
|
||||
<img src="../../common/get_alipay.png" />
|
||||
</div>
|
||||
</body>
|
||||
|
||||
</html>
|
@ -14,35 +14,42 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="PanelItem" v-for="item of items">
|
||||
<div class="row">
|
||||
<div class="col-md-7">
|
||||
<div class="PanelItemInfo">
|
||||
<h4 v-if="item.data.jarName == '' && !item.data.highCommande "><span class="color-high-red">[未配置端] </span><s v-text="item.serverName"></s></h4>
|
||||
<h4 v-if="item.data.highCommande"><span class="color-green">[自定义参数]</span><span v-text="item.serverName"></span></h4>
|
||||
<h4 v-if="item.data.jarName == '' && !item.data.highCommande ">
|
||||
<span class="color-high-red">[未配置端] </span>
|
||||
<s v-text="item.serverName"></s>
|
||||
</h4>
|
||||
<h4 v-if="item.data.highCommande">
|
||||
<span class="color-green">[自定义参数]</span>
|
||||
<span v-text="item.serverName"></span>
|
||||
</h4>
|
||||
<h4 v-if="item.data.jarName != '' && !item.data.highCommande" v-text="item.serverName"></h4>
|
||||
状态:
|
||||
<span v-if="item.data.run" class="color-green"> 正在运行 </span>
|
||||
<span v-else="item.data.run" class="color-red"> 关闭 </span> | 创建时间 :<span v-text="item.data.createDate"> </span> | 最后启动:
|
||||
<span v-text="item.data.lastDate"> </span> | 端: <span v-text="item.data.jarName"> </span >
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-5 NextCol">
|
||||
<div class="PanelItemMuem">
|
||||
<!--<button class="btn btn-success">开启</button>
|
||||
<button class="btn btn-success">关闭</button>-->
|
||||
<button class="btn btn-success" v-on:click="onRedirect('./template/component/server.html','server/get',item.serverName)">
|
||||
参数 | 配置
|
||||
</button>
|
||||
<button class="btn btn-info" v-on:click="onRedirect('./template/component/console.html', 'server/console', item.serverName );">
|
||||
控制 | 管理
|
||||
</button>
|
||||
<button class="btn btn-danger" v-on:click="toDeleteServer(item.serverName)">删除</button>
|
||||
|
||||
</div>
|
||||
<span v-if="item.data.run" class="color-green"> 正在运行 </span>
|
||||
<span v-else="item.data.run" class="color-red"> 关闭 </span> | 创建时间 :
|
||||
<span v-text="item.data.createDate"> </span> | 最后启动:
|
||||
<span v-text="item.data.lastDate"> </span> | 端:
|
||||
<span v-text="item.data.jarName"> </span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-5 NextCol">
|
||||
<div class="PanelItemMuem">
|
||||
<!--<button class="btn btn-success">开启</button>
|
||||
<button class="btn btn-success">关闭</button>-->
|
||||
<button class="btn btn-success" v-on:click="onRedirect('./template/component/server.html','server/get',item.serverName)">
|
||||
参数 | 配置
|
||||
</button>
|
||||
<button class="btn btn-info" v-on:click="onRedirect('./template/component/console.html', 'server/console', item.serverName );">
|
||||
控制 | 管理
|
||||
</button>
|
||||
<button class="btn btn-danger" v-on:click="toDeleteServer(item.serverName)">删除</button>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -51,33 +58,28 @@
|
||||
</div>
|
||||
|
||||
<script>
|
||||
MI.rListener('onload', function() {
|
||||
console.log('页面开始')
|
||||
MI.rListener('onload', function () {
|
||||
VIEW_MODEL.newVue('ServerList', {
|
||||
el: '#ServerList',
|
||||
methods: {
|
||||
onRedirect: function(link, api,serverName) {
|
||||
onRedirect: function (link, api, serverName) {
|
||||
RES.redirectPage(link, api, serverName);
|
||||
},
|
||||
newServer:function(){
|
||||
newServer: function () {
|
||||
RES.redirectPage('./template/component/newserver.html', null, '');
|
||||
},
|
||||
newServerx:function(){
|
||||
newServerx: function () {
|
||||
RES.redirectPage('./template/component/newserverx.html', null, '');
|
||||
},
|
||||
toDeleteServer :function(serverName){
|
||||
//删除服务器
|
||||
console.log('删除服务器:' + serverName);
|
||||
var result = confirm('是否删除 ['+serverName+'] 这个服务端?\n注意: 删除服务器并不会删除服务端文件');
|
||||
if(!result)return;
|
||||
WS.sendMsg('server/delete',serverName);
|
||||
toDeleteServer: function (serverName) {
|
||||
var result = confirm('是否删除 [' + serverName + '] 这个服务端?\n注意: 删除服务器并不会删除服务端文件');
|
||||
if (!result) return;
|
||||
WS.sendMsg('server/delete', serverName);
|
||||
RES.redirectPage('./template/server.html', 'server/view');
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
MI.rListener('onend', function() {
|
||||
console.log('页面关闭')
|
||||
});
|
||||
MI.rListener('onend', function () {});
|
||||
</script>
|
@ -44,8 +44,7 @@
|
||||
</div>
|
||||
|
||||
<script>
|
||||
MI.rListener('onload', function() {
|
||||
console.log('页面开始')
|
||||
MI.rListener('onload', function () {
|
||||
//自動調整菜單
|
||||
MCSERVER.autoColmDo();
|
||||
|
||||
@ -55,11 +54,11 @@
|
||||
|
||||
},
|
||||
methods: {
|
||||
toUpdateProperties: function() {
|
||||
if(!this.softConfig) return;
|
||||
toUpdateProperties: function () {
|
||||
if (!this.softConfig) return;
|
||||
WS.sendMsg('soft/update', JSON.stringify(this.softConfig));
|
||||
},
|
||||
findKey: function(key) {
|
||||
findKey: function (key) {
|
||||
var SuwingsLoveYou = {
|
||||
"__filename__": "控制面板内部使用,请勿改动",
|
||||
'port': '控制面板程序端口号(务必进行更改)',
|
||||
@ -73,7 +72,5 @@
|
||||
});
|
||||
});
|
||||
|
||||
MI.rListener('onend', function() {
|
||||
console.log('页面关闭')
|
||||
});
|
||||
MI.rListener('onend', function () {});
|
||||
</script>
|
@ -23,7 +23,9 @@
|
||||
<div class="PanelItemInfo">
|
||||
<h4 v-text="item.username"></h4>
|
||||
<div>
|
||||
创建时间: <span v-text="item.data.createDate"> </span> | 最后上线: <span v-text="item.data.lastDate"> </span>
|
||||
创建时间:
|
||||
<span v-text="item.data.createDate"> </span> | 最后上线:
|
||||
<span v-text="item.data.lastDate"> </span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -62,7 +64,7 @@
|
||||
<div class="col-sm-6">
|
||||
<p>用户名 [字母 数字 下划线] (6~18位)</p>
|
||||
<div class="input-group input-group-sm">
|
||||
<span class="input-group-addon"> 用户名 </span>
|
||||
<span class="input-group-addon"> 用户名 </span>
|
||||
<input type="text" class="form-control" v-model="username">
|
||||
</div>
|
||||
</div>
|
||||
@ -76,7 +78,7 @@
|
||||
</div>
|
||||
<p>准许的服务器,输入服务器名字,分别以空格分割</p>
|
||||
<div class="input-group input-group-sm">
|
||||
<span class="input-group-addon"> 准许的服务器 </span>
|
||||
<span class="input-group-addon"> 准许的服务器 </span>
|
||||
<input type="text" class="form-control" v-model="allowedServer">
|
||||
</div>
|
||||
<div class="row">
|
||||
@ -96,8 +98,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
MI.rListener('onload', function() {
|
||||
console.log('页面开始')
|
||||
MI.rListener('onload', function () {
|
||||
VIEW_MODEL.newVue('UsersetList', {
|
||||
el: '#UsersetList',
|
||||
data: {
|
||||
@ -107,7 +108,7 @@
|
||||
allowedServer: ''
|
||||
},
|
||||
methods: {
|
||||
toRegisterUser: function() {
|
||||
toRegisterUser: function () {
|
||||
var allwoedServers = this.allowedServer.trim().split(' ');
|
||||
|
||||
var obj = {
|
||||
@ -115,41 +116,39 @@
|
||||
password: this.password,
|
||||
allowedServer: allwoedServers
|
||||
};
|
||||
WS.sendMsg('userset/create', JSON.stringify(obj), function() {
|
||||
WS.sendMsg('userset/create', JSON.stringify(obj), function () {
|
||||
PAGE.refresh();
|
||||
});
|
||||
},
|
||||
|
||||
toDeleteUser: function(itemUsername) {
|
||||
toDeleteUser: function (itemUsername) {
|
||||
var obj = {
|
||||
username: itemUsername
|
||||
};
|
||||
var result = confirm('您真的打算删除这个这个用户吗?');
|
||||
if(!result)return;
|
||||
WS.sendMsg('userset/delete', JSON.stringify(obj), function() {
|
||||
if (!result) return;
|
||||
WS.sendMsg('userset/delete', JSON.stringify(obj), function () {
|
||||
PAGE.refresh();
|
||||
});
|
||||
|
||||
},
|
||||
refresh: function() {
|
||||
refresh: function () {
|
||||
PAGE.refresh();
|
||||
TOOLS.pushMsgWindow('刷新完毕√')
|
||||
},
|
||||
|
||||
reloadUser: function() {
|
||||
WS.sendMsg('userset/reload', '', function() {
|
||||
reloadUser: function () {
|
||||
WS.sendMsg('userset/reload', '', function () {
|
||||
PAGE.refresh();
|
||||
});
|
||||
},
|
||||
|
||||
toUserView: function(_username) {
|
||||
toUserView: function (_username) {
|
||||
RES.redirectPage('./template/component/user.html', 'userset/view', _username);
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
MI.rListener('onend', function() {
|
||||
console.log('页面关闭')
|
||||
});
|
||||
MI.rListener('onend', function () {});
|
||||
</script>
|
Loading…
x
Reference in New Issue
Block a user