From 4682f55613336be67d662faa5b8ddea1d1c37160 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=88=98=E6=AE=BF=E6=98=95?= Date: Fri, 30 Oct 2020 11:59:32 +0800 Subject: [PATCH] =?UTF-8?q?=E9=97=AE=E7=AD=94=E4=B8=AD=E5=BF=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/menu.vue | 3 +- src/components/new-com/apassTable.vue | 9 +++++ .../user/questions-answers/community.vue | 12 +++++- src/pages/user/questions-answers/my-qa.vue | 38 ++++++++----------- 4 files changed, 36 insertions(+), 26 deletions(-) diff --git a/src/components/menu.vue b/src/components/menu.vue index 4cb40cd..817232a 100644 --- a/src/components/menu.vue +++ b/src/components/menu.vue @@ -400,6 +400,7 @@ export default { font-size: 14px; display: none; z-index: 1; + text-align: center; } .shop_menu { width: 280px; @@ -435,7 +436,7 @@ export default { height: 44px; line-height: 44px; padding: 0 30px; - text-align: left; + text-align: center; color: #0d1847; } .user_menu div:hover { diff --git a/src/components/new-com/apassTable.vue b/src/components/new-com/apassTable.vue index f027bb7..2d33788 100644 --- a/src/components/new-com/apassTable.vue +++ b/src/components/new-com/apassTable.vue @@ -246,6 +246,11 @@ export default { { length: this.data.length }, (item, index) => (item = 0) ); + let self = this; + window.gotodetail = (val) => { + console.log(val) + self.$emit("gotodetail", val) + } }, methods: { toggleSelection(rows) { @@ -348,6 +353,10 @@ export default { this.$refs.multipleTable.clearSelection(); this.$emit("selectnum", { select: [], rows: [] }); }, + gotodetail(val) { + console.log(val) + this.$emit("gotodetail", val) + } }, }; diff --git a/src/pages/user/questions-answers/community.vue b/src/pages/user/questions-answers/community.vue index ef737ec..ed27450 100644 --- a/src/pages/user/questions-answers/community.vue +++ b/src/pages/user/questions-answers/community.vue @@ -31,6 +31,7 @@ v-if="tableData.length" :data="tableData" :header="table_header" + @gotodetail="gotodeta" > { - return `${str.title}`; + return `${str.title}`; }, }, { @@ -368,7 +376,7 @@ export default { align: "left", type: "html", getHtml: (str) => { - return `${str.title}`; + return `${str.title}`; }, }, { diff --git a/src/pages/user/questions-answers/my-qa.vue b/src/pages/user/questions-answers/my-qa.vue index fdcfbda..46d2763 100644 --- a/src/pages/user/questions-answers/my-qa.vue +++ b/src/pages/user/questions-answers/my-qa.vue @@ -70,7 +70,10 @@

{{ item.answer }}

-

+

{{ item.title }}

@@ -189,21 +192,7 @@ export default { label: "50", }, ], - data_list: [ - { - id: 1, - title: "平台的流程引擎怎么样", // 标题 - content: "我们想用流程引擎,不会用,求大神指点", // 内容 - created_by: "abc", // 发布人的userid - created: "2020-10-21T14:28:10+08:00", // 发布时间 - updated: "2020-10-21T14:28:10+08:00", // 更新时间 - view: 0, // 浏览量 - answer_num: 2, // 回答数, - user_name: "普通neo", // 发布人 - picture_path: - "/apaas/static/docs/image/image/blob_18f512d3-ee8f-4112-89a9-b2e7bfdfdec1.blob", // 头像 - }, - ], + data_list: [], user_info: { user_name: "", role: "", @@ -240,12 +229,12 @@ export default { }, refreshData() { if (this.activeName == "0") { - this.getQList(); - } else if (this.activeName == "1") { - this.getAList(); - } else if (this.activeName == "2") { - this.getDeleteList(); - } + this.getQList(); + } else if (this.activeName == "1") { + this.getAList(); + } else if (this.activeName == "2") { + this.getDeleteList(); + } }, pageResize() { let listWidth = this.$refs.commodityCardIn.clientWidth; @@ -310,6 +299,9 @@ export default { } }); }, + gotodeta(val) { + this.$router.push("/technical_support/answer_center/detail/" + val); + }, cancelDel() { this.diaDelItem = false; }, @@ -349,7 +341,7 @@ export default { }, mounted() { this.getUserQA(); - // this.getQList(); + this.getQList(); }, }; -- 2.26.0