dev_new_shixunsrepository
杨树明 5 years ago
parent d71932c93a
commit 0c2fdb8030

@ -147,7 +147,7 @@ class ShixunsController < ApplicationController
## 实训详情
def show
# 当前用户开启的实训
can_fork = current_user.is_certification_teacher || current_user.admin?
can_fork = current_user.is_certification_teacher || current_user.admin_or_business?
unless can_fork
@can_fork = {can_fork: "已经职业认证的教师才能fork实训",
certi_url: "/account/certification"}

@ -43,6 +43,7 @@ class ExportShixunReportService
@user = @work.user
@shixun = homework.shixuns.take
@games = @work.myshixun.games.includes(:challenge, :game_codes,:outputs) if @work.myshixun
@challenges = @shixun.challenges if @shixun
# 用户最大评测次数
@user_evaluate_count = @games.pluck(:evaluate_count).sum if @games

@ -143,4 +143,18 @@
/* 选中行边框 */
.monaco-editor .view-overlays .current-line {
border-width: 1px !important;
}
.monaco-editor .margin,
.monaco-editor .margin-view-overlays{
width: 54px !important;
text-align: center !important;
}
.monaco-editor .monaco-scrollable-element{
left: 54px !important;
}
.monaco-editor .margin-view-overlays .line-numbers{
text-align: center !important;
}
Loading…
Cancel
Save