Merge branch 'dev_aliyun' into dev_cs

dev_cs
caicai8 5 years ago
commit 9b9226a065

@ -0,0 +1,6 @@
function show_add_manager(id) {
$(".auth-schools-user-add").modal("show");
$(".auth-schools-user-add").find("#school_id_input").val(id)
}

@ -0,0 +1,13 @@
$(document).on('turbolinks:load', function() {
if ($('body.admins-major-informations-index-page').length > 0) {
var box_contain = $(".major-informations-list-container");
box_contain.on("click",".collapse-item",function () {
var a_fa = $(this).find("i");
if(a_fa.hasClass("fa-caret-right")){
a_fa.removeClass("fa-caret-right").addClass("fa-caret-down");
}else{
a_fa.removeClass("fa-caret-down").addClass("fa-caret-right");
}
});
}
});

@ -51,3 +51,5 @@ input.form-control {
position: absolute;
}
.position-r{position:relative;}
.color-grey-c{color:#ccc}
.inline-block{display:inline-block;}

@ -0,0 +1,66 @@
.admins-auth-schools-index-page{
.list-item-title{
padding-bottom:5px;
padding-left: 33px;
color: #555;
}
.list-item-title-1{
width: 100px;
display: inline-block;
}
.list-item-title-2{
width: 200px;
display: inline-block;
}
.collegeManage{
float: left;
padding: 0px 8px;
border-radius: 6px;
background-color: #f5f5f5;
margin: 3px 0px 3px 10px;
height: 34px;
line-height: 34px;
a{
color: #05101a;
}
a:hover{
color: #007bff;
}
}
i:hover{
color: #333;
}
.add-manager-i{
float: left;
i{
padding: 10px 5px;
}
}
.auth-schools-new-add, .auth-schools-user-add{
.flex-column{
input{
height: 38px;
}
}
.search-school{
margin-left: 15px;
}
}
.school-search-list{
background: #F4FAFF;
height: 280px;
overflow-y: scroll;
padding: 10px 0;
}
.school-list-item{
padding: 2px 10px;
input{
font-size: 20px;
margin-right: 5px;
}
}
}

@ -0,0 +1,37 @@
.admins-major-informations-index-page{
.fr{
float:right;
}
.panel-default{
margin-bottom: 10px;
background-color: rgb(245, 245, 245);
.panel-heading{
i{
margin-right:15px;
font-size:16px;
color:rgb(204, 204, 204);
}
a{
padding: 8px 10px;
display: inline-block;
width:100%;
color:rgb(102, 102, 102);
}
}
.panel-collapse{
padding-top: 10px;
background: #fff;
table{
text-align:center;
th,td{
padding: 8px;
}
td{
color:#888;
}
}
}
}
}

@ -33,4 +33,8 @@ input.form-control {
.font-12 { font-size: 12px !important; }
.font-14 { font-size: 14px !important; }
.font-16 { font-size: 16px !important; }
.font-18 { font-size: 18px !important; }
.font-18 { font-size: 18px !important; }
.padding10-5 { padding: 10px 5px;}
.width100 { width: 100%;}
.mb10 { margin-bottom: 10px ;}
.mt10 { margin-top: 10px ;}

@ -0,0 +1,57 @@
class Admins::AuthSchoolsController < Admins::BaseController
def index
schools = School.where(ec_auth: 1).includes(:users).order("updated_at desc")
@params_page = params[:page] || 1
@schools = paginate schools
end
def destroy
ActiveRecord::Base.transaction do
school = School.where(id: params[:id]).first
school.destroy
end
end
# 工程认证单位列表搜索学校
def search_school
@schools = School.where("ec_auth != 1 and name like '%#{params[:name]}%'").limit(10)
end
# 添加认证学校
def add_school
all_schools = School.all
all_schools.where(id: params[:school_id]).update_all(ec_auth: 1)
schools = all_schools.where(ec_auth: 1).order("updated_at desc")
@params_page = params[:page] || 1
@schools = paginate schools
end
# 搜索用户
def search_manager
school = School.find_by(id: params[:school_id])
user_ids = school&.ec_school_users&.pluck(:user_id)
@users = User.where.not(id: user_ids).where("concat(lastname, firstname) like ?", "%#{params[:name].strip.to_s}%").limit(10)
end
# 添加认证学校管理员
def add_manager
ActiveRecord::Base.transaction do
user_ids = params[:user_id]
@school_id = params[:school_id]
user_ids.each do |id|
EcSchoolUser.create(user_id: id, school_id: @school_id)
end
@school_users = User.where(id: user_ids)
end
end
# 删除学校管理员
def remove_manager
ActiveRecord::Base.transaction do
manager = EcSchoolUser.where(school_id: params[:school_id], user_id: params[:user_id]).first
manager&.destroy
end
end
end

@ -0,0 +1,8 @@
class Admins::MajorInformationsController < Admins::BaseController
def index
disciplines = EcDiscipline.includes(ec_discipline_firsts: {ec_majors: :schools}).order("ec_disciplines.code asc")
@disciplines = paginate disciplines
end
end

@ -708,6 +708,7 @@ class CoursesController < ApplicationController
def students
search = params[:search].present? ? params[:search].strip : nil
order = params[:order].present? ? params[:order].to_i : 0
sort = params[:sort].present? ? params[:sort] : "desc"
course_group_id = params[:course_group_id].present? ? params[:course_group_id].to_i : nil
@students = CourseMember.students(@course)
@ -719,12 +720,12 @@ class CoursesController < ApplicationController
if order == 1
# REDO:Extension
@students = @students.includes(user: :user_extension).order("user_extensions.student_id, users.login")
@students = @students.includes(user: :user_extension).order("user_extensions.student_id #{sort}, users.login #{sort}")
elsif order == 2
@students = @students.includes(:course_group).order("course_groups.position, users.login")
@students = @students.includes(:course_group).order("course_groups.position #{sort}, users.login #{sort}")
else
# REDO:Extension
@students = @students.includes(user: :user_extension).order("user_extensions.student_id, users.login")
@students = @students.includes(user: :user_extension).order("user_extensions.student_id #{sort}, users.login #{sort}")
end
if course_group_id.present?

@ -103,4 +103,8 @@ module Admins::BaseHelper
def unsafe_params
params.except(:controller, :action).to_unsafe_h
end
def list_index_no(page,index)
(page - 1) * 20 + index + 1
end
end

@ -0,0 +1,12 @@
class EcDiscipline < ActiveRecord::Base
validates_presence_of :code, :name
has_many :ec_discipline_firsts
# 专业数目
def major_count
count = 0
self.ec_discipline_firsts.map{|f| count += f.ec_majors.count}
count
end
end

@ -0,0 +1,6 @@
class EcDisciplineFirst < ActiveRecord::Base
validates_presence_of :code, :name
has_many :ec_majors
belongs_to :ec_discipline
end

@ -1,7 +1,10 @@
class EcMajor < ApplicationRecord
# 主页对应的学校,不同学校可以选用同样的专业,而每个专业又各具特色
has_many :schools, through: :ec_major_schools
has_many :ec_major_schools, dependent: :destroy
has_many :schools, through: :ec_major_schools
# 一级专业
belongs_to :ec_discipline_first
scope :search_name_or_code, -> (keyword) { where('name LIKE :keyword OR code LIKE :keyword', keyword: "%#{keyword.strip}%") }
end

@ -0,0 +1,6 @@
if($(".auth-schools-user-add").length > 0){
$(".auth-schools-user-add").modal("hide")
}
<% if @school_users.size > 0 %>
$("#table-school-<%= @school_id %>").find(".school_user_list").html("<%= j render partial: "admins/auth_schools/shared/school_user_list", locals: {users: @school_users, school_id: @school_id} %> ")
<% end %>

@ -0,0 +1,2 @@
$(".auth-schools-list-container").html("<%= j render partial: "admins/auth_schools/shared/list", locals: {schools: @schools} %>")
$(".auth-schools-new-add").modal("hide")

@ -0,0 +1 @@
$("#table-school-<%= params[:id] %>").remove()

@ -0,0 +1,14 @@
<% define_admin_breadcrumbs do %>
<% add_admin_breadcrumb('认证单位列表') %>
<% end %>
<div class="box search-form-container auth-schools-list-form">
<%= javascript_void_link '新增', class: 'btn btn-primary', data: { toggle: 'modal', target: '.auth-schools-new-add' } %>
</div>
<div class="box auth-schools-list-container">
<%= render(partial: 'admins/auth_schools/shared/list', locals: { schools: @schools }) %>
</div>
<%= render partial: "admins/auth_schools/shared/new_modal" %>
<%= render partial: "admins/auth_schools/shared/user_add_modal" %>

@ -0,0 +1 @@
$(".auth-schools-list-container").html("<%= j render partial: "admins/auth_schools/shared/list", locals: {schools: @schools} %>")

@ -0,0 +1,2 @@
$("#table-school-<%= params[:school_id] %>").find("#manager-<%= params[:user_id] %>").remove()

@ -0,0 +1,4 @@
if($("#add-users-list").length > 0){
$("#add-users-list").html("<%= j render partial: "admins/auth_schools/shared/add_users_list", locals: {users: @users, school_id: params[:school_id]} %>")
}

@ -0,0 +1,3 @@
if($("#add-schools-list").length > 0){
$("#add-schools-list").html("<%= j render partial: "admins/auth_schools/shared/add_schools_list", locals: {schools: @schools} %>")
}

@ -0,0 +1,23 @@
<%= form_tag(add_school_admins_auth_schools_path, method: :post, remote: true) do %>
<div class="add-school-list-item">
<div class="list-item-title">单位名称</div>
<div class="school-search-list">
<% if schools.size > 0 %>
<% schools.each do |school| %>
<div class="school-list-item">
<%= check_box_tag("school_id[]", school.id, false, id: "check_school_#{school.id}") %>
<label for="check_school_<%= school.id %>">
<%= school.try(:name) %>
</label>
</div>
<% end %>
<% else %>
<p class="padding10-5 color-grey-c">没有相关的单位</p>
<% end %>
</div>
</div>
<div class="text-right mt10">
<%= submit_tag("确认",class: "btn btn-primary submit-btn") %>
</div>
<% end %>

@ -0,0 +1,31 @@
<%= form_tag(add_manager_admins_auth_schools_path, method: :post, remote: true) do %>
<%= hidden_field_tag("school_id",school_id) %>
<div class="add-school-list-item">
<div class="list-item-title">
<span class="list-item-title-1">姓名</span>
<span class="list-item-title-2">单位</span>
</div>
<div class="school-search-list">
<% if users.size > 0 %>
<% users.each do |user| %>
<div class="school-list-item">
<%= check_box_tag("user_id[]", user.id, false, id: "check_user_#{user.id}") %>
<label for="check_user_<%= user.id %>">
<span class="list-item-title-1">
<%= user.try(:show_real_name) %>
</span>
<span class="list-item-title-2">
<%= user.try(:school_name) %>
</span>
</label>
</div>
<% end %>
<% else %>
<p class="padding10-5 color-grey-c">没有相关的单位</p>
<% end %>
</div>
</div>
<div class="text-right mt10">
<%= submit_tag("确认",class: "btn btn-primary submit-btn") %>
</div>
<% end %>

@ -0,0 +1,38 @@
<table class="table" cellspacing="0" cellpadding="0">
<thead>
<th width="10%">序号</th>
<th width="30%">学校名称</th>
<th width="50%">学校管理员</th>
<th width="10%">操作</th>
</thead>
<tbody>
<% if schools.size > 0 %>
<% schools.each_with_index do |school, index| %>
<tr id="table-school-<%= school.id %>">
<td><%= list_index_no(@params_page.to_i, index) %></td>
<td>
<%= link_to "#{school.name}", "/ecs/department?school_id=#{school.id}", target: "_blank" %>
</td>
<td>
<div class="add-manager-i">
<%= link_to "<i class='fa fa-plus-circle font-18 color-grey-c'></i>".html_safe, "javascript:void(0)", class: "action", onclick: "show_add_manager('#{school.id}')" %>
</div>
<div class="inline-block school_user_list">
<% if school.users.size > 0 %>
<%= render partial: "admins/auth_schools/shared/school_user_list", locals: {users: school.users, school_id: school.id} %>
<% end %>
</div>
</td>
<td>
<%= link_to "<i class='fa fa-trash-o color-grey-c font-18 padding10-5'></i>".html_safe, admins_auth_school_path(school), method: :delete, data: {confirm: "确认删除吗?"}, remote: true %>
</td>
</tr>
<% end %>
<% else %>
<%= render 'admins/shared/no_data_for_table' %>
<% end %>
</tbody>
</table>
<%= render partial: 'admins/shared/paginate', locals: { objects: schools } %>

@ -0,0 +1,32 @@
<div class="modal fade auth-schools-new-add" tabindex="-1" role="dialog" aria-hidden="true">
<div class="modal-dialog modal-dialog-centered" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title">新增认证单位</h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
<%= form_tag(search_school_admins_auth_schools_path,method: :get ,remote: true) do %>
<div class="form-group d-flex mbt10">
<div class="w-75 d-flex flex-column">
<%= text_field_tag(:name, nil, class: 'form-control', placeholder: '请输入单位名称搜索') %>
</div>
<%= submit_tag("搜索",class:"btn btn-primary search-school", 'data-disable-with': "搜索中...") %>
</div>
<% end %>
<div id="add-schools-list">
<div class="add-school-list-item">
<div class="list-item-title">单位名称</div>
<div class="school-search-list">
<div class="school-list-item">
<span class="color-grey-c">请输入单位名称</span>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>

@ -0,0 +1,6 @@
<% users.each do |user| %>
<span class="collegeManage" id="manager-<%= user.id %>">
<%= link_to user.show_real_name, "/users/#{user.login}", target: "_blank" %>
<%= link_to "×", remove_manager_admins_auth_schools_path(user_id: user.id, school_id: school_id),method: :post, class: "font-16 ml3", remote: true %>
</span>
<% end %>

@ -0,0 +1,36 @@
<div class="modal fade auth-schools-user-add" tabindex="-1" role="dialog" aria-hidden="true">
<div class="modal-dialog modal-dialog-centered" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title">添加管理员</h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
</div>
<div class="modal-body">
<%= form_tag(search_manager_admins_auth_schools_path, method: :get ,remote: true) do %>
<%= hidden_field("school_id","",id:"school_id_input") %>
<div class="form-group d-flex mbt10">
<div class="w-75 d-flex flex-column">
<%= text_field_tag(:name, nil, class: 'form-control', placeholder: '请输入用户姓名搜索') %>
</div>
<%= submit_tag("搜索",class:"btn btn-primary search-school", 'data-disable-with': "搜索中...") %>
</div>
<% end %>
<div id="add-users-list">
<div class="add-school-list-item">
<div class="list-item-title">
<span class="list-item-title-1">姓名</span>
<span class="list-item-title-2">单位</span>
</div>
<div class="school-search-list">
<div class="school-list-item">
<span class="color-grey-c">请输入用户姓名搜索</span>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>

@ -0,0 +1,7 @@
<% define_admin_breadcrumbs do %>
<% add_admin_breadcrumb('本科专业目录') %>
<% end %>
<div class="box major-informations-list-container">
<%= render(partial: 'admins/major_informations/shared/list', locals: { majors: @disciplines }) %>
</div>

@ -0,0 +1,48 @@
<div class="panel-group" id="accordion">
<% if @disciplines.size > 0 %>
<% @disciplines.each_with_index do |d,index| %>
<div class="panel panel-default">
<div class="panel-heading">
<div class="panel-title">
<a data-toggle="collapse" data-parent="#accordion"
href="#collapse-<%= index %>" class="collapse-item">
<i class="fa fa-caret-right fa-fw"></i>
<span><%= "#{d.code} #{d.name}" %></span>
<span class="fr"><%= d.major_count %></span>
</a>
</div>
</div>
<div id="collapse-<%= index %>" class="panel-collapse collapse in">
<div class="panel-body">
<table class="table table-bordered" cellpadding="0" cellspacing="0">
<thead>
<th class="with20">一级学科代码</th>
<th class="with20">一级学科名称</th>
<th class="with20">专业代码</th>
<th class="with20">专业名称</th>
<th class="with20">认证学校数量</th>
</thead>
<tbody>
<% d.ec_discipline_firsts.each do |f| %>
<% f.ec_majors.each_with_index do |m, index| %>
<tr>
<td><%= index == 0 ? f.code : "" %></td>
<td><%= index == 0 ? f.name : "" %></td>
<td><%= m.code %></td>
<td><%= m.name %></td>
<td><%= m.schools.size.to_i %></td>
</tr>
<% end %>
<% end %>
</tbody>
</table>
</div>
</div>
</div>
<% end %>
<% else %>
<%= render 'admins/shared/no_data_for_table' %>
<% end %>
</div>
<%= render partial: 'admins/shared/paginate', locals: { objects: @disciplines } %>

@ -66,6 +66,12 @@
<% end %>
</li>
<li>
<%= sidebar_item_group('#major-identification-submenu', '工程认证', icon: 'anchor') do %>
<li><%= sidebar_item(admins_major_informations_path, '本科专业目录', icon: 'outdent', controller: 'admins-major_informations') %></li>
<li><%= sidebar_item(admins_auth_schools_path, '认证单位列表', icon: 'th', controller: 'admins-auth_schools') %></li>
<% end %>
</li>
<li>
<%= sidebar_item_group('#helps-submenu', '帮助中心', icon: 'info-circle') do %>

@ -17,7 +17,7 @@
<% if shixuns.present? %>
<% shixuns.each_with_index do |shixun,index| %>
<tr>
<td><%= (@params_page.to_i - 1) * 20 + index + 1%></td>
<td><%= list_index_no(@params_page.to_i, index) %></td>
<td><%= shixun.identifier %></td>
<td class="text-left"><span><%= link_to overflow_hidden_span(shixun.name), "/shixuns/#{shixun.identifier}", :target => "_blank", :title => shixun.name %></span></td>
<td>

@ -38,7 +38,7 @@ if @shixun
json.game_score @work.work_challenge_score game, challenge_score
challenge_comment = @work.shixun_work_comments.find_by(challenge_id: game.challenge_id)
json.challenge_comment challenge_comment&.comment
json.challenge_comment_hidden challenge_comment&.hidden_comment
json.challenge_comment_hidden @user_course_identity < Course::STUDENT ? challenge_comment&.hidden_comment : nil
json.comment_id challenge_comment&.id
end
end

@ -802,6 +802,17 @@ Rails.application.routes.draw do
namespace :admins do
get '/', to: 'dashboards#index'
resources :major_informations, only: [:index]
resources :auth_schools, only: [:index, :destroy] do
collection do
get :search_school
post :add_school
get :search_manager
post :add_manager
post :remove_manager
end
end
resources :dashboards, only: [:index] do
collection do
get :month_active_user

@ -22,7 +22,6 @@
-->
<title>EduCoder</title>
<script type="text/javascript">
window.__testImageUrl = "https://pre-newweb.educoder.net/react/build/images/share_logo_icon.jpg"
window.__isR = true;
// 不支持ie9 ie10

@ -101,7 +101,7 @@
height : "100%",
path : "./lib/", // Dependents module file directory
pluginPath : "", // If this empty, default use settings.path + "../plugins/"
delay : 300, // Delay parse markdown to html, Uint : ms
delay : 500, // Delay parse markdown to html, Uint : ms
autoLoadModules : true, // Automatic load dependent module files
watch : true,
placeholder : "Enjoy Markdown! coding now...",

File diff suppressed because one or more lines are too long

@ -71,7 +71,10 @@ html, body {
/* 某些情况下被cm盖住了 */
z-index: 99;
}
/* 解决鼠标框选时,左边第一列没高亮的问题 */
.CodeMirror .CodeMirror-lines pre.CodeMirror-line, .CodeMirror .CodeMirror-lines pre.CodeMirror-line-like {
padding: 0 12px ;
}
/* antd扩展 */

@ -391,7 +391,7 @@ class CommonWorkDetailIndex extends Component{
{ work_statuses && work_statuses.indexOf('补交作品') != -1 &&
<a className={"fr color-blue font-16"} href={"javascript:void(0)"}
onClick={() => { this.props.toWorkPostPage(this.props.match.params, null, true, work_id)}}>
onClick={() => { this.props.toWorkPostPage(this.props.match.params)}}>
补交作品</a> }
{work_statuses && work_statuses.indexOf('修改作品') != -1 && <a className={"fr color-blue font-16"} href={"javascript:void(0)"}

@ -457,6 +457,7 @@ class Listofworksstudentone extends Component {
),
},
],
orders: "",
columnsstu2: [
{
title: '序号',
@ -583,11 +584,11 @@ class Listofworksstudentone extends Component {
<span className="font-14 maxnamewidth145" style={{width:'145px'}}>
{record.classroom === undefined ?
<a className=" font-14 maxnamewidth145"
style={{
color: '#9A9A9A',
textAlign: "center",
width:'145px',
}}>--</a> : record.classroom === "" ?
style={{
color: '#9A9A9A',
textAlign: "center",
width:'145px',
}}>--</a> : record.classroom === "" ?
<a className=" font-14 maxnamewidth145"
style={{
color: '#9A9A9A',
@ -601,13 +602,13 @@ class Listofworksstudentone extends Component {
width:'145px',
}}>--</a>
:
<a className=" font-14 maxnamewidth145"
title={record.classroom}
style={{
color: '#9A9A9A',
textAlign: "center",
width:'145px',
}}>{record.classroom}</a>
<a className=" font-14 maxnamewidth145"
title={record.classroom}
style={{
color: '#9A9A9A',
textAlign: "center",
width:'145px',
}}>{record.classroom}</a>
}
</span>
),
@ -650,14 +651,14 @@ class Listofworksstudentone extends Component {
}
}>
{record.cost_time === null? "--":record.cost_time === undefined?"--":record.cost_time === "--"?"--":
<span style={
{
color: '#747A7F',
textAlign: "center",
width:'145px',
}
<span style={
{
color: '#747A7F',
textAlign: "center",
width:'145px',
}
>{record.cost_time === null ? "--":record.cost_time === undefined ?"--":record.cost_time}
}
>{record.cost_time === null ? "--":record.cost_time === undefined ?"--":record.cost_time}
</span>
}
</span>
@ -804,7 +805,6 @@ class Listofworksstudentone extends Component {
),
},
],
orders: "",
b_order:"desc",
allow_late:false,
checkedValuesine: undefined,
@ -1816,7 +1816,10 @@ class Listofworksstudentone extends Component {
}
// console.log("554");
// console.log("Listofworksstudentone.js45666");
// console.log(columns2);
// console.log(columns3);
// console.log(arr);
this.setState({
data: datalist,
@ -1889,7 +1892,7 @@ class Listofworksstudentone extends Component {
if(item.title==="学号") {
continue
}else{
arr.push(item);
arr2.push(item);
}
}else{
if (this.state.work_efficiency === false) {
@ -1898,11 +1901,11 @@ class Listofworksstudentone extends Component {
} else if (item.title === "效率分") {
continue
}else{
arr.push(item);
arr2.push(item);
}
}else{
arr.push(item);
arr2.push(item);
}
}
@ -1970,7 +1973,9 @@ class Listofworksstudentone extends Component {
// console.log("datalistdatalist文件");
// console.log(datalist);
// console.log("645");
// console.log("Listofworksstudentone12314.js");
// console.log(columns2);
// console.log(columns3);
this.setState({
data: datalist,
teacherlist: teacherlist,

@ -17,7 +17,8 @@ class ShowAppraiseList extends Component{
render(){
let {data, work_comment,work_comment_hidden}=this.props;
let work_commenttype=work_comment===undefined||work_comment===null||work_comment==="";
let work_comment_hiddentype=work_comment===undefined||work_comment===null||work_comment==="";
let work_comment_hiddentype=work_comment_hidden===undefined||work_comment_hidden===null||work_comment_hidden==="";
return(
<div>
<style>
@ -66,25 +67,28 @@ class ShowAppraiseList extends Component{
{this.props&&this.props.isAdmin()===true?
<div className="font-16 color-dark-21 shixunreporttitleboxbom pd30bt">
<div>
{work_commenttype===true?"":<div>
<span className={"z000"}>学生可见<span className={"z666"}>学生可查看老师的评阅内容</span></span>
</div>
<div className={"borderbom"} style={{minHeight:'40px'}}>
{work_comment===true?"":<div className={"personalsummary"}>
</div>}
{work_commenttype===true?"":<div className={work_comment_hiddentype===true?"":"borderbom"} style={{minHeight:'40px'}}>
<div className={"personalsummary"}>
<div className={"markdown-body"}
dangerouslySetInnerHTML={{__html: markdownToHTML(work_comment).replace(/▁/g, "▁▁▁")}}></div>
</div>}
</div>
</div>
</div>}
<div>
{work_comment_hiddentype===true?"":<div>
<span className={"z000"}>学生不可见<span className={"z666"}>仅对课堂老师可见</span></span>
</div>
<div style={{minHeight:'40px'}}>
{work_comment_hidden===true?"":<div className={"personalsummary"}>
</div>}
{work_comment_hiddentype===true?"":<div style={{minHeight:'40px'}}>
<div className={"personalsummary"}>
<div className={"markdown-body"}
dangerouslySetInnerHTML={{__html: markdownToHTML(work_comment_hidden).replace(/▁/g, "▁▁▁")}}></div>
</div>}
</div>
</div>
</div>}
</div>:<div className="font-16 color-dark-21 shixunreporttitleboxbom pd30">
@ -109,7 +113,7 @@ class ShowAppraiseList extends Component{
return(
<div key={key}>
{challenge_comment===false&&challenge_comment_hidden==false?<div className="stud-class-set mt17" >
{challenge_comment===false||challenge_comment_hidden==false?<div className="stud-class-set mt17" >
<div className="clearfix edu-back-white poll_list">
<div className="font-16 color-dark-21 shixunreporttitleboxtop pd20 color333">
@ -125,25 +129,27 @@ class ShowAppraiseList extends Component{
{this.props&&this.props.isAdmin()===true?
<div className="font-16 color-dark-21 shixunreporttitleboxbom pd30bt">
<div>
{challenge_comment===true?"":<div>
<span className={"z000"}>学生可见<span className={"z666"}>学生可查看老师的评阅内容</span></span>
</div>
<div className={"borderbom"} style={{minHeight:'40px'}}>
{challenge_comment===true?"":<div className={"personalsummary"}>
</div>}
{challenge_comment===true?"":<div className={challenge_comment_hidden===true?"":"borderbom"} style={{minHeight:'40px'}}>
<div className={"personalsummary"}>
<div className={"markdown-body"}
dangerouslySetInnerHTML={{__html: markdownToHTML(item.challenge_comment).replace(/▁/g, "▁▁▁")}}></div>
</div>}
</div>
</div>
</div>}
<div>
{challenge_comment_hidden===true?"":<div>
<span className={"z000"}>学生不可见<span className={"z666"}>仅对课堂老师可见</span></span>
</div>
<div style={{minHeight:'40px'}}>
{challenge_comment_hidden===true?"":<div className={"personalsummary"}>
</div>}
{challenge_comment_hidden===true?"":<div style={{minHeight:'40px'}}>
<div className={"personalsummary"}>
<div className={"markdown-body"}
dangerouslySetInnerHTML={{__html: markdownToHTML(item.challenge_comment_hidden).replace(/▁/g, "▁▁▁")}}></div>
</div>}
</div>
</div>
</div>}
</div>: <div className="font-16 color-dark-21 shixunreporttitleboxbom pd30">
<div style={{minHeight:'40px'}}>

@ -121,7 +121,7 @@ class TPMRightSection extends Component {
<div className="padding20 edu-back-white mb10 mt10" style={{
display: TPMRightSectionData === undefined?"none":TPMRightSectionData.paths===undefined?"":TPMRightSectionData.paths.length === 0 ? "none" : "block"
}}>
<p className="mb20 font-16 clearfix">相关实践课程</p>
<p className="mb20 font-16 clearfix">所属课程</p>
<div className="recommend-list" >
{
TPMRightSectionData===undefined?"":TPMRightSectionData.paths===undefined?"":TPMRightSectionData.paths.map((i,k)=>{
@ -161,6 +161,7 @@ class TPMRightSection extends Component {
</div>
</div>
{TPMRightSectionData === undefined?"":TPMRightSectionData.paths===undefined?"":TPMRightSectionData.paths.length === 0 ? "" :
<div className="padding20 edu-back-white"
style={{
display:
@ -190,7 +191,7 @@ class TPMRightSection extends Component {
})
}
</div>
</div>
</div> }
</div>
}

Loading…
Cancel
Save