加载提示信息;控制台文本;

This commit is contained in:
bunny 2025-07-02 20:00:27 +08:00
parent 7f55cecb7a
commit 25f46606fc
5 changed files with 17 additions and 12 deletions

View File

@ -5,6 +5,7 @@ import cn.bunny.domain.entity.ColumnMetaData;
import cn.bunny.domain.entity.DatabaseInfoMetaData;
import cn.bunny.domain.entity.TableMetaData;
import cn.bunny.domain.result.Result;
import cn.bunny.domain.result.ResultCodeEnum;
import cn.bunny.service.TableService;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
@ -49,7 +50,7 @@ public class TableController {
@GetMapping("tableColumnInfo")
public Result<List<ColumnMetaData>> tableColumnInfo(String tableName) {
List<ColumnMetaData> columnInfo = databaseMetadataProvider.getColumnInfoList(tableName);
return Result.success(columnInfo);
return Result.success(columnInfo, ResultCodeEnum.LOAD_FINISHED);
}
}

View File

@ -9,13 +9,13 @@ import lombok.Getter;
public enum ResultCodeEnum {
// 成功操作 200
SUCCESS(200, "操作成功"),
LOAD_FINISHED(200, "加载完成"),
ADD_SUCCESS(200, "添加成功"),
UPDATE_SUCCESS(200, "修改成功"),
DELETE_SUCCESS(200, "删除成功"),
SORT_SUCCESS(200, "排序成功"),
SUCCESS_UPLOAD(200, "上传成功"),
SUCCESS_LOGOUT(200, "退出成功"),
LOGOUT_SUCCESS(200, "退出成功"),
EMAIL_CODE_REFRESH(200, "邮箱验证码已刷新"),
EMAIL_CODE_SEND_SUCCESS(200, "邮箱验证码已发送"),

View File

@ -1,10 +1,13 @@
_ _
| |__ _ _ _ __ _ __ _ _ (_) __ ___ ____ _
| '_ \| | | | '_ \| '_ \| | | | | |/ _` \ \ / / _` |
| |_) | |_| | | | | | | | |_| | | | (_| |\ V | (_| |
|_.__/ \__,_|_| |_|_| |_|\__, | _/ |\__,_| \_/ \__,_|
|___/ |__/
____ _____ _
| _ \ / ____| | |
| |_) |_ _ _ __ _ __ _ _ | | __ ___ _ __ ___ _ __ __ _| |_ ___ _ __
| _ <| | | | '_ \| '_ \| | | | | | |_ |/ _ \ '_ \ / _ \ '__/ _` | __/ _ \| '__|
| |_) | |_| | | | | | | | |_| | | |__| | __/ | | | __/ | | (_| | || (_) | |
|____/ \__,_|_| |_|_| |_|\__, | \_____|\___|_| |_|\___|_| \__,_|\__\___/|_|
__/ |
|___/
Service Name${spring.application.name}
SpringBoot Version: ${spring-boot.version}${spring-boot.formatted-version}
SpringActive${spring.profiles.active}
Spring Active${spring.profiles.active}

View File

@ -23,8 +23,9 @@ const DatabaseCard = defineComponent({
</div>
<p class="card-subtitle mt-2 text-muted">
<i class="bi bi-mouse me-1"></i>
点击 <code class="bg-primary bg-opacity-10">表名</code>
<code class="bg-primary bg-opacity-10">生成</code>
点击 <code class="bg-primary bg-opacity-10">复选框</code>
<code class="bg-primary bg-opacity-10">选择按钮</code>
进行选择之后点击 <code class="bg-primary bg-opacity-10">生成选中表</code>
</p>
</div>

View File

@ -331,7 +331,7 @@ const DatabaseTable = defineComponent({
*/
async toggleTableDetails(table) {
// 如果是展开操作且没有列数据,则请求获取列信息
if (!table.showDetails && !table.columns) {
if (!table.showDetails) {
// 发送请求获取列信息
const {data, code, message} = await axiosInstance({
url: "/table/tableColumnInfo",