lrf преди 6 месеца
родител
ревизия
427c634394

+ 7 - 1
src/views/detail/achievementDetail.vue

@@ -196,7 +196,13 @@ const toChat = () => {
   if (user.value.id) {
   if (user.value.id) {
     ElMessageBox.confirm(`您确认要预约对接?`, '提示', { confirmButtonText: '确定', cancelButtonText: '取消', type: 'warning' })
     ElMessageBox.confirm(`您确认要预约对接?`, '提示', { confirmButtonText: '确定', cancelButtonText: '取消', type: 'warning' })
       .then(async () => {
       .then(async () => {
-        ElMessage({ message: `预约对接成功等待消息通知`, type: 'success' })
+        const obj = {
+          source_id: route.query.id,
+          source: 'achievement',
+          apply_user: user.value.id,
+        }
+        const res = await contactApplyStore.create(obj)
+        $checkRes(res, `预约对接成功等待消息通知`, res.errmsg)
       })
       })
       .catch(() => {})
       .catch(() => {})
   } else ElMessage({ message: '未登录!', type: 'error' })
   } else ElMessage({ message: '未登录!', type: 'error' })

+ 2 - 2
src/views/detail/baseDetail.vue

@@ -209,8 +209,8 @@ const toChat = () => {
         let source = 'incubator'
         let source = 'incubator'
         let apply_user = user.value.id
         let apply_user = user.value.id
         const obj = { source_id, source, apply_user }
         const obj = { source_id, source, apply_user }
-        await contactApplyStore.create(obj)
-        ElMessage({ message: `预约对接成功等待消息通知`, type: 'success' })
+        const res = await contactApplyStore.create(obj)
+        $checkRes(res,`预约对接成功等待消息通知`,res.errmsg)
       })
       })
       .catch(() => {})
       .catch(() => {})
   } else ElMessage({ message: '未登录!', type: 'error' })
   } else ElMessage({ message: '未登录!', type: 'error' })

+ 2 - 2
src/views/detail/demandDetail.vue

@@ -227,8 +227,8 @@ const toChat = () => {
         let source = 'demand'
         let source = 'demand'
         let apply_user = user.value.id
         let apply_user = user.value.id
         const obj = { source_id, source, apply_user }
         const obj = { source_id, source, apply_user }
-        await contactApplyStore.create(obj)
-        ElMessage({ message: `预约对接成功等待消息通知`, type: 'success' })
+        const res = await contactApplyStore.create(obj)
+        $checkRes(res,`预约对接成功等待消息通知`,res.errmsg)
       })
       })
       .catch(() => {})
       .catch(() => {})
   } else ElMessage({ message: '未登录!', type: 'error' })
   } else ElMessage({ message: '未登录!', type: 'error' })

+ 2 - 2
src/views/detail/projectDetail.vue

@@ -240,8 +240,8 @@ const toChat = () => {
         let source = 'project'
         let source = 'project'
         let apply_user = user.value.id
         let apply_user = user.value.id
         const obj = { source_id, source, apply_user }
         const obj = { source_id, source, apply_user }
-        await contactApplyStore.create(obj)
-        ElMessage({ message: `预约对接成功等待消息通知`, type: 'success' })
+        const res = await contactApplyStore.create(obj)
+        $checkRes(res,`预约对接成功等待消息通知`,res.errmsg)
       })
       })
       .catch(() => {})
       .catch(() => {})
   } else ElMessage({ message: '未登录!', type: 'error' })
   } else ElMessage({ message: '未登录!', type: 'error' })

+ 3 - 2
src/views/detail/supplyDetail.vue

@@ -216,8 +216,9 @@ const toChat = () => {
         let source = 'supply'
         let source = 'supply'
         let apply_user = user.value.id
         let apply_user = user.value.id
         const obj = { source_id, source, apply_user }
         const obj = { source_id, source, apply_user }
-        await contactApplyStore.create(obj)
-        ElMessage({ message: `预约对接成功等待消息通知`, type: 'success' })
+        const res = await contactApplyStore.create(obj)
+        $checkRes(res,`预约对接成功等待消息通知`,res.errmsg)
+        // ElMessage({ message: `预约对接成功等待消息通知`, type: 'success' })
       })
       })
       .catch(() => {})
       .catch(() => {})
   } else ElMessage({ message: '未登录!', type: 'error' })
   } else ElMessage({ message: '未登录!', type: 'error' })