change url param name to "subdomain"

This commit is contained in:
2025-10-31 13:56:20 +03:00
parent 42d0b2cacf
commit 3dddc78dda
24 changed files with 89 additions and 116 deletions

View File

@@ -21,7 +21,7 @@ export default function LoginPage() {
const { themeName } = useAppSelector((state) => state.theme);
const [form] = Form.useForm();
const [sendOtp, { isLoading }] = useSendOtpMutation();
const { id } = useParams();
const { subdomain } = useParams();
const [phone, setPhone] = useState<string>("");
const [selectedDate, setSelectedDate] = useState<string>("");
@@ -33,7 +33,7 @@ export default function LoginPage() {
if (form.getFieldsValue())
sendOtp(form.getFieldsValue()).then((response: any) => {
message.info(t("login.OTPSentToYourPhoneNumber"));
navigate(`/${id}/otp`);
navigate(`/${subdomain}/otp`);
localStorage.setItem("otp", response.data.result.otp);
});
};