From c294724fa42a5d28991c356efa2e5e962c13c2ca Mon Sep 17 00:00:00 2001 From: ye1023 <12588209+ye1023@user.noreply.gitee.com> Date: Thu, 30 Jul 2026 11:07:02 +0800 Subject: [PATCH 1/4] =?UTF-8?q?yxk-20260730=20=E6=94=B9=E5=96=84=E6=8F=90?= =?UTF-8?q?=E6=A1=88=20=E6=89=93=E5=88=86=E7=9A=84=E6=97=B6=E5=80=99?= =?UTF-8?q?=EF=BC=8C=E6=8F=90=E4=BE=9B=E4=B8=8B=E8=BD=BD=E8=AF=84=E5=88=86?= =?UTF-8?q?=E6=A0=87=E5=87=86=E7=9A=84=E9=99=84=E4=BB=B6=E5=8A=9F=E8=83=BD?= =?UTF-8?q?=EF=BC=8C=E4=B8=8B=E8=BD=BD=E8=B7=AF=E5=BE=84=E5=9C=A8=E5=86=85?= =?UTF-8?q?=E7=BD=91=E5=86=99=E5=85=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/ImprovementProposalBPMForm.vue | 30 +++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/src/views/gh/improvementProposal/components/ImprovementProposalBPMForm.vue b/src/views/gh/improvementProposal/components/ImprovementProposalBPMForm.vue index 9936aaf..4706333 100644 --- a/src/views/gh/improvementProposal/components/ImprovementProposalBPMForm.vue +++ b/src/views/gh/improvementProposal/components/ImprovementProposalBPMForm.vue @@ -155,6 +155,13 @@ +
+ 评分标准附件: + + + 查看评分标准 + +
@@ -255,6 +262,8 @@ { value: '2', label: '铜奖' }, { value: '3', label: '参与奖' }, ]; + // 评分标准由 MinIO 提供,使用完整地址避免受前端部署路径影响。 + const scoreStandardUrl = 'http://localhost:9000/api/v1/buckets/supervision/objects/download?prefix=%E6%94%B9%E5%96%84%E6%8F%90%E6%A1%88%E8%AF%84%E5%88%86%E6%A0%87%E5%87%86(1).xlsx&version_id=null'; // 流程引擎在运行待办中提供 taskDefKey,节点功能只依赖该稳定标识而非表单 URL 参数。 const processInfo = computed(() => ({ mainId: props.formData?.processDataId || props.formData?.dataId, @@ -448,6 +457,10 @@ scoreModalVisible.value = true; } + function openScoreStandard() { + window.open(scoreStandardUrl, '_blank', 'noopener,noreferrer'); + } + async function saveScoreDraft() { if (!hasValidScoreValues()) { createMessage.warning('请完整填写 0 到 100 分之间的七项评分'); @@ -594,6 +607,23 @@ margin-bottom: 16px; } + .score-standard-entry { + display: flex; + flex-wrap: wrap; + align-items: center; + gap: 2px; + margin: -8px 0 16px; + color: #64748b; + font-size: 14px; + } + + .score-standard-button { + display: inline-flex; + align-items: center; + gap: 4px; + padding-inline: 2px; + } + .institute-vote-summary { display: flex; flex-wrap: wrap; From b228a806f04ad6768ef3951b2d68cb6ab72c260f Mon Sep 17 00:00:00 2001 From: ye1023 <12588209+ye1023@user.noreply.gitee.com> Date: Thu, 30 Jul 2026 14:25:34 +0800 Subject: [PATCH 2/4] =?UTF-8?q?yxk-20260730=20=E6=94=B9=E5=96=84=E6=8F=90?= =?UTF-8?q?=E6=A1=88=20=E9=87=8D=E6=9E=84=20Task=5Fimprove002=20=E8=AF=84?= =?UTF-8?q?=E5=88=86=E5=BC=B9=E7=AA=97=E7=9A=84=E5=B1=95=E7=A4=BA=E5=B1=82?= =?UTF-8?q?=E7=BA=A7=EF=BC=8C=E6=B8=85=E6=99=B0=E7=AA=81=E5=87=BA=E2=80=9C?= =?UTF-8?q?=E6=94=B9=E5=96=84=E6=95=88=E6=9E=9C=E3=80=81=E5=8F=AF=E6=8E=A8?= =?UTF-8?q?=E5=B9=BF=E5=BA=A6=E3=80=81=E7=8B=AC=E5=88=9B=E6=80=A7=E3=80=81?= =?UTF-8?q?=E5=8A=AA=E5=8A=9B=E5=BA=A6=E2=80=9D=E5=9B=9B=E4=B8=AA=E5=A4=A7?= =?UTF-8?q?=E7=B1=BB=E8=AF=84=E4=BB=B7=E7=BB=B4=E5=BA=A6=EF=BC=8C=E5=90=8C?= =?UTF-8?q?=E6=97=B6=E4=BF=9D=E7=95=99=E7=8E=B0=E6=9C=89=E4=B8=83=E9=A1=B9?= =?UTF-8?q?=E5=BD=95=E5=85=A5=E3=80=81=E6=9D=83=E9=87=8D=E5=92=8C=E8=AE=A1?= =?UTF-8?q?=E7=AE=97=E9=80=BB=E8=BE=91=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/ImprovementProposalBPMForm.vue | 242 +++++++++++++++--- 1 file changed, 203 insertions(+), 39 deletions(-) diff --git a/src/views/gh/improvementProposal/components/ImprovementProposalBPMForm.vue b/src/views/gh/improvementProposal/components/ImprovementProposalBPMForm.vue index 4706333..31f7e73 100644 --- a/src/views/gh/improvementProposal/components/ImprovementProposalBPMForm.vue +++ b/src/views/gh/improvementProposal/components/ImprovementProposalBPMForm.vue @@ -152,7 +152,15 @@ /> - +
@@ -162,46 +170,79 @@ 查看评分标准
- - - - - - - - - - - - - - - - - -
改善效果得分按安全、质量、效率、成本四项的平均分自动计算:{{ effectAveragePreview }}
-
-
- - - - - - - - - - - - - - - -
- + +
+
+
+
+ 01 + 改善效果 +
+ 权重 50% +
+ + + + + + + + + + + + + + +
+ 安全、质量、效率、成本四项平均分 + {{ effectAveragePreview }} +
+
+ + + +
+
+
+ 02 + 可推广度 +
+ 权重 20% +
+ +
+
+ +
+
+
+ 03 + 独创性 +
+ 权重 20% +
+ +
+
+ +
+
+
+ 04 + 努力度 +
+ 权重 10% +
+ +
+
+
+
+
保存评分 评分已锁定,请重新提交流程办理 - +
@@ -624,6 +665,106 @@ padding-inline: 2px; } + .score-dimension-list { + display: flex; + flex-direction: column; + gap: 12px; + } + + .score-dimension { + min-height: 126px; + padding: 14px; + border-left: 3px solid #1677ff; + background: #f6fbff; + } + + .score-dimension-header { + display: flex; + align-items: center; + justify-content: space-between; + gap: 12px; + margin-bottom: 14px; + } + + .score-dimension-name { + display: inline-flex; + align-items: center; + min-width: 0; + gap: 8px; + } + + .score-dimension-index { + flex: 0 0 auto; + color: #1677ff; + font-size: 14px; + font-weight: 700; + line-height: 1; + } + + .score-dimension-title { + color: #1f2937; + font-size: 17px; + font-weight: 700; + line-height: 1.4; + } + + .score-dimension-weight { + flex: 0 0 auto; + color: #1677ff; + font-size: 14px; + font-weight: 600; + white-space: nowrap; + } + + .score-effect-dimension { + min-height: auto; + } + + .score-subitem { + margin-bottom: 0; + + :deep(.ant-form-item-label > label) { + color: #334155; + font-size: 15px; + font-weight: 600; + } + } + + .score-dimension { + :deep(.ant-input-number-input) { + color: #1f2937; + font-size: 16px; + font-weight: 600; + } + } + + .effect-score-summary { + display: flex; + align-items: baseline; + justify-content: space-between; + gap: 12px; + margin-top: 14px; + padding-top: 10px; + border-top: 1px solid #d6e8ff; + color: #475569; + font-size: 14px; + + strong { + flex: 0 0 auto; + color: #1677ff; + font-size: 20px; + font-weight: 700; + } + } + + .score-form-actions { + display: flex; + align-items: center; + justify-content: flex-end; + min-height: 32px; + margin-top: 20px; + } + .institute-vote-summary { display: flex; flex-wrap: wrap; @@ -732,6 +873,29 @@ } @media (max-width: 576px) { + .score-dimension { + min-height: auto; + padding: 12px; + } + + .score-dimension-header { + margin-bottom: 12px; + } + + .effect-score-summary { + align-items: flex-start; + flex-direction: column; + gap: 2px; + } + + .score-form-actions { + justify-content: stretch; + + :deep(.ant-btn) { + width: 100%; + } + } + .base-info-header { align-items: flex-start; } From 87bf2d945f0fcd2c9a3229ae7409c9dc84625ae7 Mon Sep 17 00:00:00 2001 From: ye1023 <12588209+ye1023@user.noreply.gitee.com> Date: Thu, 30 Jul 2026 14:42:24 +0800 Subject: [PATCH 3/4] =?UTF-8?q?yxk-20260730=20=E6=94=B9=E5=96=84=E6=8F=90?= =?UTF-8?q?=E6=A1=88=20=E5=B0=86=E6=B5=81=E7=A8=8B=E5=8A=9E=E7=90=86?= =?UTF-8?q?=E9=A1=B5=E5=9F=BA=E6=9C=AC=E4=BF=A1=E6=81=AF=E4=B8=AD=E7=9A=84?= =?UTF-8?q?=E2=80=9C=E6=8F=90=E6=A1=88=E7=B1=BB=E5=88=AB=E2=80=9D=E6=94=B9?= =?UTF-8?q?=E4=B8=BA=E4=BC=98=E5=85=88=E6=98=BE=E7=A4=BA=E4=B8=8E=E5=8F=B0?= =?UTF-8?q?=E8=B4=A6=E5=88=97=E8=A1=A8=E4=B8=80=E8=87=B4=E7=9A=84=E5=AD=97?= =?UTF-8?q?=E5=85=B8=E6=96=87=E6=9C=AC=EF=BC=8C=E4=B8=8D=E5=86=8D=E7=9B=B4?= =?UTF-8?q?=E6=8E=A5=E5=B1=95=E7=A4=BA=20proposal=5Fcategory=20=E6=95=B0?= =?UTF-8?q?=E6=8D=AE=E5=80=BC=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/ImprovementProposalBPMForm.vue | 68 +++++++++++++++++-- 1 file changed, 63 insertions(+), 5 deletions(-) diff --git a/src/views/gh/improvementProposal/components/ImprovementProposalBPMForm.vue b/src/views/gh/improvementProposal/components/ImprovementProposalBPMForm.vue index 31f7e73..2ff8be8 100644 --- a/src/views/gh/improvementProposal/components/ImprovementProposalBPMForm.vue +++ b/src/views/gh/improvementProposal/components/ImprovementProposalBPMForm.vue @@ -14,7 +14,7 @@ {{ proposal.proposalNo || '-' }} {{ proposal.proposalName || '-' }} {{ formatDate(proposal.proposalDate) }} - {{ proposal.proposalCategory || '-' }} + {{ proposal.proposalCategory_dictText || proposal.proposalCategory || '-' }} {{ proposal.proposalDeptName || '-' }} {{ proposal.applicantName || '-' }} {{ proposal.teamName || '-' }} @@ -239,6 +239,10 @@
+
+ 加权总分 + {{ weightedTotalPreview }} +
保存评分 评分已锁定,请重新提交流程办理 @@ -325,10 +329,18 @@ if (!currentScore.value) return '未保存'; return scoreLocked.value ? '评分已锁定' : '已保存,待流程提交'; }); - const effectAveragePreview = computed(() => { - const values = ['safetyScore', 'qualityScore', 'efficiencyScore', 'costScore'].map((key) => scoreForm.value[key]); - if (values.some((value) => value === undefined || value === null)) return '-'; - return (values.reduce((sum, value) => sum + Number(value), 0) / values.length).toFixed(2); + // 以前端“分”的整数计算,匹配服务端 BigDecimal 在改善效果和总分阶段的两次 HALF_UP 取整。 + const effectScoreCents = computed(() => calculateEffectScoreCents()); + const effectAveragePreview = computed(() => formatScoreCents(effectScoreCents.value)); + const weightedTotalPreview = computed(() => { + const effectCents = effectScoreCents.value; + const promotionCents = getScoreCents(scoreForm.value.promotionScore); + const originalityCents = getScoreCents(scoreForm.value.originalityScore); + const effortCents = getScoreCents(scoreForm.value.effortScore); + if (effectCents === null || promotionCents === null || originalityCents === null || effortCents === null) return '-'; + + const totalCents = Math.round(effectCents * 0.5 + promotionCents * 0.2 + originalityCents * 0.2 + effortCents * 0.1); + return formatScoreCents(totalCents); }); // 部门评分完成后必须以系统建议奖项为基准,不能回退到初审奖项。 const leaderAwardBase = computed(() => { @@ -532,6 +544,22 @@ }; } + function calculateEffectScoreCents(): number | null { + const values = ['safetyScore', 'qualityScore', 'efficiencyScore', 'costScore'].map((key) => getScoreCents(scoreForm.value[key])); + if (values.some((value) => value === null)) return null; + return Math.round((values as number[]).reduce((sum, value) => sum + value, 0) / values.length); + } + + function getScoreCents(value: unknown): number | null { + if (value === undefined || value === null || value === '') return null; + const score = Number(value); + return Number.isFinite(score) ? Math.round(score * 100) : null; + } + + function formatScoreCents(scoreCents: number | null): string { + return scoreCents === null ? '-' : (scoreCents / 100).toFixed(2); + } + function hasValidScoreValues() { return ['safetyScore', 'qualityScore', 'efficiencyScore', 'costScore', 'promotionScore', 'originalityScore', 'effortScore'].every((key) => { const value = scoreForm.value[key]; @@ -757,6 +785,28 @@ } } + .weighted-total-summary { + display: flex; + align-items: baseline; + justify-content: space-between; + gap: 12px; + margin-top: 16px; + padding: 14px 16px; + border-left: 4px solid #1677ff; + background: #e6f4ff; + color: #1f2937; + font-size: 16px; + font-weight: 700; + + strong { + flex: 0 0 auto; + color: #0958d9; + font-size: 28px; + font-weight: 700; + line-height: 1; + } + } + .score-form-actions { display: flex; align-items: center; @@ -888,6 +938,14 @@ gap: 2px; } + .weighted-total-summary { + padding: 12px; + + strong { + font-size: 24px; + } + } + .score-form-actions { justify-content: stretch; From 3b3ff8228e48cdfacf23eee39a6a7fffd4dd6004 Mon Sep 17 00:00:00 2001 From: ye1023 <12588209+ye1023@user.noreply.gitee.com> Date: Thu, 30 Jul 2026 15:00:54 +0800 Subject: [PATCH 4/4] =?UTF-8?q?yxk-20260730=20=E6=94=B9=E5=96=84=E6=8F=90?= =?UTF-8?q?=E6=A1=88=20=E4=BF=AE=E5=A4=8D=E9=99=84=E4=BB=B6=E4=B8=8A?= =?UTF-8?q?=E4=BC=A0businessid=E5=AD=98=E5=82=A8=E9=94=99=E8=AF=AF?= =?UTF-8?q?=E7=9A=84bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ImprovementProposal.data.ts | 4 ++-- .../ImprovementProposalList.vue | 4 ++-- .../components/ImprovementProposalForm.vue | 15 ++++++++++----- 3 files changed, 14 insertions(+), 9 deletions(-) diff --git a/src/views/gh/improvementProposal/ImprovementProposal.data.ts b/src/views/gh/improvementProposal/ImprovementProposal.data.ts index 0e11cd3..edd1061 100644 --- a/src/views/gh/improvementProposal/ImprovementProposal.data.ts +++ b/src/views/gh/improvementProposal/ImprovementProposal.data.ts @@ -71,7 +71,7 @@ export const columns: BasicColumn[] = [ dataIndex: 'finalAward_dictText' }, { - title: '业务展示状态', + title: '流程状态', align:"center", dataIndex: 'bpmStatus_dictText' }, @@ -313,7 +313,7 @@ export const superQuerySchema = { problemDesc: {title: '问题描述',order: 9,view: 'textarea', type: 'string',}, improvementMethod: {title: '改善方法及措施',order: 10,view: 'textarea', type: 'string',}, finalAward: {title: '最终奖项',order: 14,view: 'text', type: 'string',}, - bpmStatus: {title: '业务展示状态',order: 15,view: 'text', type: 'string',}, + bpmStatus: {title: '流程状态',order: 15,view: 'text', type: 'string',}, //子表高级查询 improvementDeptScore: { title: '部门评议评分表', diff --git a/src/views/gh/improvementProposal/ImprovementProposalList.vue b/src/views/gh/improvementProposal/ImprovementProposalList.vue index 221b963..f44f508 100644 --- a/src/views/gh/improvementProposal/ImprovementProposalList.vue +++ b/src/views/gh/improvementProposal/ImprovementProposalList.vue @@ -18,8 +18,8 @@ - - + + diff --git a/src/views/gh/improvementProposal/components/ImprovementProposalForm.vue b/src/views/gh/improvementProposal/components/ImprovementProposalForm.vue index 73cd63d..45f88c9 100644 --- a/src/views/gh/improvementProposal/components/ImprovementProposalForm.vue +++ b/src/views/gh/improvementProposal/components/ImprovementProposalForm.vue @@ -134,6 +134,7 @@ import JDictSelectTag from '/@/components/Form/src/jeecg/components/JDictSelectTag.vue'; import SUploadFile from '/@/components/semri/fileComponent/SUploadFile.vue'; import { useUserStore } from '/@/store/modules/user'; + import { useMessage } from '/@/hooks/web/useMessage'; const useForm = Form.useForm; export default defineComponent({ @@ -154,6 +155,7 @@ }, emits:['success'], setup(props, {emit}) { + const { createMessage } = useMessage(); const loading = ref(false); const formRef = ref(); const beforeFileRef = ref(); @@ -417,12 +419,15 @@ const result = await saveOrUpdate(values, isUpdate); // 新增阶段附件暂不绑定;主表生成 ID 后统一关联,保证普通表单和 BPM 使用同一查询键。 if (!isUpdate) { - const newId = typeof result === 'string' ? result : (result?.id || result); - if (newId) { - formData.id = newId; - await beforeFileRef.value?.bindBussinessId(`${formData.id}:before`); - await afterFileRef.value?.bindBussinessId(`${formData.id}:after`); + const newId = typeof result?.id === 'string' ? result.id.trim() : ''; + if (!newId) { + // 阻断成功文案等非业务 ID 写入附件表,避免后续 BPM 无法按主表 ID 查询附件。 + createMessage.error('新增成功但未返回提案ID,附件未关联,请刷新后重试'); + return; } + formData.id = newId; + await beforeFileRef.value?.bindBussinessId(`${formData.id}:before`); + await afterFileRef.value?.bindBussinessId(`${formData.id}:after`); } emit('success'); }