Browse Source

简历管理问题修改

yanliming 4 năm trước cách đây
mục cha
commit
c9c620bfd2

+ 13 - 1
src/api/job/recruitment.js

@@ -41,6 +41,10 @@ function down(id){
   return request.post(constant.serverUrl + "/job/recruitment/down/" + id);
 }
 
+function up(id){
+  return request.post(constant.serverUrl + "/job/recruitment/up/" + id);
+}
+
 
 function batchRemove(idList){
   return request.post(constant.serverUrl + "/job/recruitment/batchDelete",idList,{
@@ -58,6 +62,14 @@ function batchDown(idList){
   });
 }
 
+function batchUp(idList){
+  return request.post(constant.serverUrl + "/job/recruitment/batchUp",idList,{
+    headers: {
+      "Content-Type": "application/json"
+    }
+  });
+}
+
 function offShelf(id){
   return request.post(constant.serverUrl + "/job/recruitment/offShelf/" + id);
 }
@@ -71,6 +83,6 @@ function batchOffShelf(idList){
 }
 
 export default {
-  pageList,pageListHR,create,edit,add,update,remove,batchRemove,offShelf,batchOffShelf,down,batchDown
+  pageList,pageListHR,create,edit,add,update,remove,batchRemove,offShelf,batchOffShelf,down,batchDown,up,batchUp
 
 }

+ 71 - 9
src/views/job/recruitmentHR-list.vue

@@ -58,9 +58,16 @@
         type="warning"
         icon="el-icon-download"
         @click="handleBatchDown"
-        v-if="activeName!='second'"
+        v-if="activeName!='second'&&activeName!='third'"
         >批量下架</el-button
       >
+      <el-button
+        type="primary"
+        icon="el-icon-upload2"
+        @click="handleBatchUp"
+        v-if="activeName!='first'&&activeName!='third'"
+        >批量上架</el-button
+      >
       <el-button
         type="danger"
         icon="el-icon-delete"
@@ -203,6 +210,9 @@
                         </el-col>
                     </el-row>
                     <el-row>
+                        <el-col :span="12">
+                            <el-button plain type="primary" @click="handleUp(row)">上架</el-button>
+                        </el-col>
                         <el-col :span="12">
                             <el-button plain type="danger" @click="handleDelete(row)">删除</el-button>
                         </el-col>
@@ -276,9 +286,6 @@
                         </el-col>
                     </el-row>
                     <el-row>
-                        <el-col :span="12">
-                            <el-button plain type="warning" @click="handleDown(row)">下架</el-button>
-                        </el-col>
                         <el-col :span="12">
                             <el-button plain type="danger" @click="handleDelete(row)">删除</el-button>
                         </el-col>
@@ -618,6 +625,34 @@ export default {
           });
         });
     },
+    handleUp(record){
+      var self = this;
+
+      self
+        .$confirm("是否确定上架招聘信息吗?", "提示", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning",
+        })
+        .then(() => {
+          recruitmentApi.up(record.id).then(function (response) {
+            var jsonData = response.data;
+
+            if (jsonData.result) {
+              // var index = self.tableData.indexOf(record);
+              // self.tableData.splice(index, 1);
+              self.changePage(self.pageIndex);
+              self.changePage2(self.pageIndex2);
+              self.changePage3(self.pageIndex3);
+
+              self.$message({
+                type: "success",
+                message: "上架成功!",
+              });
+            }
+          });
+        });
+    },
     handleBatchDown(){
       var self = this;
 
@@ -628,11 +663,6 @@ export default {
           return record.id;
         });
       }
-      else if(self.activeName=='third'){
-        idList = this.multipleSelection3.map((record) => {
-          return record.id;
-        });
-      }
 
     this.$confirm("是否确认下架选中项?", "提示", {
         confirmButtonText: "确定",
@@ -655,6 +685,38 @@ export default {
         });
       });
     },
+    handleBatchUp(){
+      var self = this;
+
+      var idList=[];
+
+      if(self.activeName=='second'){
+        idList = this.multipleSelection2.map((record) => {
+          return record.id;
+        });
+      }
+
+    this.$confirm("是否确认上架选中项?", "提示", {
+        confirmButtonText: "确定",
+        cancelButtonText: "取消",
+        type: "warning",
+      }).then(() => {
+        recruitmentApi.batchUp(idList).then(function (response) {
+          var jsonData = response.data;
+
+          if (jsonData.result) {
+            self.changePage(self.pageIndex);
+            self.changePage2(self.pageIndex);
+            self.changePage3(self.pageIndex3);
+
+            self.$message({
+              type: "success",
+              message: "上架成功!",
+            });
+          }
+        });
+      });
+    },
     handleBatchDelete() {
       var self = this;
 

+ 19 - 22
src/views/job/resumeHR-list.vue

@@ -96,8 +96,9 @@
                             <div class="nameDiv">{{item.name}}</div>
                             <div class="descFont">基本信息:</div>
                             <div>
-                                <span v-if="item.sexN=='0'">男</span>
-                                <span v-else>女</span>
+                                <span v-if="item.sexN=='1'">男</span>
+                                <span v-if="item.sexN=='0'">女</span>
+                                <span v-if="item.sexN=='2'">保密</span>
                                 ·
                                 <span>{{item.age}}岁</span>
                                 ·
@@ -117,15 +118,12 @@
                         <div class="buttonDiv">
                             <el-row>
                                 <el-col :span="24">
-                                    <el-button type="primary" style="width:180px">面试邀请</el-button>
+                                    <el-button type="primary" style="width:210px">面试邀请</el-button>
                                 </el-col>
                             </el-row>
                             <el-row style="margin-top:20px">
-                                <el-col :span="13">
-                                <el-button type="primary" style="width:80px" plain @click="handleDownload(item)">导出</el-button>
-                                </el-col>
-                                <el-col :span="11">
-                                    <el-button type="primary" style="width:80px" plain @click="handleDeleteHr(item)">删除</el-button>
+                                <el-col :span="24">
+                                <el-button type="primary" style="width:210px" plain @click="handleDownload(item)">导出</el-button>
                                 </el-col>
                             </el-row>
                             
@@ -170,8 +168,9 @@
                             <div class="nameDiv">{{item.name}}</div>
                             <div class="descFont">基本信息:</div>
                             <div>
-                                <span v-if="item.sexN=='0'">男</span>
-                                <span v-else>女</span>
+                                <span v-if="item.sexN=='1'">男</span>
+                                <span v-if="item.sexN=='0'">女</span>
+                                <span v-if="item.sexN=='2'">保密</span>
                                 ·
                                 <span>{{item.age}}岁</span>
                                 ·
@@ -191,15 +190,12 @@
                         <div class="buttonDiv">
                             <el-row>
                                 <el-col :span="24">
-                                    <el-button type="primary" style="width:180px">面试邀请</el-button>
+                                    <el-button type="primary" style="width:210px">面试邀请</el-button>
                                 </el-col>
                             </el-row>
                             <el-row style="margin-top:20px">
-                                <el-col :span="13">
-                                <el-button type="primary" style="width:80px" plain @click="handleDownload(item)">导出</el-button>
-                                </el-col>
-                                <el-col :span="11">
-                                    <el-button type="primary" style="width:80px" plain @click="handleDelete(item)">删除</el-button>
+                                <el-col :span="24">
+                                <el-button type="primary" style="width:210px" plain @click="handleDownload(item)">导出</el-button>
                                 </el-col>
                             </el-row>
                             
@@ -244,8 +240,9 @@
                             <div class="nameDiv">{{item.name}}</div>
                             <div class="descFont">基本信息:</div>
                             <div>
-                                <span v-if="item.sexN=='0'">男</span>
-                                <span v-else>女</span>
+                                <span v-if="item.sexN=='1'">男</span>
+                                <span v-if="item.sexN=='0'">女</span>
+                                <span v-if="item.sexN=='2'">保密</span>
                                 ·
                                 <span>{{item.age}}岁</span>
                                 ·
@@ -265,7 +262,7 @@
                         <div class="buttonDiv">
                             <el-row>
                                 <el-col :span="24">
-                                    <el-button type="primary" style="width:180px">面试邀请</el-button>
+                                    <el-button type="primary" style="width:210px">面试邀请</el-button>
                                 </el-col>
                             </el-row>
                             <el-row style="margin-top:20px">
@@ -273,7 +270,7 @@
                                 <el-button type="primary" style="width:80px" plain @click="handleDownload(item)">导出</el-button>
                                 </el-col>
                                 <el-col :span="11">
-                                    <el-button type="primary" style="width:80px" plain @click="handleDeleteCollection(item)">删除</el-button>
+                                    <el-button type="danger" style="width:95px" plain @click="handleDeleteCollection(item)">取消收藏</el-button>
                                 </el-col>
                             </el-row>
                             
@@ -631,7 +628,7 @@ export default {
       var self = this;
 
       self
-        .$confirm("是否确认删除?", "提示", {
+        .$confirm("是否确认取消收藏?", "提示", {
           confirmButtonText: "确定",
           cancelButtonText: "取消",
           type: "warning",
@@ -647,7 +644,7 @@ export default {
 
               self.$message({
                 type: "success",
-                message: "删除成功!",
+                message: "取消成功!",
               });
             }
           });