mirror of
https://github.com/nocobase/nocobase
synced 2024-11-15 09:47:10 +00:00
fix: move page templates to pages/index
This commit is contained in:
parent
bd1449e87a
commit
e443857309
@ -2,7 +2,7 @@ import React, { useState } from 'react';
|
|||||||
// import { request } from 'umi';
|
// import { request } from 'umi';
|
||||||
import { TemplateLoader } from './TemplateLoader';
|
import { TemplateLoader } from './TemplateLoader';
|
||||||
import { useRequest, request } from '@nocobase/client';
|
import { useRequest, request } from '@nocobase/client';
|
||||||
import templates from '@/templates';
|
import { templates } from '@/pages';
|
||||||
import api from '@/api-client';
|
import api from '@/api-client';
|
||||||
|
|
||||||
export function PageLoader(props: any) {
|
export function PageLoader(props: any) {
|
||||||
|
@ -1,4 +1,13 @@
|
|||||||
// import PageLoader from '@nocobase/plugin-pages/lib/components/index';
|
|
||||||
import PageLoader from '@/components/pages';
|
import PageLoader from '@/components/pages';
|
||||||
|
|
||||||
|
export const templates = {
|
||||||
|
TopMenuLayout: require('@/components/pages/TopMenuLayout').default,
|
||||||
|
SideMenuLayout: require('@/components/pages/SideMenuLayout').default,
|
||||||
|
AdminLoader: require('@/components/pages/AdminLoader').default,
|
||||||
|
login: require('@/pages/login').default,
|
||||||
|
register: require('@/pages/register').default,
|
||||||
|
lostpassword: require('@/pages/lostpassword').default,
|
||||||
|
resetpassword: require('@/pages/resetpassword').default,
|
||||||
|
};
|
||||||
|
|
||||||
export default PageLoader;
|
export default PageLoader;
|
||||||
|
@ -1,18 +0,0 @@
|
|||||||
/**
|
|
||||||
* 模板映射暂时先放在这里
|
|
||||||
*/
|
|
||||||
export default {
|
|
||||||
'TopMenuLayout': require('@/components/pages/TopMenuLayout').default,
|
|
||||||
'SideMenuLayout': require('@/components/pages/SideMenuLayout').default,
|
|
||||||
'layout1': require('@/components/pages/TopMenuLayout').default,
|
|
||||||
'layout2': require('@/components/pages/SideMenuLayout').default,
|
|
||||||
'page1': require('@/pages/page1').default,
|
|
||||||
'page2': require('@/pages/page2').default,
|
|
||||||
'page3': require('@/pages/page3').default,
|
|
||||||
'page4': require('@/pages/page4').default,
|
|
||||||
login: require('@/pages/login').default,
|
|
||||||
register: require('@/pages/register').default,
|
|
||||||
lostpassword: require('@/pages/lostpassword').default,
|
|
||||||
resetpassword: require('@/pages/resetpassword').default,
|
|
||||||
AdminLoader: require('@/components/pages/AdminLoader').default,
|
|
||||||
};
|
|
Loading…
Reference in New Issue
Block a user