Commit 9d6bdf4b authored by 杨思琦's avatar 杨思琦

fix: 免登工单详情处理

parent db72ffc7
Pipeline #80023 passed with stages
......@@ -15,6 +15,13 @@ import { defaultApp } from '../../../micro';
const Login = forwardRef((props, _ref) => {
const history = useHistory();
const [action, setAction] = useState(() => new LoginAction(Object.assign({}, props, { history }), () => {}, false));
const [jumpParam] = useState(() => {
const param = params
.getParams('jumpParam')
?.replaceAll(';', ',')
?.replace(/=/g, ':');
return param ? decodeURIComponent(escape(param)) : null;
});
const [redirect] = useState(() => {
const param = params.getParams('redirect')?.replaceAll(';', '&');
return param ? decodeURIComponent(escape(param)) : null;
......@@ -91,6 +98,8 @@ const Login = forwardRef((props, _ref) => {
_.isString(redirect) && redirect.replace(new RegExp(/ /g), '').length > 0
? redirect.replace('&skipHome=true', '')
: '';
const param = JSON.parse(jumpParam);
if (param) window.sessionStorage.setItem('routerParams', JSON.stringify(param));
} catch (error) {}
// props.history.push('/' + params.getParams('redirect'))
props.history.push(`/?client=${props.global.client}`);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment