Proyectos de Subversion LeadersLinked - Antes de SPA

Rev

Rev 6959 | Rev 6976 | Ir a la última revisión | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 6959 Rev 6968
Línea 8... Línea 8...
8
 
8
 
9
import EmptySection from '../../components/UI/EmptySection'
9
import EmptySection from '../../components/UI/EmptySection'
10
import InmailChat from '../../components/chat/InmailChat'
10
import InmailChat from '../../components/chat/InmailChat'
11
import Contacts from '../../components/chat/Contacts'
11
import Contacts from '../../components/chat/Contacts'
-
 
12
import StartConversationModal from '../../components/modals/StartConversationModal'
Línea 12... Línea 13...
12
import StartConversationModal from '../../components/modals/StartConversationModal'
13
import { useParams } from 'react-router-dom'
13
 
14
 
14
const InmailPage = () => {
15
const InmailPage = () => {
15
  const [conversations, setConversations] = useState([])
16
  const [conversations, setConversations] = useState([])
Línea 21... Línea 22...
21
    {
22
    {
22
      label: 'Iniciar conversación',
23
      label: 'Iniciar conversación',
23
      action: () => toggleConversationModal(),
24
      action: () => toggleConversationModal(),
24
    },
25
    },
25
  ])
26
  ])
-
 
27
  const { uuid } = useParams()
26
  const labels = useSelector(({ intl }) => intl.labels)
28
  const labels = useSelector(({ intl }) => intl.labels)
27
  const dispatch = useDispatch()
29
  const dispatch = useDispatch()
Línea 28... Línea 30...
28
 
30
 
29
  const toggleConversationModal = () => {
31
  const toggleConversationModal = () => {
Línea 66... Línea 68...
66
    return () => {
68
    return () => {
67
      clearTimeout(messagesInterval)
69
      clearTimeout(messagesInterval)
68
    }
70
    }
69
  }, [loading])
71
  }, [loading])
Línea -... Línea 72...
-
 
72
 
-
 
73
  useEffect(() => {
-
 
74
    if (uuid && conversations.length) {
-
 
75
      const conversation = conversations.find((c) => c.uuid === uuid)
-
 
76
 
-
 
77
      setCurrentConversation(conversation)
-
 
78
    }
-
 
79
  }, [conversations])
70
 
80
 
71
  return (
81
  return (
72
    <>
82
    <>
73
      <Container>
83
      <Container>
74
        <Row>
84
        <Row>