Explorar el Código

Merge branch 'master' of http://git.ycjcjy.com/kypay/global_funding-pc-merchant

fangmingyue hace 1 año
padre
commit
4469303fa2

+ 11
- 0
src/index.less Ver fichero

@@ -39,6 +39,7 @@ body,
39 39
 .layout-sidebar {
40 40
   width: var(--siderbar-width);
41 41
   color: var(--theme-front);
42
+  background: #ffffff !important;
42 43
 }
43 44
 
44 45
 .ant-card,
@@ -76,4 +77,14 @@ body,
76 77
 
77 78
 .pointer {
78 79
   cursor: pointer;
80
+}
81
+
82
+.ant-btn-primary {
83
+  border-color: #3eaeb4;
84
+  background: #3eaeb4;
85
+}
86
+
87
+.ant-btn-primary:hover {
88
+  border-color: #389da2;
89
+  background-color: #389da2;
79 90
 }

+ 17
- 9
src/layouts/AuthLayout/components/Footer.jsx Ver fichero

@@ -1,15 +1,23 @@
1
-import React from 'react';
2
-import { Layout } from 'antd';
3
-import { useModel } from '@/store';
1
+import React from "react";
2
+import { Layout } from "antd";
3
+import { useModel } from "@/store";
4 4
 
5 5
 const { Footer } = Layout;
6 6
 
7 7
 const year = new Date().getFullYear();
8 8
 export default React.forwardRef((props, ref) => {
9
-  const { app } = useModel('system');
10
-  const copyRight = `${app.company || '南京云致'} @ ${year}`;
9
+  const { app } = useModel("system");
10
+  const copyRight = `${app.company || "南京云致"} @ ${year}`;
11 11
 
12
-  return (
13
-    <Footer ref={ref} style={{ textAlign: 'center', color: 'rgba(0,0,0, 0.3)' }}>{copyRight}</Footer>
14
-  )
15
-})
12
+  return ( 
13
+    <Footer
14
+      ref={ref}
15
+      style={{
16
+        textAlign: "center", 
17
+        color: "rgba(0,0,0, 0.3)",
18
+      }}
19
+    >
20
+      {copyRight}
21
+    </Footer>
22
+  );
23
+});

+ 25
- 16
src/layouts/AuthLayout/components/Header/index.jsx Ver fichero

@@ -1,30 +1,39 @@
1
-import React, { useMemo } from 'react';
2
-import { Layout, Space } from 'antd';
3
-import classNames from 'classnames';
4
-import Title from './Title';
5
-import User from './User';
6
-import Exit from './Exit';
7
-import Logo from '../Logo';
8
-import Language from './Language';
1
+import React, { useMemo } from "react";
2
+import { Layout, Space } from "antd";
3
+import classNames from "classnames";
4
+import Title from "./Title";
5
+import User from "./User";
6
+import Exit from "./Exit";
7
+import Logo from "../Logo";
8
+import Language from "./Language";
9 9
 
10 10
 const { Header } = Layout;
11
+// const style = {
12
+//   background: "#f7fafa !important",
13
+//   display: "flex",
14
+//   justifyContent: "flex-end",
15
+// };
11 16
 
12 17
 export default (props) => {
13 18
   const { user } = props;
14 19
 
15
-  const className = useMemo(() => classNames({
16
-    'layout-header': true,
17
-    'light': props.theme === 'light',
18
-  }), [props.theme]);
19
-
20
+  const className = useMemo(
21
+    () =>
22
+      classNames({
23
+        "layout-header": true,
24
+        light: props.theme === "light",
25
+      }),
26
+    [props.theme]
27
+  );
20 28
   return (
21
-    <Header className={className}>
29
+    <Header className={className} >
22 30
       <Logo />
31
+
23 32
       <Space>
24 33
         <Language />
25 34
         <User user={user} />
26 35
         <Exit />
27 36
       </Space>
28 37
     </Header>
29
-  )
30
-}
38
+  );
39
+};

+ 8
- 8
src/layouts/AuthLayout/components/SiderBar.jsx Ver fichero

@@ -1,21 +1,21 @@
1
-import React, { useMemo } from 'react';
2
-import { Layout, Spin } from 'antd';
3
-import { getPropertyValue } from '@/utils/css';
4
-import Menus from './Menus';
1
+import React, { useMemo } from "react";
2
+import { Layout, Spin } from "antd";
3
+import { getPropertyValue } from "@/utils/css";
4
+import Menus from "./Menus";
5
+import Logo from "./Logo";
5 6
 
6 7
 const { Sider } = Layout;
7 8
 
8
-
9 9
 export default (props) => {
10 10
   const { theme, location, menus } = props;
11 11
 
12 12
   const width = useMemo(() => {
13
-    return /\d+/.exec(getPropertyValue('--siderbar-width'))[0] - 0;
13
+    return /\d+/.exec(getPropertyValue("--siderbar-width"))[0] - 0;
14 14
   }, []);
15 15
 
16 16
   return (
17
-    <Sider className='layout-sidebar' theme={theme} collapsible width={width}>
17
+    <Sider className="layout-sidebar" theme={theme} collapsible width={width}>
18 18
       <Menus theme={theme} items={menus} location={location} />
19 19
     </Sider>
20 20
   );
21
-}
21
+};

+ 4
- 1
src/layouts/AuthLayout/index.jsx Ver fichero

@@ -13,6 +13,9 @@ import { authRoutes } from "@/routes/routes";
13 13
 import { getMenuItems } from "@/routes/menus";
14 14
 import RequireLogin from "./RequireLogin";
15 15
 import "./style.less";
16
+import Sider from "antd/lib/layout/Sider";
17
+import Login from "@/pages/login";
18
+import Logo from "./components/Logo";
16 19
 
17 20
 const Spinner = () => (
18 21
   <div
@@ -42,7 +45,7 @@ export default (props) => {
42 45
       {/* <React.Suspense fallback={<Spinner />}> */}
43 46
       <RequireLogin>
44 47
         <Layout className={theme} style={{ height: "100vh" }}>
45
-          <Header theme={theme} user={user} />
48
+            <Header theme={theme} user={user} />
46 49
           <Layout style={{ height: "calc(100vh - var(--header-height))" }}>
47 50
             <SiderBar theme="light" menus={menus} location={location} />
48 51
             <Container location={location} />

+ 6
- 3
src/layouts/AuthLayout/style.less Ver fichero

@@ -46,7 +46,7 @@
46 46
   padding-left: 1em;
47 47
   color: inherit;
48 48
 
49
-  & > * {
49
+  &>* {
50 50
     color: inherit;
51 51
     margin: 0;
52 52
   }
@@ -68,6 +68,7 @@
68 68
   overflow-y: auto;
69 69
   scrollbar-width: none;
70 70
   -ms-overflow-style: none;
71
+  background-color: #f7fafa !important;
71 72
 
72 73
   &::--webkit-scrollbar {
73 74
     display: none;
@@ -75,7 +76,9 @@
75 76
 
76 77
   padding-top: 0; // 避免子元素的 margin 影响
77 78
 }
78
-
79
+.ant-layout-footer {
80
+  background: none;
81
+}
79 82
 .ant-menu-vertical {
80 83
   border: none;
81
-}
84
+}

+ 2
- 1
src/theme.less Ver fichero

@@ -6,6 +6,7 @@
6 6
   .ant-layout-sider-trigger,
7 7
   .ant-menu
8 8
    {
9
-    background: transparent !important;
9
+    // background: transparent !important;
10
+    background: #FFF !important;
10 11
   }
11 12
 }

+ 1
- 1
src/utils/request.js Ver fichero

@@ -36,7 +36,7 @@ instance.interceptors.request.use(
36 36
         "Content-Type": "application/json;charset=utf-8",
37 37
         ...headers,
38 38
         Authorization: token,
39
-        "x-client-type": "pc.admin",
39
+        // "x-client-type": "pc.admin",
40 40
       },
41 41
       responseType: download ? "blob" : responseType,
42 42
     };