mirror of
				https://github.com/TeaOSLab/EdgeAdmin.git
				synced 2025-11-04 05:00:25 +08:00 
			
		
		
		
	数据库手动清理页面增加按表名和按占用空间排序/优化数据库相关界面
This commit is contained in:
		@@ -1,9 +1,10 @@
 | 
			
		||||
<first-menu>
 | 
			
		||||
	<menu-item href="/settings/database" code="index">详情</menu-item>
 | 
			
		||||
	<menu-item href="/settings/database/update" code="update">修改</menu-item>
 | 
			
		||||
	<menu-item href="/settings/database" code="index">配置模板</menu-item>
 | 
			
		||||
	<menu-item href="/settings/database/update" code="update">修改模板</menu-item>
 | 
			
		||||
    <span class="item disabled">|</span>
 | 
			
		||||
    <menu-item href="/settings/database/clean" code="clean">手动清理</menu-item>
 | 
			
		||||
    <menu-item href="/settings/database/cleanSetting" code="cleanSetting">自动清理设置</menu-item>
 | 
			
		||||
    <span class="item">|</span>
 | 
			
		||||
    <span class="item disabled">|</span>
 | 
			
		||||
    <span class="item"><tip-icon content="在这里可以设置API节点可以使用的数据库,修改后请重新配置并启动API节点才能生效。"></tip-icon></span>
 | 
			
		||||
</first-menu>
 | 
			
		||||
<div class="margin"></div>
 | 
			
		||||
@@ -3,11 +3,15 @@
 | 
			
		||||
 | 
			
		||||
<div class="ui message" v-if="isLoading">正在加载中...</div>
 | 
			
		||||
 | 
			
		||||
<table class="ui table selectable">
 | 
			
		||||
<div class="ui message small warning" v-if="tables.length > 0">
 | 
			
		||||
    <p>请确认数据表用途后再执行相关操作。</p>
 | 
			
		||||
</div>
 | 
			
		||||
 | 
			
		||||
<table class="ui table selectable" v-if="tables.length > 0">
 | 
			
		||||
    <thead>
 | 
			
		||||
        <tr>
 | 
			
		||||
            <th>表名</th>
 | 
			
		||||
            <th>占用空间</th>
 | 
			
		||||
            <th>数据表名<sort-arrow name="orderTable"></sort-arrow></th>
 | 
			
		||||
            <th>占用空间<sort-arrow name="orderSize"></sort-arrow></th>
 | 
			
		||||
            <th>用途</th>
 | 
			
		||||
            <th class="two op">操作</th>
 | 
			
		||||
        </tr>
 | 
			
		||||
 
 | 
			
		||||
@@ -9,6 +9,10 @@ Tea.context(function () {
 | 
			
		||||
    this.reload = function () {
 | 
			
		||||
        this.isLoading = true
 | 
			
		||||
        this.$post("$")
 | 
			
		||||
			.params({
 | 
			
		||||
				orderTable: this.orderTable,
 | 
			
		||||
				orderSize: this.orderSize
 | 
			
		||||
			})
 | 
			
		||||
            .success(function (resp) {
 | 
			
		||||
                this.tables = resp.data.tables;
 | 
			
		||||
            })
 | 
			
		||||
 
 | 
			
		||||
@@ -1,6 +1,10 @@
 | 
			
		||||
{$layout}
 | 
			
		||||
{$template "menu"}
 | 
			
		||||
 | 
			
		||||
<div class="ui message small warning">
 | 
			
		||||
    <p>这里只能修改配置模板文件里的配置信息,并不能直接修改数据库的用户名、密码等信息。</p>
 | 
			
		||||
</div>
 | 
			
		||||
 | 
			
		||||
<form method="post" class="ui form" data-tea-action="$" data-tea-success="success">
 | 
			
		||||
	<table class="ui table selectable definition">
 | 
			
		||||
		<tr>
 | 
			
		||||
@@ -37,8 +41,4 @@
 | 
			
		||||
		</tr>
 | 
			
		||||
	</table>
 | 
			
		||||
	<submit-btn></submit-btn>
 | 
			
		||||
</form>
 | 
			
		||||
 | 
			
		||||
<div class="ui message small warning">
 | 
			
		||||
	<p>修改数据库配置后需要重新配置API节点。</p>
 | 
			
		||||
</div>
 | 
			
		||||
</form>
 | 
			
		||||
		Reference in New Issue
	
	Block a user