Browse Source

修改bug

Fan 3 weeks ago
parent
commit
25a9f6e9d6

+ 10 - 4
ui/smarttrade-platform/src/components/addMarketing.vue

@@ -455,7 +455,7 @@
                                 "></div>
                             <div class="rule-content">
                                 <div class="rule-title">未打开邮件自动跟进</div>
-                                <div class="rule-desc">3天后发送提醒邮件,更换主题行</div>
+                                <div class="rule-desc">{{ newCampaign.rules.noOpenFollowupDays }}天后发送提醒邮件,更换主题行</div>
                             </div>
                             <div class="rule-config" v-if="newCampaign.rules.noOpenFollowup">
                                 <el-select style="width: 90px;" v-model="newCampaign.rules.noOpenFollowupDays" placeholder="请选择">
@@ -632,9 +632,9 @@
                 <button v-if="currentStep < 5" class="btn btn-primary" @click="currentStep++">
                     下一步 <i class="fas fa-arrow-right"></i>
                 </button>
-                <button v-else class="btn btn-primary" @click="createCampaign">
-                    <i class="fas fa-rocket"></i> {{ isEditMode ? "保存活动" : "创建活动" }}
-                </button>
+                <el-button :loading="loading" style="height: 41px;" v-else class="btn btn-primary" @click="createCampaign">
+                    <i class="fas fa-rocket" style="margin-right: 6px;"></i> {{ isEditMode ? "保存活动" : "创建活动" }}
+                </el-button>
             </div>
         </div>
     </div>
@@ -888,6 +888,7 @@
 
     const goToStep = (step) => { currentStep.value = step }
 
+    const loading = ref(false)
     const createCampaign = async () => {
         if (!newCampaign.value.name) {
             currentStep.value = 1
@@ -904,6 +905,7 @@
             return
         }
         try {
+            loading.value = true
             const typeMap = { prospect: 1, nurture: 2, reactivate: 3, promote: 4, seasonal: 5, exhibition: 6, other: 7 }
             const priorityMap = { urgent: 1, high: 2, medium: 3, low: 4 }
             const channelConfig = newCampaign.value.channels.reduce((acc, channel) => {
@@ -952,6 +954,8 @@
                     closeCreateModal()
                 }).catch(err => {
                     ElMessage.error(err?.message || '更新营销活动失败')
+                }).finally(() => {
+                    loading.value = false
                 })
             } else {
                 await addMarketing(payload).then(res => {
@@ -960,6 +964,8 @@
                     closeCreateModal()
                 }).catch(err => {
                     ElMessage.error(err?.message || '创建营销活动失败')
+                }).finally(() => {
+                    loading.value = false
                 })
             }
         } catch (error) {

+ 1 - 0
ui/smarttrade-platform/src/components/marketing/emailList.vue

@@ -75,6 +75,7 @@ const emailList = ref([])
 const open = (campaign) => {
   selectedCampaign.value = campaign || null
   emailList.value = []
+  activeFilter.value = 'pending'
   getStatusCounts()
   getList()
   showEmailListModal.value = true

+ 1 - 1
ui/smarttrade-platform/src/components/marketing/marketingDetail.vue

@@ -143,7 +143,7 @@
                   <div class="step-marker">{{ item.step }}</div>
                   <div class="step-content">
                     <div class="step-title">{{ item.name }}</div>
-                    <div class="step-meta">第{{ item.days }}天 · 邮件 · 待执行</div>
+                    <div class="step-meta">间隔{{ item.days }}天 · 邮件 · 待执行</div>
                   </div>
                 </div>
               </div>