From 9c6795fd3c44e46cf3955fbfd8f8eeca23acb7a9 Mon Sep 17 00:00:00 2001 From: king <18310653075@163.com> Date: 星期六, 08 十月 2022 00:31:51 +0800 Subject: [PATCH] 2022-10-08 --- src/components/breadview/index.jsx | 28 ++++------------------------ 1 files changed, 4 insertions(+), 24 deletions(-) diff --git a/src/components/breadview/index.jsx b/src/components/breadview/index.jsx index fe00251..62ae100 100644 --- a/src/components/breadview/index.jsx +++ b/src/components/breadview/index.jsx @@ -1,5 +1,4 @@ import React, {Component} from 'react' -import {connect} from 'react-redux' import { BackTop, Breadcrumb, notification} from 'antd' import { HomeOutlined, RightOutlined, RedoOutlined } from '@ant-design/icons' import moment from 'moment' @@ -9,7 +8,6 @@ import NotFount from '@/components/404' import options from '@/store/options.js' import MKEmitter from '@/utils/events.js' -import { initActionPermission } from '@/store/action' import Api from '@/api' import './index.scss' @@ -22,14 +20,6 @@ const Iframe = asyncComponent(() => import('@/tabviews/iframe')) const RoleManage = asyncComponent(() => import('@/tabviews/rolemanage')) const FormTab = asyncComponent(() => import('@/tabviews/formtab')) - -let service = '' - -if (process.env.NODE_ENV === 'production') { - service = document.location.origin + '/' + window.GLOB.service + 'zh-CN/' -} else { - service = window.GLOB.location + '/' + window.GLOB.service + 'zh-CN/' -} class BreadView extends Component { state = { @@ -65,7 +55,7 @@ }) } - this.props.initActionPermission(_permAction) + window.GLOB.mkActions = _permAction } resolve() @@ -93,7 +83,7 @@ // 鏍规嵁tab椤典腑鑿滃崟淇℃伅锛岄�夋嫨鎵�闇�鐨勭粍浠� if (view.type === 'Home') { return (<Home MenuNo={view.MenuNo} MenuID={view.MenuID} MenuName={view.MenuName} key={view.MenuID}/>) - } else if (view.type === 'CommonTable' || view.type === 'ManageTable') { + } else if (view.type === 'CommonTable') { return (<CommonTable MenuNo={view.MenuNo} MenuID={view.MenuID} MenuName={view.MenuName} key={view.MenuID} param={view.param}/>) // } else if (view.type === 'BaseTable') { // return (<BaseTable MenuNo={view.MenuNo} MenuID={view.MenuID} MenuName={view.MenuName} key={view.MenuID} param={view.param}/>) @@ -108,7 +98,7 @@ } else if (view.type === 'FormTab') { return (<FormTab MenuNo={view.MenuNo} MenuID={view.MenuID} MenuName={view.MenuName} key={view.MenuID} param={view.param}/>) } else if (view.type === 'iframe') { - return (<Iframe key={view.MenuID} MenuID={view.MenuID} MenuNo={view.MenuNo} title={view.MenuName} MenuName={view.MenuName} url={service + view.LinkUrl}/>) + return (<Iframe key={view.MenuID} MenuID={view.MenuID} MenuNo={view.MenuNo} title={view.MenuName} MenuName={view.MenuName} url={window.GLOB.baseurl + 'zh-CN/' + view.LinkUrl}/>) } else { return (<NotFount key={view.MenuID} />) } @@ -197,14 +187,4 @@ } } -const mapStateToProps = () => { - return {} -} - -const mapDispatchToProps = (dispatch) => { - return { - initActionPermission: (permAction) => dispatch(initActionPermission(permAction)), - } -} - -export default connect(mapStateToProps, mapDispatchToProps)(BreadView) \ No newline at end of file +export default BreadView \ No newline at end of file -- Gitblit v1.8.0