4 Revīzijas 2a3d7dc07b ... cd8c81809a

Autors SHA1 Ziņojums Datums
  amenpunk cd8c81809a change title and icon 1 gadu atpakaļ
  amenpunk 2b4f361249 some fixes 1 gadu atpakaļ
  amenpunk 30653e1529 automated register test 1 gadu atpakaļ
  amenpunk 6649f8e1ea style fixes 1 gadu atpakaļ

BIN
public/favicon.ico


BIN
public/favicon2.ico


+ 43 - 38
public/index.html

@@ -1,39 +1,42 @@
1 1
 <!DOCTYPE html>
2 2
 <html lang="es">
3
-    <head>
4
-        <meta charset="utf-8" />
5
-        <link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
6
-        <meta name="viewport" content="width=device-width, initial-scale=1" />
7
-        <meta name="theme-color" content="#fd4b4b" />
8
-
9
-        <!-- Chrome, Firefox OS and Opera -->
10
-        <meta name="theme-color" content="#fd4b4b">
11
-        <!-- Windows Phone -->
12
-        <meta name="msapplication-navbutton-color" content="#fd4b4b">
13
-        <!-- iOS Safari -->
14
-        <meta name="apple-mobile-web-app-status-bar-style" content="#fd4b4b">
15
-
16
-
17
-        <meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate" />
18
-        <meta http-equiv="Pragma" content="no-cache" />
19
-        <meta http-equiv="Expires" content="0" />
20
-
21
-        <meta
22
-                name="description"
23
-                content="Web site created using create-react-app"
24
-                />
25
-        <script defer src="https://use.fontawesome.com/releases/v5.0.13/js/solid.js" integrity="sha384-tzzSw1/Vo+0N5UhStP3bvwWPq+uvzCMfrN1fEFe+xBmv1C/AtVX5K0uZtmcHitFZ" crossorigin="anonymous"></script>
26
-        <link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.5.0/css/all.css" integrity="sha384-B4dIYHKNBt8Bc12p+WXckhzcICo0wtJAoU8YZTY5qE0Id1GSseTk6S+L3BlXeVIU" crossorigin="anonymous">
27
-        <link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" />
28
-
29
-        <!-- <link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto:300,400,500,700&display=swap" /> -->
30
-        <link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons" />
31
-        <!--
3
+
4
+<head>
5
+  <meta charset="utf-8" />
6
+  <link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
7
+  <meta name="viewport" content="width=device-width, initial-scale=1" />
8
+  <meta name="theme-color" content="#fd4b4b" />
9
+
10
+  <!-- Chrome, Firefox OS and Opera -->
11
+  <meta name="theme-color" content="#fd4b4b">
12
+  <!-- Windows Phone -->
13
+  <meta name="msapplication-navbutton-color" content="#fd4b4b">
14
+  <!-- iOS Safari -->
15
+  <meta name="apple-mobile-web-app-status-bar-style" content="#fd4b4b">
16
+
17
+
18
+  <meta http-equiv="cache-control" content="max-age=0">
19
+  <meta http-equiv="cache-control" content="no-cache">
20
+  <meta http-equiv="expires" content="-1">
21
+  <meta http-equiv="expires" content="Tue, 01 Jan 1980 11:00:00 GMT">
22
+  <meta http-equiv="pragma" content="no-cache">
23
+
24
+  <meta name="description" content="Web site created using create-react-app" />
25
+  <script defer src="https://use.fontawesome.com/releases/v5.0.13/js/solid.js"
26
+    integrity="sha384-tzzSw1/Vo+0N5UhStP3bvwWPq+uvzCMfrN1fEFe+xBmv1C/AtVX5K0uZtmcHitFZ"
27
+    crossorigin="anonymous"></script>
28
+  <link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.5.0/css/all.css"
29
+    integrity="sha384-B4dIYHKNBt8Bc12p+WXckhzcICo0wtJAoU8YZTY5qE0Id1GSseTk6S+L3BlXeVIU" crossorigin="anonymous">
30
+  <link rel="apple-touch-icon" href="%PUBLIC_URL%/logo192.png" />
31
+
32
+  <!-- <link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto:300,400,500,700&display=swap" /> -->
33
+  <link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons" />
34
+  <!--
32 35
             manifest.json provides metadata used when your web app is installed on a
33 36
             user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
34 37
         -->
35
-        <link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
36
-        <!--
38
+  <link rel="manifest" href="%PUBLIC_URL%/manifest.json" />
39
+  <!--
37 40
             Notice the use of %PUBLIC_URL% in the tags above.
38 41
             It will be replaced with the URL of the `public` folder during the build.
39 42
             Only files inside the `public` folder can be referenced from the HTML.
@@ -42,12 +45,13 @@
42 45
             work correctly both with client-side routing and a non-root public URL.
43 46
             Learn how to configure a non-root public URL by running `npm run build`.
44 47
         -->
45
-        <title>Psico Admin</title>
46
-    </head>
47
-    <body>
48
-        <noscript>You need to enable JavaScript to run this app.</noscript>
49
-        <div id="root"></div>
50
-        <!--
48
+  <title>evaluacionline</title>
49
+</head>
50
+
51
+<body>
52
+  <noscript>You need to enable JavaScript to run this app.</noscript>
53
+  <div id="root"></div>
54
+  <!--
51 55
             This HTML file is a template.
52 56
             If you open it directly in the browser, you will see an empty page.
53 57
 
@@ -57,5 +61,6 @@
57 61
             To begin the development, run `npm start` or `yarn start`.
58 62
             To create a production bundle, use `npm run build` or `yarn build`.
59 63
         -->
60
-            </body>
64
+</body>
65
+
61 66
 </html>

+ 15 - 0
src/App.css

@@ -478,3 +478,18 @@
478 478
 .lodingSpinner{
479 479
   place-self: center;
480 480
 }
481
+
482
+
483
+.text_underline:hover {
484
+  cursor: pointer;
485
+  text-decoration: underline;
486
+  text-decoration-color: blue;
487
+}
488
+
489
+/* CSS */
490
+.text_underline {
491
+  transition: color 0.3s ease; /* Transición suave del color durante 0.3 segundos */
492
+  animation: fadeIn 1s ease; /* Aplicar la animación de fade-in */
493
+}
494
+
495
+

+ 1 - 0
src/Components/Home/Candidato.jsx

@@ -186,6 +186,7 @@ function SinAsignRealizadas() {
186 186
 }
187 187
 
188 188
 export function Preview() {
189
+  console.log('preview')
189 190
   return (
190 191
     <Box sx={{ width: '100%' }}>
191 192
       <Skeleton height={big_as} animation="wave" />

+ 3 - 1
src/Components/Password/Steps/TypePwd.jsx

@@ -321,7 +321,9 @@ export function TypePwd(props) {
321 321
         </div>
322 322
 
323 323
         <div className="typepwdlist">
324
-          <FormLabel className="demo-radio-buttons-group-label">Selecciona los privilegios</FormLabel>
324
+          <FormLabel className="demo-radio-buttons-group-label">
325
+            Selecciona los privilegios
326
+          </FormLabel>
325 327
           {
326 328
             recursos &&
327 329
             Object.keys(recursos).map((k) =>

+ 5 - 2
src/Components/Puestos/GridMode.jsx

@@ -2,10 +2,13 @@ import React from "react";
2 2
 import { Grow } from '@mui/material';
3 3
 import { Col } from 'react-bootstrap'
4 4
 import { PuestoCard } from './Card';
5
+import {SinPuestos} from './SinPuestos'
5 6
 
6 7
 export function GridMode(props) {
7 8
 
8
-  let { data, index, showing, toggle } = props;
9
+  let { data, index, showing, toggle, new_puesto } = props;
10
+  
11
+  console.log(data)
9 12
 
10 13
   return (
11 14
     <React.Fragment>
@@ -21,7 +24,7 @@ export function GridMode(props) {
21 24
                 </Col>
22 25
               </Grow>
23 26
             )
24
-          }) : <div></div>
27
+          }) : <SinPuestos toggle={new_puesto}/>
25 28
       }
26 29
     </React.Fragment>
27 30
   )

+ 2 - 1
src/Components/Puestos/ListMode.jsx

@@ -4,6 +4,7 @@ import { Zoom, useMediaQuery as Size, TableCell  } from '@mui/material'
4 4
 import ShowI from '@mui/icons-material/Grading';
5 5
 import EditI from '@mui/icons-material/Edit';
6 6
 import Deletei from '@mui/icons-material/Delete';
7
+import {SinPuestos} from './SinPuestos'
7 8
 
8 9
 export function ListMode(props) {
9 10
 
@@ -63,7 +64,7 @@ export function ListMode(props) {
63 64
                       </tr>
64 65
                     </Zoom>
65 66
                   )
66
-                }) : undefined
67
+                }) : <SinPuestos toggle={props.new_puesto}/>
67 68
             }
68 69
           </tbody>
69 70
           <tfoot>

+ 9 - 0
src/Components/Puestos/SinPuestos.jsx

@@ -0,0 +1,9 @@
1
+
2
+export function SinPuestos({ toggle}) {
3
+  return (
4
+    <div style={{ paddingTop: 25  }}>
5
+      <h1>Aun no tienes puestos creados</h1>
6
+      <h1>Crea tu primer puesto haciendo click <i onClick={() => toggle()} className="text_underline">aquí</i> </h1>
7
+    </div>
8
+  )
9
+}

+ 1 - 0
src/Components/Register/Company.jsx

@@ -71,6 +71,7 @@ export function Company(props) {
71 71
           <Box sx={{ mb: 2 }}>
72 72
             <div style={{ paddingTop: 15 }}>
73 73
               <Button
74
+                name="submit_second_step"
74 75
                 type="submit"
75 76
                 className="registerBtn"
76 77
                 variant="contained"

+ 1 - 0
src/Components/Register/PersonalInfo.js

@@ -141,6 +141,7 @@ export function PersonalInfo(props) {
141 141
           <Box sx={{ mb: 2 }}>
142 142
             <div style={{ paddingTop: 15 }}>
143 143
               <Button
144
+                name="save_new_client"
144 145
                 type="submit"
145 146
                 className="registerBtn"
146 147
                 variant="contained"

+ 134 - 133
src/Components/Register/RegisterForm.jsx

@@ -4,9 +4,9 @@ import { useState } from 'react';
4 4
 import { useFormik, Form, FormikProvider } from 'formik';
5 5
 import { Icon } from '@iconify/react';
6 6
 
7
-import {  
8
-    Box, Button,
9
-    Stack, TextField, IconButton, InputAdornment, 
7
+import {
8
+  Box, Button,
9
+  Stack, TextField, IconButton, InputAdornment,
10 10
 } from '@mui/material';
11 11
 
12 12
 import eyeFill from '@iconify/icons-eva/eye-fill';
@@ -15,134 +15,135 @@ import eyeOffFill from '@iconify/icons-eva/eye-off-fill';
15 15
 
16 16
 export function RegisterForm(props) {
17 17
 
18
-    const steplen = 2;
19
-    const index = 0;
20
-
21
-    const [showPassword, setShowPassword] = useState(false);
22
-    const [showPasswordTwo, setShowPasswordTwo] = useState(false);
23
-
24
-    const RegisterSchema = Yup.object().shape({
25
-        firstName: Yup.string().min(2, 'Demasiado corto!').max(50, 'Demasiado largo!').required('Tu nombre es requerido'),
26
-        lastName: Yup.string().min(2, 'Demasiado corto!').max(50, 'Demasiado Largo!').required('El apellido es requerido'),
27
-        email: Yup.string().email('El correo no es valido').required('Email es requerido'),
28
-        password: Yup.string().min(5, 'La contraseña debe contener mínimo 5 caracteres').required('la contraseña es requerida'),
29
-        password_confirm: Yup.string().required('Las contraseñas no coincidien').oneOf([Yup.ref('password'), null], 'Las contraseñas no coincidien')
30
-    });
31
-
32
-    let {client, setClient, handleNext, handleBack } = props
33
-
34
-    const formik = useFormik({
35
-        initialValues: {
36
-            firstName: client.firstName,
37
-            lastName: client.lastName,
38
-            email: client.email,
39
-            password: client.password,
40
-            password_confirm: client.password_confirm
41
-        },
42
-        onSubmit: (fields) => {
43
-            setClient({ 
44
-                ...client,
45
-                ...fields 
46
-            })
47
-            handleNext()
48
-        },
49
-        validationSchema: RegisterSchema,
50
-    });
51
-
52
-    const {errors, touched, handleSubmit, getFieldProps } = formik;
53
-
54
-    return (
55
-        <FormikProvider style={{ padding : 15 }} value={formik}>
56
-            <Form autoComplete="off" noValidate onSubmit={handleSubmit}>
57
-                <Stack spacing={3}>
58
-                    <Stack direction={{ xs: 'column', sm: 'row' }} spacing={2}>
59
-                        <TextField
60
-                            label="Nombre"
61
-                            fullWidth
62
-                            {...getFieldProps('firstName')}
63
-                            error={Boolean(touched.firstName && errors.firstName)}
64
-                            helperText={touched.firstName && errors.firstName}
65
-                        />
66
-
67
-                        <TextField
68
-                            label="Apellidos"
69
-                            fullWidth
70
-                            {...getFieldProps('lastName')}
71
-                            error={Boolean(touched.lastName && errors.lastName)}
72
-                            helperText={touched.lastName && errors.lastName}
73
-                        />
74
-                    </Stack>
75
-
76
-                    <TextField
77
-                        fullWidth
78
-                        autoComplete="username"
79
-                        type="email"
80
-                        label="Correo Electrónico"
81
-                        {...getFieldProps('email')}
82
-                        error={Boolean(touched.email && errors.email)}
83
-                        helperText={touched.email && errors.email}
84
-                    />
85
-
86
-                    <TextField
87
-                        fullWidth
88
-                        autoComplete="current-password"
89
-                        type={showPassword ? 'text' : 'password'}
90
-                        label="Contraseña"
91
-                        {...getFieldProps('password')}
92
-                        InputProps={{
93
-                            endAdornment: (
94
-                                <InputAdornment position="end">
95
-                                    <IconButton edge="end" onClick={() => setShowPassword((prev) => !prev)}>
96
-                                        <Icon icon={showPassword ? eyeFill : eyeOffFill} />
97
-                                    </IconButton>
98
-                                </InputAdornment>
99
-                            )
100
-                        }}
101
-                        error={Boolean(touched.password && errors.password)}
102
-                        helperText={touched.password && errors.password}
103
-                    />
104
-
105
-                    <TextField
106
-                        fullWidth
107
-                        type={showPasswordTwo ? 'text' : 'password'}
108
-                        label="Confirma contraseña"
109
-                        {...getFieldProps('password_confirm')}
110
-                        InputProps={{
111
-                            endAdornment: (
112
-                                <InputAdornment position="end">
113
-                                    <IconButton edge="end" onClick={() => setShowPasswordTwo((prev) => !prev)}>
114
-                                        <Icon icon={showPasswordTwo ? eyeFill : eyeOffFill} />
115
-                                    </IconButton>
116
-                                </InputAdornment>
117
-                            )
118
-                        }}
119
-                        error={Boolean(touched.password_confirm && errors.password_confirm)}
120
-                        helperText={touched.password_confirm && errors.password_confirm}
121
-                    />
122
-
123
-
124
-                  <Box sx={{ mb: 2 }}>
125
-                    <div style={{ paddingTop  : 15}}>
126
-                      <Button
127
-                        type="submit"
128
-                        className="registerBtn" 
129
-                        variant="contained"
130
-                        sx={{ mt: 1, mr: 1 }}
131
-                      >
132
-                        {index === steplen - 1 ? 'Registrarme' : 'Siguiente'}
133
-                      </Button>
134
-                      <Button
135
-                        disabled={true}
136
-                        onClick={handleBack}
137
-                        sx={{ mt: 1, mr: 1 }}
138
-                      >
139
-                        Regresar
140
-                      </Button>
141
-                    </div>
142
-                  </Box>
143
-
144
-                </Stack>
145
-            </Form>
146
-        </FormikProvider>
147
-    );
18
+  const steplen = 2;
19
+  const index = 0;
20
+
21
+  const [showPassword, setShowPassword] = useState(false);
22
+  const [showPasswordTwo, setShowPasswordTwo] = useState(false);
23
+
24
+  const RegisterSchema = Yup.object().shape({
25
+    firstName: Yup.string().min(2, 'Demasiado corto!').max(50, 'Demasiado largo!').required('Tu nombre es requerido'),
26
+    lastName: Yup.string().min(2, 'Demasiado corto!').max(50, 'Demasiado Largo!').required('El apellido es requerido'),
27
+    email: Yup.string().email('El correo no es valido').required('Email es requerido'),
28
+    password: Yup.string().min(5, 'La contraseña debe contener mínimo 5 caracteres').required('la contraseña es requerida'),
29
+    password_confirm: Yup.string().required('Las contraseñas no coincidien').oneOf([Yup.ref('password'), null], 'Las contraseñas no coincidien')
30
+  });
31
+
32
+  let { client, setClient, handleNext, handleBack } = props
33
+
34
+  const formik = useFormik({
35
+    initialValues: {
36
+      firstName: client.firstName,
37
+      lastName: client.lastName,
38
+      email: client.email,
39
+      password: client.password,
40
+      password_confirm: client.password_confirm
41
+    },
42
+    onSubmit: (fields) => {
43
+      setClient({
44
+        ...client,
45
+        ...fields
46
+      })
47
+      handleNext()
48
+    },
49
+    validationSchema: RegisterSchema,
50
+  });
51
+
52
+  const { errors, touched, handleSubmit, getFieldProps } = formik;
53
+
54
+  return (
55
+    <FormikProvider style={{ padding: 15 }} value={formik}>
56
+      <Form autoComplete="off" noValidate onSubmit={handleSubmit}>
57
+        <Stack spacing={3}>
58
+          <Stack direction={{ xs: 'column', sm: 'row' }} spacing={2}>
59
+            <TextField
60
+              label="Nombre"
61
+              fullWidth
62
+              {...getFieldProps('firstName')}
63
+              error={Boolean(touched.firstName && errors.firstName)}
64
+              helperText={touched.firstName && errors.firstName}
65
+            />
66
+
67
+            <TextField
68
+              label="Apellidos"
69
+              fullWidth
70
+              {...getFieldProps('lastName')}
71
+              error={Boolean(touched.lastName && errors.lastName)}
72
+              helperText={touched.lastName && errors.lastName}
73
+            />
74
+          </Stack>
75
+
76
+          <TextField
77
+            fullWidth
78
+            autoComplete="username"
79
+            type="email"
80
+            label="Correo Electrónico"
81
+            {...getFieldProps('email')}
82
+            error={Boolean(touched.email && errors.email)}
83
+            helperText={touched.email && errors.email}
84
+          />
85
+
86
+          <TextField
87
+            fullWidth
88
+            autoComplete="current-password"
89
+            type={showPassword ? 'text' : 'password'}
90
+            label="Contraseña"
91
+            {...getFieldProps('password')}
92
+            InputProps={{
93
+              endAdornment: (
94
+                <InputAdornment position="end">
95
+                  <IconButton edge="end" onClick={() => setShowPassword((prev) => !prev)}>
96
+                    <Icon icon={showPassword ? eyeFill : eyeOffFill} />
97
+                  </IconButton>
98
+                </InputAdornment>
99
+              )
100
+            }}
101
+            error={Boolean(touched.password && errors.password)}
102
+            helperText={touched.password && errors.password}
103
+          />
104
+
105
+          <TextField
106
+            fullWidth
107
+            type={showPasswordTwo ? 'text' : 'password'}
108
+            label="Confirma contraseña"
109
+            {...getFieldProps('password_confirm')}
110
+            InputProps={{
111
+              endAdornment: (
112
+                <InputAdornment position="end">
113
+                  <IconButton edge="end" onClick={() => setShowPasswordTwo((prev) => !prev)}>
114
+                    <Icon icon={showPasswordTwo ? eyeFill : eyeOffFill} />
115
+                  </IconButton>
116
+                </InputAdornment>
117
+              )
118
+            }}
119
+            error={Boolean(touched.password_confirm && errors.password_confirm)}
120
+            helperText={touched.password_confirm && errors.password_confirm}
121
+          />
122
+
123
+
124
+          <Box sx={{ mb: 2 }}>
125
+            <div style={{ paddingTop: 15 }}>
126
+              <Button
127
+                name="submit_first_step"
128
+                type="submit"
129
+                className="registerBtn"
130
+                variant="contained"
131
+                sx={{ mt: 1, mr: 1 }}
132
+              >
133
+                {index === steplen - 1 ? 'Registrarme' : 'Siguiente'}
134
+              </Button>
135
+              <Button
136
+                disabled={true}
137
+                onClick={handleBack}
138
+                sx={{ mt: 1, mr: 1 }}
139
+              >
140
+                Regresar
141
+              </Button>
142
+            </div>
143
+          </Box>
144
+
145
+        </Stack>
146
+      </Form>
147
+    </FormikProvider>
148
+  );
148 149
 }

+ 11 - 15
src/Css/all.css

@@ -323,26 +323,26 @@ li.nav-item {
323 323
 .body-table {
324 324
     /* padding: 40px; */
325 325
     padding: 15px;
326
-    background: #24344d;
326
+    /* background: #24344d; */
327 327
     border-radius: 2px;
328 328
     box-shadow: 0 1px 2px rgba(0,0,0,.15), 0 -1px 0 rgba(0,0,0,.02); 
329 329
 }
330 330
 .body-table-responsive {
331 331
     font-size:13px;
332 332
     padding: 2px;
333
-    background: #24344d;
333
+    /* background: #24344d; */
334 334
     border-radius: 2px;
335 335
     box-shadow: 0 1px 2px rgba(0,0,0,.15), 0 -1px 0 rgba(0,0,0,.02); 
336 336
 }
337 337
 .body-table th {
338 338
     font-size: 14px;
339
-    color: #fff;
340
-    font-weight: 300!important;
341
-    border-top: none!important;
339
+    /* color: #fff; */
340
+    font-weight: bold;
342 341
     border-left: none!important;
343 342
     border-right: none!important;
344 343
     border-bottom: 1px solid #2e3f5b!important;
345
-    color: rgba(225,235,245,.8);
344
+    border-top: 1px solid #2e3f5b!important;
345
+    /* color: rgba(225,235,245,.8); */
346 346
 }
347 347
 .body-table tr {
348 348
     font-size: 14px;
@@ -351,14 +351,14 @@ li.nav-item {
351 351
     border-top: none!important;
352 352
     border-left: none!important;
353 353
     border-right: none!important;
354
-    border-bottom: 1px solid #2e3f5b!important;
354
+    /* border-bottom: 1px solid #2e3f5b!important; */
355 355
     background: #24344d!important;
356 356
 }
357 357
 .body-table td {
358 358
     border-top: none!important;
359 359
     border-left: none!important;
360 360
     border-right: none!important;
361
-    border-bottom: 1px solid #2e3f5b!important;
361
+    /* border-bottom: 1px solid #2e3f5b!important; */
362 362
 }
363 363
 .table-bordered {
364 364
     border-top: none!important;
@@ -1318,7 +1318,7 @@ button.restore_btn:hover {
1318 1318
 .ver_producto:hover {
1319 1319
     background: transparent;
1320 1320
     border: 1px solid #2ec5d3;
1321
-    color: #fff;
1321
+    color: black;
1322 1322
     transition: all 0.3s;
1323 1323
 }
1324 1324
 .editar_producto {
@@ -1332,7 +1332,7 @@ button.restore_btn:hover {
1332 1332
 .editar_producto:hover {
1333 1333
     background: transparent!important;
1334 1334
     border: 1px solid #5893df!important;
1335
-    color: #fff;
1335
+    color: black;
1336 1336
     transition: all 0.3s;
1337 1337
 }
1338 1338
 .eliminar_producto {
@@ -1346,7 +1346,7 @@ button.restore_btn:hover {
1346 1346
 .eliminar_producto:hover {
1347 1347
     background: transparent!important;
1348 1348
     border: 1px solid #ec5e69!important;
1349
-    color: #fff;
1349
+    color: black;
1350 1350
     transition: all 0.3s;
1351 1351
 }
1352 1352
 .col-left {
@@ -1755,12 +1755,8 @@ li.cabecera_li {
1755 1755
     padding-top: 10px;
1756 1756
     padding-bottom: 10px;
1757 1757
     border: 1px solid #dcdcdc;
1758
-    height : 53px;
1759 1758
 }
1760 1759
 .header_historial p{
1761
-    /* margin: 0!important; */
1762
-    /* padding: 0; */
1763
-    /* line-height: 1; */
1764 1760
     color: #fff;
1765 1761
     letter-spacing: 5px;
1766 1762
 }

+ 2 - 0
src/Pages/Puestos.jsx

@@ -130,6 +130,7 @@ export function Puestos() {
130 130
                   {isLoading && <Loading />}
131 131
                   { !error ?
132 132
                     <GridMode
133
+                      new_puesto={() => setManual(true) }
133 134
                       toggle={toggle}
134 135
                       showing={alignment}
135 136
                       data={filter ? Divide(filter) : Divide(result ? result.data  : [])}
@@ -144,6 +145,7 @@ export function Puestos() {
144 145
                   {isLoading && <Loading />}
145 146
                   { !error ?
146 147
                     <ListMode
148
+                      new_puesto={() => setManual(true) }
147 149
                       toggle={toggle}
148 150
                       showing={alignment}
149 151
                       data={filter ? Divide(filter) : Divide(result ? result.data : [])}

+ 3 - 0
test/.gitignore

@@ -0,0 +1,3 @@
1
+target
2
+.settings
3
+.classpath

+ 34 - 0
test/.project

@@ -0,0 +1,34 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<projectDescription>
3
+	<name>test</name>
4
+	<comment></comment>
5
+	<projects>
6
+	</projects>
7
+	<buildSpec>
8
+		<buildCommand>
9
+			<name>org.eclipse.jdt.core.javabuilder</name>
10
+			<arguments>
11
+			</arguments>
12
+		</buildCommand>
13
+		<buildCommand>
14
+			<name>org.eclipse.m2e.core.maven2Builder</name>
15
+			<arguments>
16
+			</arguments>
17
+		</buildCommand>
18
+	</buildSpec>
19
+	<natures>
20
+		<nature>org.eclipse.jdt.core.javanature</nature>
21
+		<nature>org.eclipse.m2e.core.maven2Nature</nature>
22
+	</natures>
23
+	<filteredResources>
24
+		<filter>
25
+			<id>1697254604875</id>
26
+			<name></name>
27
+			<type>30</type>
28
+			<matcher>
29
+				<id>org.eclipse.core.resources.regexFilterMatcher</id>
30
+				<arguments>node_modules|\.git|__CREATED_BY_JAVA_LANGUAGE_SERVER__</arguments>
31
+			</matcher>
32
+		</filter>
33
+	</filteredResources>
34
+</projectDescription>

+ 94 - 0
test/pom.xml

@@ -0,0 +1,94 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+
3
+<project xmlns="http://maven.apache.org/POM/4.0.0"
4
+  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
5
+  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
6
+  <modelVersion>4.0.0</modelVersion>
7
+
8
+  <groupId>com.psicoweb.test</groupId>
9
+  <artifactId>test</artifactId>
10
+  <version>1.0-SNAPSHOT</version>
11
+
12
+  <name>test</name>
13
+  <!-- FIXME change it to the project's website -->
14
+  <url>http://www.example.com</url>
15
+
16
+  <properties>
17
+    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
18
+    <maven.compiler.source>1.7</maven.compiler.source>
19
+    <maven.compiler.target>1.7</maven.compiler.target>
20
+  </properties>
21
+
22
+  <dependencies>
23
+    <dependency>
24
+      <groupId>junit</groupId>
25
+      <artifactId>junit</artifactId>
26
+      <version>4.11</version>
27
+      <scope>test</scope>
28
+    </dependency>
29
+
30
+    <dependency>
31
+      <groupId>org.seleniumhq.selenium</groupId>
32
+      <artifactId>selenium-java</artifactId>
33
+      <version>4.14.0</version>
34
+    </dependency>
35
+
36
+    <dependency>
37
+      <groupId>com.github.javafaker</groupId>
38
+      <artifactId>javafaker</artifactId>
39
+      <version>0.15</version>
40
+    </dependency>
41
+
42
+
43
+  </dependencies>
44
+
45
+  <build>
46
+    <pluginManagement><!-- lock down plugins versions to avoid using Maven defaults (may be moved to
47
+      parent pom) -->
48
+      <plugins>
49
+        <!-- clean lifecycle, see
50
+        https://maven.apache.org/ref/current/maven-core/lifecycles.html#clean_Lifecycle -->
51
+        <plugin>
52
+          <artifactId>maven-clean-plugin</artifactId>
53
+          <version>3.1.0</version>
54
+        </plugin>
55
+        <!-- default lifecycle, jar packaging: see
56
+        https://maven.apache.org/ref/current/maven-core/default-bindings.html#Plugin_bindings_for_jar_packaging -->
57
+        <plugin>
58
+          <artifactId>maven-resources-plugin</artifactId>
59
+          <version>3.0.2</version>
60
+        </plugin>
61
+        <plugin>
62
+          <artifactId>maven-compiler-plugin</artifactId>
63
+          <version>3.8.0</version>
64
+        </plugin>
65
+        <plugin>
66
+          <artifactId>maven-surefire-plugin</artifactId>
67
+          <version>2.22.1</version>
68
+        </plugin>
69
+        <plugin>
70
+          <artifactId>maven-jar-plugin</artifactId>
71
+          <version>3.0.2</version>
72
+        </plugin>
73
+        <plugin>
74
+          <artifactId>maven-install-plugin</artifactId>
75
+          <version>2.5.2</version>
76
+        </plugin>
77
+        <plugin>
78
+          <artifactId>maven-deploy-plugin</artifactId>
79
+          <version>2.8.2</version>
80
+        </plugin>
81
+        <!-- site lifecycle, see
82
+        https://maven.apache.org/ref/current/maven-core/lifecycles.html#site_Lifecycle -->
83
+        <plugin>
84
+          <artifactId>maven-site-plugin</artifactId>
85
+          <version>3.7.1</version>
86
+        </plugin>
87
+        <plugin>
88
+          <artifactId>maven-project-info-reports-plugin</artifactId>
89
+          <version>3.0.0</version>
90
+        </plugin>
91
+      </plugins>
92
+    </pluginManagement>
93
+  </build>
94
+</project>

+ 8 - 0
test/src/main/java/com/psicoweb/test/App.java

@@ -0,0 +1,8 @@
1
+package com.psicoweb.test;
2
+
3
+
4
+public class App {
5
+  public static void main(String[] args) {
6
+
7
+  }
8
+}

+ 79 - 0
test/src/test/java/com/psicoweb/test/AppTest.java

@@ -0,0 +1,79 @@
1
+package com.psicoweb.test;
2
+
3
+import static org.junit.Assert.assertTrue;
4
+
5
+import org.junit.Test;
6
+
7
+import org.openqa.selenium.By;
8
+import org.openqa.selenium.WebDriver;
9
+import org.openqa.selenium.WebElement;
10
+import org.openqa.selenium.chrome.ChromeDriver;
11
+import com.github.javafaker.Faker;
12
+
13
+import java.time.Duration;
14
+import java.util.UUID;
15
+
16
+public class AppTest {
17
+
18
+  @Test
19
+  public void resgister() {
20
+
21
+    WebDriver driver = new ChromeDriver();
22
+    Faker faker = new Faker();
23
+
24
+    String url = "http://localhost:3000/register";
25
+    driver.get(url);
26
+
27
+    driver.manage().timeouts().implicitlyWait(Duration.ofMillis(500));
28
+
29
+    // NOTE: FIRST FORM
30
+    WebElement nombre = driver.findElement(By.name("firstName"));
31
+    WebElement apellido = driver.findElement(By.name("lastName"));
32
+    WebElement email = driver.findElement(By.name("email"));
33
+    WebElement password = driver.findElement(By.name("password"));
34
+    WebElement password_confirm = driver.findElement(By.name("password_confirm"));
35
+
36
+    WebElement first_form_btn = driver.findElement(By.name("submit_first_step"));
37
+
38
+    nombre.sendKeys(faker.name().firstName());
39
+    apellido.sendKeys(faker.name().lastName());
40
+    email.sendKeys(faker.internet().emailAddress());
41
+    String pass = faker.internet().password();
42
+    password.sendKeys(pass);
43
+    password_confirm.sendKeys(pass);
44
+
45
+    first_form_btn.click();
46
+    
47
+    // NOTE: SECOND FORM
48
+
49
+    WebElement nombre_comercial = driver.findElement(By.name("nombrecpmercial"));
50
+    WebElement telefono = driver.findElement(By.name("telefono"));
51
+    WebElement descripcion = driver.findElement(By.name("decription"));
52
+
53
+    nombre_comercial.sendKeys(faker.company().name());
54
+    telefono.sendKeys("42405339");
55
+    descripcion.sendKeys(faker.company().profession());
56
+
57
+    WebElement second_form_btn = driver.findElement(By.name("submit_second_step"));
58
+    second_form_btn.click();
59
+
60
+    WebElement nit = driver.findElement(By.name("nit"));
61
+    WebElement cui = driver.findElement(By.name("cui"));
62
+    WebElement direccion = driver.findElement(By.name("direccion"));
63
+    WebElement nacimiento = driver.findElement(By.name("nacimiento"));
64
+    WebElement telefono_dos = driver.findElement(By.xpath("//*[@id=\"mui-13\"]"));
65
+
66
+    nit.sendKeys("121212");
67
+    cui.sendKeys("1111111111111111111111111111");
68
+    direccion.sendKeys(faker.address().streetName());
69
+    nacimiento.sendKeys("10/12/1995");
70
+    telefono_dos.sendKeys("42405339");
71
+
72
+    WebElement submit_btn = driver.findElement(By.name("save_new_client"));
73
+    submit_btn.click();
74
+
75
+    // driver.quit();
76
+
77
+
78
+  }
79
+}