diff --git a/electrmangnetic/src/main/java/com/electromagnetic/industry/software/manage/config/AiAdvisor.java b/electrmangnetic/src/main/java/com/electromagnetic/industry/software/manage/config/AiAdvisor.java index 5607318..af9a9ed 100644 --- a/electrmangnetic/src/main/java/com/electromagnetic/industry/software/manage/config/AiAdvisor.java +++ b/electrmangnetic/src/main/java/com/electromagnetic/industry/software/manage/config/AiAdvisor.java @@ -1,12 +1,7 @@ package com.electromagnetic.industry.software.manage.config; -import org.springframework.ai.chat.client.advisor.MessageChatMemoryAdvisor; -import org.springframework.ai.embedding.EmbeddingModel; -import org.springframework.context.annotation.Bean; import org.springframework.stereotype.Component; -import java.util.Map; - @Component public class AiAdvisor { diff --git a/electrmangnetic/src/main/java/com/electromagnetic/industry/software/manage/service/serviceimpl/ChatService.java b/electrmangnetic/src/main/java/com/electromagnetic/industry/software/manage/service/serviceimpl/ChatService.java index 411fad6..b2f9d42 100644 --- a/electrmangnetic/src/main/java/com/electromagnetic/industry/software/manage/service/serviceimpl/ChatService.java +++ b/electrmangnetic/src/main/java/com/electromagnetic/industry/software/manage/service/serviceimpl/ChatService.java @@ -22,7 +22,6 @@ import com.electromagnetic.industry.software.manage.pojo.req.QueryDTO; import jakarta.annotation.Resource; import lombok.extern.slf4j.Slf4j; import org.springframework.ai.chat.client.ChatClient; -import org.springframework.ai.chat.client.advisor.MessageChatMemoryAdvisor; import org.springframework.ai.chat.messages.UserMessage; import org.springframework.ai.chat.model.ChatResponse; import org.springframework.ai.chat.prompt.Prompt; @@ -53,7 +52,7 @@ public class ChatService { private VectorStore vectorStore; @Resource private OllamaChatModel model; -// @Resource + // @Resource // private MessageChatMemoryAdvisor messageChatMemoryAdvisor; @Resource private AiFileUploadRecordMapper aiFileUploadRecordMapper; diff --git a/electrmangnetic/src/main/java/com/electromagnetic/industry/software/manage/service/serviceimpl/PermissionServiceImpl.java b/electrmangnetic/src/main/java/com/electromagnetic/industry/software/manage/service/serviceimpl/PermissionServiceImpl.java index bfc7bf7..335440f 100644 --- a/electrmangnetic/src/main/java/com/electromagnetic/industry/software/manage/service/serviceimpl/PermissionServiceImpl.java +++ b/electrmangnetic/src/main/java/com/electromagnetic/industry/software/manage/service/serviceimpl/PermissionServiceImpl.java @@ -1,7 +1,9 @@ package com.electromagnetic.industry.software.manage.service.serviceimpl; +import cn.hutool.core.collection.CollUtil; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; +import com.baomidou.mybatisplus.core.toolkit.Wrappers; import com.electromagnetic.industry.software.common.enums.DataOwnEnum; import com.electromagnetic.industry.software.common.enums.EffectFlagEnum; import com.electromagnetic.industry.software.common.enums.EleDataStatusEnum; @@ -92,10 +94,13 @@ public class PermissionServiceImpl implements PermissionService { .eq(RolePermission::getPermissionCode, FilePermission.VIEW.getCode()); List ids = rolePermissionService.listObjs(queryWrapper1).stream().map(Object::toString).toList(); + if (CollUtil.isEmpty(ids)) { + return new ArrayList<>(); + } Set result = new HashSet<>(); // 把父亲节点加上 - for (String id : ids) { - EdFileInfo file = edFileInfoMapper.selectById(id); + List edFileInfos = edFileInfoMapper.selectList(Wrappers.lambdaQuery(EdFileInfo.class).in(EdFileInfo::getId, ids)); + for (EdFileInfo file : edFileInfos) { String[] parentIds = file.getFilePath().split("_"); result.addAll(Arrays.asList(parentIds)); } diff --git a/electrmangnetic/src/main/resources/sqlmapper/UserMapper.xml b/electrmangnetic/src/main/resources/sqlmapper/UserMapper.xml index 49e1370..300a01c 100644 --- a/electrmangnetic/src/main/resources/sqlmapper/UserMapper.xml +++ b/electrmangnetic/src/main/resources/sqlmapper/UserMapper.xml @@ -166,7 +166,8 @@ where r.id in (select ur.role_id from ed_users u left join ed_user_role ur on u.id = ur.user_id - where u.id = #{userId} and ur.effect_flag = 1) + where u.id = #{userId} + and ur.effect_flag = 1) \ No newline at end of file diff --git a/electrmangnetic/src/main/resources/static/assets/_commonjs-dynamic-modules-TDtrdbi3.js b/electrmangnetic/src/main/resources/static/assets/_commonjs-dynamic-modules-TDtrdbi3.js index f19d79e..6c9159d 100644 --- a/electrmangnetic/src/main/resources/static/assets/_commonjs-dynamic-modules-TDtrdbi3.js +++ b/electrmangnetic/src/main/resources/static/assets/_commonjs-dynamic-modules-TDtrdbi3.js @@ -1 +1,5 @@ -function r(o){throw new Error('Could not dynamically require "'+o+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}export{r as c}; +function r(o) { + throw new Error('Could not dynamically require "' + o + '". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.') +} + +export {r as c}; diff --git a/electrmangnetic/src/main/resources/static/assets/_plugin-vue_export-helper-DlAUqK2U.js b/electrmangnetic/src/main/resources/static/assets/_plugin-vue_export-helper-DlAUqK2U.js index 718edd3..f7e876c 100644 --- a/electrmangnetic/src/main/resources/static/assets/_plugin-vue_export-helper-DlAUqK2U.js +++ b/electrmangnetic/src/main/resources/static/assets/_plugin-vue_export-helper-DlAUqK2U.js @@ -1 +1,6 @@ -const s=(t,r)=>{const o=t.__vccOpts||t;for(const[c,e]of r)o[c]=e;return o};export{s as _}; +const s = (t, r) => { + const o = t.__vccOpts || t; + for (const [c, e] of r) o[c] = e; + return o +}; +export {s as _}; diff --git a/electrmangnetic/src/main/resources/static/assets/backup-setting-CVjbnu-d.css b/electrmangnetic/src/main/resources/static/assets/backup-setting-CVjbnu-d.css index 4932bc7..28af1a1 100644 --- a/electrmangnetic/src/main/resources/static/assets/backup-setting-CVjbnu-d.css +++ b/electrmangnetic/src/main/resources/static/assets/backup-setting-CVjbnu-d.css @@ -1 +1,7 @@ -.backup-setting-management[data-v-592b576d]{background-color:#fff;padding:16px 24px;display:flex;flex-direction:column;height:100%} +.backup-setting-management[data-v-592b576d] { + background-color: #fff; + padding: 16px 24px; + display: flex; + flex-direction: column; + height: 100% +} diff --git a/electrmangnetic/src/main/resources/static/assets/file-type-management-CORsQiOS.css b/electrmangnetic/src/main/resources/static/assets/file-type-management-CORsQiOS.css index 7024611..76b8399 100644 --- a/electrmangnetic/src/main/resources/static/assets/file-type-management-CORsQiOS.css +++ b/electrmangnetic/src/main/resources/static/assets/file-type-management-CORsQiOS.css @@ -1 +1,7 @@ -.file-type-management[data-v-4e509c99]{background-color:#fff;padding:16px 24px;display:flex;flex-direction:column;height:100%} +.file-type-management[data-v-4e509c99] { + background-color: #fff; + padding: 16px 24px; + display: flex; + flex-direction: column; + height: 100% +} diff --git a/electrmangnetic/src/main/resources/static/assets/iconfont-BkE803Av.css b/electrmangnetic/src/main/resources/static/assets/iconfont-BkE803Av.css index eb2a41b..c0caef3 100644 --- a/electrmangnetic/src/main/resources/static/assets/iconfont-BkE803Av.css +++ b/electrmangnetic/src/main/resources/static/assets/iconfont-BkE803Av.css @@ -1 +1,7 @@ -.icon[data-v-0273bbfb]{width:1em;height:1em;vertical-align:-.15em;fill:currentColor;overflow:hidden} +.icon[data-v-0273bbfb] { + width: 1em; + height: 1em; + vertical-align: -.15em; + fill: currentColor; + overflow: hidden +} diff --git a/electrmangnetic/src/main/resources/static/assets/input-round-C0hN3Cc1.css b/electrmangnetic/src/main/resources/static/assets/input-round-C0hN3Cc1.css index bfa2444..cbe339c 100644 --- a/electrmangnetic/src/main/resources/static/assets/input-round-C0hN3Cc1.css +++ b/electrmangnetic/src/main/resources/static/assets/input-round-C0hN3Cc1.css @@ -1 +1,3 @@ -.round[data-v-52b10b31]{border-radius:18px} +.round[data-v-52b10b31] { + border-radius: 18px +} diff --git a/electrmangnetic/src/main/resources/static/assets/not-data-CgFOvFiq.js b/electrmangnetic/src/main/resources/static/assets/not-data-CgFOvFiq.js index a683fe0..35b2e92 100644 --- a/electrmangnetic/src/main/resources/static/assets/not-data-CgFOvFiq.js +++ b/electrmangnetic/src/main/resources/static/assets/not-data-CgFOvFiq.js @@ -1 +1,2 @@ -const t=""+new URL("not-data-Byd7gMOX.png",import.meta.url).href;export{t as n}; +const t = "" + new URL("not-data-Byd7gMOX.png", import.meta.url).href; +export {t as n}; diff --git a/electrmangnetic/src/main/resources/static/assets/not-data-legacy-DRFNaMW6.js b/electrmangnetic/src/main/resources/static/assets/not-data-legacy-DRFNaMW6.js index be539c8..4ab0075 100644 --- a/electrmangnetic/src/main/resources/static/assets/not-data-legacy-DRFNaMW6.js +++ b/electrmangnetic/src/main/resources/static/assets/not-data-legacy-DRFNaMW6.js @@ -1 +1,8 @@ -System.register([],(function(e,t){"use strict";return{execute:function(){e("n",""+new URL("not-data-Byd7gMOX.png",t.meta.url).href)}}})); +System.register([], (function (e, t) { + "use strict"; + return { + execute: function () { + e("n", "" + new URL("not-data-Byd7gMOX.png", t.meta.url).href) + } + } +})); diff --git a/electrmangnetic/src/main/resources/static/assets/useActivated-CHvUoPMG.js b/electrmangnetic/src/main/resources/static/assets/useActivated-CHvUoPMG.js index ac0d62e..05a4055 100644 --- a/electrmangnetic/src/main/resources/static/assets/useActivated-CHvUoPMG.js +++ b/electrmangnetic/src/main/resources/static/assets/useActivated-CHvUoPMG.js @@ -1 +1,12 @@ -import{t as e,aY as a,cA as r}from"./index-CnBLdARH.js";function u(){const t=e(!0);return a(()=>{t.value=!0}),r(()=>{t.value=!1}),t}export{u}; +import {aY as a, cA as r, t as e} from "./index-CnBLdARH.js"; + +function u() { + const t = e(!0); + return a(() => { + t.value = !0 + }), r(() => { + t.value = !1 + }), t +} + +export {u}; diff --git a/electrmangnetic/src/main/resources/static/assets/useFlexGapSupport-D6YO9lTS.js b/electrmangnetic/src/main/resources/static/assets/useFlexGapSupport-D6YO9lTS.js index b176356..070094c 100644 --- a/electrmangnetic/src/main/resources/static/assets/useFlexGapSupport-D6YO9lTS.js +++ b/electrmangnetic/src/main/resources/static/assets/useFlexGapSupport-D6YO9lTS.js @@ -1 +1,9 @@ -import{aC as a,v as o,eH as t}from"./index-CnBLdARH.js";const l=()=>{const e=a(!1);return o(()=>{e.value=t()}),e};export{l as u}; +import {aC as a, eH as t, v as o} from "./index-CnBLdARH.js"; + +const l = () => { + const e = a(!1); + return o(() => { + e.value = t() + }), e +}; +export {l as u}; diff --git a/electrmangnetic/src/main/resources/static/mockServiceWorker.js b/electrmangnetic/src/main/resources/static/mockServiceWorker.js index 6eb8052..511955d 100644 --- a/electrmangnetic/src/main/resources/static/mockServiceWorker.js +++ b/electrmangnetic/src/main/resources/static/mockServiceWorker.js @@ -14,143 +14,143 @@ const IS_MOCKED_RESPONSE = Symbol('isMockedResponse') const activeClientIds = new Set() self.addEventListener('install', function () { - self.skipWaiting() + self.skipWaiting() }) self.addEventListener('activate', function (event) { - event.waitUntil(self.clients.claim()) + event.waitUntil(self.clients.claim()) }) self.addEventListener('message', async function (event) { - const clientId = event.source.id + const clientId = event.source.id - if (!clientId || !self.clients) { - return - } - - const client = await self.clients.get(clientId) - - if (!client) { - return - } - - const allClients = await self.clients.matchAll({ - type: 'window', - }) - - switch (event.data) { - case 'KEEPALIVE_REQUEST': { - sendToClient(client, { - type: 'KEEPALIVE_RESPONSE', - }) - break + if (!clientId || !self.clients) { + return } - case 'INTEGRITY_CHECK_REQUEST': { - sendToClient(client, { - type: 'INTEGRITY_CHECK_RESPONSE', - payload: { - packageVersion: PACKAGE_VERSION, - checksum: INTEGRITY_CHECKSUM, - }, - }) - break + const client = await self.clients.get(clientId) + + if (!client) { + return } - case 'MOCK_ACTIVATE': { - activeClientIds.add(clientId) + const allClients = await self.clients.matchAll({ + type: 'window', + }) - sendToClient(client, { - type: 'MOCKING_ENABLED', - payload: { - client: { - id: client.id, - frameType: client.frameType, - }, - }, - }) - break + switch (event.data) { + case 'KEEPALIVE_REQUEST': { + sendToClient(client, { + type: 'KEEPALIVE_RESPONSE', + }) + break + } + + case 'INTEGRITY_CHECK_REQUEST': { + sendToClient(client, { + type: 'INTEGRITY_CHECK_RESPONSE', + payload: { + packageVersion: PACKAGE_VERSION, + checksum: INTEGRITY_CHECKSUM, + }, + }) + break + } + + case 'MOCK_ACTIVATE': { + activeClientIds.add(clientId) + + sendToClient(client, { + type: 'MOCKING_ENABLED', + payload: { + client: { + id: client.id, + frameType: client.frameType, + }, + }, + }) + break + } + + case 'MOCK_DEACTIVATE': { + activeClientIds.delete(clientId) + break + } + + case 'CLIENT_CLOSED': { + activeClientIds.delete(clientId) + + const remainingClients = allClients.filter((client) => { + return client.id !== clientId + }) + + // Unregister itself when there are no more clients + if (remainingClients.length === 0) { + self.registration.unregister() + } + + break + } } - - case 'MOCK_DEACTIVATE': { - activeClientIds.delete(clientId) - break - } - - case 'CLIENT_CLOSED': { - activeClientIds.delete(clientId) - - const remainingClients = allClients.filter((client) => { - return client.id !== clientId - }) - - // Unregister itself when there are no more clients - if (remainingClients.length === 0) { - self.registration.unregister() - } - - break - } - } }) self.addEventListener('fetch', function (event) { - const { request } = event + const {request} = event - // Bypass navigation requests. - if (request.mode === 'navigate') { - return - } + // Bypass navigation requests. + if (request.mode === 'navigate') { + return + } - // Opening the DevTools triggers the "only-if-cached" request - // that cannot be handled by the worker. Bypass such requests. - if (request.cache === 'only-if-cached' && request.mode !== 'same-origin') { - return - } + // Opening the DevTools triggers the "only-if-cached" request + // that cannot be handled by the worker. Bypass such requests. + if (request.cache === 'only-if-cached' && request.mode !== 'same-origin') { + return + } - // Bypass all requests when there are no active clients. - // Prevents the self-unregistered worked from handling requests - // after it's been deleted (still remains active until the next reload). - if (activeClientIds.size === 0) { - return - } + // Bypass all requests when there are no active clients. + // Prevents the self-unregistered worked from handling requests + // after it's been deleted (still remains active until the next reload). + if (activeClientIds.size === 0) { + return + } - // Generate unique request ID. - const requestId = crypto.randomUUID() - event.respondWith(handleRequest(event, requestId)) + // Generate unique request ID. + const requestId = crypto.randomUUID() + event.respondWith(handleRequest(event, requestId)) }) async function handleRequest(event, requestId) { - const client = await resolveMainClient(event) - const response = await getResponse(event, client, requestId) + const client = await resolveMainClient(event) + const response = await getResponse(event, client, requestId) - // Send back the response clone for the "response:*" life-cycle events. - // Ensure MSW is active and ready to handle the message, otherwise - // this message will pend indefinitely. - if (client && activeClientIds.has(client.id)) { - ;(async function () { - const responseClone = response.clone() + // Send back the response clone for the "response:*" life-cycle events. + // Ensure MSW is active and ready to handle the message, otherwise + // this message will pend indefinitely. + if (client && activeClientIds.has(client.id)) { + ;(async function () { + const responseClone = response.clone() - sendToClient( - client, - { - type: 'RESPONSE', - payload: { - requestId, - isMockedResponse: IS_MOCKED_RESPONSE in response, - type: responseClone.type, - status: responseClone.status, - statusText: responseClone.statusText, - body: responseClone.body, - headers: Object.fromEntries(responseClone.headers.entries()), - }, - }, - [responseClone.body], - ) - })() - } + sendToClient( + client, + { + type: 'RESPONSE', + payload: { + requestId, + isMockedResponse: IS_MOCKED_RESPONSE in response, + type: responseClone.type, + status: responseClone.status, + statusText: responseClone.statusText, + body: responseClone.body, + headers: Object.fromEntries(responseClone.headers.entries()), + }, + }, + [responseClone.body], + ) + })() + } - return response + return response } // Resolve the main client for the given event. @@ -158,136 +158,136 @@ async function handleRequest(event, requestId) { // that registered the worker. It's with the latter the worker should // communicate with during the response resolving phase. async function resolveMainClient(event) { - const client = await self.clients.get(event.clientId) + const client = await self.clients.get(event.clientId) - if (activeClientIds.has(event.clientId)) { - return client - } + if (activeClientIds.has(event.clientId)) { + return client + } - if (client?.frameType === 'top-level') { - return client - } + if (client?.frameType === 'top-level') { + return client + } - const allClients = await self.clients.matchAll({ - type: 'window', - }) - - return allClients - .filter((client) => { - // Get only those clients that are currently visible. - return client.visibilityState === 'visible' - }) - .find((client) => { - // Find the client ID that's recorded in the - // set of clients that have registered the worker. - return activeClientIds.has(client.id) + const allClients = await self.clients.matchAll({ + type: 'window', }) + + return allClients + .filter((client) => { + // Get only those clients that are currently visible. + return client.visibilityState === 'visible' + }) + .find((client) => { + // Find the client ID that's recorded in the + // set of clients that have registered the worker. + return activeClientIds.has(client.id) + }) } async function getResponse(event, client, requestId) { - const { request } = event + const {request} = event - // Clone the request because it might've been already used - // (i.e. its body has been read and sent to the client). - const requestClone = request.clone() + // Clone the request because it might've been already used + // (i.e. its body has been read and sent to the client). + const requestClone = request.clone() - function passthrough() { - const headers = Object.fromEntries(requestClone.headers.entries()) + function passthrough() { + const headers = Object.fromEntries(requestClone.headers.entries()) - // Remove internal MSW request header so the passthrough request - // complies with any potential CORS preflight checks on the server. - // Some servers forbid unknown request headers. - delete headers['x-msw-intention'] + // Remove internal MSW request header so the passthrough request + // complies with any potential CORS preflight checks on the server. + // Some servers forbid unknown request headers. + delete headers['x-msw-intention'] - return fetch(requestClone, { headers }) - } - - // Bypass mocking when the client is not active. - if (!client) { - return passthrough() - } - - // Bypass initial page load requests (i.e. static assets). - // The absence of the immediate/parent client in the map of the active clients - // means that MSW hasn't dispatched the "MOCK_ACTIVATE" event yet - // and is not ready to handle requests. - if (!activeClientIds.has(client.id)) { - return passthrough() - } - - // Notify the client that a request has been intercepted. - const requestBuffer = await request.arrayBuffer() - const clientMessage = await sendToClient( - client, - { - type: 'REQUEST', - payload: { - id: requestId, - url: request.url, - mode: request.mode, - method: request.method, - headers: Object.fromEntries(request.headers.entries()), - cache: request.cache, - credentials: request.credentials, - destination: request.destination, - integrity: request.integrity, - redirect: request.redirect, - referrer: request.referrer, - referrerPolicy: request.referrerPolicy, - body: requestBuffer, - keepalive: request.keepalive, - }, - }, - [requestBuffer], - ) - - switch (clientMessage.type) { - case 'MOCK_RESPONSE': { - return respondWithMock(clientMessage.data) + return fetch(requestClone, {headers}) } - case 'PASSTHROUGH': { - return passthrough() + // Bypass mocking when the client is not active. + if (!client) { + return passthrough() } - } - return passthrough() + // Bypass initial page load requests (i.e. static assets). + // The absence of the immediate/parent client in the map of the active clients + // means that MSW hasn't dispatched the "MOCK_ACTIVATE" event yet + // and is not ready to handle requests. + if (!activeClientIds.has(client.id)) { + return passthrough() + } + + // Notify the client that a request has been intercepted. + const requestBuffer = await request.arrayBuffer() + const clientMessage = await sendToClient( + client, + { + type: 'REQUEST', + payload: { + id: requestId, + url: request.url, + mode: request.mode, + method: request.method, + headers: Object.fromEntries(request.headers.entries()), + cache: request.cache, + credentials: request.credentials, + destination: request.destination, + integrity: request.integrity, + redirect: request.redirect, + referrer: request.referrer, + referrerPolicy: request.referrerPolicy, + body: requestBuffer, + keepalive: request.keepalive, + }, + }, + [requestBuffer], + ) + + switch (clientMessage.type) { + case 'MOCK_RESPONSE': { + return respondWithMock(clientMessage.data) + } + + case 'PASSTHROUGH': { + return passthrough() + } + } + + return passthrough() } function sendToClient(client, message, transferrables = []) { - return new Promise((resolve, reject) => { - const channel = new MessageChannel() + return new Promise((resolve, reject) => { + const channel = new MessageChannel() - channel.port1.onmessage = (event) => { - if (event.data && event.data.error) { - return reject(event.data.error) - } + channel.port1.onmessage = (event) => { + if (event.data && event.data.error) { + return reject(event.data.error) + } - resolve(event.data) - } + resolve(event.data) + } - client.postMessage( - message, - [channel.port2].concat(transferrables.filter(Boolean)), - ) - }) + client.postMessage( + message, + [channel.port2].concat(transferrables.filter(Boolean)), + ) + }) } async function respondWithMock(response) { - // Setting response status code to 0 is a no-op. - // However, when responding with a "Response.error()", the produced Response - // instance will have status code set to 0. Since it's not possible to create - // a Response instance with status code 0, handle that use-case separately. - if (response.status === 0) { - return Response.error() - } + // Setting response status code to 0 is a no-op. + // However, when responding with a "Response.error()", the produced Response + // instance will have status code set to 0. Since it's not possible to create + // a Response instance with status code 0, handle that use-case separately. + if (response.status === 0) { + return Response.error() + } - const mockedResponse = new Response(response.body, response) + const mockedResponse = new Response(response.body, response) - Reflect.defineProperty(mockedResponse, IS_MOCKED_RESPONSE, { - value: true, - enumerable: true, - }) + Reflect.defineProperty(mockedResponse, IS_MOCKED_RESPONSE, { + value: true, + enumerable: true, + }) - return mockedResponse + return mockedResponse } diff --git a/electrmangnetic/src/main/resources/static/model/favicon.svg b/electrmangnetic/src/main/resources/static/model/favicon.svg index 40a4fc5..b9bdda0 100644 --- a/electrmangnetic/src/main/resources/static/model/favicon.svg +++ b/electrmangnetic/src/main/resources/static/model/favicon.svg @@ -1,10 +1,15 @@ - + - - - + + + diff --git a/electrmangnetic/src/main/resources/static/model/index-plush.html b/electrmangnetic/src/main/resources/static/model/index-plush.html index 9281707..8de8f77 100644 --- a/electrmangnetic/src/main/resources/static/model/index-plush.html +++ b/electrmangnetic/src/main/resources/static/model/index-plush.html @@ -1,19 +1,19 @@ - - - + + + chili3d - - - - - - + + + + + + - - + - + + diff --git a/electrmangnetic/src/main/resources/static/model/index.html b/electrmangnetic/src/main/resources/static/model/index.html index c4bd274..7f3c554 100644 --- a/electrmangnetic/src/main/resources/static/model/index.html +++ b/electrmangnetic/src/main/resources/static/model/index.html @@ -1,5 +1,24 @@ -chili3d - - + + + + + + + + chili3d + + + + + + + - \ No newline at end of file + + + + \ No newline at end of file diff --git a/electrmangnetic/src/main/resources/templates/index.html b/electrmangnetic/src/main/resources/templates/index.html index fcee0dd..a4e6f08 100644 --- a/electrmangnetic/src/main/resources/templates/index.html +++ b/electrmangnetic/src/main/resources/templates/index.html @@ -1,19 +1,42 @@ - - - - + + + + 商飞数据库后台管理系统 - - - - - - -
- - - - + + + + + + +
+ + + + diff --git a/electrmangnetic/src/test/java/Test1.java b/electrmangnetic/src/test/java/Test1.java index cd0032f..6e13839 100644 --- a/electrmangnetic/src/test/java/Test1.java +++ b/electrmangnetic/src/test/java/Test1.java @@ -1,38 +1,15 @@ -//import com.electromagnetic.industry.software.manage.Application; -//import jakarta.annotation.Resource; -//import org.junit.jupiter.api.Test; -//import org.springframework.ai.document.Document; -//import org.springframework.ai.document.DocumentReader; -//import org.springframework.ai.reader.TextReader; -//import org.springframework.ai.transformer.splitter.TokenTextSplitter; -//import org.springframework.ai.vectorstore.VectorStore; -//import org.springframework.boot.test.context.SpringBootTest; -// -//import java.io.File; -//import java.net.MalformedURLException; -//import java.nio.file.Path; -//import java.util.List; -// -//@SpringBootTest(classes = Application.class) -//public class Test1 { -// -// @Resource -// private VectorStore vectorStore; -// -// @Test -// public void testTree() throws MalformedURLException { -// String path = "D:/明朝那些事儿.txt"; -// File file = new File(path); -// Path tempFile = file.toPath(); -// DocumentReader documentReader = new TextReader(String.valueOf(tempFile.toUri().toURL())); -// List documents = new TokenTextSplitter().apply(documentReader.get()); -// documents = documents.subList(0, 200); -// vectorStore.write(documents); -// -/// / Path tempFile = Paths.get(file.getAbsolutePath()); -/// / DocumentReader documentReader = new TextReader(String.valueOf(tempFile.toUri().toURL())); -/// / List documents = documentReader.get(); -/// / vectorStore.write(documents); -// } -// -//} +import com.electromagnetic.industry.software.manage.Application; +import org.junit.jupiter.api.Test; +import org.springframework.boot.test.context.SpringBootTest; + +import java.net.MalformedURLException; + +@SpringBootTest(classes = Application.class) +public class Test1 { + + @Test + public void test() throws MalformedURLException { + + } + +}