Commit fc2a6539 by zhaochengxiang

修改内页

parent dc7019be
...@@ -362,7 +362,15 @@ module.exports = function(webpackEnv) { ...@@ -362,7 +362,15 @@ module.exports = function(webpackEnv) {
{ {
loader: "less-loader", loader: "less-loader",
options: { options: {
"javascriptEnabled": true modifyVars: {
"text-color": "#000",
"heading-color":"#000",
"text-color-secondary": "rgba(0, 0, 0, 0.85)",
"primary-color": "#249aec",
"error-color": "#f19687",
"warning-color": "#f4c660",
},
javascriptEnabled: true,
} }
}] }]
}, },
......
...@@ -29,10 +29,6 @@ ...@@ -29,10 +29,6 @@
overflow: hidden; overflow: hidden;
} }
.bg-primary {
background-color: #0168cf;
}
.d-flex { .d-flex {
display: flex; display: flex;
} }
...@@ -87,4 +83,87 @@ ...@@ -87,4 +83,87 @@
} }
::-webkit-scrollbar-thumb:hover { ::-webkit-scrollbar-thumb:hover {
background-color:#bbb; background-color:#bbb;
} }
\ No newline at end of file
.ant-table-thead > tr > th {
background: #e8f5fb !important;
text-align: center !important;
}
.ant-table-tbody > tr > td {
text-align: center !important;
}
.ant-table-title {
border: none !important;
}
.ant-table-bordered .ant-table-header > table,.ant-table-bordered .ant-table-thead > tr > th, .ant-table-bordered .ant-table-body > table, .ant-table-bordered .ant-table-tbody > tr, .ant-table-bordered .ant-table-tbody > tr > td {
border-color: rgba(36, 154, 236, 0.2) !important;
}
.ant-table-pagination.ant-pagination {
float: none !important;
text-align: center;
margin: 15px 0 !important;
}
.ant-menu {
background-color: transparent;
border-bottom: none;
}
.ant-menu-horizontal {
border-bottom: none !important;
}
.ant-menu-horizontal .ant-menu-submenu-title,
.ant-menu-horizontal .ant-menu-submenu-title:hover {
color: #fff !important;
}
.ant-menu-horizontal .ant-menu-submenu-title .anticon {
margin-right: 0 !important;
font-size: 18px !important;
}
.ant-layout-sider .ant-menu-item:after {
border: 0 !important;
}
.ant-layout-sider .ant-menu-item-selected {
background-color: #249aec !important;
color: #fff !important;
}
.ant-layout-sider .ant-menu-item-selected > a, .ant-layout-sider .ant-menu-item-selected > a:hover {
color: #fff !important;
}
.ant-layout-sider .ant-menu-submenu-open .ant-menu-submenu-title {
box-shadow:0px 2px 2px 0px rgba(0, 0, 0, 0.1);
}
.ant-layout-sider .ant-menu-sub {
background-color: #f7f7f7 !important;
}
// .ant-btn-primary {
// background-color: #249aec !important;
// }
// .ant-btn-danger {
// background-color: #f19687 !important;
// }
.ant-tabs-bar {
margin: 0 !important;
}
.ant-tabs-nav-scroll {
text-align: center !important;
}
.ant-form-item {
margin-bottom: 10px !important;
}
\ No newline at end of file
...@@ -29,7 +29,3 @@ code { ...@@ -29,7 +29,3 @@ code {
monospace; monospace;
} }
.ant-form-item {
margin-bottom: 10px !important;
}
...@@ -50,20 +50,20 @@ export default class PageHeaderWrapper extends React.Component { ...@@ -50,20 +50,20 @@ export default class PageHeaderWrapper extends React.Component {
return ( return (
<div className="page-container"> <div className="page-container">
<div className="page-container-header"> <div className="page-container-header">
<div className="pl-4 page-container-header-title"> <div className="pl-3 page-container-header-title">
{ {
curRoute && <span>{curRoute.text}</span> curRoute && <span>{curRoute.text}</span>
} }
</div> </div>
{ {
extra&&( extra&&(
<div className="ml-auto pr-4"> <div className="ml-auto pr-3">
{ extra } { extra }
</div> </div>
) )
} }
</div> </div>
<div className="m-3 page-container-content"> <div className="mt-3 page-container-content">
{ children } { children }
</div> </div>
</div> </div>
......
import React, { useState, Fragment } from "react"; import React, { useState, Fragment } from "react";
import { Link } from 'react-router-dom'; import { Link } from 'react-router-dom';
import { Layout, Menu, Icon, message } from 'antd'; import { Layout, Menu, Icon, message, Avatar } from 'antd';
import { connect } from 'react-redux'; import { connect } from 'react-redux';
import { ContextPath, Open } from '../util'; import { ContextPath, Open } from '../util';
...@@ -10,7 +10,7 @@ import { routes, routeMap } from '../routes'; ...@@ -10,7 +10,7 @@ import { routes, routeMap } from '../routes';
import './index.less'; import './index.less';
import { dispatchLatest } from "../model"; import { dispatchLatest } from "../model";
import logo from '../assets/logo_hnyc.png'; import logo from '../assets/logo.png';
const { Header, Sider, Content } = Layout; const { Header, Sider, Content } = Layout;
const { SubMenu } = Menu; const { SubMenu } = Menu;
...@@ -21,8 +21,8 @@ const _Logout = ({session, location}) => session ? ...@@ -21,8 +21,8 @@ const _Logout = ({session, location}) => session ?
<SubMenu <SubMenu
title={ title={
<Fragment> <Fragment>
<Icon type="user" /> <Avatar icon="user" />
<span>{`${session.userDName}/${session.userName}`}</span> <span className="ml-2">{`${session.userDName}/${session.userName}`}</span>
</Fragment> </Fragment>
} }
> >
...@@ -66,41 +66,45 @@ export const ManageLayout = function ({ content, location }) { ...@@ -66,41 +66,45 @@ export const ManageLayout = function ({ content, location }) {
const [collapsed, toggle] = useState(false); const [collapsed, toggle] = useState(false);
return <Layout style={{ minHeight: '100vh' }}> return <Layout style={{ minHeight: '100vh' }}>
<Sider trigger={null} collapsible collapsed={collapsed}>
<Link to={`${ContextPath}/home`} className="manage-sider-logo">
<img
src={logo}
className="mx-1"
alt=""
style={{ maxHeight: '2rem' }}
/>
</Link>
<Menu theme="dark" mode="inline"
defaultSelectedKeys={[location.pathname]}
selectedKeys={[location.pathname]}
defaultOpenKeys={[openKey]} >
{subMenus}
</Menu>
</Sider>
<Layout>
<Header className={'bg-primary d-flex manage-header'} > <Header className={'bg-primary d-flex manage-header'} >
<Link to={`${ContextPath}/home`} className="manage-sider-logo">
<img
src={logo}
alt=""
style={{ width: '150px', marginLeft: '24px' }}
/>
</Link>
<Icon <Icon
className="trigger" className="trigger"
type={collapsed ? 'menu-unfold' : 'menu-fold'} type={collapsed ? 'menu-unfold' : 'menu-fold'}
onClick={() => toggle(!collapsed)} onClick={() => toggle(!collapsed)}
style={{ marginLeft: '16px' }}
/> />
<Logout /> <Logout />
</Header> </Header>
<Content> <Layout>
{content}
</Content> <Sider trigger={null} collapsible collapsed={collapsed} style={{ backgroundColor: '#fff' }}>
<Menu mode="inline"
defaultSelectedKeys={[location.pathname]}
selectedKeys={[location.pathname]}
defaultOpenKeys={[openKey]} >
{subMenus}
</Menu>
</Sider>
<Content className="m-4" style={{ backgroundColor: '#eee' }}>
{content}
</Content>
</Layout>
</Layout> </Layout>
</Layout>
} }
export const HomeLayout = function ({ content, location }) { export const HomeLayout = function ({ content, location }) {
......
...@@ -37,7 +37,6 @@ ...@@ -37,7 +37,6 @@
display: flex; display: flex;
align-items: center; align-items: center;
height: 64px; height: 64px;
padding: 0 24px;
overflow: hidden; overflow: hidden;
} }
......
@paddingArray: 0 0, 1 2px, 2 5px, 3 10px, 4 20px, 5 30px, 6 50px, 7 100px; @paddingArray: 0 0, 1 2px, 2 5px, 3 10px, 4 15px, 5 20px, 6 30px, 7 50px, 8 100px;
.paddingNmargin(@iterator:1) when(@iterator <= length(@paddingArray)) { .paddingNmargin(@iterator:1) when(@iterator <= length(@paddingArray)) {
@name: extract(extract(@paddingArray, @iterator), 1); @name: extract(extract(@paddingArray, @iterator), 1);
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
} }
.paddingNmargin(); .paddingNmargin();
@colorArray: primary #0168cf, success @success-color, warning @warning-color, error @error-color, @colorArray: primary @primary-color, success @success-color, warning @warning-color, error @error-color,
muted @normal-color, white @white, transparent transparent; muted @normal-color, white @white, transparent transparent;
.color(@iterator:1) when(@iterator <= length(@colorArray)) { .color(@iterator:1) when(@iterator <= length(@colorArray)) {
......
...@@ -11,7 +11,6 @@ import menuImg1 from '../../assets/home/menu1.png'; ...@@ -11,7 +11,6 @@ import menuImg1 from '../../assets/home/menu1.png';
import menuImg2 from '../../assets/home/menu2.png'; import menuImg2 from '../../assets/home/menu2.png';
import menuImg3 from '../../assets/home/menu3.png'; import menuImg3 from '../../assets/home/menu3.png';
import menuImg4 from '../../assets/home/menu4.png'; import menuImg4 from '../../assets/home/menu4.png';
import menuImg5 from '../../assets/home/menu5.png';
import nodeImg1 from '../../assets/home/node1.png'; import nodeImg1 from '../../assets/home/node1.png';
import nodeImg2 from '../../assets/home/node2.png'; import nodeImg2 from '../../assets/home/node2.png';
...@@ -109,7 +108,6 @@ const homeMenu = [ ...@@ -109,7 +108,6 @@ const homeMenu = [
{ title: '元数据', img: menuImg2, url: `${ContextPath}/manage/metadata` }, { title: '元数据', img: menuImg2, url: `${ContextPath}/manage/metadata` },
{ title: '数据指标', img: menuImg3, url: `${ContextPath}/manage/indicator` }, { title: '数据指标', img: menuImg3, url: `${ContextPath}/manage/indicator` },
{ title: '数据标准', img: menuImg4, url: `${ContextPath}/manage/standard` }, { title: '数据标准', img: menuImg4, url: `${ContextPath}/manage/standard` },
// { title: '数据质量', img: menuImg5 },
]; ];
export class HomeMenu extends Component { export class HomeMenu extends Component {
......
...@@ -4,7 +4,7 @@ import { connect } from 'react-redux'; ...@@ -4,7 +4,7 @@ import { connect } from 'react-redux';
import { GetSession } from '../../util'; import { GetSession } from '../../util';
import { HomeLayout } from '../../layout'; import { HomeLayout } from '../../layout';
import { HomeSearch, HomeMenu, HomeGrid } from './HomeHelper'; import { HomeSearch, HomeMenu } from './HomeHelper';
class Home extends Component { class Home extends Component {
...@@ -18,7 +18,6 @@ class Home extends Component { ...@@ -18,7 +18,6 @@ class Home extends Component {
<div className="home-container overflow-hidden"> <div className="home-container overflow-hidden">
<HomeSearch {...this.props} /> <HomeSearch {...this.props} />
<HomeMenu /> <HomeMenu />
<HomeGrid />
</div> </div>
) )
: <GetSession {...this.props} />} : <GetSession {...this.props} />}
......
...@@ -76,7 +76,7 @@ class Assets extends Component { ...@@ -76,7 +76,7 @@ class Assets extends Component {
/> />
} }
> >
<Row gutter={16} className="manage-asset"> <Row gutter={10} className="manage-asset">
<Col md={6}> <Col md={6}>
<AssetTreeCOM treeData={treeData} onSelect={this.getList} /> <AssetTreeCOM treeData={treeData} onSelect={this.getList} />
</Col> </Col>
......
.asset-list { .asset-list {
height: calc(100vh - 148px - 48px - 42px) !important; height: calc(100vh - 168px - 48px - 42px) !important;
overflow: auto; overflow: auto;
margin-bottom: 10px; margin-bottom: 10px;
& .ant-list-item-action { & .ant-list-item-action {
...@@ -11,12 +11,12 @@ ...@@ -11,12 +11,12 @@
} }
.asset-table { .asset-table {
height: calc(100vh - 148px); height: calc(100vh - 168px);
overflow: auto; overflow: auto;
} }
.asset-tree { .asset-tree {
height: calc(100vh - 148px); height: calc(100vh - 168px);
overflow: auto; overflow: auto;
border-right: 1px solid #ededed; border-right: 1px solid #ededed;
} }
......
.asset-search { .asset-search {
.asset-list { .asset-list {
height: calc(100vh - 148px - 48px - 42px - 133px) !important; height: calc(100vh - 168px - 48px - 42px - 117px) !important;
} }
} }
\ No newline at end of file
...@@ -66,7 +66,7 @@ export default class Indicator extends Component { ...@@ -66,7 +66,7 @@ export default class Indicator extends Component {
/> />
} }
> >
<Row gutter={16} className="indicator-container" > <Row gutter={10} className="indicator-container" >
<Col md={6}> <Col md={6}>
<MetadataTreeCOM type="IndicatorCatalog" onSelect={this.onTreeSelect} /> <MetadataTreeCOM type="IndicatorCatalog" onSelect={this.onTreeSelect} />
</Col> </Col>
......
.metadata-tree { .metadata-tree {
height: calc(100vh - 148px); height: calc(100vh - 168px);
overflow: auto; overflow: auto;
} }
.metadata-list { .metadata-list {
height: calc(100vh - 148px - 48px - 42px) !important; height: calc(100vh - 168px - 48px - 42px) !important;
overflow: auto; overflow: auto;
margin-bottom: 10px; margin-bottom: 10px;
} }
\ No newline at end of file
import React, { Component } from "react"; import React, { Component } from "react";
import { Card, Form, Input, Button, message, Icon } from 'antd'; import { Form, Input, Button, message, Icon } from 'antd';
import { connect } from 'react-redux'; import { connect } from 'react-redux';
import CryptoJS from "crypto-js"; import CryptoJS from "crypto-js";
...@@ -9,8 +9,6 @@ import { dispatchLatest } from '../../model'; ...@@ -9,8 +9,6 @@ import { dispatchLatest } from '../../model';
import loginBG from "../../assets/login_bg.png"; import loginBG from "../../assets/login_bg.png";
import loginLogo from "../../assets/login_logo.png"; import loginLogo from "../../assets/login_logo.png";
import classnames from 'classnames';
class _Signin extends Component{ class _Signin extends Component{
signin = (e) => { signin = (e) => {
...@@ -45,8 +43,8 @@ class _Signin extends Component{ ...@@ -45,8 +43,8 @@ class _Signin extends Component{
return ( return (
<> <>
<img className="position-absolute" src={loginBG} style={{ objectFit: 'cover', top: 0, left: 0, right: 0 ,bottom: 0, width: '100%', height:'100%' }} /> <img className="position-absolute" src={loginBG} style={{ objectFit: 'cover', top: 0, left: 0, right: 0 ,bottom: 0, width: '100%', height:'100%' }} alt="" />
<img className="position-absolute" src={loginLogo} style={{ objectFit: 'cover',top: 20, left: 20, width: 304, height: 43 }} /> <img className="position-absolute" src={loginLogo} style={{ objectFit: 'cover',top: 20, left: 20, width: 304, height: 43 }} alt="" />
<div className="position-absolute" style={{ top: '50%', right: '10%', backgroundColor: '#fff', width: 350, transform: 'translateY(-50%)'}}> <div className="position-absolute" style={{ top: '50%', right: '10%', backgroundColor: '#fff', width: 350, transform: 'translateY(-50%)'}}>
<div style={{ padding: '30px' }}> <div style={{ padding: '30px' }}>
......
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