许静 5 gadus atpakaļ
vecāks
revīzija
5710f3dd93

+ 0
- 1
src/layouts/UserLayout.jsx Parādīt failu

@@ -34,7 +34,6 @@ const UserLayout = props => {
34 34
         <div className={styles.content}>
35 35
           {children}
36 36
         </div>
37
-        {/* <DefaultFooter /> */}
38 37
       </div>
39 38
     </DocumentTitle>
40 39
   );

+ 1
- 0
src/layouts/UserLayout.less Parādīt failu

@@ -21,6 +21,7 @@
21 21
 .content {
22 22
   flex: 1;
23 23
   padding: 32px 0;
24
+
24 25
 }
25 26
 
26 27
 @media (min-width: @screen-md-min) {

+ 8
- 2
src/pages/user/login/components/Login/LoginSubmit.jsx Parādīt failu

@@ -3,12 +3,18 @@ import React from 'react';
3 3
 import classNames from 'classnames';
4 4
 import styles from './index.less';
5 5
 const FormItem = Form.Item;
6
-
6
+import router from 'umi/router';
7
+// 跳转到编辑商品
8
+function toIndex() {
9
+  router.push({
10
+    pathname: '/welcome',
11
+  });
12
+}
7 13
 const LoginSubmit = ({ className, ...rest }) => {
8 14
   const clsString = classNames(styles.submit, className);
9 15
   return (
10 16
     <FormItem>
11
-      <Button size="large" className={clsString} type="primary" htmlType="submit" {...rest} />
17
+      <Button size="large" className={clsString} type="primary" htmlType="submit" {...rest} style={{ background: 'linear-gradient(270deg,rgba(43,112,192,1) 0%,rgba(6,185,209,1) 100%)', borderRadius: '7px', border: 'none' }} />
12 18
     </FormItem>
13 19
   );
14 20
 };

+ 6
- 2
src/pages/user/login/components/Login/index.jsx Parādīt failu

@@ -6,6 +6,7 @@ import LoginItem from './LoginItem';
6 6
 import LoginSubmit from './LoginSubmit';
7 7
 import styles from './index.less';
8 8
 
9
+
9 10
 class Login extends Component {
10 11
 
11 12
   static Submit = LoginSubmit;
@@ -13,7 +14,7 @@ class Login extends Component {
13 14
     className: '',
14 15
     defaultActiveKey: '',
15 16
     onTabChange: () => { },
16
-    onSubmit: () => { },
17
+    onSubmit: () => {},
17 18
   };
18 19
 
19 20
   constructor(props) {
@@ -112,13 +113,16 @@ class Login extends Component {
112 113
 
113 114
     });
114 115
     return (
116
+      <div  className={styles.loginBox}>
117
+      <div className={styles.leftBox}></div>
115 118
       <LoginContext.Provider value={this.getContext()}>
116
-        <div className={classNames(className, styles.login)}>
119
+        <div className={styles.login}>
117 120
           <Form onSubmit={this.handleSubmit}>
118 121
             {children}
119 122
           </Form>
120 123
         </div>
121 124
       </LoginContext.Provider>
125
+      </div>
122 126
     );
123 127
   }
124 128
 }

+ 21
- 1
src/pages/user/login/components/Login/index.less Parādīt failu

@@ -1,6 +1,26 @@
1 1
 @import '~antd/es/style/themes/default.less';
2
-
2
+.loginBox{
3
+  width:880px;
4
+height:480px;
5
+background:rgba(255,255,255,1);
6
+box-shadow:0px 2px 14px 4px rgba(0,0,0,0.12);
7
+border-radius:30px;
8
+margin: 16vh auto;
9
+.leftBox{
10
+  width:440px;
11
+height:480px;
12
+background:linear-gradient(180deg,rgba(108,193,216,1) 0%,rgba(54,141,212,1) 100%);
13
+border-radius:30px 0px 0px 30px;
14
+display: inline-block;
15
+}
16
+}
3 17
 .login {
18
+  background-color: #fff;
19
+  width:440px;
20
+  height:480px;
21
+  padding:120px 50px;
22
+  border-radius:0px 30px 30px 0px;
23
+ float: right;
4 24
   :global {
5 25
     .ant-tabs .ant-tabs-bar {
6 26
       margin-bottom: 24px;

+ 1
- 1
src/pages/user/login/style.less Parādīt failu

@@ -1,7 +1,7 @@
1 1
 @import '~antd/es/style/themes/default.less';
2 2
 
3 3
 .main {
4
-  width: 368px;
4
+  // width: 368px;
5 5
   margin: 0 auto;
6 6
   @media screen and (max-width: @screen-sm) {
7 7
     width: 95%;

+ 2
- 4
src/services/login.js Parādīt failu

@@ -1,13 +1,11 @@
1 1
 import request from 'umi-request';
2
-import { Redirect } from 'umi';
2
+
3 3
 
4 4
 export async function fakeAccountLogin(params) {
5 5
   return request('/api/admin/taUser/signin', {
6 6
     method: 'POST',
7 7
     data: params,
8
-  }).then(res => {
9
-    return <Redirect to="/welcome"></Redirect>;
10
-  });
8
+  })
11 9
 
12 10
 
13 11
 }