diff --git a/public/config.js b/public/config.js index 3961c92..76939e6 100644 --- a/public/config.js +++ b/public/config.js @@ -2,5 +2,6 @@ // 部署时可以直接修改这个文件来改变配置,无需重新编译 window.APP_CONFIG = { // 权限验证开关:'1' 开启,'0' 关闭 - AUTH_ACCESS: "0", + AUTH_ACCESS: "1", + ICP_NUMBER: "", }; \ No newline at end of file diff --git a/src/pages/login/comonents/PhoneLogin.tsx b/src/pages/login/comonents/PhoneLogin.tsx index c39c93a..4cea270 100644 --- a/src/pages/login/comonents/PhoneLogin.tsx +++ b/src/pages/login/comonents/PhoneLogin.tsx @@ -14,6 +14,9 @@ const PhoneLogin: React.FC = ({ handleLoginSuccess }) => { const [countdown, setCountdown] = useState(0); const [isLoading, setIsLoading] = useState(false); + // 获取备案号配置 + const icpNumber = (window as any).APP_CONFIG?.ICP_NUMBER; + // 发送验证码 const handleSendCode = async () => { if (!phone || !/^1[3-9]\d{9}$/.test(phone)) { @@ -144,6 +147,13 @@ const PhoneLogin: React.FC = ({ handleLoginSuccess }) => { ) : '登录'} + + {/* 备案号显示 */} + {icpNumber && ( +
+ {icpNumber} +
+ )} );