Mila-Zagrevskaya 5 лет назад
Родитель
Сommit
836fef0944
3 измененных файлов с 18 добавлено и 9 удалено
  1. 4 7
      src/components/Admin/Orders/Orders.js
  2. 1 1
      src/containers/user.js
  3. 13 1
      src/style/user.scss

+ 4 - 7
src/components/Admin/Orders/Orders.js

@@ -1,6 +1,7 @@
 import React, {Component} from 'react';
 import {Link} from 'react-router-dom'
 import ChangeOrder from "./ChangeOrder";
+
 class Orders extends Component {
     state={
         order:null,
@@ -8,7 +9,6 @@ class Orders extends Component {
 
     componentDidMount() {
         this.props.getUsers();
-
     }
 
     componentDidUpdate(prevProps, prevState, snapshot) {
@@ -42,7 +42,7 @@ class Orders extends Component {
     };
 
     render() {
-        const{findOrderInput,ordersArray,searching,orders,doctors,services,
+        const{ findOrderInput,ordersArray,searching,orders,doctors,services,
             appointment,
             timeArray,
             setAppointmentSpec,
@@ -94,10 +94,7 @@ class Orders extends Component {
                         </div>
                     ))}
                 </div>
-                <div className = "orders-item" style={{
-                    display:'flex',
-                    flexDirection:'column',
-                }}>
+                <div className = "orders-item">
                     {orders.map(el => (
                         <div  className = "order"  key={el._id} >
                             <div className = "order-date">
@@ -116,7 +113,7 @@ class Orders extends Component {
                     ))}
                 </div>
             </div>
-                </>
+        </>
         );
     }
 }

+ 1 - 1
src/containers/user.js

@@ -41,7 +41,7 @@ class UserContainer extends Component {
       <div className="main">
         <div className="info-wrap">
           <h2>Добро пожаловать в личный кабинет, {currentUser.firstName}!</h2>
-          <div className="btn-box">
+          <div className="btn-box user-btn-box">
             <Link to="/user/orders" className="btn link admin user-link">
               Мои заказы
             </Link>

+ 13 - 1
src/style/user.scss

@@ -5,7 +5,9 @@
     margin: 10px 5px;
   }
 }
-
+.user-btn-box {
+  justify-content: space-evenly;
+}
 .user-info {
   display: flex;
   justify-content: center;
@@ -29,9 +31,17 @@
   display: flex;
   justify-content: space-between;
   align-items: flex-start;
+  flex-wrap: wrap;
   margin-top: 20px;
   &__content {
     color: #789084;
+    padding: 5px;
+    margin: 10px;
+    align-items: stretch;
+    align-content: stretch;
+    height: 100%;
+    flex-basis: 30%;
+    border: 1px solid;
     box-shadow: 0 1.5rem 4rem rgba(17, 17, 17, 1.5);
     border-radius: 10px;
     background-color: rgba(17, 17, 17, 0.5);
@@ -39,11 +49,13 @@
 
   &__heading {
     // margin: 2px;
+    margin: 15px 0;
     text-align: center;
     border-bottom: 1px solid rgba(17, 17, 17, 0.8);
   }
   &__paragraph {
     text-align: center;
+    margin: 5px;
   }
   @media (max-width: 769px) {
     display: block;