Przeglądaj źródła

Display date information for entries

master
Immanuel Onyeka 2 lat temu
rodzic
commit
2361295f5f
2 zmienionych plików z 7 dodań i 2 usunięć
  1. +3
    -0
      src/Call.jsx
  2. +4
    -2
      src/Feed.jsx

+ 3
- 0
src/Call.jsx Wyświetl plik

@@ -71,6 +71,9 @@ function Call(props) {
{hour: '2-digit', minute: '2-digit'})
} - {props.info.call_type}
</h4>
<small>
{new Date(props.info.created_at).toLocaleDateString()}
</small>
</div>

<div>


+ 4
- 2
src/Feed.jsx Wyświetl plik

@@ -76,14 +76,16 @@ function Feed(props) {
}

return (
<li className={props.recent ? 'fade-in' : 'fade-in-right'} key={entry.id}>
<li className={props.recent ? 'fade-in'
: 'fade-in-right'} key={entry.id}>

<h4>{entry.direction == 'inbound' ? entry.from : entry.to}
<PhoneSymbol inbound={entry.direction == 'inbound'}>
</PhoneSymbol>
</h4>

<small>{(new Date(entry.created_at).toLocaleTimeString([],
<small>{(new Date(entry.created_at).toLocaleDateString())}
</small> <small>{(new Date(entry.created_at).toLocaleTimeString([],
{hour: '2-digit',
minute: '2-digit'}))} - {entry.call_type}
</small>


Ładowanie…
Anuluj
Zapisz