Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
apaas-ui
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
gzga-jzapi
apaas-ui
Commits
d27c444f
Commit
d27c444f
authored
Oct 26, 2020
by
徐一鸣
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
问答中心
parent
6cb66255
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
187 additions
and
494 deletions
+187
-494
src/pages/technical-support/answer-center/detail.vue
src/pages/technical-support/answer-center/detail.vue
+73
-191
src/pages/technical-support/answer-center/edit.vue
src/pages/technical-support/answer-center/edit.vue
+13
-13
src/pages/technical-support/answer-center/index.vue
src/pages/technical-support/answer-center/index.vue
+51
-153
src/pages/technical-support/answer-center/list.vue
src/pages/technical-support/answer-center/list.vue
+50
-137
No files found.
src/pages/technical-support/answer-center/detail.vue
View file @
d27c444f
<
template
>
<
template
>
<div
class=
"detail_box"
>
<div
class=
"detail_box"
>
<p
class=
"now_page_title"
>
<div
class=
"apass_breadcrumb"
>
技术支持 / 问答中心 / 问答列表 /
<el-breadcrumb
separator=
"/"
>
<span>
详情
</span>
<el-breadcrumb-item
to=
"/technical_support"
>
</p>
技术支持
</el-breadcrumb-item>
<el-breadcrumb-item
to=
"/technical_support/answer_center"
>
问答中心
</el-breadcrumb-item>
<el-breadcrumb-item
to=
"/technical_support/answer_center/list"
>
问答列表
</el-breadcrumb-item>
<el-breadcrumb-item>
详情
</el-breadcrumb-item>
</el-breadcrumb>
</div>
<div
class=
"detail_content"
>
<div
class=
"detail_content"
>
<div
class=
"question"
v-if=
"question.title"
>
<div
class=
"question"
v-if=
"question.title"
>
<p>
{{
question
.
title
}}
</p>
<p>
{{
question
.
title
}}
</p>
...
@@ -49,34 +59,36 @@
...
@@ -49,34 +59,36 @@
<div
slot=
"suffix"
class=
"back_solt"
@
click=
"answer_question(item.id,item.user_id)"
>
回复
</div>
<div
slot=
"suffix"
class=
"back_solt"
@
click=
"answer_question(item.id,item.user_id)"
>
回复
</div>
</el-input>
</el-input>
</div>
</div>
<div
class=
"back_fllow answer_box"
v-for=
"(it,idx) in item.children"
:key=
"'ans_child'+idx+5000"
v-if=
"idx
<
=
4
||
answer_child_index=
==index"
>
<template
v-for=
"(it,idx) in item.children"
>
<div
:style=
"idx == item.children.length-1&&item.children.length
<
=
5
?
{border:'0',overflow:'hidden',}:{borderBottom:'2px solid #f4f7fc',overflow:'hidden',}" >
<div
class=
"back_fllow answer_box"
:key=
"'ans_child'+idx+5000"
v-if=
"idx
<
=
4
||
answer_child_index=
==index"
>
<div
class=
"picture"
>
<div
:style=
"idx == item.children.length-1&&item.children.length
<
=
5
?
{border:'0',overflow:'hidden',}:{borderBottom:'2px solid #f4f7fc',overflow:'hidden',}" >
<img
:src=
"it.user_picture_path"
alt=
""
style=
"width:100%"
>
<div
class=
"picture"
>
</div>
<img
:src=
"it.user_picture_path"
alt=
""
style=
"width:100%"
>
<div
class=
"text"
style=
"border:0;"
>
</div>
<p>
<div
class=
"text"
style=
"border:0;"
>
<span
class=
"left"
>
{{
it
.
username
}}
<span><span
style=
"color:#bcc1d0;margin:0 9px;"
>
回复
</span>
{{
it
.
answered_user
}}
</span>
</span>
<p>
<span
class=
"right"
>
<span
class=
"left"
>
{{
it
.
username
}}
<span><span
style=
"color:#bcc1d0;margin:0 9px;"
>
回复
</span>
{{
it
.
answered_user
}}
</span>
</span>
<span></span><span>
{{
deal_time
(
it
.
created
)
}}
</span>
<span
class=
"right"
>
</span>
<span></span><span>
{{
deal_time
(
it
.
created
)
}}
</span>
</p>
</span>
<div
v-html=
"it.content"
class=
"hf_content"
></div>
</p>
<div
@
click=
"showinput(index,idx)"
class=
"back"
><img
src=
"../../../assets/imgs/jszc_btn_huifu.png"
alt=
""
>
回复
</div>
<div
v-html=
"it.content"
class=
"hf_content"
></div>
</div>
<div
@
click=
"showinput(index,idx)"
class=
"back"
><img
src=
"../../../assets/imgs/jszc_btn_huifu.png"
alt=
""
>
回复
</div>
<div
class=
"back_input"
style=
"padding:0;height:auto;margin-bottom:0;"
v-if=
"answer_count[0]==index&&answer_count[1]==idx"
>
</div>
<el-input
<div
class=
"back_input"
style=
"padding:0;height:auto;margin-bottom:0;"
v-if=
"answer_count[0]==index&&answer_count[1]==idx"
>
:placeholder=
"'回复'+it.username"
<el-input
@
blur=
"clear_index"
:placeholder=
"'回复'+it.username"
:ref=
"'input'+index+idx"
@
blur=
"clear_index"
v-model=
"back_info"
>
:ref=
"'input'+index+idx"
<div
slot=
"prefix"
style=
"height:48px;line-height:48px;"
>
v-model=
"back_info"
>
<img
:src=
"user_info.picture_path"
alt=
""
style=
"width:24px;margin:0 10px 0 10px;vertical-align:-6px;border-radius:50%;"
></div>
<div
slot=
"prefix"
style=
"height:48px;line-height:48px;"
>
<div
slot=
"suffix"
class=
"back_solt"
@
click=
"answer_question(it.id,it.user_id)"
>
回复
</div>
<img
:src=
"user_info.picture_path"
alt=
""
style=
"width:24px;margin:0 10px 0 10px;vertical-align:-6px;border-radius:50%;"
></div>
</el-input>
<div
slot=
"suffix"
class=
"back_solt"
@
click=
"answer_question(it.id,it.user_id)"
>
回复
</div>
</el-input>
</div>
</div>
</div>
</div>
</div>
</
div
>
</
template
>
<div
class=
"under_count"
v-if=
"item.children&&item.children.length>5&&answer_child_index!==index"
>
<div
class=
"under_count"
v-if=
"item.children&&item.children.length>5&&answer_child_index!==index"
>
还有{{item.children.length-5}}条回复,
<span
@
click=
"answer_child_index=index"
>
点击查看
</span>
还有{{item.children.length-5}}条回复,
<span
@
click=
"answer_child_index=index"
>
点击查看
</span>
</div>
</div>
...
@@ -124,130 +136,7 @@ export default {
...
@@ -124,130 +136,7 @@ export default {
'
video
'
'
video
'
],
],
editstr
:
''
,
editstr
:
''
,
answer
:
[
answer
:
[],
{
id
:
4
,
username
:
"
普通neo
"
,
created
:
"
2020-10-21T15:30:13+08:00
"
,
content
:
"
这个问题我知道,详情请参见http://www.baidu.com/abc
"
,
answered_user
:
""
,
children
:
[
{
id
:
5
,
username
:
"
普通neo
"
,
created
:
"
2020-10-21T15:34:20+08:00
"
,
content
:
"
这个问题我知道,详情请参见http://www.baidu.com/abc
"
,
answered_user
:
"
我是超级管理员
"
,
children
:
null
,
},
{
id
:
6
,
username
:
"
普通neo
"
,
created
:
"
2020-10-21T15:34:20+08:00
"
,
content
:
"
这个问题我知道,详情请参见http://www.baidu.com/abc
"
,
answered_user
:
"
我是超级管理员
"
,
children
:
null
,
},
{
id
:
7
,
username
:
"
普通neo
"
,
created
:
"
2020-10-21T15:34:20+08:00
"
,
content
:
"
这个问题我知道,详情请参见http://www.baidu.com/abc
"
,
answered_user
:
"
我是超级管理员
"
,
children
:
null
,
},
{
id
:
5
,
username
:
"
普通neo
"
,
created
:
"
2020-10-21T15:34:20+08:00
"
,
content
:
"
这个问题我知道,详情请参见http://www.baidu.com/abc
"
,
answered_user
:
"
我是超级管理员
"
,
children
:
null
,
},
{
id
:
6
,
username
:
"
普通neo
"
,
created
:
"
2020-10-21T15:34:20+08:00
"
,
content
:
"
这个问题我知道,详情请参见http://www.baidu.com/abc
"
,
answered_user
:
"
我是超级管理员
"
,
children
:
null
,
},
{
id
:
7
,
username
:
"
普通neo
"
,
created
:
"
2020-10-21T15:34:20+08:00
"
,
content
:
"
这个问题我知道,详情请参见http://www.baidu.com/abc
"
,
answered_user
:
"
我是超级管理员
"
,
children
:
null
,
},
],
},
{
id
:
4
,
username
:
"
普通neo
"
,
created
:
"
2020-10-21T15:30:13+08:00
"
,
content
:
"
这个问题我知道,详情请参见http://www.baidu.com/abc
"
,
answered_user
:
""
,
children
:
[
{
id
:
5
,
username
:
"
普通neo
"
,
created
:
"
2020-10-21T15:34:20+08:00
"
,
content
:
"
这个问题我知道,详情请参见http://www.baidu.com/abc
"
,
answered_user
:
"
我是超级管理员
"
,
children
:
null
,
},
{
id
:
6
,
username
:
"
普通neo
"
,
created
:
"
2020-10-21T15:34:20+08:00
"
,
content
:
"
这个问题我知道,详情请参见http://www.baidu.com/abc
"
,
answered_user
:
"
我是超级管理员
"
,
children
:
null
,
},
{
id
:
7
,
username
:
"
普通neo
"
,
created
:
"
2020-10-21T15:34:20+08:00
"
,
content
:
"
这个问题我知道,详情请参见http://www.baidu.com/abc
"
,
answered_user
:
"
我是超级管理员
"
,
children
:
null
,
},
{
id
:
5
,
username
:
"
普通neo
"
,
created
:
"
2020-10-21T15:34:20+08:00
"
,
content
:
"
这个问题我知道,详情请参见http://www.baidu.com/abc
"
,
answered_user
:
"
我是超级管理员
"
,
children
:
null
,
},
{
id
:
6
,
username
:
"
普通neo
"
,
created
:
"
2020-10-21T15:34:20+08:00
"
,
content
:
"
这个问题我知道,详情请参见http://www.baidu.com/abc
"
,
answered_user
:
"
我是超级管理员
"
,
children
:
null
,
},
{
id
:
7
,
username
:
"
普通neo
"
,
created
:
"
2020-10-21T15:34:20+08:00
"
,
content
:
"
这个问题我知道,详情请参见http://www.baidu.com/abc
"
,
answered_user
:
"
我是超级管理员
"
,
children
:
null
,
},
],
},
{
id
:
4
,
username
:
"
普通neo
"
,
created
:
"
2020-10-21T15:30:13+08:00
"
,
content
:
"
这个问题我知道,详情请参见http://www.baidu.com/abc
"
,
answered_user
:
""
,
children
:
null
,
},
],
};
};
},
},
watch
:
{},
watch
:
{},
...
@@ -348,50 +237,43 @@ export default {
...
@@ -348,50 +237,43 @@ export default {
})
})
},
100
)
},
100
)
},
},
deal_time
(
time
){
deal_time
(
time
){
console
.
log
(
time
);
console
.
log
(
time
);
return
time
.
split
(
'
+
'
)[
0
].
replace
(
"
T
"
,
"
"
)
return
time
.
split
(
'
+
'
)[
0
].
replace
(
"
T
"
,
"
"
)
},
},
showinput
(...
arg
){
showinput
(...
arg
){
console
.
log
(
arg
);
console
.
log
(
arg
);
this
.
answer_count
=
[]
this
.
answer_index
=
''
this
.
back_info
=
''
if
(
!
arg
[
1
]
&&
arg
[
1
]
!==
0
){
this
.
answer_index
=
arg
[
0
]
this
.
$nextTick
(()
=>
{
var
temp
=
'
input
'
+
arg
[
0
]
this
.
$refs
[
temp
][
0
].
$refs
.
input
.
focus
()
})
}
else
{
this
.
answer_count
=
arg
this
.
$nextTick
(()
=>
{
this
.
$refs
[
'
input
'
+
arg
[
0
]
+
arg
[
1
]][
0
].
$refs
.
input
.
focus
();
})
}
},
clear_index
(){
setTimeout
(()
=>
{
this
.
answer_count
=
[]
this
.
answer_count
=
[]
this
.
answer_index
=
''
this
.
answer_index
=
''
this
.
back_info
=
''
this
.
back_info
=
''
if
(
!
arg
[
1
]
&&
arg
[
1
]
!==
0
){
},
500
)
this
.
answer_index
=
arg
[
0
]
}
this
.
$nextTick
(()
=>
{
var
temp
=
'
input
'
+
arg
[
0
]
this
.
$refs
[
temp
][
0
].
$refs
.
input
.
focus
()
})
}
else
{
this
.
answer_count
=
arg
this
.
$nextTick
(()
=>
{
this
.
$refs
[
'
input
'
+
arg
[
0
]
+
arg
[
1
]][
0
].
$refs
.
input
.
focus
();
})
}
},
clear_index
(){
setTimeout
(()
=>
{
this
.
answer_count
=
[]
this
.
answer_index
=
''
this
.
back_info
=
''
},
500
)
}
},
},
};
};
</
script
>
</
script
>
<
style
scoped
>
<
style
scoped
>
.detail_box
{
.apass_breadcrumb
>
.el-breadcrumb
{
/* min-height: calc(100% - 15px); */
padding
:
12px
0
11px
;
}
.now_page_title
{
margin
:
13px
0
;
color
:
#898d9e
;
}
.now_page_title
span
{
color
:
#242c43
;
}
}
.detail_content
{
.detail_content
{
width
:
100%
;
width
:
100%
;
...
@@ -399,7 +281,7 @@ export default {
...
@@ -399,7 +281,7 @@ export default {
}
}
.question
,
.question
,
.answer
{
.answer
{
width
:
856px
;
width
:
100%
;
background-color
:
#fff
;
background-color
:
#fff
;
box-shadow
:
0px
3px
6px
0px
rgba
(
15
,
19
,
65
,
0.04
);
box-shadow
:
0px
3px
6px
0px
rgba
(
15
,
19
,
65
,
0.04
);
border-radius
:
12px
;
border-radius
:
12px
;
...
...
src/pages/technical-support/answer-center/edit.vue
View file @
d27c444f
<
template
>
<
template
>
<div
class=
"detail_box"
>
<div
class=
"detail_box"
>
<p
class=
"now_page_title"
>
<div
class=
"apass_breadcrumb"
>
技术支持 / 问答中心 /
<el-breadcrumb
separator=
"/"
>
<span>
发帖提问
</span>
<el-breadcrumb-item
to=
"/technical_support"
>
</p>
技术支持
</el-breadcrumb-item>
<el-breadcrumb-item
to=
"/technical_support/answer_center"
>
问答中心
</el-breadcrumb-item>
<el-breadcrumb-item>
发帖提问
</el-breadcrumb-item>
</el-breadcrumb>
</div>
<div
class=
"detail_content"
>
<div
class=
"detail_content"
>
<div
class=
"detail_title"
>
<div
class=
"detail_title"
>
<el-input
v-model=
"title"
placeholder=
"请输入问题标题"
></el-input>
<el-input
v-model=
"title"
placeholder=
"请输入问题标题"
></el-input>
...
@@ -93,15 +100,8 @@ export default {
...
@@ -93,15 +100,8 @@ export default {
</
script
>
</
script
>
<
style
scoped
>
<
style
scoped
>
.detail_box
{
.apass_breadcrumb
>
.el-breadcrumb
{
padding
:
12px
0
11px
;
}
.now_page_title
{
margin
:
13px
0
;
color
:
#898d9e
;
}
.now_page_title
span
{
color
:
#242c43
;
}
}
.detail_content
{
.detail_content
{
width
:
100%
;
width
:
100%
;
...
...
src/pages/technical-support/answer-center/index.vue
View file @
d27c444f
<
template
>
<
template
>
<div
class=
"answer_container"
>
<div
class=
"answer_container"
>
<router-view
class=
"left_content"
/>
<router-view
class=
"left_content"
/>
<div
class=
"right_content"
v-if=
"$route.path!== '/technical_support/answer_center/edit'"
>
<div
<div
class=
"user_info"
>
class=
"right_content"
v-if=
"$route.path !== '/technical_support/answer_center/edit'"
>
<div
class=
"user_info"
v-if=
"userInfo"
>
<div
class=
"user_img"
>
<div
class=
"user_img"
>
<img
:src=
"
require('../../../assets/imgs/img_head.png')
"
/>
<img
:src=
"
userInfo.picture_path || head_pic
"
/>
</div>
</div>
<p
class=
"user_name"
>
勒布朗
</p>
<p
class=
"user_name"
>
{{
userInfo
.
user_name
}}
</p>
<p
class=
"user_level"
>
普通用户
</p>
<p
class=
"user_level"
>
{{
userInfo
.
role
}}
</p>
<ul
class=
"user_other"
>
<ul
class=
"user_other"
>
<li
style=
"cursor: pointer;"
@
click=
"intoListPage(0)"
>
<li
style=
"cursor: pointer;"
@
click=
"intoListPage(0)"
>
<p>
800
</p>
<p>
{{
userInfo
.
question_num
}}
</p>
<p>
我的提问
</p>
<p>
我的提问
</p>
</li>
</li>
<li
style=
"cursor: pointer;"
@
click=
"intoListPage(1)"
>
<li
style=
"cursor: pointer;"
@
click=
"intoListPage(1)"
>
<p>
800
</p>
<p>
{{
userInfo
.
answer_num
}}
</p>
<p>
我的回答
</p>
<p>
我的回答
</p>
</li>
</li>
<li>
<li>
<p>
8.88万
</p>
<p>
{{
userInfo
.
view_num
}}
</p>
<p>
浏览数
</p>
<p>
浏览数
</p>
</li>
</li>
</ul>
</ul>
</div>
</div>
<div
class=
"contributor_info"
>
<div
class=
"contributor_info"
v-if=
"contributorAnswerList"
>
<h3
class=
"contributor_title"
>
<h3
class=
"contributor_title"
>
<span>
本月回答贡献榜
</span>
<span>
本月回答贡献榜
</span>
</h3>
</h3>
...
@@ -33,13 +36,13 @@
...
@@ -33,13 +36,13 @@
:key=
"'answer_' + index"
:key=
"'answer_' + index"
>
>
<span
class=
"list_index"
v-text=
"index + 1"
></span>
<span
class=
"list_index"
v-text=
"index + 1"
></span>
<img
class=
"list_img"
:src=
"item.picture_path"
/>
<img
class=
"list_img"
:src=
"item.picture_path
|| head_pic
"
/>
<span
class=
"list_text text_clip"
v-text=
"item.
content
"
></span>
<span
class=
"list_text text_clip"
v-text=
"item.
item
"
></span>
<span
class=
"list_count"
v-text=
"item.
answer_
num"
></span>
<span
class=
"list_count"
v-text=
"item.num"
></span>
</li>
</li>
</ul>
</ul>
</div>
</div>
<div
class=
"contributor_info"
>
<div
class=
"contributor_info"
v-if=
"contributorQuizList"
>
<h3
class=
"contributor_title"
>
<h3
class=
"contributor_title"
>
<span>
本月提问贡献榜
</span>
<span>
本月提问贡献榜
</span>
</h3>
</h3>
...
@@ -49,9 +52,9 @@
...
@@ -49,9 +52,9 @@
:key=
"'quiz_' + index"
:key=
"'quiz_' + index"
>
>
<span
class=
"list_index"
v-text=
"index + 1"
></span>
<span
class=
"list_index"
v-text=
"index + 1"
></span>
<img
class=
"list_img"
:src=
"item.picture_path"
/>
<img
class=
"list_img"
:src=
"item.picture_path
|| head_pic
"
/>
<span
class=
"list_text text_clip"
v-text=
"item.
content
"
></span>
<span
class=
"list_text text_clip"
v-text=
"item.
item
"
></span>
<span
class=
"list_count"
v-text=
"item.
answer_
num"
></span>
<span
class=
"list_count"
v-text=
"item.num"
></span>
</li>
</li>
</ul>
</ul>
</div>
</div>
...
@@ -64,152 +67,47 @@ export default {
...
@@ -64,152 +67,47 @@ export default {
components
:
{},
components
:
{},
data
()
{
data
()
{
return
{
return
{
contributorAnswerList
:
[],
userInfo
:
null
,
contributorQuizList
:
[],
contributorAnswerList
:
null
,
contributorQuizList
:
null
,
head_pic
:
require
(
"
../../../assets/imgs/img_head.png
"
),
};
};
},
},
created
()
{
created
()
{
this
.
getUserInfo
();
this
.
getAnwerList
();
this
.
getAnwerList
();
},
},
methods
:
{
methods
:
{
getUserInfo
()
{
this
.
$http
.
get
(
"
/apaas/support/qa/info
"
).
then
(({
data
})
=>
{
if
(
data
.
success
)
{
this
.
userInfo
=
data
.
data
;
}
});
},
getAnwerList
()
{
getAnwerList
()
{
this
.
contributorAnswerList
=
[
this
.
$http
{
.
get
(
"
/apaas/support/qa/question/contribution
"
)
id
:
1
,
.
then
(({
data
})
=>
{
title
:
"
平台的流程引擎怎么样
"
,
// 标题
if
(
data
.
success
)
{
content
:
"
我们想用流程引擎,不会用,求大神指点
"
,
// 内容
this
.
contributorAnswerList
=
data
.
data
||
[];
created_by
:
"
abc
"
,
// 发布人的userid
}
created
:
"
2020-10-21T14:28:10+08:00
"
,
// 发布时间
});
updated
:
"
2020-10-21T14:28:10+08:00
"
,
// 更新时间
view
:
0
,
// 浏览量
this
.
$http
answer_num
:
2
,
// 回答数,
.
get
(
"
/apaas/support/qa/answer/contribution
"
)
user_name
:
"
普通neo
"
,
// 发布人
.
then
(({
data
})
=>
{
picture_path
:
if
(
data
.
success
)
{
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
this
.
contributorQuizList
=
data
.
data
||
[];
},
}
{
});
id
:
2
,
title
:
"
平台的流程引擎怎么样6666
"
,
// 标题
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
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
{
id
:
3
,
title
:
"
平台的流程引擎怎么样23233333
"
,
// 标题
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
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
{
id
:
4
,
title
:
"
平台的流程引擎怎么样23233333
"
,
// 标题
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
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
{
id
:
5
,
title
:
"
平台的流程引擎怎么样23233333
"
,
// 标题
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
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
];
this
.
contributorQuizList
=
[
{
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
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
{
id
:
2
,
title
:
"
平台的流程引擎怎么样6666
"
,
// 标题
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
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
{
id
:
3
,
title
:
"
平台的流程引擎怎么样23233333
"
,
// 标题
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
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
{
id
:
4
,
title
:
"
平台的流程引擎怎么样23233333
"
,
// 标题
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
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
{
id
:
5
,
title
:
"
平台的流程引擎怎么样23233333
"
,
// 标题
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
:
9999
,
// 回答数,
user_name
:
"
普通neo
"
,
// 发布人
picture_path
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
];
},
},
intoListPage
(
type
)
{
intoListPage
(
type
)
{
console
.
log
(
type
===
0
?
"
我的提问
"
:
"
我的回答
"
);
if
(
type
===
0
)
{
this
.
$router
.
push
(
"
/qa/questions
"
);
}
else
{
this
.
$router
.
push
(
"
/qa/answers
"
);
}
},
},
},
},
};
};
...
...
src/pages/technical-support/answer-center/list.vue
View file @
d27c444f
...
@@ -29,7 +29,11 @@
...
@@ -29,7 +29,11 @@
</el-button>
</el-button>
</span>
</span>
<span>
<span>
<el-input
placeholder=
"请输入搜索内容"
></el-input>
<el-input
v-model=
"searchText"
placeholder=
"请输入搜索内容"
@
input=
"searchInput"
></el-input>
</span>
</span>
<span>
<span>
<el-button
type=
"primary"
@
click=
"intoAnswerPage"
>
<el-button
type=
"primary"
@
click=
"intoAnswerPage"
>
...
@@ -48,13 +52,13 @@
...
@@ -48,13 +52,13 @@
@
click=
"viewItem(item)"
@
click=
"viewItem(item)"
>
>
<h3
class=
"answer_title"
v-text=
"item.title"
></h3>
<h3
class=
"answer_title"
v-text=
"item.title"
></h3>
<p
class=
"answer_content"
v-text=
"
item.content
"
></p>
<p
class=
"answer_content"
v-text=
"
getContentText(item.content)
"
></p>
<p
class=
"answer_info"
>
<p
class=
"answer_info"
>
<span>
<span>
<img
class=
"user_img"
:src=
"item.picture_path"
/>
<img
class=
"user_img"
:src=
"item.picture_path"
/>
<span
class=
"user_name"
v-text=
"item.user_name"
></span>
<span
class=
"user_name"
v-text=
"item.user_name"
></span>
<span
class=
"user_text"
>
发布于
</span>
<span
class=
"user_text"
>
发布于
</span>
<span
class=
"user_time"
v-text=
"
item.created
"
></span>
<span
class=
"user_time"
v-text=
"
getTimeText(item.created)
"
></span>
</span>
</span>
<span>
<span>
<span
class=
"num_answer"
v-text=
"item.answer_num"
></span>
<span
class=
"num_answer"
v-text=
"item.answer_num"
></span>
...
@@ -78,6 +82,7 @@
...
@@ -78,6 +82,7 @@
</
template
>
</
template
>
<
script
>
<
script
>
import
helper
from
"
@/services/helper.js
"
;
import
ListPagination
from
"
@/components/comments-pagination
"
;
import
ListPagination
from
"
@/components/comments-pagination
"
;
export
default
{
export
default
{
...
@@ -87,11 +92,13 @@ export default {
...
@@ -87,11 +92,13 @@ export default {
data
()
{
data
()
{
return
{
return
{
answerList
:
[],
answerList
:
[],
sortType
:
0
,
// 0:最新问题 1:最热问题
listTotal
:
0
,
listTotal
:
0
,
pageSizes
:
[
10
,
20
,
50
],
pageSizes
:
[
10
,
20
,
50
],
pageSize
:
10
,
pageSize
:
10
,
currentPage
:
1
,
currentPage
:
1
,
sortType
:
0
,
// 0:最新问题 1:最热问题
searchText
:
""
,
inputTimer
:
null
,
};
};
},
},
created
()
{
created
()
{
...
@@ -99,144 +106,38 @@ export default {
...
@@ -99,144 +106,38 @@ export default {
},
},
methods
:
{
methods
:
{
getAnwerList
()
{
getAnwerList
()
{
this
.
answerList
=
[
this
.
$http
{
.
get
(
"
/apaas/support/qa/question/list
"
,
{
id
:
1
,
params
:
{
title
:
"
平台的流程引擎怎么样
"
,
// 标题
style
:
1
,
content
:
"
我们想用流程引擎,不会用,求大神指点
"
,
// 内容
order
:
this
.
sortType
===
0
?
""
:
"
created
"
,
created_by
:
"
abc
"
,
// 发布人的userid
search
:
this
.
searchText
,
created
:
"
2020-10-21T14:28:10+08:00
"
,
// 发布时间
limit
:
this
.
pageSize
,
updated
:
"
2020-10-21T14:28:10+08:00
"
,
// 更新时间
page
:
this
.
currentPage
,
view
:
0
,
// 浏览量
},
answer_num
:
2
,
// 回答数,
})
user_name
:
"
普通neo
"
,
// 发布人
.
then
(({
data
})
=>
{
picture_path
:
if
(
data
.
success
)
{
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
this
.
answerList
=
data
.
data
||
[];
},
this
.
listTotal
=
data
.
total
;
{
}
id
:
2
,
});
title
:
"
平台的流程引擎怎么样6666
"
,
// 标题
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
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
{
id
:
3
,
title
:
"
平台的流程引擎怎么样23233333
"
,
// 标题
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
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
{
id
:
4
,
title
:
"
平台的流程引擎怎么样23233333
"
,
// 标题
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
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
{
id
:
5
,
title
:
"
平台的流程引擎怎么样23233333
"
,
// 标题
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
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
{
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
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
{
id
:
2
,
title
:
"
平台的流程引擎怎么样6666
"
,
// 标题
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
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
{
id
:
3
,
title
:
"
平台的流程引擎怎么样23233333
"
,
// 标题
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
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
{
id
:
4
,
title
:
"
平台的流程引擎怎么样23233333
"
,
// 标题
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
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
{
id
:
5
,
title
:
"
平台的流程引擎怎么样23233333
"
,
// 标题
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
:
"
http://pic1.win4000.com/tj/2017-07-11/596437562ae53.jpg
"
,
},
];
this
.
listTotal
=
15
;
},
},
selectSortType
(
type
)
{
selectSortType
(
type
)
{
this
.
sortType
=
type
;
this
.
sortType
=
type
;
this
.
getAnwerList
();
this
.
getAnwerList
();
},
},
searchInput
()
{
if
(
this
.
inputTimer
)
{
clearTimeout
(
this
.
inputTimer
);
}
this
.
inputTimer
=
setTimeout
(()
=>
{
console
.
log
(
this
.
searchText
);
this
.
currentPage
=
1
;
this
.
getAnwerList
();
},
200
);
},
changePageSize
(
value
)
{
changePageSize
(
value
)
{
this
.
pageSize
=
value
;
this
.
pageSize
=
value
;
this
.
currentPage
=
1
;
this
.
currentPage
=
1
;
...
@@ -252,6 +153,18 @@ export default {
...
@@ -252,6 +153,18 @@ export default {
intoAnswerPage
()
{
intoAnswerPage
()
{
this
.
$router
.
push
(
"
/technical_support/answer_center/edit
"
);
this
.
$router
.
push
(
"
/technical_support/answer_center/edit
"
);
},
},
getTimeText
(
time
)
{
return
helper
.
dateStringTransform
(
time
||
""
);
},
getContentText
(
content
)
{
let
text
=
content
.
replace
(
/<img
[^
>
]
+>/g
,
"
【图片】
"
);
text
=
text
.
replace
(
/<iframe
(([\s\S])
*
?)
<
\/
iframe>/g
,
"
【视频】
"
);
text
=
text
.
replace
(
/<pre
(([\s\S])
*
?)
<
\/
pre>/g
,
"
【代码】
"
);
text
=
text
.
replace
(
/<
\/?
.+
?
>/g
,
""
);
return
text
;
},
},
},
};
};
</
script
>
</
script
>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment