Proyectos de Subversion LeadersLinked - SPA

Rev

Rev 2614 | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 2614 Rev 2827
Línea 1... Línea 1...
1
import React from 'react'
1
import React from 'react'
2
import { useNavigate } from 'react-router-dom'
2
import { useNavigate } from 'react-router-dom'
3
import {
-
 
4
  Avatar,
-
 
5
  Button,
-
 
6
  CardActions,
-
 
7
  CardContent,
-
 
8
  CardMedia,
-
 
9
  Typography
-
 
10
} from '@mui/material'
3
import { Avatar, Button, Typography } from '@mui/material'
11
import { useDispatch } from 'react-redux'
4
import { useDispatch } from 'react-redux'
12
import parse from 'html-react-parser'
5
import parse from 'html-react-parser'
Línea 13... Línea 6...
13
 
6
 
14
import { axios } from '@app/utils'
7
import { axios } from '@app/utils'
Línea 15... Línea 8...
15
import { addNotification } from '@app/redux/notification/notification.actions'
8
import { addNotification } from '@app/redux/notification/notification.actions'
Línea 16... Línea 9...
16
 
9
 
17
import WidgetWrapper from '../widgets/WidgetLayout'
10
import Widget from '@components/UI/Widget'
18
 
11
 
19
const CompanyActions = ({
12
const CompanyActions = ({
20
  cover = '',
13
  cover = '',
21
  name = '',
14
  name = '',
22
  image = '',
15
  image = '',
23
  actionLinks = {},
-
 
24
  overview = '',
16
  actionLinks = {},
25
  refetch = () => {}
17
  overview = '',
26
  // companyId
18
  refetch = () => {}
27
}) => {
19
}) => {
28
  const {
20
  const {
Línea 49... Línea 41...
49
      )
41
      )
50
    }
42
    }
51
  }
43
  }
Línea 52... Línea 44...
52
 
44
 
53
  return (
45
  return (
54
    <WidgetWrapper>
46
    <Widget>
-
 
47
      <Widget.Media height={150} src={cover} />
55
      <CardMedia component='img' height='150' image={cover} />
48
 
56
      <CardContent sx={{ paddingBottom: 0 }}>
49
      <Widget.Body>
57
        <Avatar
50
        <Avatar
58
          src={image}
51
          src={image}
59
          alt={name}
52
          alt={name}
60
          sx={{ mt: '-40px', width: '80px', height: '80px' }}
53
          sx={{ mt: '-40px', width: '80px', height: '80px' }}
61
        />
54
        />
62
        <Typography variant='h2'>{name}</Typography>
55
        <Typography variant='h2'>{name}</Typography>
63
        <Typography variant='body1'>{parse(overview ?? '')}</Typography>
56
        <Typography variant='body1'>{parse(overview ?? '')}</Typography>
-
 
57
      </Widget.Body>
64
      </CardContent>
58
 
65
      <CardActions sx={{ paddingTop: 0 }}>
59
      <Widget.Actions>
66
        {link_contact && (
60
        {link_contact && (
67
          <Button variant='primary' onClick={() => navigate(link_contact)}>
61
          <Button variant='primary' onClick={() => navigate(link_contact)}>
68
            Mensaje
62
            Mensaje
69
          </Button>
63
          </Button>
Línea 122... Línea 116...
122
            onClick={() => handleButtonAction(link_leave)}
116
            onClick={() => handleButtonAction(link_leave)}
123
          >
117
          >
124
            Abandonar esta empresa
118
            Abandonar esta empresa
125
          </Button>
119
          </Button>
126
        )}
120
        )}
127
      </CardActions>
121
      </Widget.Actions>
128
    </WidgetWrapper>
122
    </Widget>
129
  )
123
  )
130
}
124
}
Línea 131... Línea 125...
131
 
125