Explorar el Código

兼职招聘bug修复

xinfeng hace 6 años
padre
commit
6d38613e2e
Se han modificado 2 ficheros con 30 adiciones y 24 borrados
  1. 1 0
      assets/css/job/_post_id.scss
  2. 29 24
      pages/job/_post/_id.vue

+ 1 - 0
assets/css/job/_post_id.scss

@@ -163,6 +163,7 @@
       line-height: remtovw(0.56);
       font-size: remtovw(0.28);
       color: #444444;
+      word-break: break-all;
     }
 
     .company-wrapper {

+ 29 - 24
pages/job/_post/_id.vue

@@ -134,7 +134,8 @@
           ownerInfo: {},
           skills: []
         },
-        showConfirm: false
+        showConfirm: false,
+        firstTip: true
       }
     },
     asyncData({ app }) {
@@ -151,6 +152,7 @@
       const string = path.split('.')[ 0 ]
       this.recruitId = string.split('/')[ 3 ]
       this.getRecruit()
+      window.closeIt = this.handleOfflineClick
     },
     methods: {
       async getRecruit() {
@@ -163,7 +165,8 @@
           this.recruitData = res.data
           let {role, longTimeTip} = this.recruitData
           //拥有者&企业方&需要提示
-          if (role==='owner' && Number(longTimeTip) === 1) {
+          if (role==='owner' && Number(longTimeTip) === 1 && this.firstTip) {
+            this.firstTip = false
             MessageBox({
               title: '温馨提示',
               message: '如果您长时间未招聘到优质程序员,可以试试发布【整包/云端项目】,有专属客服帮您人工对接开发者。',
@@ -204,26 +207,28 @@
           recruitId
         }
         let res = await this.$axios.$post("/api/recruit/offline", params)
+        console.log("关闭岗位", res)
         if (res.status === 1) {
-          console.log(res)
           this.$message({
             message: '岗位关闭成功!',
             type: 'success'
           })
-          MessageBox({
-            title: '温馨提示',
-            message: '程序员客栈邀请您评价本次兼职招聘,希望您能抽出5-10秒的时间参与,以帮助我们更好的提升服务。',
-            cancelButtonText: "残忍拒绝",
-            confirmButtonText: "前往评价",
-            closeOnClickModal: true,
-            showCancelButton: true,
-            showConfirmButton: true,
-          }).then(action => {
-            if (action!=='cancel') {
-              location.href = `proginn://recruit/company_comment?id=${this.recruitId}`
-            }
-            this.getRecruit()
-          });
+          setTimeout(()=>{
+            MessageBox({
+              title: '温馨提示',
+              message: '程序员客栈邀请您评价本次兼职招聘,希望您能抽出5-10秒的时间参与,以帮助我们更好的提升服务。',
+              cancelButtonText: "残忍拒绝",
+              confirmButtonText: "前往评价",
+              closeOnClickModal: true,
+              showCancelButton: true,
+              showConfirmButton: true,
+            }).then(action => {
+              if (action!=='cancel') {
+                location.href = `proginn://recruit/company_comment?id=${this.recruitId}`
+              }
+              this.getRecruit()
+            });
+          }, 1500)
         }
       },
       /** 发布 **/
@@ -252,7 +257,7 @@
           location.href = 'proginn://login'
           return
         }
-        let checkAns = await this.dealTips()
+        let checkAns = await this.dealTips("沟通")
         if (!checkAns) {
           return
         }
@@ -276,7 +281,7 @@
         if (!await this.checkLogin(true)) {
           return
         }
-        let checkAns = await this.dealTips()
+        let checkAns = await this.dealTips("投递")
         if (!checkAns) {
           return
         }
@@ -340,7 +345,7 @@
           return {}
         }
       },
-      async dealTips() {
+      async dealTips(word="投递") {
         let { directionNotMatch, workTypeNotMatch} = this.recruitData
         //职位类型
         directionNotMatch = 1
@@ -348,14 +353,14 @@
         if (Number(directionNotMatch) === 1) {
          let ans1 = await MessageBox({
             title: '温馨提示',
-            message: '该兼职岗位与您的【职位方向不符】,请您确认是否继续投递/沟通。',
+            message: `该兼职岗位与您的【职位方向不符】,请您确认是否继续${word}。`,
             cancelButtonText: "再考虑下",
             confirmButtonText: "继续操作",
             closeOnClickModal: true,
             showCancelButton: true,
             showConfirmButton: true,
           })
-          if (ans1 === "cancle") {
+          if (ans1 === "cancel") {
             return false
           }
         }
@@ -363,14 +368,14 @@
         if (Number(workTypeNotMatch) === 1) {
           let ans2 = await MessageBox({
             title: '温馨提示',
-            message: '该兼职岗位与您选择的【工作方式不符】,请您确认是否继续投递/沟通。',
+            message: `该兼职岗位与您选择的【工作方式不符】,请您确认是否继续${word}。`,
             cancelButtonText: "再考虑下",
             confirmButtonText: "继续操作",
             closeOnClickModal: true,
             showCancelButton: true,
             showConfirmButton: true,
           })
-          if (ans2 === "cancle") {
+          if (ans2 === "cancel") {
             return false
           }
         }