talentPool-detail.vue 8.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273
  1. <style lang="scss" scoped>
  2. .el-breadcrumb {
  3. margin: 10px;
  4. line-height: 20px;
  5. }
  6. .el-divider {
  7. margin: 5px 0;
  8. }
  9. .demo-form-inline {
  10. margin-left: 10px;
  11. text-align: left;
  12. }
  13. .button-group {
  14. margin-left: 10px;
  15. text-align: left;
  16. }
  17. .el-header, .el-footer {
  18. //background-color: #B3C0D1;
  19. //color: #333;
  20. text-align: center;
  21. line-height: 60px;
  22. }
  23. .el-aside {
  24. //background-color: #D3DCE6;
  25. //color: #333;
  26. }
  27. .el-main {
  28. //background-color: #E9EEF3;
  29. //color: #333;
  30. text-align: left;
  31. }
  32. body > .el-container {
  33. margin-bottom: 40px;
  34. }
  35. .el-container:nth-child(5) .el-aside,
  36. .el-container:nth-child(6) .el-aside {
  37. line-height: 260px;
  38. }
  39. .el-container:nth-child(7) .el-aside {
  40. line-height: 320px;
  41. }
  42. .avatarImg{
  43. margin-top: 50px;
  44. }
  45. .divMain{
  46. margin-top: 40px;
  47. }
  48. .descDiv{
  49. margin-bottom: 20px;
  50. }
  51. .descDivBottom{
  52. margin-bottom: 50px;
  53. }
  54. .divMain2{
  55. margin-top: 50px;
  56. }
  57. .divMain3{
  58. margin-top: 30px;
  59. }
  60. </style>
  61. <template>
  62. <div>
  63. <el-breadcrumb separator=">">
  64. <el-breadcrumb-item :to="{ path: '/' }">首页</el-breadcrumb-item>
  65. <el-breadcrumb-item>
  66. <a href="#">企业HR</a>
  67. </el-breadcrumb-item>
  68. <el-breadcrumb-item>
  69. <a href="/talentPoolDetail">简历详情</a>
  70. </el-breadcrumb-item>
  71. </el-breadcrumb>
  72. <el-divider></el-divider>
  73. <div class="user-panel">
  74. <el-container>
  75. <el-aside width="230px">
  76. <el-avatar :size="150" shape="circle" class="avatarImg"
  77. :src="formModel.headImageUrl +'?x-oss-process=image/resize,m_fill,w_150,h_150'"
  78. ></el-avatar>
  79. </el-aside>
  80. <el-main>
  81. <div class="divMain">
  82. <H2>{{formModel.realName}}</H2>
  83. <div class="descDiv">
  84. <span v-if="formModel.sex=='0'">男</span>
  85. <span v-else>女</span>
  86. <span style="margin-left:20px;margin-right:20px">|</span>
  87. <span>{{formModel.age}}岁</span>
  88. <span style="margin-left:20px;margin-right:20px">|</span>
  89. <span>{{formModel.educationName}}</span>
  90. <span style="margin-left:20px;margin-right:20px">|</span>
  91. <span>{{formModel.workExpName}}</span>
  92. </div>
  93. <div class="descDiv">
  94. <span v-if="formModel.jobStatus=='1'">求职状态:在职</span>
  95. <span v-else>求职状态:已离职</span>
  96. </div>
  97. <div class="descDiv">
  98. <span>期望地点:{{formModel.dreamAdd}}</span>
  99. </div>
  100. <div class="descDiv">
  101. <span>期望薪资:{{formModel.dreamMoneyName}}</span>
  102. </div>
  103. <div class="descDivBottom">
  104. <el-button type="primary" plain icon="el-icon-star-off" @click="handleCollection(formModel.resumeId)">收藏简历</el-button>
  105. <el-button type="primary" icon="el-icon-download" @click="handleDownload">下载简历</el-button>
  106. <el-button type="warning" icon="el-icon-phone">立即沟通</el-button>
  107. </div>
  108. </div>
  109. <el-divider></el-divider>
  110. <div class="divMain2">
  111. <H2>个人介绍</H2>
  112. <div class="descDivBottom">
  113. {{formModel.introduction}}
  114. </div>
  115. </div>
  116. <el-divider></el-divider>
  117. <H2 style="margin-top:50px">工作经历</H2>
  118. <div class="divMain3" v-for="(item,index) in formModel.resumeWorkExperienceList" v-bind:key="index">
  119. <div class="descDiv" style="font-size:18px">
  120. {{item.companyName}}
  121. </div>
  122. <div class="descDiv">
  123. 工作时间:{{item.startTime}}-{{item.endTime}}
  124. </div>
  125. <div class="descDiv">
  126. 薪资水平:保密
  127. </div>
  128. <div class="descDiv">
  129. 在职职位:{{item.job}}
  130. </div>
  131. <div class="descDivBottom">
  132. 工作职责:{{item.content}}
  133. </div>
  134. </div>
  135. </el-main>
  136. </el-container>
  137. </div>
  138. <div style="background-color:#EFEFEF;padding:5px;">
  139. <el-button @click="closeDialog">关闭</el-button>
  140. </div>
  141. </div>
  142. </template>
  143. <script>
  144. import Constant from "@/constant";
  145. import jobUserApi from "@/api/job/jobUser";
  146. import recruitmentCollectionApi from "@/api/job/recruitmentCollection";
  147. export default {
  148. name: "talentPoolDetail",
  149. props: ["businessKey", "title"],
  150. data() {
  151. return {
  152. id:"",
  153. formModel:{
  154. resumeId:"",
  155. },
  156. submitting: false
  157. }
  158. },
  159. methods: {
  160. closeDialog() {
  161. //删除当前页面
  162. this.$store.dispatch('tagsView/delView', {
  163. path: '/job/talentPool/detail',
  164. name: 'talentPoolDetail'
  165. })
  166. .then(({ visitedViews }) => {
  167. this.$router.push({
  168. path: "/job/talentPool/list"
  169. })
  170. });
  171. this.$store.state.tagsView.visitedViews.splice(this.$store.state.tagsView.visitedViews.findIndex(item => item.path === this.$route.path), 1)
  172. },
  173. handleCollection(resumeId){
  174. var self = this;
  175. (function() {
  176. self.formModel.resumeId = resumeId;
  177. return recruitmentCollectionApi.add(self.formModel);
  178. })().then(function(response) {
  179. var jsonData = response.data;
  180. if (jsonData.result) {
  181. self.$message({
  182. message: "收藏简历成功!",
  183. type: "success"
  184. });
  185. }
  186. else{
  187. self.$message({
  188. message: jsonData.message,
  189. type: "error"
  190. });
  191. }
  192. });
  193. },
  194. handleDownload(){
  195. var self = this;
  196. self.loading = true;
  197. var formData = new FormData();
  198. formData.append("id",self.id);
  199. jobUserApi
  200. .exportXls(formData)
  201. .then(function (response) {
  202. self.loading = false;
  203. var jsonData = response.data;
  204. if(jsonData.result) {
  205. //导出
  206. self.$message({
  207. showClose: true,
  208. type: "success",
  209. message: `报表已生成,<a href="${jsonData.data}">请点击链接下载</a>`,
  210. dangerouslyUseHTMLString: true,
  211. duration: 30000,
  212. });
  213. }
  214. })
  215. .catch((error) => {
  216. self.loading = false;
  217. // self.$message.error(error + "");
  218. });
  219. },
  220. },
  221. async mounted() {
  222. var self = this;
  223. self.loading = true;
  224. self.id = this.$route.query.businessKey;
  225. (function() {
  226. return jobUserApi.edit(self.id);
  227. })()
  228. .then(response => {
  229. var jsonData = response.data;
  230. self.loading = false;
  231. if (jsonData.result) {
  232. self.formModel = jsonData.data;
  233. self.formModel.id = this.businessKey;
  234. } else {
  235. self.$message.error(jsonData.message + "");
  236. }
  237. })
  238. .catch(error => {
  239. self.$message.error(error + "");
  240. });
  241. }
  242. }
  243. </script>