list sessions according to the fetch status
This commit is contained in:
parent
97d23a6bcb
commit
49d3e2a4ac
|
|
@ -40,7 +40,7 @@ function JKMusicSessions() {
|
|||
<CardBody className="pt-0">
|
||||
{loadingStatus === 'loading' && sessions.length === 0 ? (
|
||||
<Loader />
|
||||
) : isIterableArray(sessions) ? (
|
||||
) : loadingStatus === "succeeded" && sessions.length > 0 ? (
|
||||
<>
|
||||
{greaterThan.sm ? (
|
||||
<Row className="mb-3 justify-content-between d-none d-md-block">
|
||||
|
|
@ -54,7 +54,7 @@ function JKMusicSessions() {
|
|||
</Row>
|
||||
)}
|
||||
</>
|
||||
) : (
|
||||
) : loadingStatus === "succeeded" && sessions.length <= 0 ? (
|
||||
<Row className="p-card">
|
||||
<Col>
|
||||
{t('list.no_records_1', { ns: 'sessions' })}
|
||||
|
|
@ -62,7 +62,13 @@ function JKMusicSessions() {
|
|||
{t('list.no_records_2', { ns: 'sessions' })}
|
||||
</Col>
|
||||
</Row>
|
||||
)}
|
||||
) : loadingStatus === "failed" ? (
|
||||
<Row className="p-card">
|
||||
<Col>
|
||||
{t('list.error', { ns: 'sessions' })}
|
||||
</Col>
|
||||
</Row>
|
||||
) : null }
|
||||
</CardBody>
|
||||
</Card>
|
||||
<JKModalDialog
|
||||
|
|
|
|||
|
|
@ -40,7 +40,8 @@
|
|||
},
|
||||
"no_records_1": "There are no public, open sessions currently available for you to join. We suggest you ",
|
||||
"create_session": "create a session",
|
||||
"no_records_2": " that others can join now, or wait a bit and then refresh this page in your browser to see if new public sessions have been started."
|
||||
"no_records_2": " that others can join now, or wait a bit and then refresh this page in your browser to see if new public sessions have been started.",
|
||||
"error": "There was an error retrieving the session list. Please try again."
|
||||
},
|
||||
"lobby": {
|
||||
"page_title": "Lobby",
|
||||
|
|
|
|||
Loading…
Reference in New Issue