修改 - 前端页面移植

This commit is contained in:
suwings 2018-04-26 10:48:20 +08:00
parent 12478a7d9f
commit 364e02f265
6 changed files with 75 additions and 107 deletions

View File

@ -1,8 +1,3 @@
const {
WebSocketObserver
} = require('../../model/WebSocketModel');
const response = require('../../helper/Response');
const permssion = require('../../helper/Permission');
const os = require("os");
//前端显示版本

View File

@ -18,11 +18,6 @@
//管理员的
//注意,这些页面只能管理员访问,普通用户就算访问,也得不到任何数据
MCSERVER.meumObject.masterMeum = [{
class: 'glyphicon-home',
name: '控制面板情报',
link: './template/index.html',
api: 'index/update'
}, {
class: 'glyphicon-equalizer',
name: '监控数据中心',
link: './template/center.html',
@ -44,7 +39,7 @@
api: 'soft/view'
}, {
class: 'glyphicon-floppy-open',
name: '客户支持',
name: '服务与支持',
link: './template/feelback.html',
api: null
}]

View File

@ -210,7 +210,7 @@
//判断是否是#权限用户,请放心,后端也会给予判断并不只是前端
if (MCSERVER.username.substr(0, 1) == '#') {
RES.redirectPage('./template/index.html', 'index/update', '--- 更新页面 ---');
RES.redirectPage('./template/center.html', 'center/show', '--- 更新页面 ---');
} else {
RES.redirectPage('./template/gen_home.html', 'genuser/home', '--- 更新页面 ---');
}

View File

@ -135,7 +135,48 @@
</div>
</div>
</div>
<div class="row">
<div class="col-md-6 ">
<div class="Panel PanelGreen">
<div class="PanelTitle">版本</div>
<div class="PanelBody">
<div id="VersionShow">
<p>程序版本:
<span class="color-gray">8.3</span>
</p>
<p>前端发行版:
<span class="color-gray">
<span class="color-gray" v-text="oneversion"></span>
</span>
</p>
<p>后端发行版:
<span class="color-gray">
<span class="color-gray" v-text="twoversion"></span>
</span>
</p>
<br>
</div>
</div>
</div>
</div>
<div class="col-md-6 ">
<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>
</div>
</div>
</div>
</div>
</div>
</div>
<script>

View File

@ -1,5 +1,17 @@
<div id='' class="OneContainer">
<div class="row">
<div id='News' class="col-md-6">
<div class="Panel PanelGreen">
<div class="PanelTitle">最新动态与信息通知</div>
<div class="PanelBody">
<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>
</div>
</div>
</div>
</div>
<div class="col-sm-6">
<div class="Panel PanelGreen">
<div class="PanelTitle">客户使用反馈</div>
@ -11,9 +23,10 @@
<a target="_blank" href="https://wj.qq.com/s/1494129/b8b5">调查问卷</a>
</p>
<br>
<p>我们将快速更新,加快版本更新周期</p>
<br>
<p>我们将逐步稳定更新,减少或不更改核心模块</p>
<br>
</div>
</div>
</div>
@ -37,8 +50,6 @@
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-sm-6">
<div class="Panel PanelRed">
<div class="PanelTitle">源代码开放协议</div>
@ -54,12 +65,29 @@
</div>
</div>
</div>
</div>
</div>
<script>
MI.rListener('onload', function () {
//请求早已缓存的 最新动态
RES.ajax({
type: 'GET',
url: './public/news.json',
success: function (data) {
VIEW_MODEL['News'] = data;
VIEW_MODEL.newVue('News', {
el: '#News',
});
MI.routeCopy('News', data);
VIEW_MODEL.newVue('SystemUp', {
el: '#SystemUp'
});
}
});
})
MI.rListener('onend', function () {})

View File

@ -1,91 +0,0 @@
<div id='IndexApp'>
<div class="OneContainer">
<div class="row">
<div id='News' class="col-md-6">
<div class="Panel PanelGreen">
<div class="PanelTitle">最新动态与信息通知</div>
<div class="PanelBody">
<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>
</div>
</div>
</div>
</div>
<div class="col-md-6 NextCol">
<div class="Panel PanelGreen">
<div class="PanelTitle">版本</div>
<div class="PanelBody">
<div id="VersionShow">
<p>程序版本:
<span class="color-gray">8.2</span>
</p>
<p>前端发行版:
<span class="color-gray">
<span class="color-gray" v-text="oneversion"></span>
</span>
</p>
<p>后端发行版:
<span class="color-gray">
<span class="color-gray" v-text="twoversion"></span>
</span>
</p>
<br>
</div>
</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>
</div>
</div>
</div>
<div class="Panel PanelRed">
<div class="PanelTitle">本程序版权与相关协议声明</div>
<div class="PanelBody">
<p>1.软件为开源自由软件,您可以进行任何修改和增删,自定义化设计。</p>
<p>2.当您使用控制台开启 Minecraft 服务器时,则代表您遵守 Minecraft 相关协议和 EULA 协议。</p>
<br>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<script>
MI.rListener('onload', function () {
//版本显示组件
VIEW_MODEL.newVue('VersionShow', {
el: '#VersionShow'
});
//请求早已缓存的 最新动态
RES.ajax({
type: 'GET',
url: './public/news.json',
success: function (data) {
VIEW_MODEL['News'] = data;
VIEW_MODEL.newVue('News', {
el: '#News',
});
MI.routeCopy('News', data);
VIEW_MODEL.newVue('SystemUp', {
el: '#SystemUp'
});
}
});
})
MI.rListener('onend', function () {})
</script>