diff --git a/catch/system/controller/DataDictionary.php b/catch/system/controller/DataDictionary.php
index 26893d8..8bb45d2 100644
--- a/catch/system/controller/DataDictionary.php
+++ b/catch/system/controller/DataDictionary.php
@@ -11,17 +11,6 @@ use think\Paginator;
class DataDictionary extends CatchController
{
- /**
- *
- * @time 2019年12月13日
- * @throws \Exception
- * @return string
- */
- public function index(): string
- {
- return $this->fetch();
- }
-
/**
*
* @time 2019年12月13日
@@ -64,18 +53,22 @@ class DataDictionary extends CatchController
return CatchResponse::paginate(Paginator::make(!$searchMode ? $tables : $searchTables, $request->get('limit') ?? 10, $request->get('page') ?? 1, $searchMode ? count($searchTables) : count($tables), false, []));
}
- /**
- *
- * @time 2019年12月13日
- * @param $table
- * @throws \Exception
- * @return string
- */
- public function view($table): string
+ /**
+ *
+ * @time 2019年12月13日
+ * @param $table
+ * @return \think\response\Json
+ * @throws \Exception
+ */
+ public function view($table): \think\response\Json
{
- $this->table = Db::query('show full columns from ' . $table);
+ $fields = Db::query('show full columns from ' . $table);
- return $this->fetch();
+ array_walk($fields, function (&$item){
+ $item = array_change_key_case($item);
+ });
+
+ return CatchResponse::success($fields);
}
/**
diff --git a/view/catch-admin/src/views/system/database/table.vue b/view/catch-admin/src/views/system/database/table.vue
new file mode 100644
index 0000000..12425fc
--- /dev/null
+++ b/view/catch-admin/src/views/system/database/table.vue
@@ -0,0 +1,13 @@
+
+ $END$
+
+
+
+
+
\ No newline at end of file