fix(bqtakepulse): 修复前端页面 QA 审查发现的问题

- 部门树切换点选模式并回写牵头/协办部门
- 导出切换 EasyExcel 端点,统计标签随操作刷新
- 牵头部门必填星号、保存提示、标题点击防连带展开
- bpmStatus 空值不再同时显示发起与再次督办,搜索加防抖

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
wsm
2026-08-11 17:43:30 +08:00
co-authored by Claude Opus 4.7
parent d0928f8edc
commit 98abb8fa95
3 changed files with 24 additions and 10 deletions
@@ -156,6 +156,7 @@ export const columns: BasicColumn[] = [
align:"center", align:"center",
dataIndex: 'bpmStatus_dictText', dataIndex: 'bpmStatus_dictText',
width: '80px', width: '80px',
fixed: 'right',
}, },
]; ];
+17 -8
View File
@@ -9,7 +9,7 @@
<template #label> <template #label>
<a-tooltip title="支持模糊查询,输入意见主题关键词">意见主题</a-tooltip> <a-tooltip title="支持模糊查询,输入意见主题关键词">意见主题</a-tooltip>
</template> </template>
<a-tooltip title="支持模糊查询,输入意见主题关键词"><JInput v-model:value="queryParam.title" type="like" placeholder="请输入意见主题" allow-clear trim @change="searchQuery" /></a-tooltip> <a-tooltip title="支持模糊查询,输入意见主题关键词"><JInput v-model:value="queryParam.title" type="like" placeholder="请输入意见主题" allow-clear trim @change="debouncedSearchQuery" /></a-tooltip>
</a-form-item> </a-form-item>
</a-col> </a-col>
<a-col :xl="4" :lg="6" :md="8" :sm="12"> <a-col :xl="4" :lg="6" :md="8" :sm="12">
@@ -25,7 +25,7 @@
<template #label> <template #label>
<a-tooltip title="按牵头部门筛选">牵头部门</a-tooltip> <a-tooltip title="按牵头部门筛选">牵头部门</a-tooltip>
</template> </template>
<a-tooltip title="按牵头部门筛选"><sz-select-dept placeholder="请选择牵头部门" v-model:value="selectedResponDept" checkStrictly allow-clear @change="handleResponDeptChange" /></a-tooltip> <a-tooltip title="按牵头部门筛选"><sz-select-dept placeholder="请选择牵头部门" v-model:value="selectedResponDept" :checkable="false" checkStrictly allow-clear @change="handleResponDeptChange" /></a-tooltip>
</a-form-item> </a-form-item>
</a-col> </a-col>
<a-col :xl="5" :lg="6" :md="8" :sm="12"> <a-col :xl="5" :lg="6" :md="8" :sm="12">
@@ -33,7 +33,7 @@
<template #label> <template #label>
<a-tooltip title="按协办部门筛选">协办部门</a-tooltip> <a-tooltip title="按协办部门筛选">协办部门</a-tooltip>
</template> </template>
<a-tooltip title="按协办部门筛选"><sz-select-dept placeholder="请选择协办部门" v-model:value="selectedAssistDept" checkStrictly allow-clear @change="handleAssistDeptChange" /></a-tooltip> <a-tooltip title="按协办部门筛选"><sz-select-dept placeholder="请选择协办部门" v-model:value="selectedAssistDept" :checkable="false" checkStrictly allow-clear @change="handleAssistDeptChange" /></a-tooltip>
</a-form-item> </a-form-item>
</a-col> </a-col>
<a-col :xl="4" :lg="6" :md="8" :sm="12"> <a-col :xl="4" :lg="6" :md="8" :sm="12">
@@ -83,7 +83,7 @@
<template v-slot:bodyCell="{ column, record, index, text }"> <template v-slot:bodyCell="{ column, record, index, text }">
<template v-if="column.dataIndex === 'title'"> <template v-if="column.dataIndex === 'title'">
<a-tooltip title="点击查看详情"> <a-tooltip title="点击查看详情">
<a style="font-weight: 500" @click="handleDetail(record)">{{ text }}</a> <a style="font-weight: 500" @click.stop="handleDetail(record)">{{ text }}</a>
</a-tooltip> </a-tooltip>
</template> </template>
</template> </template>
@@ -155,11 +155,12 @@
import {useModal} from '/@/components/Modal'; import {useModal} from '/@/components/Modal';
import BgTakepulseModal from './components/BgTakepulseModal.vue' import BgTakepulseModal from './components/BgTakepulseModal.vue'
import {columns, superQuerySchema} from './BgTakepulse.data'; import {columns, superQuerySchema} from './BgTakepulse.data';
import {list, statusStats, deleteOne, getImportUrl, getExportUrl, getImportExcelByEasyExcelUrl, getCheckExcelByEasyExcelUrl, getExportXlsHeadersUrl, saveOrUpdate, bgTakepulseFeedbackList} from './BgTakepulse.api'; import {list, statusStats, deleteOne, getImportUrl, getExportXlsByEasyExcelUrl, getImportExcelByEasyExcelUrl, getCheckExcelByEasyExcelUrl, getExportXlsHeadersUrl, saveOrUpdate, bgTakepulseFeedbackList} from './BgTakepulse.api';
import { defHttp } from '/@/utils/http/axios'; import { defHttp } from '/@/utils/http/axios';
import { showImportValidationErrors } from '/@/utils/helper/importError'; import { showImportValidationErrors } from '/@/utils/helper/importError';
import { useMessage } from '/@/hooks/web/useMessage'; import { useMessage } from '/@/hooks/web/useMessage';
import { countFeedbackStatus } from '/@/views/bg/utils/feedbackStatusCount'; import { countFeedbackStatus } from '/@/views/bg/utils/feedbackStatusCount';
import { useDebounceFn } from '@vueuse/core';
import SzSelectDept from '/@/components/Form/src/jeecg/components/SzSelectDept.vue'; import SzSelectDept from '/@/components/Form/src/jeecg/components/SzSelectDept.vue';
import JInput from '/@/components/Form/src/jeecg/components/JInput.vue'; import JInput from '/@/components/Form/src/jeecg/components/JInput.vue';
import DeptRoleUserSelectDropDown from '/@/components/semri/userComponent/DeptRoleUserSelectDropDown.vue'; import DeptRoleUserSelectDropDown from '/@/components/semri/userComponent/DeptRoleUserSelectDropDown.vue';
@@ -235,7 +236,7 @@
}, },
exportConfig: { exportConfig: {
name:"我为四所把把脉", name:"我为四所把把脉",
url: getExportUrl, url: getExportXlsByEasyExcelUrl,
params: queryParam, params: queryParam,
}, },
importConfig: { importConfig: {
@@ -361,8 +362,12 @@
selectedRowKeys.value = []; selectedRowKeys.value = [];
resetFeedbackExpand(); resetFeedbackExpand();
reload({ page: 1 }); reload({ page: 1 });
fetchStatusStats();
} }
// 输入框逐字触发的查询做防抖,查询按钮仍走未防抖的 searchQuery
const debouncedSearchQuery = useDebounceFn(searchQuery, 500);
async function fetchStatusStats() { async function fetchStatusStats() {
try { try {
const params: Recordable = {}; const params: Recordable = {};
@@ -432,6 +437,7 @@
selectedRowKeys.value = []; selectedRowKeys.value = [];
resetFeedbackExpand(); resetFeedbackExpand();
reload(); reload();
fetchStatusStats();
} }
/** /**
* 操作栏 * 操作栏
@@ -471,13 +477,13 @@
onClick: handleQueryProcess.bind(null, record), onClick: handleQueryProcess.bind(null, record),
} }
]; ];
if(record.bpmStatus == '1' || !record.bpmStatus){ if(!record.bpmStatus || record.bpmStatus == '1'){
dropDownAction.push({ dropDownAction.push({
label: '发起督办流程', label: '发起督办流程',
onClick: handleProcess.bind(null, record), onClick: handleProcess.bind(null, record),
}) })
} }
if(record.bpmStatus == '2' || !record.bpmStatus){ if(record.bpmStatus == '2'){
dropDownAction.push({ dropDownAction.push({
label: '再次督办', label: '再次督办',
onClick: handleProcess.bind(null, record), onClick: handleProcess.bind(null, record),
@@ -713,6 +719,7 @@
delete queryParam.responDeptid; delete queryParam.responDeptid;
} }
searchQuery(); searchQuery();
fetchStatusStats();
} }
function handleAssistDeptChange(values) { function handleAssistDeptChange(values) {
@@ -722,6 +729,7 @@
delete queryParam.assistDeptid; delete queryParam.assistDeptid;
} }
searchQuery(); searchQuery();
fetchStatusStats();
} }
function searchReset() { function searchReset() {
@@ -732,6 +740,7 @@
resetFeedbackExpand(); resetFeedbackExpand();
//刷新数据 //刷新数据
reload({ page: 1 }); reload({ page: 1 });
fetchStatusStats();
} }
/** /**
@@ -66,12 +66,12 @@
</a-col> </a-col>
<a-col :xs="24" :md="12"> <a-col :xs="24" :md="12">
<a-form-item label="牵头部门" v-bind="validateInfos.responDeptid" id="BgTakepulseForm-responDeptid" name="responDeptid"> <a-form-item label="牵头部门" v-bind="validateInfos.responDeptid" id="BgTakepulseForm-responDeptid" name="responDeptid">
<sz-select-dept v-model:value="formData.responDeptid" :multiple="true" checkStrictly allow-clear /> <sz-select-dept v-model:value="formData.responDeptid" :multiple="true" :checkable="false" checkStrictly allow-clear />
</a-form-item> </a-form-item>
</a-col> </a-col>
<a-col :xs="24" :md="12"> <a-col :xs="24" :md="12">
<a-form-item label="协办部门" v-bind="validateInfos.assistDeptid" id="BgTakepulseForm-assistDeptid" name="assistDeptid"> <a-form-item label="协办部门" v-bind="validateInfos.assistDeptid" id="BgTakepulseForm-assistDeptid" name="assistDeptid">
<sz-select-dept v-model:value="formData.assistDeptid" :multiple="true" checkStrictly allow-clear /> <sz-select-dept v-model:value="formData.assistDeptid" :multiple="true" :checkable="false" checkStrictly allow-clear />
</a-form-item> </a-form-item>
</a-col> </a-col>
<a-col :xs="24" :md="12"> <a-col :xs="24" :md="12">
@@ -172,6 +172,7 @@
<script lang="ts"> <script lang="ts">
import { defineComponent, ref, reactive, computed, toRaw, onMounted, watch } from 'vue'; import { defineComponent, ref, reactive, computed, toRaw, onMounted, watch } from 'vue';
import { defHttp } from '/@/utils/http/axios'; import { defHttp } from '/@/utils/http/axios';
import { useMessage } from '/@/hooks/web/useMessage';
import { queryDataById, saveOrUpdate } from '../BgTakepulse.api'; import { queryDataById, saveOrUpdate } from '../BgTakepulse.api';
import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue'; import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue';
import JSwitch from '/@/components/Form/src/jeecg/components/JSwitch.vue'; import JSwitch from '/@/components/Form/src/jeecg/components/JSwitch.vue';
@@ -215,6 +216,7 @@
setup(props, {emit}) { setup(props, {emit}) {
const SUP_LEADER_DEPT_ID = SUOBAN_DEPT_ID; const SUP_LEADER_DEPT_ID = SUOBAN_DEPT_ID;
const SUP_LEADER_ROLE_ID = MEASURE_RES_LEADER_ROLE_ID; const SUP_LEADER_ROLE_ID = MEASURE_RES_LEADER_ROLE_ID;
const { createMessage } = useMessage();
const loading = ref(false); const loading = ref(false);
const formRef = ref(); const formRef = ref();
const formData = reactive<Record<string, any>>({ const formData = reactive<Record<string, any>>({
@@ -258,6 +260,7 @@
secretLevel: [{ required: true, message: '请选择密级' }], secretLevel: [{ required: true, message: '请选择密级' }],
title: [{ required: true, message: '请输入意见主题' }], title: [{ required: true, message: '请输入意见主题' }],
responDeptid: [ responDeptid: [
{ required: true, message: '请选择牵头部门' },
{ {
validator: async (_rule, value) => { validator: async (_rule, value) => {
if (value === undefined || value === null || value === '' || (Array.isArray(value) && value.length === 0)) { if (value === undefined || value === null || value === '' || (Array.isArray(value) && value.length === 0)) {
@@ -394,6 +397,7 @@
console.log('表单提交数据', values) console.log('表单提交数据', values)
const isUpdate = values.id ? true : false const isUpdate = values.id ? true : false
await saveOrUpdate(values, isUpdate); await saveOrUpdate(values, isUpdate);
createMessage.success('保存成功');
//关闭弹窗 //关闭弹窗
emit('success'); emit('success');
} }