zhanjiaduijie.vue 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425
  1. <template>
  2. <div id="dockDetail">
  3. <el-row>
  4. <el-col :span="24" class="style">
  5. <el-image :src="beijingPic"></el-image>
  6. <el-col :span="24" class="info">
  7. <div class="w_1200">
  8. <el-col :span="24" class="top">
  9. <p>吉林省计算中心对接直播大厅</p>
  10. <p>主办方:吉林省计算中心</p>
  11. </el-col>
  12. <el-col :span="24" class="main">
  13. <el-col :span="24" class="mainTop">
  14. <span v-if="display === '1'">
  15. <el-col :span="24" class="one">
  16. <el-col :span="7" class="oneLeft">
  17. <el-image :src="detailInfo.img_path" style="width: 100%;height: 210px;"> </el-image>
  18. </el-col>
  19. <el-col :span="17" class="oneRight">
  20. <p class="textOver">
  21. {{ detailInfo.name }}
  22. </p>
  23. <p>
  24. <span>性别:{{ detailInfo.gender || '暂无' }}</span>
  25. <span>出生年月:{{ detailInfo.birthday || '暂无' }}</span>
  26. </p>
  27. <p>
  28. <span> 毕业院校:{{ detailInfo.school }} </span>
  29. <span>专业:{{ detailInfo.major || '暂无' }}</span>
  30. </p>
  31. <p>
  32. <span>学历:{{ detailInfo.xl || '暂无' }}</span>
  33. <span>学位:{{ detailInfo.xw || '暂无' }}</span>
  34. </p>
  35. <p>
  36. <span>电话号码:{{ detailInfo.phone || '暂无' }}</span>
  37. <span>邮箱:{{ detailInfo.email || '暂无' }}</span>
  38. </p>
  39. </el-col>
  40. <el-col :span="24" class="oneDown">
  41. <div>
  42. <p>身份证号:{{ detailInfo.cardnumber || '暂无' }}</p>
  43. <p>地址:{{ detailInfo.addr || '暂无' }}</p>
  44. <p>职称级别:{{ detailInfo.level || '暂无' }}</p>
  45. <p>职称名称:{{ detailInfo.levelname || '暂无' }}</p>
  46. <p>职务:{{ detailInfo.position || '暂无' }}</p>
  47. <p>项目:{{ detailInfo.project || '暂无' }}</p>
  48. <p>学术成就:{{ detailInfo.academic || '暂无' }}</p>
  49. <p>论文:{{ detailInfo.paper || '暂无' }}</p>
  50. <p>备注:{{ detailInfo.remark || '暂无' }}</p>
  51. <p>从事专业:{{ detailInfo.professional || '暂无' }}</p>
  52. </div>
  53. <div>
  54. <p>工作简介:</p>
  55. <p class="resume" v-if="resume != ''">{{ detailInfo.resume || '暂无' }}</p>
  56. <p class="resume1" v-else>{{ detailInfo.resume || '暂无' }}</p>
  57. <el-button size="mini" v-if="detailInfo.resume != null && detailInfo.resume.length > 288">
  58. <span v-if="resume != ''" @click="resumeMore()">更多</span>
  59. <span v-else @click="resumeMore1()">收起</span>
  60. </el-button>
  61. </div>
  62. </el-col>
  63. </el-col>
  64. </span>
  65. <!-- <span v-if="display === '2'">
  66. <el-col :span="24" class="two">
  67. <chat :room="room"></chat>
  68. </el-col>
  69. </span> -->
  70. </el-col>
  71. <el-col class="mainDown">
  72. <!-- <el-button @click="btnInfo()" type="info">项目详情</el-button> -->
  73. <!-- <el-button v-if="this.user.uid != detailInfo.userid" @click="btnPhone()" type="primary">对接聊天</el-button> -->
  74. <el-button type="warning" style="float:left;" @click.native="back()">返回</el-button>
  75. <el-button type="primary" @click="btnPhone()" v-if="this.user.uid != detailInfo.userid">对接聊天</el-button>
  76. <el-button v-if="this.user.uid != detailInfo.userid" @click="btnTrade()" type="success">洽谈交易</el-button>
  77. <el-dialog title="对接聊天" :visible.sync="dialogTableVisible">
  78. <el-col :span="24" class="two">
  79. <chat :room="room"></chat>
  80. </el-col>
  81. </el-dialog>
  82. </el-col>
  83. </el-col>
  84. </div>
  85. </el-col>
  86. </el-col>
  87. </el-row>
  88. <el-dialog title="产品参数" :visible.sync="dialogVisible" width="50%">
  89. <el-table :data="tableData" border style="width: 100%">
  90. <el-table-column prop="arg_name" label="参数名称" align="center"> </el-table-column>
  91. <el-table-column prop="memo" label="参数内容" align="center"> </el-table-column>
  92. </el-table>
  93. </el-dialog>
  94. </div>
  95. </template>
  96. <script>
  97. import _ from 'lodash';
  98. import { mapState, createNamespacedHelpers } from 'vuex';
  99. import chat from './parts/chat.vue';
  100. const { mapActions: expertsuser } = createNamespacedHelpers('expertsuser');
  101. const { mapActions: personalRoom } = createNamespacedHelpers('personalroom');
  102. const { mapActions: transaction } = createNamespacedHelpers('transaction');
  103. export default {
  104. name: 'dockDetail',
  105. props: {},
  106. components: {
  107. chat,
  108. },
  109. data: () => ({
  110. beijingPic: require('@a/live/top_3.png'),
  111. display: '1',
  112. detailInfo: {},
  113. scope: '123',
  114. resume: '123',
  115. dialogVisible: false,
  116. tableData: [],
  117. dialogTableVisible: false,
  118. room: {},
  119. }),
  120. created() {
  121. if (this.$route.query.id) {
  122. this.searchInfo();
  123. }
  124. },
  125. methods: {
  126. ...expertsuser(['fetch']),
  127. ...personalRoom(['create', 'countDelete']),
  128. ...transaction({ buyProduct: 'create' }),
  129. async searchInfo() {
  130. let res = await this.fetch(this.$route.query.id);
  131. if (res.errcode === 0) {
  132. this.$set(this, `detailInfo`, res.data);
  133. }
  134. },
  135. argsBtn(data) {
  136. this.dialogVisible = true;
  137. this.$set(this, `tableData`, data);
  138. },
  139. // handleClose(done) {
  140. // this.$confirm('确认关闭?')
  141. // .then(_ => {
  142. // done();
  143. // })
  144. // .catch(_ => {});
  145. // },
  146. // 更多
  147. scopeMore() {
  148. this.scope = '';
  149. },
  150. // 收起
  151. scopeMore1() {
  152. this.scope = '123';
  153. },
  154. // 更多
  155. resumeMore() {
  156. this.resume = '';
  157. },
  158. // 收起
  159. resumeMore1() {
  160. this.resume = '123';
  161. },
  162. btnInfo() {
  163. this.display = '1';
  164. },
  165. // 线下对接
  166. async btnPhone() {
  167. if (!this.room.id) {
  168. //TODO 请求房间号
  169. let obj = {};
  170. if (!this.user.uid) {
  171. // this.$message.error({
  172. // dangerouslyUseHTMLString: true,
  173. // message: '<strong>游客身份无法与卖家对话,请先注册<a href="/login" >注册<a> </strong>',
  174. // });
  175. this.$message({
  176. dangerouslyUseHTMLString: true,
  177. message:
  178. '<strong><a href="http://free.liaoningdoupo.com/platlive/webLogin" style="color:red;text-decoration:none;">游客身份无法与卖家对话,请先注册</a></strong>',
  179. type: 'error',
  180. });
  181. return;
  182. } else {
  183. obj.buyer_id = this.user.uid;
  184. obj.buyer_name = this.user.name;
  185. }
  186. if (!this.detailInfo.id) {
  187. this.$message.error('缺少卖家信息,请联系卖家或管理员');
  188. return;
  189. } else {
  190. obj.seller_id = this.detailInfo.userid;
  191. obj.seller_name = this.detailInfo.name;
  192. }
  193. let res = await this.create(obj);
  194. if (this.$checkRes(res)) {
  195. this.$set(this, `room`, res.data);
  196. }
  197. }
  198. this.dialogTableVisible = true;
  199. },
  200. async btnTrade() {
  201. let form = {};
  202. form.userid = this.user.uid;
  203. form.username = this.user.name;
  204. form.product_id = this.detailInfo.id;
  205. form.product_name = this.detailInfo.name;
  206. form.market_userid = this.detailInfo.id;
  207. form.market_username = this.detailInfo.name;
  208. form.status = '0';
  209. form.type = '1';
  210. if (!this.user.uid) {
  211. // this.$message.error({
  212. // dangerouslyUseHTMLString: true,
  213. // message: '<strong>游客身份无法与卖家对话,请先注册<a href="/login" >注册<a> </strong>',
  214. // });
  215. this.$message({
  216. dangerouslyUseHTMLString: true,
  217. message:
  218. '<strong><a href="http://free.liaoningdoupo.com/platlive/webLogin" style="color:red;text-decoration:none;">游客身份无法与卖家对话,请先注册</a></strong>',
  219. type: 'error',
  220. });
  221. return;
  222. } else {
  223. let res = await this.buyProduct(form);
  224. this.$checkRes(res, '购买申请成功', res.errmsg || '购买申请失败');
  225. }
  226. },
  227. // killTalk() {
  228. // this.$alert('您确认对话已经可以结束了吗?');
  229. // let room_id = _.get(this.room, 'id');
  230. // if (room_id) {
  231. // this.countDelete(room_id);
  232. // }
  233. // },
  234. back() {
  235. history.back();
  236. },
  237. },
  238. computed: {
  239. ...mapState(['user']),
  240. pageTitle() {
  241. return `${this.$route.meta.title}`;
  242. },
  243. },
  244. metaInfo() {
  245. return { title: this.$route.meta.title };
  246. },
  247. // beforeDestroy() {
  248. // this.killTalk();
  249. // },
  250. beforeRouteLeave(to, from, next) {
  251. // this.killTalk();
  252. next();
  253. },
  254. };
  255. </script>
  256. <style lang="less" scoped>
  257. .w_1200 {
  258. width: 1200px;
  259. margin: 0 auto;
  260. }
  261. p {
  262. padding: 0;
  263. margin: 0;
  264. }
  265. .textOver {
  266. overflow: hidden;
  267. text-overflow: ellipsis;
  268. white-space: nowrap;
  269. }
  270. // .textOver{}
  271. // overflow: hidden;
  272. // text-overflow: ellipsis;
  273. // -webkit-line-clamp: 3;
  274. // word-break: break-all;
  275. // display: -webkit-box;
  276. // -webkit-box-orient: vertical;
  277. // }
  278. .style {
  279. height: 100vh;
  280. }
  281. .style .info {
  282. position: relative;
  283. top: -450px;
  284. }
  285. .style .top {
  286. position: relative;
  287. top: 0;
  288. width: 100%;
  289. text-align: center;
  290. z-index: 999;
  291. height: 172px;
  292. margin: 0 0 20px 0;
  293. }
  294. .style .top p:first-child {
  295. font-size: 50px;
  296. color: #fff;
  297. }
  298. .style .top p:last-child {
  299. font-size: 30px;
  300. color: #fff;
  301. position: absolute;
  302. width: 100%;
  303. top: 135px;
  304. }
  305. .style .main {
  306. min-height: 600px;
  307. border: 1px solid red;
  308. background: #fff;
  309. padding: 30px 20px;
  310. .mainTop {
  311. min-height: 550px;
  312. .one {
  313. min-height: 550px;
  314. .oneLeft {
  315. height: 210px;
  316. overflow: hidden;
  317. }
  318. .oneRight {
  319. padding: 0 15px;
  320. p {
  321. font-size: 16px;
  322. padding: 0px 0 11px 0;
  323. span {
  324. display: inline-block;
  325. width: 50%;
  326. }
  327. }
  328. p:first-child {
  329. font-size: 20px;
  330. font-weight: bold;
  331. padding: 20px 0;
  332. color: red;
  333. }
  334. // p:nth-child(2) span:last-child {
  335. // color: red;
  336. // font-weight: bold;
  337. // }
  338. }
  339. .oneDown {
  340. border-top: 1px dashed #ccc;
  341. margin: 30px 0 0 0;
  342. padding: 30px 0 0 0;
  343. div {
  344. padding: 0 0 15px 0;
  345. p {
  346. font-size: 16px;
  347. padding: 0 0 8px 0;
  348. }
  349. }
  350. div:nth-child(2) p span:last-child {
  351. color: #409eff;
  352. padding: 0 10px;
  353. }
  354. div:nth-child(2) p span:last-child:hover {
  355. cursor: pointer;
  356. }
  357. div:nth-child(3) .moreScope {
  358. overflow: hidden;
  359. text-overflow: ellipsis;
  360. -webkit-line-clamp: 6;
  361. word-break: break-all;
  362. display: -webkit-box;
  363. -webkit-box-orient: vertical;
  364. }
  365. div:nth-child(3) .moreScope1 {
  366. overflow: none;
  367. }
  368. div:nth-child(3) .el-button {
  369. float: right;
  370. }
  371. div:last-child .resume {
  372. overflow: hidden;
  373. text-overflow: ellipsis;
  374. -webkit-line-clamp: 4;
  375. word-break: break-all;
  376. display: -webkit-box;
  377. -webkit-box-orient: vertical;
  378. padding: 0;
  379. }
  380. div:last-child .resume1 {
  381. overflow: none;
  382. }
  383. div:last-child .el-button {
  384. float: right;
  385. }
  386. }
  387. }
  388. }
  389. .mainDown {
  390. height: 50px;
  391. text-align: center;
  392. /deep/.el-dialog__body {
  393. padding: 15px 20px;
  394. color: #606266;
  395. font-size: 14px;
  396. height: 660px;
  397. word-break: break-all;
  398. }
  399. }
  400. }
  401. .marketPublish {
  402. position: fixed;
  403. background: #0279d5;
  404. width: 100px;
  405. height: 100px;
  406. z-index: 999;
  407. left: 13%;
  408. top: 49%;
  409. border-radius: 20px;
  410. box-shadow: 2px 2px 2px #055c9f;
  411. text-align: center;
  412. line-height: 100px;
  413. font-size: 20px;
  414. color: #fff;
  415. font-weight: bold;
  416. }
  417. .marketPublish:hover {
  418. background: #f60;
  419. cursor: pointer;
  420. }
  421. </style>