Добавлена маршрутизация, выбор вида списка: Авторы, Серии, Книги
This commit is contained in:
@@ -122,7 +122,7 @@
|
||||
</div>
|
||||
<!-- Формирование списка конец ------------------------------------------------------------------>
|
||||
|
||||
<div v-if="ready && !refreshing && !tableData.length" class="row items-center q-ml-md" style="font-size: 120%">
|
||||
<div v-if="!refreshing && !tableData.length" class="row items-center q-ml-md" style="font-size: 120%">
|
||||
<q-icon class="la la-meh q-mr-xs" size="28px" />
|
||||
Поиск не дал результатов
|
||||
</div>
|
||||
@@ -176,16 +176,11 @@ const componentOptions = {
|
||||
showDeleted() {
|
||||
this.updateTableData();
|
||||
},
|
||||
ready(newValue) {
|
||||
if (newValue)
|
||||
this.refresh();//no await
|
||||
}
|
||||
},
|
||||
};
|
||||
class AuthorList extends BaseList {
|
||||
_options = componentOptions;
|
||||
_props = {
|
||||
ready: Boolean,
|
||||
list: Object,
|
||||
search: Object,
|
||||
genreMap: Object,
|
||||
@@ -221,6 +216,10 @@ class AuthorList extends BaseList {
|
||||
this.loadSettings();
|
||||
}
|
||||
|
||||
mounted() {
|
||||
this.refresh();//no await
|
||||
}
|
||||
|
||||
loadSettings() {
|
||||
const settings = this.settings;
|
||||
|
||||
@@ -811,9 +810,6 @@ class AuthorList extends BaseList {
|
||||
}
|
||||
|
||||
async refresh() {
|
||||
if (!this.ready)
|
||||
return;
|
||||
|
||||
//параметры запроса
|
||||
const newQuery = _.cloneDeep(this.search);
|
||||
newQuery.offset = (newQuery.page - 1)*newQuery.limit;
|
||||
|
||||
Reference in New Issue
Block a user