客户端打包
@@ -1,2 +1,3 @@
|
||||
VITE_h5_client_url=http://10.9.18.138:18900
|
||||
### VITE_h5_client_url=http://10.9.18.138:18900
|
||||
VITE_h5_client_url=https://bqw-120.ii999.live:20038
|
||||
VITE_HsAppCode=1
|
||||
|
||||
BIN
build/icon.ico
|
Before Width: | Height: | Size: 264 KiB After Width: | Height: | Size: 353 KiB |
BIN
build/icon.png
|
Before Width: | Height: | Size: 60 KiB After Width: | Height: | Size: 1.4 MiB |
BIN
build/icon_pinshan.ico
Normal file
|
After Width: | Height: | Size: 264 KiB |
BIN
build/icon_pinshan.png
Normal file
|
After Width: | Height: | Size: 60 KiB |
|
Before Width: | Height: | Size: 353 KiB |
|
Before Width: | Height: | Size: 1.4 MiB |
|
Before Width: | Height: | Size: 353 KiB After Width: | Height: | Size: 353 KiB |
@@ -1,6 +1,6 @@
|
||||
appId: com.huashiai.dify-market-manager-gui
|
||||
compression: maximum
|
||||
productName: 智能体平台
|
||||
productName: 深燃智能体平台
|
||||
directories:
|
||||
buildResources: build
|
||||
files:
|
||||
@@ -12,7 +12,7 @@ files:
|
||||
asarUnpack:
|
||||
- resources/**
|
||||
win:
|
||||
executableName: 智能体平台
|
||||
executableName: 深燃智能体平台
|
||||
nsis:
|
||||
artifactName: ${name}-${version}-setup.${ext}
|
||||
shortcutName: ${productName}
|
||||
@@ -41,4 +41,4 @@ publish:
|
||||
provider: generic
|
||||
url: ""
|
||||
electronDownload:
|
||||
mirror: http://172.22.33.66:18900/update_files
|
||||
mirror: https://npmmirror.com/mirrors/electron/
|
||||
|
||||
|
Before Width: | Height: | Size: 239 KiB After Width: | Height: | Size: 244 KiB |
|
Before Width: | Height: | Size: 9.1 KiB After Width: | Height: | Size: 12 KiB |
|
Before Width: | Height: | Size: 479 B After Width: | Height: | Size: 611 B |
|
Before Width: | Height: | Size: 817 B After Width: | Height: | Size: 1.1 KiB |
|
Before Width: | Height: | Size: 28 KiB After Width: | Height: | Size: 32 KiB |
|
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.7 KiB |
|
Before Width: | Height: | Size: 2.0 KiB After Width: | Height: | Size: 3.1 KiB |
|
Before Width: | Height: | Size: 83 KiB After Width: | Height: | Size: 89 KiB |
|
Before Width: | Height: | Size: 3.1 KiB After Width: | Height: | Size: 4.6 KiB |
|
Before Width: | Height: | Size: 60 KiB After Width: | Height: | Size: 32 KiB |
|
Before Width: | Height: | Size: 3.1 KiB After Width: | Height: | Size: 4.6 KiB |
@@ -65,8 +65,10 @@ export async function createWindow() {
|
||||
|
||||
// Create the browser window.
|
||||
mainWindow = new BrowserWindow({
|
||||
width: 420,
|
||||
height: 900,
|
||||
width: 1480,
|
||||
height: 980,
|
||||
minWidth: 1480,
|
||||
minHeight: 980,
|
||||
show: false,
|
||||
media: {
|
||||
audio: true,
|
||||
@@ -161,7 +163,7 @@ export async function createWindow() {
|
||||
setStoreValue("h5_client_url", import.meta.env.VITE_h5_client_url)
|
||||
}
|
||||
|
||||
const h5_client_url=getStoreValue("h5_client_url")+"/h5_client/"
|
||||
const h5_client_url=getStoreValue("h5_client_url")+"/pc_client/"
|
||||
|
||||
logger.info("==================================== mainWindow.loadURL:"+h5_client_url)
|
||||
// 加载存储的 URL
|
||||
@@ -174,10 +176,10 @@ export async function createWindow() {
|
||||
|
||||
mainWindow.webContents.on('did-fail-load', async (event, errorCode, errorDescription, validatedURL) => {
|
||||
logger.error(`主窗口页面加载失败: code=${errorCode}, desc=${errorDescription}, url=${validatedURL}, 失败次数: ${failLoadCount + 1}`)
|
||||
|
||||
|
||||
// 增加失败计数
|
||||
failLoadCount++;
|
||||
|
||||
|
||||
if (failLoadCount <= maxRetries) {
|
||||
logger.info(`页面加载失败,${retryDelay}ms后进行第${failLoadCount}次重试...`);
|
||||
setTimeout(async () => {
|
||||
@@ -503,18 +505,18 @@ export async function createNewWindow(url, access_token, refresh_token,sandbox=f
|
||||
|
||||
difyfullScreenWindow.webContents.on('did-fail-load', async (event, errorCode, errorDescription, validatedURL) => {
|
||||
logger.error(`全屏窗口页面加载失败: code=${errorCode}, desc=${errorDescription}, url=${validatedURL}, 失败次数: ${failLoadCount + 1}`)
|
||||
|
||||
|
||||
failLoadCount++;
|
||||
|
||||
|
||||
if (failLoadCount <= maxRetries) {
|
||||
logger.info(`全屏窗口页面加载失败,${retryDelay}ms后进行第${failLoadCount}次重试...`);
|
||||
|
||||
|
||||
setTimeout(async () => {
|
||||
try {
|
||||
// 在重试前先检查网络连接
|
||||
const { checkDefaultClientConnection } = await import('./utils/networkUtils.js');
|
||||
const isNetworkConnected = await checkDefaultClientConnection(3000);
|
||||
|
||||
|
||||
if (isNetworkConnected) {
|
||||
logger.info('网络连接正常,重新加载全屏窗口页面');
|
||||
difyfullScreenWindow.reload();
|
||||
@@ -606,18 +608,18 @@ export function createDrageWindow() {
|
||||
|
||||
drageWindow.webContents.on('did-fail-load', async (event, errorCode, errorDescription, validatedURL) => {
|
||||
logger.error(`悬浮窗口页面加载失败: code=${errorCode}, desc=${errorDescription}, url=${validatedURL}, 失败次数: ${drageFailLoadCount + 1}`)
|
||||
|
||||
|
||||
drageFailLoadCount++;
|
||||
|
||||
|
||||
if (drageFailLoadCount <= drageMaxRetries) {
|
||||
logger.info(`悬浮窗口页面加载失败,${drageRetryDelay}ms后进行第${drageFailLoadCount}次重试...`);
|
||||
|
||||
|
||||
setTimeout(async () => {
|
||||
try {
|
||||
// 在重试前先检查网络连接
|
||||
const { checkDefaultClientConnection } = await import('./utils/networkUtils.js');
|
||||
const isNetworkConnected = await checkDefaultClientConnection(3000);
|
||||
|
||||
|
||||
if (isNetworkConnected) {
|
||||
logger.info('网络连接正常,重新加载悬浮窗口页面');
|
||||
drageWindow.reload();
|
||||
@@ -653,6 +655,8 @@ export async function tokenExpireTimer(){
|
||||
const LOG_INTERVAL = 60000; // 日志打印间隔,60秒打印一次
|
||||
|
||||
const tokenExpireTimer = setInterval(async () => {
|
||||
return false;
|
||||
|
||||
const currentTime = Date.now();
|
||||
const lastActiveTime = getStoreValue("lastActiveTime")||null
|
||||
|
||||
|
||||