diff --git a/electron.vite.config.mjs b/electron.vite.config.mjs index c48cc00..9b9c503 100644 --- a/electron.vite.config.mjs +++ b/electron.vite.config.mjs @@ -24,8 +24,8 @@ export default defineConfig({ server: { proxy: { '/dev-api': { - target: 'http://27.128.240.72:7865', - // target: 'http://192.168.2.52:7863', + // target: 'http://27.128.240.72:7865', + target: 'http://192.168.2.52:7863', changeOrigin: true, rewrite: (p) => p.replace(/^\/dev-api/, '') } diff --git a/src/main/file.js b/src/main/file.js index 9cc20ea..d3eede2 100644 --- a/src/main/file.js +++ b/src/main/file.js @@ -250,7 +250,9 @@ export default async function ({ app, shell, BrowserWindow, ipcMain }) { onDownloadStarted: async ({ id, item, webContents }) => { // Do something with the download id }, - onDownloadProgress: async ({ id, item, percentCompleted }) => {}, + onDownloadProgress: async ({ id, item, percentCompleted }) => { + e.reply('download-file-default-prog' + fileName, percentCompleted) + }, onDownloadCompleted: async ({ id, item }) => { console.log('完成') e.reply('download-file-default' + fileName, true) diff --git a/src/main/index.js b/src/main/index.js index 653c83c..441bf06 100644 --- a/src/main/index.js +++ b/src/main/index.js @@ -243,4 +243,4 @@ function handleAll() { } } }) -} \ No newline at end of file +} diff --git a/src/renderer/src/api/classManage/index.js b/src/renderer/src/api/classManage/index.js index 14a8314..6db5913 100644 --- a/src/renderer/src/api/classManage/index.js +++ b/src/renderer/src/api/classManage/index.js @@ -130,3 +130,46 @@ export function addStudentmainByNameArray(data) { data: data }) } +//新增课程预约 +export function addSmartClassReserv(data) { + return request({ + url: '/smarttalk/classReserv/addSmartClassReserv', + method: 'post', + data: data + }) +} +//修改课程预约 +export function updateSmartClassReserv(data) { + return request({ + url: '/smarttalk/classReserv/updateSmartClassReserv', + method: 'post', + data: data + }) +} +//查询课程预约 +export function getSelfReserv() { + return request({ + url: '/smarttalk/classReserv/getSelfReserv', + method: 'get' + }) +} +export function deleteSmartReserv(id) { + return request({ + url: '/smarttalk/classReserv/' + id, + method: 'delete' + }) +} +export function startClass(id) { + return request({ + url: '/smarttalk/classReserv/startClass', + method: 'get', + params: {id} + }) +} +export function endClass(id) { + return request({ + url: '/smarttalk/classReserv/endClass', + method: 'get', + params: {id} + }) +} diff --git a/src/renderer/src/layout/components/Header.vue b/src/renderer/src/layout/components/Header.vue index 00deb25..799bf33 100644 --- a/src/renderer/src/layout/components/Header.vue +++ b/src/renderer/src/layout/components/Header.vue @@ -35,6 +35,7 @@