Fix: The time zone is unable to update properly in the database #12696 (#12704)

### What problem does this PR solve?

Fix: The time zone is unable to update properly in the database #12696

### Type of change

- [x] Bug Fix (non-breaking change which fixes an issue)
This commit is contained in:
balibabu
2026-01-20 09:47:16 +08:00
committed by GitHub
parent b40d639fdb
commit 59f3da2bdf

View File

@ -1,6 +1,7 @@
// src/components/ProfilePage.tsx // src/components/ProfilePage.tsx
import { AvatarUpload } from '@/components/avatar-upload'; import { AvatarUpload } from '@/components/avatar-upload';
import PasswordInput from '@/components/originui/password-input'; import PasswordInput from '@/components/originui/password-input';
import { SelectWithSearch } from '@/components/originui/select-with-search';
import Spotlight from '@/components/spotlight'; import Spotlight from '@/components/spotlight';
import { Button } from '@/components/ui/button'; import { Button } from '@/components/ui/button';
import { import {
@ -13,7 +14,6 @@ import {
} from '@/components/ui/form'; } from '@/components/ui/form';
import { Input } from '@/components/ui/input'; import { Input } from '@/components/ui/input';
import { Modal } from '@/components/ui/modal/modal'; import { Modal } from '@/components/ui/modal/modal';
import { RAGFlowSelect } from '@/components/ui/select';
import { useTranslate } from '@/hooks/common-hooks'; import { useTranslate } from '@/hooks/common-hooks';
import { TimezoneList } from '@/pages/user-setting/constants'; import { TimezoneList } from '@/pages/user-setting/constants';
import { zodResolver } from '@hookform/resolvers/zod'; import { zodResolver } from '@hookform/resolvers/zod';
@ -276,12 +276,12 @@ const ProfilePage: FC = () => {
<FormLabel className="text-sm text-text-secondary whitespace-nowrap"> <FormLabel className="text-sm text-text-secondary whitespace-nowrap">
{t('timezone')} {t('timezone')}
</FormLabel> </FormLabel>
<RAGFlowSelect <SelectWithSearch
options={TimezoneList.map((timeStr) => { options={TimezoneList.map((timeStr) => {
return { value: timeStr, label: timeStr }; return { value: timeStr, label: timeStr };
})} })}
placeholder="Select a timeZone" placeholder="Select a timeZone"
onValueChange={field.onChange} onChange={field.onChange}
value={field.value} value={field.value}
/> />
</div> </div>