fix: 多应用预览跳转路径不对 (#1501)
Reviewed-on: daoyoucloud/tachybase#1501 Co-authored-by: wjh <wwwjh0710@163.com> Co-committed-by: wjh <wwwjh0710@163.com>
This commit is contained in:
parent
5d51d312dc
commit
72cfc91e5f
@ -26,7 +26,7 @@ export const useGridCustomPageUrl = ({ field, fieldSchema }) => {
|
||||
fieldSchema?.parent?.parent?.['x-decorator-props']?.['linkConfig'] || {};
|
||||
const { record } = field;
|
||||
let options = '?';
|
||||
fields.forEach((item, index) => {
|
||||
fields?.forEach((item, index) => {
|
||||
if (!record[item]) return;
|
||||
return (options += `${index === 0 ? '' : '&'}${item}=${record[item]}`);
|
||||
});
|
||||
|
@ -11,7 +11,9 @@ export const OpenInNewTab = () => {
|
||||
const app = useApp();
|
||||
|
||||
const onOpenInNewTab = () => {
|
||||
window.open(app.getRouteUrl('/mobile'));
|
||||
const search = window.location;
|
||||
const hash = search.hash.slice(search.hash.indexOf('/'));
|
||||
window.open(app.getRouteUrl(hash));
|
||||
};
|
||||
|
||||
return (
|
||||
|
Loading…
Reference in New Issue
Block a user