diff --git a/README_en.md b/README_en.md index a56438ffa..1dd705549 100644 --- a/README_en.md +++ b/README_en.md @@ -193,6 +193,7 @@ Xiaozhi is an ecosystem. When using this product, you might want to check out ot - [Xiaozhi PC Client](https://github.com/Huang-junsen/py-xiaozhi) This project provides a Python-based Xiaobai AI client, allowing you to experience Xiaozhi AI features through code even without physical hardware. Main features include AI voice interaction, visual multimodal recognition, IoT device integration, online music playback, voice wake-up, automatic dialogue mode, graphical interface, command-line mode, cross-platform support, volume control, session management, encrypted audio transmission, automatic verification code processing, etc. - [Xiaozhi Java Server](https://github.com/joey-zhou/xiaozhi-esp32-server-java) + The Xiaozhi open-source backend service Java version is a Java-based open-source project that includes both frontend and backend services, aiming to provide users with a complete backend service solution. --- ## Feature List ✨ diff --git a/main/manager-web/src/apis/api.js b/main/manager-web/src/apis/api.js index 97ab1e74c..a2354e0eb 100755 --- a/main/manager-web/src/apis/api.js +++ b/main/manager-web/src/apis/api.js @@ -7,7 +7,7 @@ import admin from './module/admin.js' * 如果你想调用8002端口,就用'/xiaozhi-esp32-api/api/v1',请与vue.config.js的devServer配置相结合,方便跨域请求 * */ -// const DEV_API_SERVICE = 'https://2662r3426b.vicp.fun/xiaozhi-esp32-api' +const DEV_API_SERVICE = 'https://2662r3426b.vicp.fun/xiaozhi-esp32-api' // 8002开发完成完成后使用这个 // const DEV_API_SERVICE = '/xiaozhi-esp32-api' @@ -16,7 +16,8 @@ import admin from './module/admin.js' * @returns {string} */ export function getServiceUrl() { - return '/xiaozhi-esp32-api' + // return '/xiaozhi-esp32-api' + return DEV_API_SERVICE } diff --git a/main/manager-web/src/apis/module/model.js b/main/manager-web/src/apis/module/model.js new file mode 100644 index 000000000..2534bb5a6 --- /dev/null +++ b/main/manager-web/src/apis/module/model.js @@ -0,0 +1,30 @@ +import RequestService from '../httpRequest' +import {getServiceUrl} from '../api' + + +export default { + // 获取模型配置列表 + getModelList(params, callback) { + const queryParams = new URLSearchParams({ + modelType: params.modelType, + modelName: params.modelName || '', + page: params.page || 0, + limit: params.limit || 10 + }).toString(); + + RequestService.sendRequest() + .url(`${getServiceUrl()}/api/v1/models/models/list?${queryParams}`) + .method('GET') + .success((res) => { + RequestService.clearRequestTime() + callback(res) + }) + .fail((err) => { + console.error('获取模型列表失败:', err) + RequestService.reAjaxFun(() => { + this.getModelList(params, callback) + }) + }).send() + }, + +} diff --git a/main/manager-web/src/components/AddDeviceDialog.vue b/main/manager-web/src/components/AddDeviceDialog.vue index a1ba55409..11189df7e 100644 --- a/main/manager-web/src/components/AddDeviceDialog.vue +++ b/main/manager-web/src/components/AddDeviceDialog.vue @@ -56,10 +56,16 @@ export default { this.loading = false; if (data.code === 0) { this.$emit('refresh'); - this.$message.success('设备绑定成功'); + this.$message.success({ + message: '设备绑定成功', + showClose: true + }); this.closeDialog(); } else { - this.$message.error(data.msg || '绑定失败'); + this.$message.error({ + message: data.msg || '绑定失败', + showClose: true + }); } } ); diff --git a/main/manager-web/src/components/HeaderBar.vue b/main/manager-web/src/components/HeaderBar.vue index 961676a3b..2efee6c17 100644 --- a/main/manager-web/src/components/HeaderBar.vue +++ b/main/manager-web/src/components/HeaderBar.vue @@ -13,11 +13,11 @@ 智能体管理 -
+
用户管理
-
+
模型配置
@@ -41,6 +41,7 @@ {{ userInfo.username || '加载中...' }} + 个人中心 修改密码 退出登录 @@ -56,7 +57,7 @@ diff --git a/main/manager-web/src/views/UserManagement.vue b/main/manager-web/src/views/UserManagement.vue index 7e92aa55c..aee22aec8 100644 --- a/main/manager-web/src/views/UserManagement.vue +++ b/main/manager-web/src/views/UserManagement.vue @@ -231,7 +231,7 @@ export default { row.status = '正常'; console.log('恢复用户:', row); }, - + // 用户删除 deleteUser(row) { this.$confirm('确定要删除该用户吗?', '警告', { @@ -346,9 +346,9 @@ $table-bg-color: #ecf1fd; } .user-card { - background: $table-bg-color; + background: white; border-radius: 12px; - padding: 20px; + padding: 15px; margin: 15px; } @@ -498,11 +498,11 @@ $table-bg-color: #ecf1fd; } :deep(.el-table) { - background: $table-bg-color; + background: white; &.transparent-table { .el-table__header th { - background: $table-bg-color !important; + background: white !important; color: black; } @@ -515,7 +515,7 @@ $table-bg-color: #ecf1fd; } .el-table__body tr { - background-color: $table-bg-color; + background-color: white; td { border: { top: 1px solid rgba(0, 0, 0, 0.04);