打开窗口

This commit is contained in:
jiangzeyin 2018-09-30 15:25:55 +08:00
parent 5becfa4e7d
commit b3917919b4
4 changed files with 6 additions and 8 deletions

View File

@ -47,7 +47,7 @@ public class BuildController extends BaseController {
}
@RequestMapping(value = "build_download", method = RequestMethod.GET, produces = MediaType.APPLICATION_JSON_UTF8_VALUE)
public String build_download(String id, String key) {
public String buildDownload(String id, String key) {
try {
ProjectInfoModel projectInfoModel = manageService.getProjectInfo(id);
if (projectInfoModel == null) {

View File

@ -16,9 +16,9 @@
function tabChange(options) {
var element = top.layui.element;
var lay_id = 'tab_' + options.id;
var lay_id = 'tab_' + options.id + options.title;
// 如果存在选项卡,切换,否则创建
if ($('[lay-id="tab_' + options.id + '"]').length > 0) {
if ($('[lay-id="' + lay_id + '"]', top.document).length > 0) {
element.tabChange('mainTabs', lay_id);
} else {
// 创建

View File

@ -30,10 +30,10 @@
<td>$item.size</td>
<td>
<button name="install" data-name="$item.shortKey" data-key="$item.key" data-id="$id"
class="layui-btn layui-btn-normal layui-btn-sm">安装
class="layui-btn layui-btn-danger layui-btn-sm">安装
</button>
<a name="download" href="build_download?key=$item.key&id=$id"
class="layui-btn layui-btn-normal layui-btn-sm">下载
class="layui-btn layui-btn-warm layui-btn-sm">下载
</a>
</td>
</tr>

View File

@ -62,7 +62,6 @@
}
});
// '刷新表格'点击事件
$('#refresh').on('click', function () {
reloadTable();
@ -180,7 +179,7 @@
area: ['80%', '90%'],
content: 'build?id=' + data.id
});
}else if ('ram' === event) {
} else if ('ram' === event) {
layer.open({
type: 2,
title: '内存',
@ -195,7 +194,6 @@
function fileManage(data) {
var lay_id = 'tab_file_' + data.id;
var url = '/file/filemanage?id=' + data.id;
tabChange({
id: data.id,
url: url,