mirror of
https://github.com/labring/FastGPT.git
synced 2025-07-24 05:23:57 +00:00
tmp org api rewrite (#4304)
* sync collection * remove lock * tmp org api rewrite
This commit is contained in:
13
packages/global/support/user/team/org/type.d.ts
vendored
13
packages/global/support/user/team/org/type.d.ts
vendored
@@ -1,6 +1,6 @@
|
||||
import type { TeamPermission } from 'support/permission/user/controller';
|
||||
import type { TeamPermission } from '../../../permission/user/controller';
|
||||
import { ResourcePermissionType } from '../type';
|
||||
import { SourceMemberType } from 'support/user/type';
|
||||
import { SourceMemberType } from '../../type';
|
||||
|
||||
type OrgSchemaType = {
|
||||
_id: string;
|
||||
@@ -8,7 +8,7 @@ type OrgSchemaType = {
|
||||
pathId: string;
|
||||
path: string;
|
||||
name: string;
|
||||
avatar?: string;
|
||||
avatar: string;
|
||||
description?: string;
|
||||
updateTime: Date;
|
||||
};
|
||||
@@ -20,7 +20,12 @@ type OrgMemberSchemaType = {
|
||||
tmbId: string;
|
||||
};
|
||||
|
||||
type OrgType = Omit<OrgSchemaType, 'avatar'> & {
|
||||
export type OrgListItemType = OrgSchemaType & {
|
||||
permission: TeamPermission;
|
||||
total: number; // members + children orgs
|
||||
};
|
||||
|
||||
export type OrgType = Omit<OrgSchemaType, 'avatar'> & {
|
||||
avatar: string;
|
||||
permission: TeamPermission;
|
||||
members: OrgMemberSchemaType[];
|
||||
|
@@ -1,7 +1,6 @@
|
||||
import { TeamCollectionName } from '@fastgpt/global/support/user/team/constant';
|
||||
import { connectionMongo, getMongoModel } from '../../../common/mongo';
|
||||
import { MemberGroupSchemaType } from '@fastgpt/global/support/permission/memberGroup/type';
|
||||
import { GroupMemberCollectionName } from './groupMemberSchema';
|
||||
const { Schema } = connectionMongo;
|
||||
|
||||
export const MemberGroupCollectionName = 'team_member_groups';
|
||||
|
Reference in New Issue
Block a user