recruitmentHR-lookUp.vue 11 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382
  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. .user-panel{
  18. margin-top: 50px;
  19. }
  20. .el-header, .el-footer {
  21. // background-color: #B3C0D1;
  22. // color: #333;
  23. text-align: center;
  24. line-height: 60px;
  25. }
  26. .el-aside {
  27. // background-color: #D3DCE6;
  28. // color: #333;
  29. text-align: left;
  30. }
  31. .el-main {
  32. //background-color: #E9EEF3;
  33. //color: #333;
  34. text-align: left;
  35. padding: 0px;
  36. margin-left: 20px;
  37. margin-right: 20px;
  38. margin-top: 5px;
  39. }
  40. body > .el-container {
  41. margin-bottom: 40px;
  42. }
  43. .el-container:nth-child(5) .el-aside,
  44. .el-container:nth-child(6) .el-aside {
  45. line-height: 260px;
  46. }
  47. .el-container:nth-child(7) .el-aside {
  48. line-height: 320px;
  49. }
  50. .el-divider--vertical{
  51. height: auto;
  52. }
  53. .leftMain{
  54. margin-left: 50px;
  55. margin-right: 30px;
  56. margin-bottom: 50px;
  57. }
  58. .el-container i{
  59. margin-right: 10px;
  60. }
  61. .leftTitle{
  62. margin-bottom: 20px;
  63. }
  64. .leftTag{
  65. margin-top: 30px;
  66. }
  67. .geSpan{
  68. margin-left: 10px;
  69. margin-right: 10px;
  70. }
  71. .geSpan2{
  72. margin-left: 20px;
  73. margin-right: 20px;
  74. }
  75. .tag1{
  76. margin-right: 20px;
  77. }
  78. .div1{
  79. margin-top: 50px;
  80. margin-bottom: 20px;
  81. font-size: 16px;
  82. }
  83. .div2{
  84. font-size: 16px;
  85. }
  86. .div3{
  87. margin-top: 30px;
  88. margin-bottom: 30px;
  89. }
  90. .xinzi{
  91. float:right;
  92. font-size: 28px;
  93. color:#FF8000;
  94. }
  95. .titleSpan{
  96. font-size: 28px;
  97. }
  98. .leftMiddle{
  99. margin-top: 30px;
  100. margin-bottom: 20px;
  101. }
  102. .leftMiddle p{
  103. font-size: 14px;
  104. }
  105. .rightTitle{
  106. font-size: 20px;
  107. }
  108. .rightDiv1{
  109. margin-top: 20px;
  110. margin-bottom: 20px;
  111. font-size: 14px;
  112. }
  113. .rightDiv2{
  114. margin-top: 50px;
  115. }
  116. .companyLogoSpan{
  117. float:right;
  118. }
  119. .companyCheckDiv{
  120. margin-top: 20px;
  121. }
  122. .leftFoot{
  123. margin-top: 50px;
  124. }
  125. .leftFoot span{
  126. margin-right: 50px;
  127. color: #7d90b5;
  128. font-size: 14px;
  129. }
  130. .titleP{
  131. font-weight: bold;
  132. }
  133. </style>
  134. <template>
  135. <div>
  136. <el-breadcrumb separator=">">
  137. <el-breadcrumb-item :to="{ path: '/' }">首页</el-breadcrumb-item>
  138. <el-breadcrumb-item>
  139. <a href="#">企业HR</a>
  140. </el-breadcrumb-item>
  141. <el-breadcrumb-item>
  142. <a href="/talentPoolDetail">简历详情</a>
  143. </el-breadcrumb-item>
  144. </el-breadcrumb>
  145. <el-divider></el-divider>
  146. <div class="user-panel">
  147. <el-container>
  148. <el-aside width="1000px">
  149. <div class="leftMain">
  150. <div class="leftTop">
  151. <div class="leftTitle">
  152. <span class="titleSpan">{{formModel.positionName}}<span class="geSpan">|</span>{{formModel.title}}</span>
  153. <span class="xinzi">{{formModel.wageTypeName}}</span>
  154. </div>
  155. <div class="leftTag">
  156. <el-tag class="tag1" type="info" v-for="(item,index) in formModel.tagList" v-bind:key="index">{{item}}</el-tag>
  157. </div>
  158. <div class="div1">
  159. <span>招{{formModel.positionNumber}}人</span>
  160. <span class="geSpan2">|</span>
  161. <span>{{formModel.positionSexN}}</span>
  162. <span class="geSpan2">|</span>
  163. <span>{{formModel.educationName}}</span>
  164. <span class="geSpan2">|</span>
  165. <span>{{formModel.workYearName}}</span>
  166. </div>
  167. <div class="div2">
  168. <i class="el-icon-location"></i>
  169. <span>{{formModel.address}}</span>
  170. <span style="margin-left:20px"><el-link type="primary">查看地图</el-link></span>
  171. </div>
  172. <div class="div3">
  173. <el-button type="primary" plain icon="el-icon-edit" @click="handleEdit(row)">编辑岗位</el-button>
  174. <el-button type="primary" icon="el-icon-download" v-if="formModel.status!='0'" @click="handleDown(row)">下架岗位</el-button>
  175. <el-button type="danger" icon="el-icon-error" @click="handleDelete">删除岗位</el-button>
  176. </div>
  177. </div>
  178. <el-divider></el-divider>
  179. <div class="leftMiddle">
  180. <div class="leftTitle">
  181. <span class="titleSpan">职位描述</span>
  182. </div>
  183. <div class="leftDesc">
  184. <p class="titleP">工作内容:</p>
  185. <p>{{formModel.positionMessage}}</p>
  186. <p class="titleP">职位要求:</p>
  187. <p>{{formModel.requirements}}</p>
  188. </div>
  189. </div>
  190. <div class="leftFoot">
  191. <span>更新:{{formModel.updateTime}}</span>
  192. <span>浏览:{{formModel.readingTimes}}</span>
  193. <span>收藏:{{formModel.collectionTimes}}</span>
  194. <span>投递:{{formModel.deliveryTimes}}</span>
  195. </div>
  196. </div>
  197. </el-aside>
  198. <el-divider direction="vertical" style="height:auto"></el-divider>
  199. <el-main style="height:500px">
  200. <div class="rightMain">
  201. <div class="rightTitle">
  202. {{formModel.companyName}}
  203. </div>
  204. <div class="rightDiv1">
  205. <span>{{formModel.companyIndustryN}}</span>
  206. <span class="geSpan2">|</span>
  207. <span>{{formModel.companyScaleN}}</span>
  208. <div class="companyLogoSpan">
  209. <el-image
  210. style="width: 100px; height: 100px"
  211. :src="formModel.companyLogo" fit="fit"></el-image>
  212. </div>
  213. <div class="companyCheckDiv">
  214. <el-tag type="primary" v-if="formModel.isCertification">企业已认证</el-tag>
  215. <el-tag type="danger" v-else>企业未认证</el-tag>
  216. </div>
  217. </div>
  218. <div class="rightDiv2">
  219. <i class="el-icon-location"></i>
  220. <span>湖北省荆州市沙市区江津东路附155号荆鹏软件园</span>
  221. </div>
  222. </div>
  223. </el-main>
  224. </el-container>
  225. </div>
  226. <div style="background-color:#EFEFEF;padding:5px;">
  227. <el-button @click="closeDialog">关闭</el-button>
  228. </div>
  229. <recruitmentHR-detail
  230. v-if="showModal"
  231. :businessKey="businessKey1"
  232. :title="modalTitle"
  233. @close="onDetailModalClose"
  234. ></recruitmentHR-detail>
  235. </div>
  236. </template>
  237. <script>
  238. import Constant from "@/constant";
  239. import recruitmentApi from "@/api/job/recruitment";
  240. import RecruitmentHRDetail from "./recruitmentHR-detail";
  241. export default {
  242. name: "recruitmentHRLookUp",
  243. props: ["businessKey", "title"],
  244. data() {
  245. return {
  246. id:"",
  247. formModel: {},
  248. showDialog: true,
  249. loading: false,
  250. submitting: false,
  251. showModal: false,
  252. modalTitle: "",
  253. businessKey1: "",
  254. }
  255. },
  256. methods:{
  257. closeDialog() {
  258. //删除当前页面
  259. this.$store.dispatch('tagsView/delView', {
  260. path: '/job/recruitmentHR/lookUp',
  261. name: 'recruitmentHRLookUp'
  262. })
  263. .then(({ visitedViews }) => {
  264. this.$router.push({
  265. path: "/job/recruitmentHR/list"
  266. })
  267. });
  268. this.$store.state.tagsView.visitedViews.splice(this.$store.state.tagsView.visitedViews.findIndex(item => item.path === this.$route.path), 1)
  269. },
  270. handleEdit() {
  271. this.modalTitle = "编辑岗位";
  272. this.businessKey1 = this.id;
  273. this.showModal = true;
  274. },
  275. handleDown(){
  276. var self = this;
  277. self
  278. .$confirm("是否确定下架招聘信息吗?", "提示", {
  279. confirmButtonText: "确定",
  280. cancelButtonText: "取消",
  281. type: "warning",
  282. })
  283. .then(() => {
  284. recruitmentApi.down(self.id).then(function (response) {
  285. var jsonData = response.data;
  286. if (jsonData.result) {
  287. self.closeDialog();
  288. }
  289. });
  290. });
  291. },
  292. handleDelete() {
  293. var self = this;
  294. self
  295. .$confirm("是否确认删除?", "提示", {
  296. confirmButtonText: "确定",
  297. cancelButtonText: "取消",
  298. type: "warning",
  299. })
  300. .then(() => {
  301. recruitmentApi.remove(self.id).then(function (response) {
  302. var jsonData = response.data;
  303. if (jsonData.result) {
  304. self.closeDialog();
  305. }
  306. });
  307. });
  308. },
  309. onDetailModalClose(refreshed) {
  310. //保存成功后回调
  311. var self = this;
  312. this.showModal = false;
  313. if (refreshed) {
  314. (function () {
  315. return recruitmentApi.edit(self.id);
  316. })()
  317. .then((response) => {
  318. var jsonData = response.data;
  319. self.loading = false;
  320. if (jsonData.result) {
  321. self.formModel = jsonData.data;
  322. } else {
  323. self.$message.error(jsonData.message + "");
  324. }
  325. })
  326. .catch((error) => {
  327. self.$message.error(error + "");
  328. });
  329. }
  330. },
  331. },
  332. mounted: function () {
  333. var self = this;
  334. self.id = this.$route.query.businessKey;
  335. (function () {
  336. return recruitmentApi.edit(self.id);
  337. })()
  338. .then((response) => {
  339. var jsonData = response.data;
  340. self.loading = false;
  341. if (jsonData.result) {
  342. self.formModel = jsonData.data;
  343. } else {
  344. self.$message.error(jsonData.message + "");
  345. }
  346. })
  347. .catch((error) => {
  348. self.$message.error(error + "");
  349. });
  350. },
  351. components: {
  352. "recruitmentHR-detail": RecruitmentHRDetail,
  353. },
  354. }
  355. </script>