feat: 🚀 钉钉跳转

This commit is contained in:
2025-10-16 15:35:43 +08:00
parent 3c72a248fa
commit 574c46580f
6 changed files with 137 additions and 27 deletions

View File

@@ -1,6 +1,16 @@
export const usePathUrl = () => {
const PATH_URL = `${import.meta.env.VITE_APP_SSO_LOGINURL}?client_id=${
import.meta.env.VITE_APP_SSO_APPID
}&redirect_uri=${encodeURIComponent(import.meta.env.VITE_REDIRECT_URL)}&response_type=code`;
return PATH_URL;
export const usePathUrl = (redirect_path?: any) => {
let PATH_URL: any = "";
if (redirect_path) {
PATH_URL = `${import.meta.env.VITE_APP_SSO_LOGINURL}?client_id=${
import.meta.env.VITE_APP_SSO_APPID
}&redirect_uri=${encodeURIComponent(
import.meta.env.VITE_REDIRECT_URL + "?redirect_path=" + redirect_path
)}&response_type=code`;
return PATH_URL;
} else {
PATH_URL = `${import.meta.env.VITE_APP_SSO_LOGINURL}?client_id=${
import.meta.env.VITE_APP_SSO_APPID
}&redirect_uri=${encodeURIComponent(import.meta.env.VITE_REDIRECT_URL)}&response_type=code`;
return PATH_URL;
}
};