讨论贴添加对应题目的链接
This commit is contained in:
parent
594147ab2a
commit
a7b29940ee
|
@ -245,6 +245,7 @@ export const m = {
|
|||
OI_Ranklist: 'OI Ranklist',
|
||||
|
||||
// /views/oj/discussion/discussionList.vue
|
||||
Go_to_problem:"Go to Problem",
|
||||
Release_Time:'Release Time',
|
||||
Likes:'Likes',
|
||||
Views:'Views',
|
||||
|
|
|
@ -247,6 +247,7 @@ export const m = {
|
|||
OI_Ranklist: 'OI 排行榜',
|
||||
|
||||
// /views/oj/discussion/discussionList.vue
|
||||
Go_to_problem:'前往原题',
|
||||
Release_Time:'发布时间',
|
||||
Likes:'点赞',
|
||||
Views:'浏览',
|
||||
|
|
|
@ -4,6 +4,14 @@
|
|||
<div class="title-article" style="text-align: left">
|
||||
<h1 class="title" id="sharetitle">
|
||||
<span>{{ discussion.title }}</span>
|
||||
<el-button
|
||||
type="primary"
|
||||
size="mini"
|
||||
style="margin-left:5px;vertical-align:middle;"
|
||||
v-if="discussion.pid"
|
||||
@click="toProblem(discussion.pid)"
|
||||
>{{ $t('m.Go_to_problem') }}</el-button
|
||||
>
|
||||
</h1>
|
||||
<div class="title-msg">
|
||||
<span>
|
||||
|
@ -262,6 +270,13 @@ export default {
|
|||
});
|
||||
},
|
||||
|
||||
toProblem(pid) {
|
||||
this.$router.push({
|
||||
name: 'ProblemDetails',
|
||||
params: { problemID: pid },
|
||||
});
|
||||
},
|
||||
|
||||
toLikeDiscussion(did, toLike) {
|
||||
if (!this.isAuthenticated) {
|
||||
myMessage.warning(this.$i18n.t('m.Please_login_first'));
|
||||
|
|
|
@ -61,12 +61,25 @@
|
|||
></path>
|
||||
</svg>
|
||||
</span>
|
||||
<a @click="toDiscussionDetail(discussion.id)" class="article-hlink">
|
||||
<h1>
|
||||
{{ discussion.title }}
|
||||
</h1>
|
||||
</a>
|
||||
|
||||
<h1 class="article-hlink">
|
||||
<a @click="toDiscussionDetail(discussion.id)">{{
|
||||
discussion.title
|
||||
}}</a>
|
||||
<el-button
|
||||
type="primary"
|
||||
size="mini"
|
||||
style="margin-left:5px;"
|
||||
v-if="discussion.pid"
|
||||
@click="
|
||||
pushRouter(
|
||||
null,
|
||||
{ problemID: discussion.pid },
|
||||
'ProblemDetails'
|
||||
)
|
||||
"
|
||||
>{{ $t('m.Go_to_problem') }}</el-button
|
||||
>
|
||||
</h1>
|
||||
<a
|
||||
@click="toDiscussionDetail(discussion.id)"
|
||||
class="article-hlink2"
|
||||
|
@ -688,7 +701,11 @@ export default {
|
|||
top: 0px;
|
||||
right: 0px;
|
||||
}
|
||||
.article-hlink h1 {
|
||||
.article-hlink {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
.article-hlink a {
|
||||
font-size: 16px;
|
||||
font-weight: 600;
|
||||
color: #34495e;
|
||||
|
|
Loading…
Reference in New Issue