4.8.11 test (#2794)

* perf: version list type

* perf: add node default value

* perf: snapshot status

* fix: version detail auth

* fix: export defalt
This commit is contained in:
Archer
2024-09-26 11:02:09 +08:00
committed by GitHub
parent e31d6ec2c1
commit 86436d55ff
24 changed files with 752 additions and 490 deletions

View File

@@ -5,19 +5,17 @@ import type { FastGPTConfigFileType } from '@fastgpt/global/common/system/types/
import { PluginSourceEnum } from '@fastgpt/global/core/plugin/constants';
import { getFastGPTConfigFromDB } from '@fastgpt/service/common/system/config/controller';
import { PluginTemplateType } from '@fastgpt/global/core/plugin/type';
import { FastGPTProUrl } from '@fastgpt/service/common/system/constants';
import { FastGPTProUrl, isProduction } from '@fastgpt/service/common/system/constants';
import { initFastGPTConfig } from '@fastgpt/service/common/system/tools';
import json5 from 'json5';
import { SystemPluginTemplateItemType } from '@fastgpt/global/core/workflow/type';
export const readConfigData = (name: string) => {
const isDev = process.env.NODE_ENV === 'development';
const splitName = name.split('.');
const devName = `${splitName[0]}.local.${splitName[1]}`;
const filename = (() => {
if (isDev) {
if (!isProduction) {
// check local file exists
const hasLocalFile = existsSync(`data/${devName}`);
if (hasLocalFile) {