fix: 修复创建流水线无法选择通知的bug

This commit is contained in:
xiaojunnuo
2026-04-09 18:43:57 +08:00
parent db87bc770e
commit a88d0a6ae1
2 changed files with 15 additions and 11 deletions
@@ -65,7 +65,7 @@
</div> </div>
<div class="get-show"> <div class="get-show">
<template v-if="item.type === 'plus'"> <template v-if="item.type === 'plus'">
<span class="mr-5"> <span v-if="todayOrderCount.showVipTotal" class="mr-5">
已有 已有
<span class="color-red"> {{ todayOrderCount.vipTotal }}</span> <span class="color-red"> {{ todayOrderCount.vipTotal }}</span>
位伙伴支持 位伙伴支持
@@ -274,6 +274,7 @@ const todayOrderCount = computed(() => {
vipTotal: countInfo?.vipTotal || 0, vipTotal: countInfo?.vipTotal || 0,
orderCount: orderCount, orderCount: orderCount,
bg: lastStage.bg, bg: lastStage.bg,
showVipTotal: showVipTotal,
}); });
if (lastStage.orderCount > 0) { if (lastStage.orderCount > 0) {
stages.push(lastStage); stages.push(lastStage);
@@ -134,18 +134,21 @@ async function emitValue(value: any) {
const userId = userStore.userInfo.id; const userId = userStore.userInfo.id;
const isEnterprice = projectStore.isEnterprise; const isEnterprice = projectStore.isEnterprise;
if (isEnterprice) { if (pipeline?.value) {
const projectId = projectStore.currentProjectId; if (isEnterprice) {
if (pipeline?.value?.projectId !== projectId) { const projectId = projectStore.currentProjectId;
message.error("对不起,您不能修改其他项目流水线的通知"); if (pipeline?.value?.projectId !== projectId) {
return; message.error("对不起,您不能修改其他项目流水线的通知");
} return;
} else { }
if (pipeline?.value?.userId !== userId) { } else {
message.error("对不起,您不能修改他人流水线的通知"); if (pipeline?.value?.userId !== userId) {
return; message.error("对不起,您不能修改他人流水线的通知");
return;
}
} }
} }
emit("change", value); emit("change", value);
emit("update:modelValue", value); emit("update:modelValue", value);
} }