update package;fix: input data model ui (#4181)
* update package * fix: ts * update config * update jieba package * add type sign * fix: input data ui
This commit is contained in:
parent
713d1901bf
commit
cf50f9ec4d
@ -20,9 +20,9 @@
|
||||
"@chakra-ui/cli": "^2.4.1",
|
||||
"@vitest/coverage-v8": "^3.0.2",
|
||||
"husky": "^8.0.3",
|
||||
"i18next": "23.11.5",
|
||||
"i18next": "23.16.8",
|
||||
"lint-staged": "^13.3.0",
|
||||
"next-i18next": "15.3.0",
|
||||
"next-i18next": "15.4.2",
|
||||
"prettier": "3.2.4",
|
||||
"react-i18next": "14.1.2",
|
||||
"vitest": "^3.0.2",
|
||||
|
||||
@ -10,7 +10,7 @@
|
||||
"js-yaml": "^4.1.0",
|
||||
"jschardet": "3.1.1",
|
||||
"nanoid": "^5.1.3",
|
||||
"next": "14.2.21",
|
||||
"next": "14.2.24",
|
||||
"openai": "4.61.0",
|
||||
"openapi-types": "^12.1.3",
|
||||
"json5": "^2.2.3",
|
||||
|
||||
@ -1,4 +1,13 @@
|
||||
import { cut } from '@node-rs/jieba';
|
||||
import { Jieba } from '@node-rs/jieba';
|
||||
import fs from 'fs';
|
||||
import path from 'path';
|
||||
|
||||
// 使用 require.resolve 获取包的路径,然后拼接字典文件路径
|
||||
const jiebaPath = path.dirname(require.resolve('@node-rs/jieba/package.json'));
|
||||
const dictPath = path.join(jiebaPath, 'dict.txt');
|
||||
|
||||
// 使用正确的文件路径加载字典
|
||||
const jieba = Jieba.withDict(fs.readFileSync(dictPath));
|
||||
|
||||
const stopWords = new Set([
|
||||
'--',
|
||||
@ -1509,8 +1518,8 @@ const stopWords = new Set([
|
||||
]
|
||||
]);
|
||||
|
||||
export function jiebaSplit({ text }: { text: string }) {
|
||||
const tokens = cut(text, true);
|
||||
export async function jiebaSplit({ text }: { text: string }) {
|
||||
const tokens = (await jieba.cutAsync(text, true)) as string[];
|
||||
|
||||
return (
|
||||
tokens
|
||||
|
||||
@ -537,7 +537,7 @@ export async function searchDatasetData(
|
||||
$match: {
|
||||
teamId: new Types.ObjectId(teamId),
|
||||
datasetId: new Types.ObjectId(id),
|
||||
$text: { $search: jiebaSplit({ text: query }) },
|
||||
$text: { $search: await jiebaSplit({ text: query }) },
|
||||
...(filterCollectionIdList
|
||||
? {
|
||||
collectionId: {
|
||||
|
||||
@ -3,7 +3,7 @@
|
||||
"version": "1.0.0",
|
||||
"dependencies": {
|
||||
"@fastgpt/global": "workspace:*",
|
||||
"@node-rs/jieba": "1.10.0",
|
||||
"@node-rs/jieba": "2.0.1",
|
||||
"@xmldom/xmldom": "^0.8.10",
|
||||
"@zilliz/milvus2-sdk-node": "2.4.2",
|
||||
"axios": "^1.8.2",
|
||||
@ -26,7 +26,7 @@
|
||||
"mammoth": "^1.6.0",
|
||||
"mongoose": "^8.10.1",
|
||||
"multer": "1.4.5-lts.1",
|
||||
"next": "14.2.21",
|
||||
"next": "14.2.24",
|
||||
"nextjs-cors": "^2.2.0",
|
||||
"node-cron": "^3.0.3",
|
||||
"node-xlsx": "^0.24.0",
|
||||
|
||||
@ -4,8 +4,8 @@
|
||||
"dependencies": {
|
||||
"@chakra-ui/anatomy": "2.2.1",
|
||||
"@chakra-ui/icons": "2.1.1",
|
||||
"@chakra-ui/next-js": "2.1.5",
|
||||
"@chakra-ui/react": "2.8.1",
|
||||
"@chakra-ui/next-js": "2.4.2",
|
||||
"@chakra-ui/react": "2.10.7",
|
||||
"@chakra-ui/styled-system": "2.9.1",
|
||||
"@chakra-ui/system": "2.6.1",
|
||||
"@emotion/react": "11.11.1",
|
||||
@ -21,11 +21,11 @@
|
||||
"ahooks": "^3.7.11",
|
||||
"date-fns": "2.30.0",
|
||||
"dayjs": "^1.11.7",
|
||||
"i18next": "23.11.5",
|
||||
"i18next": "23.16.8",
|
||||
"js-cookie": "^3.0.5",
|
||||
"lexical": "0.12.6",
|
||||
"lodash": "^4.17.21",
|
||||
"next-i18next": "15.3.0",
|
||||
"next-i18next": "15.4.2",
|
||||
"papaparse": "^5.4.1",
|
||||
"react": "18.3.1",
|
||||
"react-beautiful-dnd": "^13.1.1",
|
||||
|
||||
10257
pnpm-lock.yaml
generated
10257
pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load Diff
@ -1,4 +1,3 @@
|
||||
//next-i18next.config.js
|
||||
/**
|
||||
* @type {import('next-i18next').UserConfig}
|
||||
*/
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
const { i18n } = require('./next-i18next.config');
|
||||
const { i18n } = require('./next-i18next.config.js');
|
||||
const path = require('path');
|
||||
const fs = require('fs');
|
||||
|
||||
@ -30,10 +30,6 @@ const nextConfig = {
|
||||
test: /\.svg$/i,
|
||||
issuer: /\.[jt]sx?$/,
|
||||
use: ['@svgr/webpack']
|
||||
},
|
||||
{
|
||||
test: /\.node$/,
|
||||
use: [{ loader: 'nextjs-node-loader' }]
|
||||
}
|
||||
]),
|
||||
exprContextCritical: false,
|
||||
@ -43,6 +39,7 @@ const nextConfig = {
|
||||
if (!config.externals) {
|
||||
config.externals = [];
|
||||
}
|
||||
config.externals.push('@node-rs/jieba');
|
||||
|
||||
if (isServer) {
|
||||
if (nextRuntime === 'nodejs') {
|
||||
@ -79,14 +76,15 @@ const nextConfig = {
|
||||
|
||||
return config;
|
||||
},
|
||||
transpilePackages: ['@fastgpt/*', 'ahooks'],
|
||||
// 需要转译的包
|
||||
transpilePackages: ['@fastgpt/global', '@fastgpt/web', 'ahooks'],
|
||||
experimental: {
|
||||
// 优化 Server Components 的构建和运行,避免不必要的客户端打包。
|
||||
serverComponentsExternalPackages: [
|
||||
'mongoose',
|
||||
'pg',
|
||||
'@node-rs/jieba',
|
||||
'@zilliz/milvus2-sdk-node'
|
||||
'@zilliz/milvus2-sdk-node',
|
||||
"tiktoken"
|
||||
],
|
||||
outputFileTracingRoot: path.join(__dirname, '../../'),
|
||||
instrumentationHook: true
|
||||
|
||||
@ -11,8 +11,8 @@
|
||||
"dependencies": {
|
||||
"@chakra-ui/anatomy": "2.2.1",
|
||||
"@chakra-ui/icons": "2.1.1",
|
||||
"@chakra-ui/next-js": "2.1.5",
|
||||
"@chakra-ui/react": "2.8.1",
|
||||
"@chakra-ui/next-js": "2.4.2",
|
||||
"@chakra-ui/react": "2.10.7",
|
||||
"@chakra-ui/styled-system": "2.9.1",
|
||||
"@chakra-ui/system": "2.6.1",
|
||||
"@emotion/react": "11.11.1",
|
||||
@ -23,9 +23,7 @@
|
||||
"@fastgpt/templates": "workspace:*",
|
||||
"@fastgpt/web": "workspace:*",
|
||||
"@fortaine/fetch-event-source": "^3.0.6",
|
||||
"@node-rs/jieba": "1.10.0",
|
||||
"@tanstack/react-query": "^4.24.10",
|
||||
"@types/nprogress": "^0.2.0",
|
||||
"ahooks": "^3.7.11",
|
||||
"axios": "^1.8.2",
|
||||
"date-fns": "2.30.0",
|
||||
@ -35,7 +33,7 @@
|
||||
"formidable": "^2.1.1",
|
||||
"framer-motion": "9.1.7",
|
||||
"hyperdown": "^2.4.29",
|
||||
"i18next": "23.11.5",
|
||||
"i18next": "23.16.8",
|
||||
"immer": "^9.0.19",
|
||||
"js-yaml": "^4.1.0",
|
||||
"json5": "^2.2.3",
|
||||
@ -44,9 +42,8 @@
|
||||
"lodash": "^4.17.21",
|
||||
"mermaid": "^10.2.3",
|
||||
"nanoid": "^5.1.3",
|
||||
"next": "14.2.21",
|
||||
"next-i18next": "15.3.0",
|
||||
"nextjs-node-loader": "^1.1.5",
|
||||
"next": "14.2.24",
|
||||
"next-i18next": "15.4.2",
|
||||
"nprogress": "^0.2.0",
|
||||
"qrcode": "^1.5.4",
|
||||
"react": "18.3.1",
|
||||
@ -76,6 +73,7 @@
|
||||
"@types/jsonwebtoken": "^9.0.3",
|
||||
"@types/lodash": "^4.14.191",
|
||||
"@types/node": "^20.14.2",
|
||||
"@types/nprogress": "^0.2.0",
|
||||
"@types/qrcode": "^1.5.5",
|
||||
"@types/react": "18.3.1",
|
||||
"@types/react-dom": "18.3.0",
|
||||
@ -83,7 +81,6 @@
|
||||
"@types/request-ip": "^0.0.37",
|
||||
"eslint": "8.56.0",
|
||||
"eslint-config-next": "14.2.24",
|
||||
"nextjs-node-loader": "^1.1.5",
|
||||
"typescript": "^5.1.3",
|
||||
"vitest": "^3.0.2"
|
||||
}
|
||||
|
||||
@ -220,13 +220,7 @@ function BillDetailModal({ bill, onClose }: { bill: BillSchemaType; onClose: ()
|
||||
{bill.metadata.payWay === 'balance' ? (
|
||||
t('user:bill.not_need_invoice')
|
||||
) : (
|
||||
<Box>
|
||||
{
|
||||
(bill.metadata.payWay = bill.hasInvoice
|
||||
? t('account_bill:yes')
|
||||
: t('account_bill:no'))
|
||||
}
|
||||
</Box>
|
||||
<Box>{bill.hasInvoice ? t('account_bill:yes') : t('account_bill:no')}</Box>
|
||||
)}
|
||||
</Flex>
|
||||
)}
|
||||
|
||||
@ -17,7 +17,6 @@ import { getSourceNameIcon } from '@fastgpt/global/core/dataset/utils';
|
||||
import { DatasetDataIndexItemType } from '@fastgpt/global/core/dataset/type';
|
||||
import DeleteIcon from '@fastgpt/web/components/common/Icon/delete';
|
||||
import { defaultCollectionDetail } from '@/web/core/dataset/constants';
|
||||
import { getDocPath } from '@/web/common/system/doc';
|
||||
import MyBox from '@fastgpt/web/components/common/MyBox';
|
||||
import { getErrText } from '@fastgpt/global/common/error/utils';
|
||||
import { useSystemStore } from '@/web/common/system/useSystemStore';
|
||||
@ -257,16 +256,18 @@ const InputDataModal = ({
|
||||
/>
|
||||
</Box>
|
||||
|
||||
<Flex
|
||||
pt={4}
|
||||
flex={'1 0 0'}
|
||||
gap={6}
|
||||
flexDir={['column', 'row']}
|
||||
overflow={'auto'}
|
||||
px={[5, '3.25rem']}
|
||||
>
|
||||
<Flex flex={'1 0 0'} h={['auto', '0']} gap={6} flexDir={['column', 'row']} px={[5, '0']}>
|
||||
{/* Data */}
|
||||
<Flex flexDir={'column'} h={'100%'} gap={3} flex={'1 0 0'}>
|
||||
<Flex
|
||||
pt={4}
|
||||
pl={[0, '3.25rem']}
|
||||
flexDir={'column'}
|
||||
h={'100%'}
|
||||
gap={3}
|
||||
flex={'1 0 0'}
|
||||
w={['100%', 0]}
|
||||
overflow={['unset', 'auto']}
|
||||
>
|
||||
<Flex flexDir={'column'} h={'100%'}>
|
||||
<FormLabel required mb={1} h={'30px'}>
|
||||
{currentTab === TabEnum.chunk
|
||||
@ -315,7 +316,13 @@ const InputDataModal = ({
|
||||
)}
|
||||
</Flex>
|
||||
{/* Index */}
|
||||
<Box flex={'1 0 0'}>
|
||||
<Box
|
||||
pt={4}
|
||||
pr={[0, '3.25rem']}
|
||||
flex={'1 0 0'}
|
||||
w={['100%', 0]}
|
||||
overflow={['unset', 'auto']}
|
||||
>
|
||||
<Flex alignItems={'flex-start'} justifyContent={'space-between'} h={'30px'}>
|
||||
<FormLabel>
|
||||
{t('common:dataset.data.edit.Index', {
|
||||
|
||||
@ -44,7 +44,7 @@ const restore = async () => {
|
||||
const data = await MongoDatasetData.findOne({ fullTextToken: { $exists: false } });
|
||||
if (!data) return;
|
||||
|
||||
data.fullTextToken = jiebaSplit({ text: `${data.q}\n${data.a}`.trim() });
|
||||
data.fullTextToken = await jiebaSplit({ text: `${data.q}\n${data.a}`.trim() });
|
||||
await data.save();
|
||||
|
||||
success++;
|
||||
|
||||
@ -138,7 +138,7 @@ export async function insertData2Dataset({
|
||||
datasetId,
|
||||
collectionId,
|
||||
dataId: _id,
|
||||
fullTextToken: jiebaSplit({ text: `${q}\n${a}`.trim() })
|
||||
fullTextToken: await jiebaSplit({ text: `${q}\n${a}`.trim() })
|
||||
}
|
||||
],
|
||||
{ session, ordered: true }
|
||||
@ -272,7 +272,7 @@ export async function updateData2Dataset({
|
||||
// update mongo data text
|
||||
await MongoDatasetDataText.updateOne(
|
||||
{ dataId: mongoData._id },
|
||||
{ fullTextToken: jiebaSplit({ text: `${mongoData.q}\n${mongoData.a}`.trim() }) },
|
||||
{ fullTextToken: await jiebaSplit({ text: `${mongoData.q}\n${mongoData.a}`.trim() }) },
|
||||
{ session }
|
||||
);
|
||||
|
||||
|
||||
@ -1,11 +1,11 @@
|
||||
import { GET, POST, DELETE, PUT } from '@/web/common/api/request';
|
||||
import type { AppDetailType, AppListItemType } from '@fastgpt/global/core/app/type.d';
|
||||
import type { GetAppChatLogsParams } from '@/global/core/api/appReq.d';
|
||||
import { AppUpdateParams, AppChangeOwnerBody } from '@/global/core/app/api';
|
||||
import type { AppUpdateParams, AppChangeOwnerBody } from '@/global/core/app/api';
|
||||
import type { CreateAppBody } from '@/pages/api/core/app/create';
|
||||
import type { ListAppBody } from '@/pages/api/core/app/list';
|
||||
import { AppLogsListItemType } from '@/types/app';
|
||||
import { PaginationResponse } from '@fastgpt/web/common/fetch/type';
|
||||
import type { AppLogsListItemType } from '@/types/app';
|
||||
import type { PaginationResponse } from '@fastgpt/web/common/fetch/type';
|
||||
|
||||
/**
|
||||
* 获取应用列表
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
import { DELETE, GET, POST } from '@/web/common/api/request';
|
||||
import type { CreateAppFolderBody } from '@/pages/api/core/app/folder/create';
|
||||
import { ParentTreePathItemType } from '@fastgpt/global/common/parentFolder/type';
|
||||
import { ParentIdType } from '@fastgpt/global/common/parentFolder/type';
|
||||
import type { ParentTreePathItemType } from '@fastgpt/global/common/parentFolder/type';
|
||||
import type { ParentIdType } from '@fastgpt/global/common/parentFolder/type';
|
||||
import type {
|
||||
transitionWorkflowBody,
|
||||
transitionWorkflowResponse
|
||||
|
||||
@ -1,9 +1,9 @@
|
||||
import {
|
||||
import type {
|
||||
UpdateAppCollaboratorBody,
|
||||
AppCollaboratorDeleteParams
|
||||
} from '@fastgpt/global/core/app/collaborator';
|
||||
import { DELETE, GET, POST } from '@/web/common/api/request';
|
||||
import { CollaboratorItemType } from '@fastgpt/global/support/permission/collaborator';
|
||||
import type { CollaboratorItemType } from '@fastgpt/global/support/permission/collaborator';
|
||||
|
||||
export const getCollaboratorList = (appId: string) =>
|
||||
GET<CollaboratorItemType[]>('/proApi/core/app/collaborator/list', { appId });
|
||||
|
||||
@ -11,9 +11,12 @@ import { defaultNodeVersion, FlowNodeTypeEnum } from '@fastgpt/global/core/workf
|
||||
import { FlowNodeTemplateTypeEnum } from '@fastgpt/global/core/workflow/constants';
|
||||
import type { GetPreviewNodeQuery } from '@/pages/api/core/app/plugin/getPreviewNode';
|
||||
import { AppTypeEnum } from '@fastgpt/global/core/app/constants';
|
||||
import { ParentIdType, ParentTreePathItemType } from '@fastgpt/global/common/parentFolder/type';
|
||||
import { GetSystemPluginTemplatesBody } from '@/pages/api/core/app/plugin/getSystemPluginTemplates';
|
||||
import { PluginGroupSchemaType } from '@fastgpt/service/core/app/plugin/type';
|
||||
import type {
|
||||
ParentIdType,
|
||||
ParentTreePathItemType
|
||||
} from '@fastgpt/global/common/parentFolder/type';
|
||||
import type { GetSystemPluginTemplatesBody } from '@/pages/api/core/app/plugin/getSystemPluginTemplates';
|
||||
import type { PluginGroupSchemaType } from '@fastgpt/service/core/app/plugin/type';
|
||||
import { useSystemStore } from '@/web/common/system/useSystemStore';
|
||||
import { defaultGroup } from '@fastgpt/web/core/workflow/constants';
|
||||
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
import { ListParams } from '@/pages/api/core/app/template/list';
|
||||
import type { ListParams } from '@/pages/api/core/app/template/list';
|
||||
import { GET } from '@/web/common/api/request';
|
||||
import { useSystemStore } from '@/web/common/system/useSystemStore';
|
||||
import { AppTemplateSchemaType, TemplateTypeSchemaType } from '@fastgpt/global/core/app/type';
|
||||
import type { AppTemplateSchemaType, TemplateTypeSchemaType } from '@fastgpt/global/core/app/type';
|
||||
import { defaultTemplateTypes } from '@fastgpt/web/core/workflow/constants';
|
||||
|
||||
export const getTemplateMarketItemList = (data: ListParams) =>
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
import { PostPublishAppProps } from '@/global/core/app/api';
|
||||
import type { PostPublishAppProps } from '@/global/core/app/api';
|
||||
import { GET, POST } from '@/web/common/api/request';
|
||||
import type { AppVersionSchemaType } from '@fastgpt/global/core/app/version';
|
||||
import { PaginationProps } from '@fastgpt/web/common/fetch/type';
|
||||
import type { PaginationProps } from '@fastgpt/web/common/fetch/type';
|
||||
import type {
|
||||
getLatestVersionQuery,
|
||||
getLatestVersionResponse
|
||||
|
||||
@ -17,7 +17,7 @@ import type {
|
||||
QueryChatInputGuideBody,
|
||||
QueryChatInputGuideResponse
|
||||
} from '@/pages/api/core/chat/inputGuide/query';
|
||||
import { deleteAllInputGuideBody } from '@/pages/api/core/chat/inputGuide/deleteAll';
|
||||
import type { deleteAllInputGuideBody } from '@/pages/api/core/chat/inputGuide/deleteAll';
|
||||
|
||||
export const getCountChatInputGuideTotal = (data: countChatInputGuideTotalQuery) =>
|
||||
GET<countChatInputGuideTotalResponse>(`/core/chat/inputGuide/countTotal`, data);
|
||||
|
||||
@ -64,8 +64,8 @@ import type {
|
||||
listExistIdQuery,
|
||||
listExistIdResponse
|
||||
} from '@/pages/api/core/dataset/apiDataset/listExistId';
|
||||
import { GetQuoteDataResponse } from '@/pages/api/core/dataset/data/getQuoteData';
|
||||
import { GetQuotePermissionResponse } from '@/pages/api/core/dataset/data/getPermission';
|
||||
import type { GetQuoteDataResponse } from '@/pages/api/core/dataset/data/getQuoteData';
|
||||
import type { GetQuotePermissionResponse } from '@/pages/api/core/dataset/data/getPermission';
|
||||
|
||||
/* ======================== dataset ======================= */
|
||||
export const getDatasets = (data: GetDatasetListBody) =>
|
||||
|
||||
@ -1,9 +1,9 @@
|
||||
import {
|
||||
import type {
|
||||
UpdateDatasetCollaboratorBody,
|
||||
DatasetCollaboratorDeleteParams
|
||||
} from '@fastgpt/global/core/dataset/collaborator';
|
||||
import { DELETE, GET, POST } from '@/web/common/api/request';
|
||||
import { CollaboratorItemType } from '@fastgpt/global/support/permission/collaborator';
|
||||
import type { CollaboratorItemType } from '@fastgpt/global/support/permission/collaborator';
|
||||
|
||||
export const getCollaboratorList = (datasetId: string) =>
|
||||
GET<CollaboratorItemType[]>('/proApi/core/dataset/collaborator/list', { datasetId });
|
||||
|
||||
@ -10,20 +10,20 @@ import {
|
||||
FlowNodeTypeEnum
|
||||
} from '@fastgpt/global/core/workflow/node/constant';
|
||||
import { getHandleConfig } from '@fastgpt/global/core/workflow/template/utils';
|
||||
import { FlowNodeItemType, StoreNodeItemType } from '@fastgpt/global/core/workflow/type/node';
|
||||
import type { FlowNodeItemType, StoreNodeItemType } from '@fastgpt/global/core/workflow/type/node';
|
||||
import type { FlowNodeTemplateType } from '@fastgpt/global/core/workflow/type/node';
|
||||
import { VARIABLE_NODE_ID } from '@fastgpt/global/core/workflow/constants';
|
||||
import { getHandleId } from '@fastgpt/global/core/workflow/utils';
|
||||
import { StoreEdgeItemType } from '@fastgpt/global/core/workflow/type/edge';
|
||||
import type { StoreEdgeItemType } from '@fastgpt/global/core/workflow/type/edge';
|
||||
import { LLMModelTypeEnum } from '@fastgpt/global/core/ai/constants';
|
||||
import {
|
||||
import type {
|
||||
FlowNodeInputItemType,
|
||||
FlowNodeOutputItemType
|
||||
} from '@fastgpt/global/core/workflow/type/io';
|
||||
import { PluginTypeEnum } from '@fastgpt/global/core/plugin/constants';
|
||||
import { getWorkflowGlobalVariables } from './utils';
|
||||
import { TFunction } from 'next-i18next';
|
||||
import { AppChatConfigType } from '@fastgpt/global/core/app/type';
|
||||
import type { TFunction } from 'next-i18next';
|
||||
import type { AppChatConfigType } from '@fastgpt/global/core/app/type';
|
||||
|
||||
export const getGlobalVariableNode = ({
|
||||
nodes,
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
import { GET, POST, PUT, DELETE } from '@/web/common/api/request';
|
||||
import { PostWorkflowDebugProps, PostWorkflowDebugResponse } from '@/global/core/workflow/api';
|
||||
import type { PostWorkflowDebugProps, PostWorkflowDebugResponse } from '@/global/core/workflow/api';
|
||||
|
||||
export const postWorkflowDebug = (data: PostWorkflowDebugProps) =>
|
||||
POST<PostWorkflowDebugResponse>(
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import { GET, POST } from '@/web/common/api/request';
|
||||
import type { PromotionRecordType } from '@/global/support/api/userRes.d';
|
||||
import { PaginationProps, PaginationResponse } from '@fastgpt/web/common/fetch/type';
|
||||
import type { PaginationProps, PaginationResponse } from '@fastgpt/web/common/fetch/type';
|
||||
|
||||
/* get promotion init data */
|
||||
export const getPromotionInitData = () =>
|
||||
|
||||
@ -2,15 +2,15 @@ import { GET, POST, PUT } from '@/web/common/api/request';
|
||||
import { hashStr } from '@fastgpt/global/common/string/tools';
|
||||
import type { ResLogin } from '@/global/support/api/userRes.d';
|
||||
import { UserAuthTypeEnum } from '@fastgpt/global/support/user/auth/constants';
|
||||
import { UserUpdateParams } from '@/types/user';
|
||||
import { UserType } from '@fastgpt/global/support/user/type.d';
|
||||
import type { UserUpdateParams } from '@/types/user';
|
||||
import type { UserType } from '@fastgpt/global/support/user/type.d';
|
||||
import type {
|
||||
FastLoginProps,
|
||||
OauthLoginProps,
|
||||
PostLoginProps,
|
||||
SearchResult
|
||||
} from '@fastgpt/global/support/user/api.d';
|
||||
import {
|
||||
import type {
|
||||
AccountRegisterBody,
|
||||
GetWXLoginQRResponse
|
||||
} from '@fastgpt/global/support/user/login/api.d';
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
import { GET, POST } from '@/web/common/api/request';
|
||||
import type { UserInformSchema } from '@fastgpt/global/support/user/inform/type';
|
||||
import { SystemMsgModalValueType } from '@fastgpt/service/support/user/inform/type';
|
||||
import { PaginationProps, PaginationResponse } from '@fastgpt/web/common/fetch/type';
|
||||
import type { SystemMsgModalValueType } from '@fastgpt/service/support/user/inform/type';
|
||||
import type { PaginationProps, PaginationResponse } from '@fastgpt/web/common/fetch/type';
|
||||
|
||||
export const getInforms = (data: PaginationProps) =>
|
||||
POST<PaginationResponse<UserInformSchema>>(`/proApi/support/user/inform/list`, data);
|
||||
|
||||
@ -1,26 +1,24 @@
|
||||
import { GET, POST, PUT, DELETE } from '@/web/common/api/request';
|
||||
import {
|
||||
import type {
|
||||
CollaboratorItemType,
|
||||
DeletePermissionQuery,
|
||||
UpdateClbPermissionProps
|
||||
} from '@fastgpt/global/support/permission/collaborator';
|
||||
import {
|
||||
import type {
|
||||
CreateTeamProps,
|
||||
InviteMemberProps,
|
||||
InviteMemberResponse,
|
||||
UpdateInviteProps,
|
||||
UpdateTeamProps
|
||||
} from '@fastgpt/global/support/user/team/controller.d';
|
||||
import type { TeamTagItemType, TeamTagSchema } from '@fastgpt/global/support/user/team/type';
|
||||
import {
|
||||
import type {
|
||||
TeamTmbItemType,
|
||||
TeamMemberItemType,
|
||||
TeamMemberSchema
|
||||
} from '@fastgpt/global/support/user/team/type.d';
|
||||
import { FeTeamPlanStatusType, TeamSubSchema } from '@fastgpt/global/support/wallet/sub/type';
|
||||
import { TeamInvoiceHeaderType } from '@fastgpt/global/support/user/team/type';
|
||||
import { PaginationProps, PaginationResponse } from '@fastgpt/web/common/fetch/type';
|
||||
import {
|
||||
import type { FeTeamPlanStatusType, TeamSubSchema } from '@fastgpt/global/support/wallet/sub/type';
|
||||
import type { TeamInvoiceHeaderType } from '@fastgpt/global/support/user/team/type';
|
||||
import type { PaginationProps, PaginationResponse } from '@fastgpt/web/common/fetch/type';
|
||||
import type {
|
||||
InvitationInfoType,
|
||||
InvitationLinkCreateType,
|
||||
InvitationLinkUpdateType,
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import { DELETE, GET, POST, PUT } from '@/web/common/api/request';
|
||||
import { MemberGroupListType } from '@fastgpt/global/support/permission/memberGroup/type';
|
||||
import {
|
||||
import type { MemberGroupListType } from '@fastgpt/global/support/permission/memberGroup/type';
|
||||
import type {
|
||||
postCreateGroupData,
|
||||
putUpdateGroupData
|
||||
} from '@fastgpt/global/support/user/team/group/api';
|
||||
|
||||
@ -5,7 +5,7 @@ import type {
|
||||
putUpdateOrgMembersData
|
||||
} from '@fastgpt/global/support/user/team/org/api';
|
||||
import type { OrgType } from '@fastgpt/global/support/user/team/org/type';
|
||||
import { putMoveOrgType } from '@fastgpt/global/support/user/team/org/api';
|
||||
import type { putMoveOrgType } from '@fastgpt/global/support/user/team/org/api';
|
||||
|
||||
export const getOrgList = () => GET<OrgType[]>('/proApi/support/user/team/org/list');
|
||||
|
||||
|
||||
@ -1,8 +1,8 @@
|
||||
import { GET, POST } from '@/web/common/api/request';
|
||||
import { CreateBillProps, CreateBillResponse } from '@fastgpt/global/support/wallet/bill/api';
|
||||
import type { CreateBillProps, CreateBillResponse } from '@fastgpt/global/support/wallet/bill/api';
|
||||
import { BillTypeEnum } from '@fastgpt/global/support/wallet/bill/constants';
|
||||
import type { BillSchemaType } from '@fastgpt/global/support/wallet/bill/type.d';
|
||||
import { PaginationProps, PaginationResponse } from '@fastgpt/web/common/fetch/type';
|
||||
import type { PaginationProps, PaginationResponse } from '@fastgpt/web/common/fetch/type';
|
||||
|
||||
export const getBills = (
|
||||
data: PaginationProps<{
|
||||
|
||||
@ -1,8 +1,8 @@
|
||||
import { GET, POST } from '@/web/common/api/request';
|
||||
import { BillTypeEnum } from '@fastgpt/global/support/wallet/bill/constants';
|
||||
import { InvoiceType } from '@fastgpt/global/support/wallet/bill/type';
|
||||
import { InvoiceSchemaType } from '@fastgpt/global/support/wallet/bill/type';
|
||||
import { PaginationProps, PaginationResponse } from '@fastgpt/web/common/fetch/type';
|
||||
import type { InvoiceType } from '@fastgpt/global/support/wallet/bill/type';
|
||||
import type { InvoiceSchemaType } from '@fastgpt/global/support/wallet/bill/type';
|
||||
import type { PaginationProps, PaginationResponse } from '@fastgpt/web/common/fetch/type';
|
||||
export type invoiceBillDataType = {
|
||||
type: BillTypeEnum;
|
||||
price: number;
|
||||
|
||||
@ -1,12 +1,12 @@
|
||||
import { POST } from '@/web/common/api/request';
|
||||
import {
|
||||
import type {
|
||||
CreateTrainingUsageProps,
|
||||
GetUsageDashboardProps,
|
||||
GetUsageDashboardResponseItem,
|
||||
GetUsageProps
|
||||
} from '@fastgpt/global/support/wallet/usage/api.d';
|
||||
import type { UsageItemType } from '@fastgpt/global/support/wallet/usage/type';
|
||||
import { PaginationProps, PaginationResponse } from '@fastgpt/web/common/fetch/type';
|
||||
import type { PaginationProps, PaginationResponse } from '@fastgpt/web/common/fetch/type';
|
||||
|
||||
export const getUserUsages = (data: PaginationProps<GetUsageProps>) =>
|
||||
POST<PaginationResponse<UsageItemType>>(`/proApi/support/wallet/usage/getUsage`, data);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user