fix correct display recent
This commit is contained in:
parent
b6598370af
commit
524cd875e1
@ -23,8 +23,12 @@ class RecentMapper extends QBMapper {
|
||||
public function find(int $id, string $userId): Station {
|
||||
/* @var $qb IQueryBuilder */
|
||||
$qb = $this->db->getQueryBuilder();
|
||||
$qb->select('*')
|
||||
$qb->selectDistinct('stationuuid')
|
||||
->addSelect('name')
|
||||
->addSelect('favicon')
|
||||
->addSelect('urlresolved')
|
||||
->from('recent')
|
||||
->orderBy('id', 'DESC')
|
||||
->where($qb->expr()->eq('id', $qb->createNamedParameter($id, IQueryBuilder::PARAM_INT)))
|
||||
->andWhere($qb->expr()->eq('user_id', $qb->createNamedParameter($userId)));
|
||||
return $this->findEntity($qb);
|
||||
@ -37,8 +41,12 @@ class RecentMapper extends QBMapper {
|
||||
public function findAll(string $userId): array {
|
||||
/* @var $qb IQueryBuilder */
|
||||
$qb = $this->db->getQueryBuilder();
|
||||
$qb->select('*')
|
||||
$qb->selectDistinct('stationuuid')
|
||||
->addSelect('name')
|
||||
->addSelect('favicon')
|
||||
->addSelect('urlresolved')
|
||||
->from('recent')
|
||||
->orderBy('id', 'DESC')
|
||||
->where($qb->expr()->eq('user_id', $qb->createNamedParameter($userId)));
|
||||
return $this->findEntities($qb);
|
||||
}
|
||||
|
@ -3,14 +3,6 @@
|
||||
<Navigation
|
||||
:station-data="tableData" />
|
||||
<AppContent>
|
||||
<Breadcrumbs
|
||||
v-if="tableData.length > 0"
|
||||
class="breadcrumbs">
|
||||
<Breadcrumb title="Home" href="/" />
|
||||
<Breadcrumb
|
||||
:title="t('radio', 'Top')"
|
||||
href="/Top" />
|
||||
</Breadcrumbs>
|
||||
<Table
|
||||
v-if="!pageLoading && tableData.length > 0"
|
||||
:station-data="tableData"
|
||||
@ -40,7 +32,6 @@
|
||||
No stations were found matching your search term
|
||||
</template>
|
||||
</EmptyContent>
|
||||
<Sidebar />
|
||||
</template>
|
||||
</AppContent>
|
||||
</Content>
|
||||
@ -49,18 +40,15 @@
|
||||
<script>
|
||||
import Content from '@nextcloud/vue/dist/Components/Content'
|
||||
import AppContent from '@nextcloud/vue/dist/Components/AppContent'
|
||||
import Breadcrumbs from '@nextcloud/vue/dist/Components/Breadcrumbs'
|
||||
import Breadcrumb from '@nextcloud/vue/dist/Components/Breadcrumb'
|
||||
import EmptyContent from '@nextcloud/vue/dist/Components/EmptyContent'
|
||||
import generateUrl from '@nextcloud/router'
|
||||
import { generateUrl } from '@nextcloud/router'
|
||||
import { showError } from '@nextcloud/dialogs'
|
||||
import axios from '@nextcloud/axios'
|
||||
|
||||
import Navigation from './Navigation'
|
||||
import Sidebar from './Sidebar'
|
||||
import Table from './Table'
|
||||
|
||||
import Howl from 'howler'
|
||||
import { Howl } from 'howler'
|
||||
|
||||
let audioPlayer = null
|
||||
|
||||
@ -70,11 +58,8 @@ export default {
|
||||
Navigation,
|
||||
Content,
|
||||
AppContent,
|
||||
Breadcrumbs,
|
||||
Breadcrumb,
|
||||
Table,
|
||||
EmptyContent,
|
||||
Sidebar,
|
||||
},
|
||||
data: () => ({
|
||||
tableData: [],
|
||||
|
@ -115,8 +115,7 @@ table {
|
||||
background-color: var(--color-main-background-translucent);
|
||||
z-index: 60;
|
||||
position: sticky;
|
||||
position: -webkit-sticky;
|
||||
top: 99px;
|
||||
top: 50px;
|
||||
|
||||
th {
|
||||
border-bottom: 1px solid var(--color-border);
|
||||
|
Loading…
Reference in New Issue
Block a user