mirror of
https://github.com/labring/FastGPT.git
synced 2025-07-27 08:25:07 +00:00
fix: multirow selector default value (#3358)
* fix: multirow selector default value * fix
This commit is contained in:
@@ -104,7 +104,7 @@ export const MultipleRowSelect = ({
|
|||||||
);
|
);
|
||||||
|
|
||||||
const onOpenSelect = useCallback(() => {
|
const onOpenSelect = useCallback(() => {
|
||||||
setCloneValue(value);
|
setCloneValue(Array.isArray(value) ? value : []);
|
||||||
onOpen();
|
onOpen();
|
||||||
}, [value, onOpen]);
|
}, [value, onOpen]);
|
||||||
|
|
||||||
|
@@ -130,7 +130,8 @@ export const onCreateApp = async ({
|
|||||||
chatConfig,
|
chatConfig,
|
||||||
versionName: name,
|
versionName: name,
|
||||||
username,
|
username,
|
||||||
avatar: userAvatar
|
avatar: userAvatar,
|
||||||
|
isPublish: true
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
{ session }
|
{ session }
|
||||||
|
@@ -97,9 +97,10 @@ const AppCard = ({ showSaveStatus, isSaved }: { showSaveStatus: boolean; isSaved
|
|||||||
appName: appDetail.name
|
appName: appDetail.name
|
||||||
})}
|
})}
|
||||||
</MyBox>
|
</MyBox>
|
||||||
<Box w={'full'} h={'1px'} bg={'myGray.200'} my={1} />
|
|
||||||
{appDetail.permission.hasWritePer && feConfigs?.show_team_chat && (
|
{appDetail.permission.hasWritePer && feConfigs?.show_team_chat && (
|
||||||
<>
|
<>
|
||||||
|
<Box w={'full'} h={'1px'} bg={'myGray.200'} my={1} />
|
||||||
|
|
||||||
<MyBox
|
<MyBox
|
||||||
display={'flex'}
|
display={'flex'}
|
||||||
size={'md'}
|
size={'md'}
|
||||||
@@ -113,25 +114,28 @@ const AppCard = ({ showSaveStatus, isSaved }: { showSaveStatus: boolean; isSaved
|
|||||||
<MyIcon name={'core/dataset/tag'} w={'16px'} mr={2} />
|
<MyIcon name={'core/dataset/tag'} w={'16px'} mr={2} />
|
||||||
<Box fontSize={'sm'}>{t('app:Team_Tags')}</Box>
|
<Box fontSize={'sm'}>{t('app:Team_Tags')}</Box>
|
||||||
</MyBox>
|
</MyBox>
|
||||||
<Box w={'full'} h={'1px'} bg={'myGray.200'} my={1} />
|
|
||||||
</>
|
</>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
{appDetail.permission.isOwner && (
|
{appDetail.permission.isOwner && (
|
||||||
<MyBox
|
<>
|
||||||
display={'flex'}
|
<Box w={'full'} h={'1px'} bg={'myGray.200'} my={1} />
|
||||||
size={'md'}
|
|
||||||
px={1}
|
<MyBox
|
||||||
py={1.5}
|
display={'flex'}
|
||||||
rounded={'4px'}
|
size={'md'}
|
||||||
color={'red.600'}
|
px={1}
|
||||||
_hover={{ bg: 'rgba(17, 24, 36, 0.05)' }}
|
py={1.5}
|
||||||
cursor={'pointer'}
|
rounded={'4px'}
|
||||||
onClick={onDelApp}
|
color={'red.600'}
|
||||||
>
|
_hover={{ bg: 'rgba(17, 24, 36, 0.05)' }}
|
||||||
<MyIcon name={'delete'} w={'16px'} mr={2} />
|
cursor={'pointer'}
|
||||||
<Box fontSize={'sm'}>{t('common:common.Delete')}</Box>
|
onClick={onDelApp}
|
||||||
</MyBox>
|
>
|
||||||
|
<MyIcon name={'delete'} w={'16px'} mr={2} />
|
||||||
|
<Box fontSize={'sm'}>{t('common:common.Delete')}</Box>
|
||||||
|
</MyBox>
|
||||||
|
</>
|
||||||
)}
|
)}
|
||||||
</Box>
|
</Box>
|
||||||
)}
|
)}
|
||||||
|
@@ -3,7 +3,6 @@ import { Box, Flex, Button, useDisclosure, Input, InputGroup } from '@chakra-ui/
|
|||||||
import { AddIcon } from '@chakra-ui/icons';
|
import { AddIcon } from '@chakra-ui/icons';
|
||||||
import { serviceSideProps } from '@/web/common/utils/i18n';
|
import { serviceSideProps } from '@/web/common/utils/i18n';
|
||||||
import { useUserStore } from '@/web/support/user/useUserStore';
|
import { useUserStore } from '@/web/support/user/useUserStore';
|
||||||
import { useI18n } from '@/web/context/I18n';
|
|
||||||
import { useTranslation } from 'next-i18next';
|
import { useTranslation } from 'next-i18next';
|
||||||
import dynamic from 'next/dynamic';
|
import dynamic from 'next/dynamic';
|
||||||
import MyMenu from '@fastgpt/web/components/common/MyMenu';
|
import MyMenu from '@fastgpt/web/components/common/MyMenu';
|
||||||
@@ -41,7 +40,6 @@ const List = dynamic(() => import('./components/List'));
|
|||||||
|
|
||||||
const MyApps = () => {
|
const MyApps = () => {
|
||||||
const { t } = useTranslation();
|
const { t } = useTranslation();
|
||||||
const { appT } = useI18n();
|
|
||||||
const router = useRouter();
|
const router = useRouter();
|
||||||
const { isPc } = useSystem();
|
const { isPc } = useSystem();
|
||||||
const {
|
const {
|
||||||
@@ -102,14 +100,14 @@ const MyApps = () => {
|
|||||||
<Input
|
<Input
|
||||||
value={searchKey}
|
value={searchKey}
|
||||||
onChange={(e) => setSearchKey(e.target.value)}
|
onChange={(e) => setSearchKey(e.target.value)}
|
||||||
placeholder={appT('search_app')}
|
placeholder={t('app:search_app')}
|
||||||
maxLength={30}
|
maxLength={30}
|
||||||
pl={8}
|
pl={8}
|
||||||
bg={'white'}
|
bg={'white'}
|
||||||
/>
|
/>
|
||||||
</InputGroup>
|
</InputGroup>
|
||||||
),
|
),
|
||||||
[searchKey, setSearchKey, appT]
|
[searchKey, setSearchKey, t]
|
||||||
);
|
);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
@@ -300,7 +298,7 @@ const MyApps = () => {
|
|||||||
});
|
});
|
||||||
}}
|
}}
|
||||||
onMove={() => setMoveAppId(folderDetail._id)}
|
onMove={() => setMoveAppId(folderDetail._id)}
|
||||||
deleteTip={appT('confirm_delete_folder_tip')}
|
deleteTip={t('app:confirm_delete_folder_tip')}
|
||||||
onDelete={() => onDeleFolder(folderDetail._id)}
|
onDelete={() => onDeleFolder(folderDetail._id)}
|
||||||
managePer={{
|
managePer={{
|
||||||
mode: 'all',
|
mode: 'all',
|
||||||
|
Reference in New Issue
Block a user