|
|
@@ -20,12 +20,12 @@
|
|
|
{
|
|
|
options: categoryData.content.value ?? [],
|
|
|
label: '分类',
|
|
|
- defaultSelectedValue: 0,
|
|
|
+ defaultSelectedValue: lastValueCategory,
|
|
|
},
|
|
|
{
|
|
|
options: computedCategoryOptions,
|
|
|
label: '状态',
|
|
|
- defaultSelectedValue: -10,
|
|
|
+ defaultSelectedValue: lastValueStatus,
|
|
|
},
|
|
|
]"
|
|
|
:load="(page: number, pageSize: number, _, searchText: string, dropDownValues: number[]) => loadInheritorData(page, pageSize, dropDownValues, searchText)"
|
|
|
@@ -47,12 +47,12 @@
|
|
|
{
|
|
|
options: categoryData.content.value ?? [],
|
|
|
label: '分类',
|
|
|
- defaultSelectedValue: 0,
|
|
|
+ defaultSelectedValue: lastValueCategory,
|
|
|
},
|
|
|
{
|
|
|
options: computedCategoryOptions,
|
|
|
label: '状态',
|
|
|
- defaultSelectedValue: -10,
|
|
|
+ defaultSelectedValue: lastValueStatus,
|
|
|
},
|
|
|
]"
|
|
|
:load="(page: number, pageSize: number, _, searchText: string, dropDownValues: number[]) => loadIchData(page, pageSize, dropDownValues, searchText)"
|
|
|
@@ -123,6 +123,7 @@ import CommonContent, { GetContentListParams } from '@/api/CommonContent';
|
|
|
import CommonListBlock, { type DropdownCommonItem } from '@/components/content/CommonListBlock.vue';
|
|
|
import InheritorContent from '@/api/inheritor/InheritorContent';
|
|
|
import AdminItemState from './components/AdminItemState.vue';
|
|
|
+import { memorizeVar } from '@/composeable/MemorizeVar';
|
|
|
|
|
|
const { toClipboard } = useClipboard();
|
|
|
const router = useRouter();
|
|
|
@@ -131,6 +132,9 @@ const authStore = useAuthStore();
|
|
|
const activeKey = ref(route.query.tab as string || '1');
|
|
|
const inheritorData = ref<GetContentListItem[]>([]);
|
|
|
|
|
|
+const { variable: lastValueCategory } = memorizeVar('categoryLastSelectValue', 0);
|
|
|
+const { variable: lastValueStatus } = memorizeVar('statusLastSelectValue', -10);
|
|
|
+
|
|
|
const computedCategoryOptions = computed<DropdownCommonItem[]>(() => {
|
|
|
if (authStore.isReviewer) {
|
|
|
return [
|
|
|
@@ -169,6 +173,8 @@ const categoryData = useSimpleDataLoader(async () => {
|
|
|
})
|
|
|
|
|
|
async function loadInheritorData(page: number, pageSize: number, dropDownValues: number[], searchText: string) {
|
|
|
+ lastValueCategory.value = dropDownValues[0];
|
|
|
+ lastValueStatus.value = dropDownValues[1];
|
|
|
const submitList = await InheritorContent.getInheritorSubmtList(7);
|
|
|
const res = await CommonContent.getContentList(
|
|
|
new GetContentListParams()
|
|
|
@@ -198,6 +204,8 @@ async function loadInheritorData(page: number, pageSize: number, dropDownValues:
|
|
|
}
|
|
|
}
|
|
|
async function loadIchData(page: number, pageSize: number, dropDownValues: number[], searchText: string) {
|
|
|
+ lastValueCategory.value = dropDownValues[0];
|
|
|
+ lastValueStatus.value = dropDownValues[1];
|
|
|
const submitList = await InheritorContent.getInheritorSubmtList(2);
|
|
|
const res = await CommonContent.getContentList(
|
|
|
new GetContentListParams()
|