|
@@ -16,11 +16,18 @@
|
|
:showTotal="true"
|
|
:showTotal="true"
|
|
:rowCount="1"
|
|
:rowCount="1"
|
|
:rowType="5"
|
|
:rowType="5"
|
|
- :dropDownNames="[{
|
|
|
|
- options: categoryData.content.value ?? [],
|
|
|
|
- label: '分类',
|
|
|
|
- defaultSelectedValue: 0,
|
|
|
|
- }]"
|
|
|
|
|
|
+ :dropDownNames="[
|
|
|
|
+ {
|
|
|
|
+ options: categoryData.content.value ?? [],
|
|
|
|
+ label: '分类',
|
|
|
|
+ defaultSelectedValue: 0,
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ options: computedCategoryOptions,
|
|
|
|
+ label: '状态',
|
|
|
|
+ defaultSelectedValue: -10,
|
|
|
|
+ },
|
|
|
|
+ ]"
|
|
:load="(page: number, pageSize: number, _, searchText: string, dropDownValues: number[]) => loadInheritorData(page, pageSize, dropDownValues, searchText)"
|
|
:load="(page: number, pageSize: number, _, searchText: string, dropDownValues: number[]) => loadInheritorData(page, pageSize, dropDownValues, searchText)"
|
|
:showDetail="(item) => router.push({ name: 'FormInheritor', query: { id: item.id } })"
|
|
:showDetail="(item) => router.push({ name: 'FormInheritor', query: { id: item.id } })"
|
|
>
|
|
>
|
|
@@ -36,11 +43,18 @@
|
|
:showTotal="true"
|
|
:showTotal="true"
|
|
:rowCount="1"
|
|
:rowCount="1"
|
|
:rowType="5"
|
|
:rowType="5"
|
|
- :dropDownNames="[{
|
|
|
|
- options: categoryData.content.value ?? [],
|
|
|
|
- label: '分类',
|
|
|
|
- defaultSelectedValue: 0,
|
|
|
|
- }]"
|
|
|
|
|
|
+ :dropDownNames="[
|
|
|
|
+ {
|
|
|
|
+ options: categoryData.content.value ?? [],
|
|
|
|
+ label: '分类',
|
|
|
|
+ defaultSelectedValue: 0,
|
|
|
|
+ },
|
|
|
|
+ {
|
|
|
|
+ options: computedCategoryOptions,
|
|
|
|
+ label: '状态',
|
|
|
|
+ defaultSelectedValue: -10,
|
|
|
|
+ },
|
|
|
|
+ ]"
|
|
:load="(page: number, pageSize: number, _, searchText: string, dropDownValues: number[]) => loadIchData(page, pageSize, dropDownValues, searchText)"
|
|
:load="(page: number, pageSize: number, _, searchText: string, dropDownValues: number[]) => loadIchData(page, pageSize, dropDownValues, searchText)"
|
|
:showDetail="(item) => router.push({ name: 'FormIch', query: { id: item.id } })"
|
|
:showDetail="(item) => router.push({ name: 'FormIch', query: { id: item.id } })"
|
|
>
|
|
>
|
|
@@ -98,7 +112,7 @@
|
|
</template>
|
|
</template>
|
|
|
|
|
|
<script setup lang="ts">
|
|
<script setup lang="ts">
|
|
-import { h, ref, watch } from 'vue';
|
|
|
|
|
|
+import { computed, h, ref, watch } from 'vue';
|
|
import { useRoute, useRouter } from 'vue-router';
|
|
import { useRoute, useRouter } from 'vue-router';
|
|
import { useAuthStore } from '@/stores/auth';
|
|
import { useAuthStore } from '@/stores/auth';
|
|
import { useSimpleDataLoader } from '@/composeable/SimpleDataLoader';
|
|
import { useSimpleDataLoader } from '@/composeable/SimpleDataLoader';
|
|
@@ -106,7 +120,7 @@ import { message, Modal } from 'ant-design-vue';
|
|
import type { GetContentListItem } from '@/api/CommonContent';
|
|
import type { GetContentListItem } from '@/api/CommonContent';
|
|
import useClipboard from 'vue-clipboard3';
|
|
import useClipboard from 'vue-clipboard3';
|
|
import CommonContent, { GetContentListParams } from '@/api/CommonContent';
|
|
import CommonContent, { GetContentListParams } from '@/api/CommonContent';
|
|
-import CommonListBlock from '@/components/content/CommonListBlock.vue';
|
|
|
|
|
|
+import CommonListBlock, { type DropdownCommonItem } from '@/components/content/CommonListBlock.vue';
|
|
import InheritorContent from '@/api/inheritor/InheritorContent';
|
|
import InheritorContent from '@/api/inheritor/InheritorContent';
|
|
import AdminItemState from './components/AdminItemState.vue';
|
|
import AdminItemState from './components/AdminItemState.vue';
|
|
|
|
|
|
@@ -117,6 +131,27 @@ const authStore = useAuthStore();
|
|
const activeKey = ref(route.query.tab as string || '1');
|
|
const activeKey = ref(route.query.tab as string || '1');
|
|
const inheritorData = ref<GetContentListItem[]>([]);
|
|
const inheritorData = ref<GetContentListItem[]>([]);
|
|
|
|
|
|
|
|
+const computedCategoryOptions = computed<DropdownCommonItem[]>(() => {
|
|
|
|
+ if (authStore.isReviewer) {
|
|
|
|
+ return [
|
|
|
|
+ { name: '全部状态', id: -10 },
|
|
|
|
+ { name: '待审核', id: 1 },
|
|
|
|
+ { name: '已通过', id: 2 },
|
|
|
|
+ ]
|
|
|
|
+ }
|
|
|
|
+ if (authStore.isAdmin) {
|
|
|
|
+ return [
|
|
|
|
+ { name: '全部状态', id: -10 },
|
|
|
|
+ { name: '保存未审核', id: -2 },
|
|
|
|
+ { name: '审核退回', id: -1 },
|
|
|
|
+ { name: '待初审', id: 0 },
|
|
|
|
+ { name: '初审通过待专家审核', id: 1 },
|
|
|
|
+ { name: '专家审核通过', id: 2 },
|
|
|
|
+ ]
|
|
|
|
+ }
|
|
|
|
+ return [];
|
|
|
|
+})
|
|
|
|
+
|
|
watch(activeKey, (newValue) => {
|
|
watch(activeKey, (newValue) => {
|
|
router.replace({ query: { tab: newValue } });
|
|
router.replace({ query: { tab: newValue } });
|
|
})
|
|
})
|
|
@@ -142,6 +177,7 @@ async function loadInheritorData(page: number, pageSize: number, dropDownValues:
|
|
.setKeywords(searchText)
|
|
.setKeywords(searchText)
|
|
.setSelfValues({
|
|
.setSelfValues({
|
|
ichType: dropDownValues[0] == 0 ? undefined: dropDownValues[0],
|
|
ichType: dropDownValues[0] == 0 ? undefined: dropDownValues[0],
|
|
|
|
+ progress: dropDownValues[1] <= -5 ? undefined: dropDownValues[1],
|
|
region: authStore.userInfo?.regionId,
|
|
region: authStore.userInfo?.regionId,
|
|
}),
|
|
}),
|
|
page,
|
|
page,
|
|
@@ -169,6 +205,7 @@ async function loadIchData(page: number, pageSize: number, dropDownValues: numbe
|
|
.setKeywords(searchText)
|
|
.setKeywords(searchText)
|
|
.setSelfValues({
|
|
.setSelfValues({
|
|
ichType: dropDownValues[0] == 0 ? undefined: dropDownValues[0],
|
|
ichType: dropDownValues[0] == 0 ? undefined: dropDownValues[0],
|
|
|
|
+ progress: dropDownValues[1] <= -5 ? undefined: dropDownValues[1],
|
|
region: authStore.userInfo?.regionId,
|
|
region: authStore.userInfo?.regionId,
|
|
}),
|
|
}),
|
|
page,
|
|
page,
|