Merge branches 'dev_aliyun' and 'dev_ysm' of https://bdgit.educoder.net/Hjqreturn/educoder into dev_ysm

issues25489
杨树明 5 years ago
commit c4855c6ee2

@ -87,7 +87,6 @@ class Admins::MirrorRepositoriesController < Admins::BaseController
end
def check_shixun_mirrors!
return
return unless request.format.html?
Admins::CheckShixunMirrorsService.call

@ -1,8 +1,7 @@
class Admins::ShixunSettingsController < Admins::BaseController
def index
params[:sort_by] = params[:sort_by].presence || 'created_on'
params[:sort_direction] = params[:sort_direction].presence || 'desc'
default_sort('created_at', 'desc')
shixun_settings = Admins::ShixunSettingsQuery.call(params)
@editing_shixuns = shixun_settings.where(status:0).size

@ -1084,14 +1084,23 @@ class ExercisesController < ApplicationController
@shixun_undo = 0
@ques_undo = 0
ex_answer_time = @exercise.time.to_i
@ex_end_time = @exercise.get_exercise_end_time(current_user.id)
if ex_answer_time > 0
exercise_end_time = @exercise.exercise_users.exercise_commit_users(current_user.id)
if exercise_end_time.present?
ex_end_times = exercise_end_time.first.start_at.nil? ? Time.now : exercise_end_time.first.start_at
@ex_end_time = ex_end_times + ex_answer_time.minutes
end
if ex_answer_time > 0 #有剩余时间的时候
user_left_time = get_exercise_left_time(@exercise,current_user)
@ex_end_time = Time.now + user_left_time.to_i.seconds
else
@ex_end_time = @exercise.get_exercise_end_time(current_user.id)
end
# @ex_end_time = @exercise.get_exercise_end_time(current_user.id)
# if ex_answer_time > 0
# left_answer_time = Time.now + ex_answer_time.minutes #判断试卷的倒计时和截止时间哪个先到
# if left_answer_time < @ex_end_time
# exercise_end_time = @exercise.exercise_users.exercise_commit_users(current_user.id)
# if exercise_end_time.present?
# ex_end_times = exercise_end_time.first.start_at.nil? ? Time.now : exercise_end_time.first.start_at
# @ex_end_time = ex_end_times + ex_answer_time.minutes
# end
# end
# end
@exercise_questions.each do |q|
if q.question_type == Exercise::PRACTICAL #当为实训题时
user_myshixun = q.shixun.myshixuns.search_myshixun_user(current_user.id)

@ -1,9 +1,14 @@
class Oauth::BaseController < ActionController::Base
include RenderHelper
include LoginHelper
include ControllerRescueHandler
skip_before_action :verify_authenticity_token
def auth_failure
render_error(params[:message])
end
private
def session_user_id
@ -15,6 +20,7 @@ class Oauth::BaseController < ActionController::Base
end
def auth_hash
Rails.logger.info("[OAuth2] omniauth.auth -> #{request.env['omniauth.auth'].inspect}")
request.env['omniauth.auth']
end
end

@ -142,6 +142,9 @@ module ExercisesHelper
right_users_count = 0
#该问题的正确率
if ex.question_type == Exercise::MULTIPLE #多选题
if standard_answer.size == 1 #以前的多选题答案存在一个表里
standard_answer = standard_answer.first.to_s.split("").map(&:to_i)
end
right_user_ids = user_ids
standard_answer.each do |choice_position|
standard_answer_choice_id = ex_choices.select{|ec| ec.choice_position == choice_position}.first&.id
@ -896,7 +899,8 @@ module ExercisesHelper
if ex_time > 0
exercise_user = exercise.exercise_users.find_by(user_id:user.id)
time_mill = ex_time * 60 #转为秒
exercise_end_time = exercise.end_time.present? ? exercise.end_time.to_i : 0
exercise_end_time = exercise.get_exercise_end_time(user.id) #没有考虑分班的情况
# exercise_end_time = exercise.end_time.present? ? exercise.end_time.to_i : 0
exercise_user_start = exercise_user&.start_at.present? ? exercise_user.start_at.to_i : 0
#用户未开始答题时即exercise_user_start为0
if exercise_user_start == 0

@ -6,6 +6,7 @@ module OmniAuth
authorize_url: '/oauth2.0/authorize',
token_url: '/oauth2.0/token'
}
option :token_params, { parse: :query }
def request_phase
super
@ -21,7 +22,17 @@ module OmniAuth
end
end
uid { raw_info['openid'].to_s }
uid do
@uid ||= begin
access_token.options[:mode] = :query
access_token.options[:param_name] = :access_token
# Response Example: "callback( {\"client_id\":\"11111\",\"openid\":\"000000FFFF\"} );\n"
response = access_token.get('/oauth2.0/me')
matched = response.body.match(/"openid":"(?<openid>\w+)"/)
matched[:openid]
end
end
info do
{
@ -35,15 +46,10 @@ module OmniAuth
{ raw_info: user_info }
end
def raw_info
access_token.options[:mode] = :query
@raw_info ||= access_token.get('/oauth2.0/me').parsed
end
def user_info
access_token.options[:mode] = :query
params = { oauth_consumer_key: options.client_id, openid: raw_info['openid'], format: 'json' }
@user_info ||= access_token.get('/user/get_user_info', params: params)
param = { oauth_consumer_key: options[:client_id], openid: uid, format: 'json' }
@user_info ||= access_token.get('/user/get_user_info', params: param, parse: :json).parsed
end
end
end

@ -77,10 +77,11 @@ class Admins::CheckShixunMirrorsService < ApplicationService
@_bridge_images ||= begin
url = EduSetting.get('cloud_bridge')
res = Faraday.get(url)
res_body = JSON.parse(res.body)
raise Error, '拉取镜像信息异常' if res && res['code'].nonzero?
raise Error, '拉取镜像信息异常' if res_body && res_body['code'].to_i != 0
res
res_body
rescue => e
Rails.logger.error("get response failed ! #{e.message}")
raise Error, '实训云平台繁忙繁忙等级84'

@ -28,7 +28,7 @@ class Oauth::CreateOrFindQqAccountService < ApplicationService
user.create_user_extension!(gender: gender)
# 下载头像
avatar_path = Util::FileManage.source_disk_filename(user)
Util.download_file(params.dig('info', 'figureurl_qq_1'), avatar_path)
Util.download_file(params.dig('info', 'image'), avatar_path)
end
new_open_user = OpenUsers::QQ.create!(user: user, uid: params['uid'], extra: params.dig('extra', 'raw_info'))

@ -12,6 +12,7 @@ json.allow_send @user.logged?
json.allow_visit @subject.status > 1 || @is_manager
json.allow_add_member @is_manager
json.is_creator @is_creator
json.cover url_to_avatar(@subject)
if @subject.excellent
json.has_start @subject.has_course_start?

@ -1,4 +1,8 @@
OmniAuth.config.add_camelization 'qq', 'QQ'
OmniAuth.config.logger = Rails.logger
OmniAuth.config.on_failure = Proc.new { |env|
OmniAuth::FailureEndpoint.new(env).redirect_to_failure
}
oauth_config = {}
begin
@ -13,5 +17,5 @@ rescue => ex
end
Rails.application.config.middleware.use OmniAuth::Builder do
provider :qq, oauth_config['appid'], oauth_config['secret']
provider :qq, oauth_config['appid'], oauth_config['secret'], { provider_ignores_state: true }
end

@ -6,6 +6,8 @@ Rails.application.routes.draw do
get 'attachments/download/:id', to: 'attachments#show'
get 'attachments/download/:id/:filename', to: 'attachments#show'
get 'auth/qq/callback', to: 'oauth/qq#create'
get 'auth/failure', to: 'oauth/base#auth_failure'
resources :edu_settings
scope '/api' do
@ -289,6 +291,7 @@ Rails.application.routes.draw do
post :down_member_position
get :right_banner
post :appointment
post :update_team_title
end
collection do
@ -1077,7 +1080,6 @@ Rails.application.routes.draw do
post :cancel_homepage_show
post :excellent
post :cancel_excellent
post :update_team_title
end
end
end

@ -32,7 +32,7 @@ module.exports = {
// See the discussion in https://github.com/facebookincubator/create-react-app/issues/343.s
// devtool: "cheap-module-eval-source-map",
// 开启调试
devtool: "source-map", // 开启调试
// devtool: "source-map", // 开启调试
// These are the "entry points" to our application.
// This means they will be the "root" imports that are included in JS bundle.
// The first two entry points enable "hot" CSS and auto-refreshes for JS.

@ -222,6 +222,12 @@
<div class="code-name">&amp;#xe693;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe6c0;</span>
<div class="name">关注</div>
<div class="code-name">&amp;#xe6c0;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe63c;</span>
<div class="name">礼物</div>
@ -324,6 +330,12 @@
<div class="code-name">&amp;#xe678;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe6c5;</span>
<div class="name">关注</div>
<div class="code-name">&amp;#xe6c5;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe608;</span>
<div class="name">喇叭</div>
@ -1718,6 +1730,15 @@
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-weibiaoti105"></span>
<div class="name">
关注
</div>
<div class="code-name">.icon-weibiaoti105
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-gift"></span>
<div class="name">
@ -1871,6 +1892,15 @@
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-guanzhu"></span>
<div class="name">
关注
</div>
<div class="code-name">.icon-guanzhu
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-laba"></span>
<div class="name">
@ -3740,6 +3770,14 @@
<div class="code-name">#icon-renzhengxinxi</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-weibiaoti105"></use>
</svg>
<div class="name">关注</div>
<div class="code-name">#icon-weibiaoti105</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-gift"></use>
@ -3876,6 +3914,14 @@
<div class="code-name">#icon-dashujucunchu</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-guanzhu"></use>
</svg>
<div class="name">关注</div>
<div class="code-name">#icon-guanzhu</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-laba"></use>

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -229,6 +229,13 @@
"unicode": "e693",
"unicode_decimal": 59027
},
{
"icon_id": "1214792",
"name": "关注",
"font_class": "weibiaoti105",
"unicode": "e6c0",
"unicode_decimal": 59072
},
{
"icon_id": "1221889",
"name": "礼物",
@ -348,6 +355,13 @@
"unicode": "e678",
"unicode_decimal": 59000
},
{
"icon_id": "1901672",
"name": "关注",
"font_class": "guanzhu",
"unicode": "e6c5",
"unicode_decimal": 59077
},
{
"icon_id": "1941293",
"name": "喇叭",

@ -116,6 +116,9 @@ Created by iconfont
<glyph glyph-name="renzhengxinxi" unicode="&#59027;" d="M485.648423-128c-144.376948 0-412.841368 220.864564-412.841368 429.728646L72.807056 717.817567l41.04289 0.68044c0.866014 0 92.50888 1.948532 187.059079 40.331521 96.962668 39.403649 159.532198 84.652894 160.11985 85.054972l24.495832 17.846079 24.712335-17.846079c0.587653-0.433007 63.126253-45.651323 160.11985-85.054972 94.550199-38.382989 186.193065-40.331521 187.151867-40.331521l40.857315-0.68044 0.185574-416.057992C898.582578 92.895494 630.118159-128 485.648423-128L485.648423-128M156.160928 638.051468l0-336.291893c0-161.511659 233.854778-346.374773 329.487495-346.374773 95.632717 0 329.487495 184.863115 329.487495 346.374773L815.135919 638.051468c-40.857315 4.422859-107.200193 15.588257-176.079256 43.548145-70.611091 28.702187-124.242117 59.909629-153.40824 78.498007-29.104265-18.588377-82.76622-49.79582-153.315452-78.498007C263.361121 653.608795 197.018243 642.474326 156.160928 638.051468L156.160928 638.051468M463.56506 145.413072 288.28996 294.738673l53.909387 63.404615 112.458137-95.725504 213.441585 245.886191 63.033466-54.682614L463.56506 145.413072 463.56506 145.413072M463.56506 145.413072 463.56506 145.413072z" horiz-adv-x="1024" />
<glyph glyph-name="weibiaoti105" unicode="&#59072;" d="M936.038 750.874c-109.38 118.519-286.737 118.519-396.083 0l-27.93-30.276-27.947 30.276c-109.363 118.519-286.703 118.519-396.066 0-109.38-118.511-109.38-310.647 0-429.158l27.93-30.251 396.083-365.414 396.066 365.414 27.947 30.251c109.362 118.51 109.362 310.647 0 429.158v0z" horiz-adv-x="1024" />
<glyph glyph-name="gift" unicode="&#58940;" d="M85.931-54.016c0-24.576 7.125-31.317 29.44-31.317h353.365v469.589h-382.805v-438.272zM555.264-85.333h353.365c22.357 0 29.44 6.699 29.44 31.317l-0 438.272h-382.848v-469.589zM938.667 640h-213.333c51.499 11.733 105.899 49.707 112.597 94.293 7.851 50.859-52.565 127.957-125.653 118.187-87.424-12.117-151.509-89.259-196.736-149.077-44.885 58.667-103.381 127.189-187.179 147.115-81.152 19.2-136.747-64.939-135.253-116.992 1.451-44.245 52.608-81.835 105.557-93.525h-213.333c-26.368 0-42.667-14.848-42.667-42.667v-170.581l426.667-0.085v213.333h85.333v-213.333l426.667 0.085v170.581c0 27.819-16.341 42.667-42.667 42.667zM251.648 717.824c-14.763 16.427-4.779 38.741 4.48 55.595 17.024 29.696 40.747 47.744 81.152 30.933 56.32-23.509 97.792-73.216 131.584-117.803-71.552-7.893-178.304-10.965-217.216 31.275zM562.944 687.317c34.816 44.629 75.221 89.941 131.157 117.803 58.581 28.971 113.024-49.323 85.205-86.912-21.419-28.544-89.259-31.232-125.909-32.853-30.080-1.536-60.501-0.811-90.453 1.963z" horiz-adv-x="1024" />
@ -167,6 +170,9 @@ Created by iconfont
<glyph glyph-name="dashujucunchu" unicode="&#59000;" d="M975.644444 233.24444400000004V534.7555560000001c28.444444 14.222222 51.2 42.666667 51.2 76.8 0 48.355556-36.977778 85.333333-85.333333 85.333333-19.911111 0-39.822222-8.533333-54.044444-19.911111L594.488889 830.577778C585.955556 867.555556 551.822222 896 512 896c-42.666667 0-79.644444-31.288889-85.333333-73.955556L145.066667 671.288889C130.844444 688.355556 108.088889 696.8888890000001 85.333333 696.8888890000001c-48.355556 0-85.333333-36.977778-85.333333-85.333333 0-39.822222 28.444444-73.955556 65.422222-82.488889v-290.133334C28.444444 230.39999999999998 0 196.26666699999998 0 156.44444399999998c0-48.355556 36.977778-85.333333 85.333333-85.333333 22.755556 0 45.511111 8.533333 59.733334 25.6l281.6-150.755555c5.688889-42.666667 39.822222-73.955556 85.333333-73.955556 39.822222 0 73.955556 28.444444 82.488889 65.422222l290.133333 153.6c14.222222-11.377778 34.133333-19.911111 54.044445-19.911111 48.355556 0 85.333333 36.977778 85.333333 85.333333 0 34.133333-19.911111 62.577778-48.355556 76.8z m-96.711111-14.222222l-133.688889 65.422222v199.111112l133.688889 65.422222c11.377778-11.377778 22.755556-17.066667 36.977778-19.911111v-290.133334c-14.222222-2.844444-25.6-11.377778-36.977778-19.911111zM853.333333 600.177778l-139.377777-68.266667L540.444444 631.4666669999999V731.022222c19.911111 8.533333 36.977778 22.755556 45.511112 39.822222l267.377777-142.222222v-28.444444zM520.533333 190.57777799999997l-170.666666 96.711111v193.422222l170.666666 96.711111 170.666667-96.711111v-193.422222l-170.666667-96.711111zM483.555556 731.022222v-105.244444l-167.822223-96.711111L170.666667 600.177778V611.555556v8.533333l270.222222 145.066667c8.533333-17.066667 25.6-28.444444 42.666667-34.133334zM145.066667 548.977778l147.911111-73.955556v-184.888889l-147.911111-73.955555c-5.688889 5.688889-14.222222 11.377778-22.755556 17.066666V534.7555560000001c8.533333 2.844444 14.222222 8.533333 22.755556 14.222222zM170.666667 167.822222l145.066666 73.955556 167.822223-96.711111v-105.244445c-17.066667-5.688889-34.133333-17.066667-42.666667-34.133333l-270.222222 142.222222V156.44444399999998v11.377778z m369.777777-130.844444v99.555555l176.355556 99.555556 139.377778-68.266667v-11.377778c0-5.688889 0-11.377778 2.844444-17.066666l-267.377778-142.222222c-14.222222 19.911111-31.288889 34.133333-51.2 39.822222z" horiz-adv-x="1026" />
<glyph glyph-name="guanzhu" unicode="&#59077;" d="M726.109 863.418c-83.782 0-158.255-32.582-214.109-93.091-55.855 60.509-130.327 93.091-214.109 93.091-162.909 0-297.891-144.291-297.891-321.164 0-93.091 37.236-181.527 107.055-246.691l353.745-367.709c13.964-13.964 32.582-23.273 51.2-23.273 18.618 0 37.236 9.309 51.2 23.273l358.4 363.055c65.164 65.164 107.055 158.255 107.055 251.345-4.655 176.873-139.636 321.164-302.545 321.164zM870.4 346.764l-358.4-363.055-358.4 367.709c-51.2 51.2-83.782 116.364-83.782 190.836 0 134.982 102.4 242.036 228.073 242.036 97.745 0 176.873-65.164 214.109-153.6 32.582 88.436 116.364 153.6 214.109 153.6 125.673 0 228.073-107.055 228.073-242.036 0-74.473-32.582-144.291-83.782-195.491z" horiz-adv-x="1028" />
<glyph glyph-name="laba" unicode="&#58888;" d="M858.584615 586.174359c-5.251282 5.251282-10.502564 10.502564-15.753846 13.128205-5.251282 5.251282-10.502564 10.502564-18.379487 13.128205v-10.502564c-21.005128 0-39.384615-18.379487-39.384615-39.384615v-2.625641c0-21.005128 18.379487-39.384615 39.384615-39.384616v-18.379487c26.25641-34.133333 39.384615-73.517949 39.384615-118.153846s-15.753846-86.646154-39.384615-118.153846v-15.753846c-21.005128 0-39.384615-18.379487-39.384615-39.384616v-2.625641c0-21.005128 18.379487-39.384615 39.384615-39.384615v-10.502564c7.876923 5.251282 13.128205 10.502564 21.005128 15.753846 5.251282 2.625641 10.502564 7.876923 13.128205 10.502564 52.512821 49.887179 86.646154 120.779487 86.646154 202.174359 0 78.769231-34.133333 149.661538-86.646154 199.548718z m-189.046153 191.671795h-7.876924c-7.876923 0-13.128205-2.625641-21.005128-7.876923l-330.830769-149.661539H157.538462c-44.635897 0-78.769231-34.133333-78.769231-78.76923v-317.702565c2.625641-42.010256 36.758974-76.14359 78.769231-76.143589h39.384615c21.005128 0 39.384615 18.379487 39.384615 39.384615s-15.753846 36.758974-34.133333 39.384615H236.307692c-65.641026 0-78.769231 13.128205-78.76923 78.769231v-2.625641 170.666667-7.876923c0 60.389744 10.502564 76.14359 65.641025 78.769231H315.076923c5.251282 0 10.502564 2.625641 15.753846 5.251282 2.625641 0 7.876923 2.625641 10.502564 5.251282l288.820513 131.282051v-593.394872L375.466667 213.333333c-18.379487 13.128205-42.010256 7.876923-55.138462-7.876923-13.128205-18.379487-7.876923-42.010256 7.876923-55.138461L638.030769 3.282051c7.876923-5.251282 18.379487-7.876923 26.25641-7.876923h2.625642c21.005128 0 39.384615 18.379487 39.384615 39.384616L708.923077 738.461538c0 23.630769-18.379487 39.384615-39.384615 39.384616z m-506.748718-551.384616H157.538462h5.251282z m-5.251282 315.076924h21.005128H157.538462z" horiz-adv-x="1024" />
@ -659,7 +665,7 @@ Created by iconfont
<glyph glyph-name="xuexizhongxin" unicode="&#59062;" d="M946.907429 889.690634H635.102609c-36.145292 0-68.945093-14.533168-92.91687-38.13605A131.510857 131.510857 0 0 1 449.389714 889.690634H137.591255C64.422957 889.690634 4.916472 830.184149 4.916472 757.015851v-643.472696a39.707031 39.707031 0 0 1 39.751553-39.751553h378.142211c55.149714 0 84.22241-45.348571 85.214609-46.957714 0.496099-0.871354 1.240248-1.367453 1.736348-2.238807 0.623304-0.871354 1.246609-1.615503 1.863552-2.353292 2.111602-2.493217 4.477615-4.725665 6.958112-6.716423l1.494659-1.113043c6.455652-4.35041 14.037068-6.958112 21.987378-6.958112 3.472696 0 7.078957 0.496099 10.558013 1.488298 1.488298 0.375255 2.734907 1.367453 4.096 1.863553 1.990758 0.744149 3.854311 1.615503 5.717863 2.607702 1.615503 0.998559 2.976596 2.111602 4.471255 3.231006a40.19677 40.19677 0 0 1 4.719304 4.471255c0.992199 1.119404 2.111602 2.359652 2.982957 3.606261 0.368894 0.616944 0.992199 1.113043 1.367453 1.736348 1.240248 1.990758 30.306584 47.332969 85.462659 47.332968h378.13585a39.707031 39.707031 0 0 1 39.751553 39.751553V757.015851c0.25441 73.168298-59.252075 132.674783-132.420372 132.674783zM422.931081 121.614311H50.576696V769.736348c0 29.320745 56.154634 69.275826 85.348174 69.275826h311.798459c29.320745 0 72.475031-40.082286 72.475031-69.275826v-667.12646c-21.739329 11.054112-65.841292 19.004422-97.267279 19.004423z m602.582658 0h-363.825292c-31.425988 0-57.884621-7.950311-79.63031-19.004423V769.736348c0 29.320745 27.120099 67.584 56.313639 67.584h330.879205c29.320745 0 56.141913-38.39046 56.141913-67.584v-648.122037h0.127205zM403.055304 644.197764H184.173714c-21.987379 0-39.751553-14.208795-39.751553-31.801242 0-17.586087 17.764174-31.801242 39.751553-31.801242h218.88159c21.987379 0 39.751553 14.215155 39.751553 31.801242 0 17.490683-17.764174 31.801242-39.751553 31.801242z m0-248.049689H184.173714c-21.987379 0-39.751553-14.208795-39.751553-31.801243 0-17.586087 17.764174-31.801242 39.751553-31.801242h218.88159c21.987379 0 39.751553 14.215155 39.751553 31.801242 0 17.490683-17.764174 31.801242-39.751553 31.801243z m497.517715 254.409937H681.564224c-21.987379 0-39.751553-14.208795-39.751553-31.801242 0-17.586087 17.764174-31.801242 39.751553-31.801242h218.88159c21.987379 0 39.751553 14.215155 39.751552 31.801242 0.127205 17.490683-17.636969 31.801242-39.624347 31.801242z m0-254.409937H681.564224c-21.987379 0-39.751553-14.208795-39.751553-31.801243 0-17.586087 17.764174-31.801242 39.751553-31.801242h218.88159c21.987379 0 39.751553 14.215155 39.751552 31.801242 0.127205 17.490683-17.636969 31.801242-39.624347 31.801243z m139.251279-457.638957H52.249441c-21.987379 0-39.751553-14.208795-39.751553-31.801242s17.764174-31.801242 39.751553-31.801242h987.574857c21.987379 0 39.751553 14.208795 39.751553 31.801242 0 17.490683-17.764174 31.801242-39.751553 31.801242z" horiz-adv-x="1081" />
<glyph glyph-name="tongji" unicode="&#59071;" d="M256-32.2h-62.5c-52.9 0-96 43.1-96 96V413.9c0 52.9 43.1 96 96 96H256c52.9 0 96-43.1 96-96v-350.1c0-53-43.1-96-96-96z m-62.5 478.1c-17.6 0-32-14.4-32-32v-350.1c0-17.6 14.4-32 32-32H256c17.6 0 32 14.4 32 32V413.9c0 17.6-14.4 32-32 32h-62.5zM542.2-32.2h-62.5c-52.9 0-96 43.1-96 96V704.2c0 52.9 43.1 96 96 96h62.5c52.9 0 96-43.1 96-96v-640.5c0-52.9-43-95.9-96-95.9z m-62.4 768.4c-17.6 0-32-14.4-32-32v-640.5c0-17.6 14.4-32 32-32h62.5c17.6 0 32 14.4 32 32V704.2c0 17.6-14.4 32-32 32h-62.5zM830.5-32.2H768c-52.9 0-96 43.1-96 96v479c0 52.9 43.1 96 96 96h62.5c52.9 0 96-43.1 96-96v-479c0-53-43.1-96-96-96zM768 574.7c-17.6 0-32-14.4-32-32v-479c0-17.6 14.4-32 32-32h62.5c17.6 0 32 14.4 32 32v479c0 17.6-14.4 32-32 32H768z" horiz-adv-x="1024" />
<glyph glyph-name="tongji" unicode="&#59071;" d="M210.823529 594.823529A90.352941 90.352941 0 0 0 301.176471 504.470588v-542.117647A90.352941 90.352941 0 0 0 210.823529-128h-120.470588A90.352941 90.352941 0 0 0 0-37.64705900000001v542.117647A90.352941 90.352941 0 0 0 90.352941 594.823529h120.470588z m361.411765 301.176471A90.352941 90.352941 0 0 0 662.588235 805.647059v-843.294118A90.352941 90.352941 0 0 0 572.235294-128h-120.470588A90.352941 90.352941 0 0 0 361.411765-37.64705900000001v843.294118A90.352941 90.352941 0 0 0 451.764706 896h120.470588z m361.411765-542.117647a90.352941 90.352941 0 0 0 90.352941-90.352941v-301.176471a90.352941 90.352941 0 0 0-90.352941-90.352941h-120.470588a90.352941 90.352941 0 0 0-90.352942 90.352941v301.176471A90.352941 90.352941 0 0 0 813.176471 353.88235299999997h120.470588z m-722.82353 180.705882h-120.470588a30.117647 30.117647 0 0 1-29.635765-24.69647L60.235294 504.470588v-542.117647a30.117647 30.117647 0 0 1 24.696471-29.635765L90.352941-67.76470600000005h120.470588a30.117647 30.117647 0 0 1 29.635765 24.696471L240.941176-37.64705900000001v542.117647a30.117647 30.117647 0 0 1-30.117647 30.117647z m361.411765 301.176471h-120.470588a30.117647 30.117647 0 0 1-29.635765-24.696471L421.647059 805.647059v-843.294118a30.117647 30.117647 0 0 1 24.69647-29.635765L451.764706-67.76470600000005h120.470588a30.117647 30.117647 0 0 1 29.635765 24.696471L602.352941-37.64705900000001v843.294118a30.117647 30.117647 0 0 1-30.117647 30.117647z m361.411765-542.117647h-120.470588a30.117647 30.117647 0 0 1-29.635765-24.696471L783.058824 263.529412v-301.176471a30.117647 30.117647 0 0 1 24.69647-29.635765l5.421177-0.481882h120.470588a30.117647 30.117647 0 0 1 29.635765 24.696471L963.764706-37.64705900000001v301.176471a30.117647 30.117647 0 0 1-30.117647 30.117647z" horiz-adv-x="1024" />
<glyph glyph-name="menu_voucher" unicode="&#59064;" d="M830.236-64.886H200.924c-63.104 0-114.421 51.316-114.421 114.421V364.191c0 63.104 51.316 114.421 114.421 114.421h629.313c63.104 0 114.421-51.316 114.421-114.421v-314.656c-0.001-63.105-51.317-114.421-114.422-114.421zM200.924 421.401c-31.538 0-57.21-25.672-57.21-57.21v-314.656c0-31.538 25.672-57.21 57.21-57.21h629.313c31.538 0 57.21 25.672 57.21 57.21V364.191c0 31.538-25.672 57.21-57.21 57.21H200.924zM801.631 604.848H229.529c-15.811 0-28.605 12.794-28.605 28.605s12.794 28.605 28.605 28.605h572.103c15.811 0 28.605-12.794 28.605-28.605s-12.795-28.605-28.606-28.605zM630 777.904H401.159c-15.811 0-28.605 12.794-28.605 28.605s12.794 28.605 28.605 28.605H630c15.811 0 28.605-12.794 28.605-28.605S645.812 777.904 630 777.904z" horiz-adv-x="1024" />

Before

Width:  |  Height:  |  Size: 306 KiB

After

Width:  |  Height:  |  Size: 308 KiB

@ -14,4 +14,9 @@ http://codemirror.net
diff_match_patch
codemirror merge.js
从 edu_tpi.js 挪过来的js
从 edu_tpi.js 挪过来的js
修改过的地方:
Raphaël 2.1.3
Element= -> __Element= Element= 替换成了 __Element=

@ -1,3 +1,8 @@
其他的文档位置:
/educoder/public/react/public/js/readme.txt 关于js_min_all
/educoder/educoder/public/react/scripts/readme-cdn.txt 关于CDN
/educoder/public/react/src/modules/page/readme.txt 关于TPI
1、 安装node v6.9.x此安装包含了node和npm。
2、 安装cnpm命令行 npm install -g cnpm --registry=https://registry.npm.taobao.org

@ -173,7 +173,7 @@ function copyPublicFolder() {
});
}
// 给build脚本增加的方法对其生成的index.html做一些文本替换以及cdn处理
function generateNewIndexJsp() {
// var combinedStream = CombinedStream.create();
var filePath = paths.appBuild + '/index.html';

@ -0,0 +1,16 @@
目前是判断域名的方式动态访问对应的cdn资源
静态资源处理在build.js中如下代码
if (window.location.host == 'pre-newweb.educoder.net') {
_host = 'https://testali-cdn.educoder.net/react/build/'
} else if (window.location.host == 'www.educoder.net') {
_host = 'https://ali-cdn.educoder.net/react/build/'
}
只对预上线和正式版做了处理
动态的chunk资源处理在public-path.js中如下代码
if ( window.location.host == 'pre-newweb.educoder.net') {
__webpack_public_path__ = 'https://testali-cdn.educoder.net/react/build/'
} else if ( window.location.host == 'www.educoder.net') {
__webpack_public_path__ = 'https://ali-cdn.educoder.net/react/build/'
}

@ -59,8 +59,14 @@ const _origin = window.location.origin;
currentPage
comments
buttonText 发送按钮 显示文本
showRewardButton 是否显示奖励按钮
showHiddenButton 是否显示隐藏按钮
onlySuperAdminCouldHide 只有超级管理员才显示隐藏取消隐藏
isChildCommentPagination 是否子回复分页
loadMoreChildComments function 加载所有子回复
接口
deleteComment 删除
@ -402,6 +408,7 @@ class Comments extends Component {
</Tooltip>
</span>
</p>
{/* __useKindEditor暂时没用到了TODO 可以去掉 */}
{ window.__useKindEditor ? <CommentItemKEEditor showReplyEditorFlag={showReplyEditorFlag}
currentReplyComment={currentReplyComment}
item={item}

@ -48,6 +48,29 @@ class CompetitionCommon extends Component{
}
}
componentDidUpdate = (prevProps) => {
if (prevProps.user != this.props.user) {
console.log("componentDidUpdatess");
console.log(this.props.user);
if (this.props.user && this.props.user.login != "") {
const zul = `/competitions/${this.props.match.params.identifier}/competition_staff.json`;
axios.get((zul)).then((result) => {
if (result) {
if (result.data) {
this.setState({
signupdata: result.data
})
}
}
}).catch((error) => {
//console.log(error);
})
}
}
}
//获取头部信息
getbannerdata=()=>{
let menuid=this.props.location.search.replace('?menu=', '');
let url=`/competitions/${this.props.match.params.identifier}/common_header.json`;
@ -55,7 +78,8 @@ class CompetitionCommon extends Component{
if(response.status===200){
this.setState({
data: response.data,
thiskeys: menuid === undefined || menuid === "" ? response.data.competition_modules[0].id : menuid
thiskeys: menuid === undefined || menuid === "" ? response.data.competition_modules[0].id : menuid,
mode: response.data.mode
})
if(menuid===undefined||menuid===""){
this.getrightdata(
@ -82,6 +106,8 @@ class CompetitionCommon extends Component{
console.log(error)
})
//this.props.user 有可能为空
if (this.props.user && this.props.user.login != "") {
const zul = `/competitions/${this.props.match.params.identifier}/competition_staff.json`;
axios.get((zul)).then((result) => {

@ -369,7 +369,9 @@ function buildColumns(that, student_works, studentData) {
</Tooltip> }
{/* toWorkDetailPage */}
{/* /courses/"+courseId+"/common_homeworks/"+workId+ '/' + record.id +"/appraise */}
<a style={{color:'#4CACFF', marginLeft: '4px'}} href={"javascript:void(0)"} onClick={() => that.props.toWorkDetailPage(courseId, workId, record.id)} >{ isAdmin ? '评阅': '查看'}</a>
<a style={{color: '#4CACFF', marginLeft: '4px'}} id={"asdasdasdasd"}
onMouseDown={(e) => that.props.toWorkDetailPage2(e, courseId, workId, record.id)}
onClick={() => that.props.toWorkDetailPage(courseId, workId, record.id)}>{isAdmin ? '评阅' : '查看'}</a>
</div>

@ -12,15 +12,15 @@ export function RouteHOC(options = {}) {
return class Wrapper extends Component {
constructor(props) {
super(props);
this.state = {
}
}
toCreateProject = () => {
let url = '/projects/new'
if (window.location.port == 3007) {
// window.location.href
// window.location.href
url = '/testbdweb.educoder.net/projects/new'
}
window.open(
@ -55,8 +55,8 @@ export function RouteHOC(options = {}) {
} else {
this.props.history.push(`/courses/${_courseId}/boards/${workId}/messages/${topicId}`)
}
}
}
toEditPage = (_courseId, _workId) => {
const secondName = this.getModuleName()
if (typeof _courseId == "object") {
@ -78,6 +78,19 @@ export function RouteHOC(options = {}) {
window.open(`/courses/${_courseId}/${secondName}/${_workId}/${_studentWorkId}/appraise`);
}
}
toWorkDetailPage2 = (e, _courseId, _workId, _studentWorkId) => {
console.log("鼠标中键点击了")
console.log(_studentWorkId)
const secondName = this.getModuleName()
if (typeof _courseId == "object") {
const workId = _courseId.workId
const courseId = _courseId.coursesId
const studentWorkId = _courseId.studentWorkId
window.open(`/courses/${courseId}/${secondName}/${_workId || workId}/${_studentWorkId || studentWorkId}/appraise`);
} else {
window.open(`/courses/${_courseId}/${secondName}/${_workId}/${_studentWorkId}/appraise`);
}
}
toNewPage = (courseId) => {
const secondName = this.getModuleName()
this.props.history.push(`/courses/${courseId.coursesId}/${secondName}/${courseId.category_id}/new`)
@ -125,8 +138,8 @@ export function RouteHOC(options = {}) {
this.props.history.push(`/courses/${_courseId}/${secondName}/${_workId}/answer`)
}
}
toWorkQuestionPage = (_courseId, _workId) => {
toWorkQuestionPage = (_courseId, _workId) => {
const secondName = this.getModuleName()
if (typeof _courseId == "object") {
const workId = _workId || _courseId.workId
@ -148,37 +161,36 @@ export function RouteHOC(options = {}) {
}
}
render() {
render() {
const { snackbarOpen} = this.state;
return (
<React.Fragment>
<WrappedComponent {...this.props}
toDetailPage={this.toDetailPage}
toEditPage={this.toEditPage}
toNewPage={this.toNewPage}
toListPage={this.toListPage}
toWorkDetailPage={this.toWorkDetailPage}
toWorkPostPage={this.toWorkPostPage}
toWorkListPage={this.toWorkListPage}
toWorkAnswerPage={this.toWorkAnswerPage}
toWorkQuestionPage={this.toWorkQuestionPage}
toWorkSettingPage={this.toWorkSettingPage}
toCreateProject={this.toCreateProject}
isGroup={this.isGroup}
getModuleName={this.getModuleName}
getModuleType={this.getModuleType}
<WrappedComponent {...this.props}
toDetailPage={this.toDetailPage}
toEditPage={this.toEditPage}
toNewPage={this.toNewPage}
toListPage={this.toListPage}
toWorkDetailPage={this.toWorkDetailPage}
toWorkDetailPage2={this.toWorkDetailPage2}
toWorkPostPage={this.toWorkPostPage}
toWorkListPage={this.toWorkListPage}
toWorkAnswerPage={this.toWorkAnswerPage}
toWorkQuestionPage={this.toWorkQuestionPage}
toWorkSettingPage={this.toWorkSettingPage}
toCreateProject={this.toCreateProject}
isGroup={this.isGroup}
getModuleName={this.getModuleName}
getModuleType={this.getModuleType}
>
</WrappedComponent>
</WrappedComponent>
</React.Fragment>
)
}
}
}
}
}

@ -458,6 +458,7 @@ class Listofworksstudentone extends Component {
:
<a style={{textAlign: "center"}}
className="color-blue"
onMouseDown={(e) => this.Viewstudenttraininginformationtysl2(e, record)}
onClick={() => this.Viewstudenttraininginformation(record)}>{record.operating}</a>
}
@ -810,6 +811,7 @@ class Listofworksstudentone extends Component {
:
<a style={{textAlign: "center"}}
className="color-blue"
onMouseDown={(e) => this.Viewstudenttraininginformationtysl2(e, record)}
onClick={() => this.Viewstudenttraininginformation(record)}>{record.operating}</a>
}
@ -1175,6 +1177,7 @@ class Listofworksstudentone extends Component {
record.submitstate === "未提交" ? <span style={{color: '#9A9A9A'}}>--</span> :
<span>
<a style={{textAlign: "center"}} className="color-blue"
onMouseDown={(e) => this.Viewstudenttraininginformationtysl2(e, record)}
onClick={() => this.Viewstudenttraininginformationt(record)}>查看</a>
</span>
)
@ -1505,6 +1508,7 @@ class Listofworksstudentone extends Component {
record.submitstate === "未提交" ? <span style={{color: '#9A9A9A'}}>--</span> :
<span>
<a style={{textAlign: "center"}} className="color-blue"
onMouseDown={(e) => this.Viewstudenttraininginformationtysl2(e, record)}
onClick={() => this.Viewstudenttraininginformationt(record)}>{record.operating}</a>
</span>
)
@ -2779,7 +2783,16 @@ class Listofworksstudentone extends Component {
}
// 调分
Viewstudenttraininginformationtysl2 = (e, data) => {
// console.log("Viewstudenttraininginformationtysl2");
// console.log("shubiao zhongjian ");
// console.log(e);
this.setState({
userids: data.myid,
})
// this.viewtrainingt(e.myid);
window.open(`/courses/${this.state.props.match.params.coursesId}/shixun_homeworks/${data.myid}/shixun_work_report`, '_blank');
}
// 查看学员实训信息
Viewstudenttraininginformationt = (e) => {
// console.log("Viewstudenttraininginformation");

@ -147,7 +147,9 @@ class ShixunsHome extends Component {
nextArrow={<CustomNextArrow />}
prevArrow={<CustomPrevArrow />}
autoplay
autoplaySpeed={4500}
animation={false}
pauseOnHover={true}
style={{width:"100%"}}
arrowPos="outer">
{homedatalist.images_url.map((item, index) => (

@ -1,3 +1,131 @@
state说明
tasks详情接口
allowed_unlock 为true时才允许非管理员用户解锁隐藏测试集
discusses_count 总评论数
challenge 实训关卡信息
exec_time --
modify_time --
path 关卡文件路径
position 第几关
praises_count 点赞数
score 分数
shixun_id
st 0-编程题 1-选择题
subject 关卡名称
task_pass 过关任务
web_route --
game 为每一个用户独立创建的实训关卡对应的信息
accuracy --
answer_deduction--
answer_open --
challenge_id
cost_time 通关耗时
created_at
end_time
evaluate_count
final_score
id
identifier
modify_time
myshixun_id
open_time
picture_path
resubmit_identifier
retry_status
star
status 2-已通关
test_sets_view true-测试集已解锁
updated_at
user_id
game_count 关卡数
git_url 仓库地址vnc会用到
has_answer
is_teacher 是否是老师 初始化被赋值到 user.is_teacher
last_compile_output
mirror_name 镜像名称 TPIMonaco会用到这个属性来判断当前关卡使用的什么语言 见 mirror2LanguageMap
myshixun
commit_id: "80cb6fc55a14bdd64a9c99913f416966238ed3de"
created_at: "2019-07-26T09:00:31.000+08:00"
git_url: null
gpid: null
id: 542543
identifier: "ns53g8vfeo" 有些接口会用到
is_public: true
modify_time: "2017-11-02T18:12:23.000+08:00"
onclick_time: "2019-07-26T09:00:31.000+08:00"
repo_name: "p15478209/ns53g8vfeo20190726090031"
reset_time: "2017-10-25T09:33:03.000+08:00"
shixun_id: 61
status: 0
system_tip: true (如果修改了测试集 || 修改了代码) && system_tip为true 也就是下面代码为true时才显示更新通知弹框
const showUpdateButton = (tpm_cases_modified || needUpdateScript) && myshixun.system_tip === true;
updated_at: "2019-11-05T10:58:35.000+08:00"
user_id: 24731
myshixun_manager: true
next_game: "so7ijzqe63a9" 下一关identifier
praise_count: 120 点赞数
prev_game: "bxg5w9uonhts" 上一关identifier
record_onsume_time: 0.296 上一次评测耗时 初始化被赋值到newResData.record = newResData.record_onsume_time
sets_error_count: 0 失败测试集数量
shixun
authentication: false
averge_star: 4.9
can_copy: false
challenges_count: 4 关卡数
closer_id: null
code_edit_permission: false 是否允许修改代码
code_hidden: false 是否隐藏文件目录按钮
created_at: "2017-06-09T11:32:16.000+08:00"
end_time: null
excute_time: null
exec_time: 25
forbid_copy: false forbid_copy ? "不允许学员复制和粘贴代码" : "允许学员复制和粘贴代码"
fork_from: null
git_url: "educoder/uznmbg54"
gpid: 2448
hidden: false
hide_code: false 是否隐藏代码tab
homepage_show: true
id: 61
identifier: "uznmbg54"
image_text: null
language: "Python3.6" !!
major_id: 635
mirror_script_id: null
modify_time: "2017-11-02T18:12:23.000+08:00"
multi_webssh: false 多命令行tab
myshixuns_count: 9655 学员数
name: "Python表达式问题求解※"
opening_time: null
pod_life: 0
publish_time: "2017-09-01T10:37:49.000+08:00"
repo_name: "educoder/uznmbg54"
reset_time: "2017-10-25T09:33:03.000+08:00"
sigle_training: false
status: 2 shixun.status >= 2 实训已发布 shixun.status <= 1 模拟实战
task_pass: task_pass ? "允许学员跳关挑战" : "不允许学员跳关挑战"
test_set_permission: true test_set_permission ? "允许学员通过金币解锁查看测试集内容" : "不允许学员通过金币解锁查看测试集内容"
trainee: 1
updated_at: "2019-10-11T08:50:59.000+08:00"
use_scope: 0
user_id: 3039
users_count: 4
visits: 69699
webssh: 1 是否显示命令行tab
st 0-编程题 1-选择题
test_sets 测试集
test_sets_count: 1
time_limit: 25 game_status.json轮训次数
tomcat_url: "http://47.96.157.89" web类型实训可以打开展现一个测试服务用来查看评测结果 const webDisplayUrl = `${tomcat_url}:${data.port}/${path}`
tpm_cases_modified: false 参考system_tip属性
tpm_modified: true 参考system_tip属性
user 当前关卡所属用户的信息
user_praise 当前用户是否点赞
-------------- -------------- -------------- -------------- -------------- -------------- -------------- -------------- --------------
TPIContextProvider
tpi主要的state容器主要接口`/tasks/${stageId}.json`一次性获取所有tpi首屏展示所需要的信息除了代码内容。
接口返回的内容包括
@ -54,4 +182,21 @@ TPIContextProvider
没用的文件
LeftNav.js
AnswerListContainer.js left 他人解答
AnswerListContainer.js left 他人解答
TPI SSH
命令行的js资源都位于这个目录/react/public/js/jsFromMiddleLayer/base64.js
/page/main/CodeRepositoryView.js文件中open_webssh.json接口返回后会根据代码区试图大小计算ssh视图的大小同样的逻辑在js_min_all中也有
var h = $("#games_repository_contents").height() - $("#top_repository").height() - repositoryTabHeight;
这里有个对应的issue https://www.trustie.net/issues/25279
这里是要判断特殊的屏幕(公司dell笔记本可重现),针对这些情况处理,加高命令行的高度
ps js_min_all中搜`$("#games_repository_contents").height()`可以找到相关代码
VNCDisplay
使用的github上的代码 https://github.com/novnc/noVNC/

@ -0,0 +1,169 @@
import React, {Component} from 'react';
import {Button, Layout, Input, Form} from 'antd';
import axios from 'axios';
import {getImageUrl} from 'educoder';
class Modifytext extends Component {
constructor(props) {
super(props)
this.state = {}
}
componentDidMount() {
}
//重新输入教学模式
Modifytext = () => {
this.props.form.validateFieldsAndScroll((err, values) => {
if (!err) {
const url = `/paths/${this.props.pathid}/update_team_title.json`;
axios.post(url, {
team_title: values.teachingteam
}).then((response) => {
console.log(response);
if (response) {
if (response.data) {
if (response.data.status === 0) {
try {
this.props.showNotification("修改成功!");
} catch (e) {
}
try {
this.props.modifysy(2);
} catch (e) {
}
}
}
}
}).catch((error) => {
console.log(error)
})
}
})
}
render() {
const {getFieldDecorator} = this.props.form;
return (
<div>
<div className="ml38">
<style>{`
.flexRow {
padding: 20px 0;
}
.flexRow .name {
margin-left: 12px;
color: #666666;
text-align: center;
flex: 0 0 100px;
}
.flexRow .description {
margin-left: 10px;
flex: 1;
color: #CDCDCD;
}
.description span {
margin-right: 20px;
color: #05101A;
}
.flexRow .status {
width: 100px;
color: #28AC7F;
text-align: right;
}
.flexTable .flexTable {
border-bottom: 1px solid #EBEBEB;
}
.settingFormsy label{
color: #666666;
font-size: 14px !important ;
}
.settingFormsy input {
width: 275px;
height: 32px;
}
.settingFormsy input.validateInput {
width: 220px;
}
.settingFormsy .formItemInline button {
width: 110px;
margin-left: 10px;
}
.settingFormsy .ant-form-item-label {
width: 60px;
text-align: left;
}
.formItemInline .ant-form-explain{
position:absolute;
bottom:-22px;
left:0px;
width:100%;
}
.yslzxueshi .ant-input{
height: 40px !important;
width: 276px !important
}
// class="ant-col ant-form-item-label"
`}</style>
<div className="settingFormsy">
<React.Fragment>
<Form>
<div style={{
display: "flex",
flexDirection: "initial",
lineHeight: " 51px",
}}>
<Form.Item
label=""
className="formItemInline hideRequireTag mb20 mt20"
>
{getFieldDecorator('teachingteam', {
rules: [{
// initialValue: this.state.cityDefaultValue,
required: true,
message: '请输入模式',
}],
})(
<Input placeholder={`例如:教学团队`}></Input>
)}
</Form.Item>
<div className="flexdirections yslzxueshi ml38 ">
<p className="fontcolorsyslhui1 font-14 myysllineheight myyslminwidth"></p>
<div className=" flexdirections ml10">
{/*<div className="buttongo mycompitcursor" onClick={()=>this.yhBanksfalse()}><p className="fontwenzi mycompitcursor" >取消</p></div>*/}
<Button type="primary" onClick={() => this.Modifytext()}>确定</Button>
</div>
</div>
</div>
</Form>
</React.Fragment>
</div>
</div>
</div>
)
}
}
const Modifytexts = Form.create({name: 'Modifytext'})(Modifytext);
export default Modifytexts;

@ -12,7 +12,7 @@ import Modals from '../../modals/Modals';
import axios from 'axios';
import TPMRightSection from "../../tpm/component/TPMRightSection";
import styled from "styled-components";
import Modifytext from './Modifytext';
const getItemStyle = (isDragging, draggableStyle) => ({
// change background colour if dragging
background: isDragging ? '#dceeff' : '',
@ -87,7 +87,9 @@ class PathDetailIndex extends Component{
dataquerys:{},
MenuItemsindex:1,
MenuItemsindextype:0,
qrcode_img:null
qrcode_img: null,
team_title: "教学团队",
modify: false,
}
this.onDragEnd = this.onDragEnd.bind(this);
@ -256,6 +258,7 @@ class PathDetailIndex extends Component{
progress:result.data.progress,
members:result.data.members,
items: getItems(result.data.members.length),
team_title: result.data.team_title
})
}).catch((error)=>{
@ -321,6 +324,7 @@ class PathDetailIndex extends Component{
progress:result.data.progress,
members:result.data.members,
items: getItems(result.data.members.length),
team_title: result.data.team_title
})
}).catch((error)=>{
@ -458,6 +462,50 @@ class PathDetailIndex extends Component{
console.log(error)
})
}
modifysy = (i) => {
if (i === 1) {
this.setState({
modify: true
})
} else if (i === 2) {
this.setState({
modify: false
})
let righturl = "/paths/" + this.props.match.params.pathId + "/right_banner.json";
axios.get(righturl).then((result) => {
if (result.data.status === 407 || result.data.status === 401) {
debugger
return;
}
if (result.data.status === 403) {
debugger
// window.location.href = "/403";
return;
}
this.setState({
// detailInfoList:result.data,
tags: result.data.tags,
progress: result.data.progress,
members: result.data.members,
items: getItems(result.data.members.length),
team_title: result.data.team_title
})
}).catch((error) => {
console.log(error);
})
}
}
setteam_title(name) {
this.setState({
team_title: name
})
}
render(){
this.updatamakedown("shixuns_propaedeutics");
@ -475,7 +523,9 @@ class PathDetailIndex extends Component{
tags,
qrcode_img,
MenuItemsindex,
MenuItemsindextype
MenuItemsindextype,
team_title,
modify
} = this.state
@ -613,7 +663,19 @@ class PathDetailIndex extends Component{
{
members ===undefined ?"":members === null ?"":
<div className="teacherTeam edu-back-white clearfix" id="subject_members">
<p className="font-16 clearfix">教学团队</p>
{
detailInfoList === undefined ? "" : detailInfoList.allow_add_member === true ?
(
modify === false ?
<p className="font-16 clearfix" onDoubleClick={() => this.modifysy(1)}>{team_title}</p>
:
<Modifytext {...this.props} {...this.state} pathid={this.props.match.params.pathId}
modifysy={(i) => this.modifysy(i)}
setteam_title={(name) => this.setteam_title(name)}></Modifytext>
)
: ""
}
{ members===undefined?
members && members.map((item,key)=>{
@ -712,4 +774,4 @@ class PathDetailIndex extends Component{
)
}
}
export default PathDetailIndex;
export default PathDetailIndex;

@ -280,7 +280,7 @@ class Infos extends Component{
}
></Route>
{/* 实训 */}
{/* 实训项目 */}
<Route exact path="/users/:username/shixuns"
render={
(props) => (<InfosShixun {...this.props} {...props} {...this.state} {..._commonProps}/>)
@ -294,7 +294,7 @@ class Infos extends Component{
}
></Route>
{/* 项目 */}
{/* 开发项目 */}
<Route exact path="/users/:username/projects"
render={
(props) => (<InfosProject {...this.props} {...props} {...this.state} {..._commonProps}/>)

@ -71,8 +71,8 @@ class InfosCourse extends Component{
page:1,
isSpin:true
})
let{status}=this.state;
this.getCourses(cate,status,1);
let {status, sort_by, sort_direction} = this.state;
this.getCourses(cate, status, 1, sort_by, sort_direction);
}
//切换状态
changeStatus=(status)=>{
@ -81,8 +81,8 @@ class InfosCourse extends Component{
page:1,
isSpin:true
})
let{category}=this.state;
this.getCourses(category,status,1);
let {category, sort_by, sort_direction} = this.state;
this.getCourses(category, status, 1, sort_by, sort_direction);
}
//切换页数
changePage=(page)=>{
@ -90,8 +90,8 @@ class InfosCourse extends Component{
page,
isSpin:true
})
let{category,status}=this.state;
this.getCourses(category,status,page);
let {category, status, sort_by, sort_direction} = this.state;
this.getCourses(category, status, page, sort_by, sort_direction);
}
// 进入课堂
@ -110,7 +110,7 @@ class InfosCourse extends Component{
this.getCourses(category, status, 1, sort_by, "desc");
}
updatedlists(sort_direction, i) {
updatedlists(sort_directions, i) {
// console.log("updatedlistssort_direction");
// console.log(sort_direction);
// console.log(i);
@ -118,8 +118,20 @@ class InfosCourse extends Component{
this.setState({
isSpin: true
});
let {category, status, page, sort_by} = this.state;
this.getCourses(category, status, page, sort_by, sort_direction);
let {category, status, page, sort_by, sort_direction} = this.state;
let sort_directiony = sort_directions;
if (sort_directions === "asc") {
if (sort_directions === sort_direction) {
sort_directiony = "desc"
}
} else if (sort_directions === "desc") {
if (sort_directions === sort_direction) {
sort_directiony = "asc"
}
}
this.getCourses(category, status, page, sort_by, sort_directiony);
}
render(){
@ -147,21 +159,87 @@ class InfosCourse extends Component{
</Menu>
);
console.log("InfosCourse");
console.log(status);
return(
<div className="educontent">
<Spin size="large" spinning={isSpin}>
<style>
{
`
.whitepanelyslli {
width: 32px !important;
height: 48px !important;
line-height: 46px !important;
}
.whitepanelyslliss {
width: 32px !important;
height: 48px !important;
line-height: 46px !important;
}
.whitepanelysllis {
width: 66px !important;
height: 48px !important;
line-height: 46px !important;
margin-left: 40px !important;
}
.whitepanelysllisyt {
width: 60px !important;
height: 48px !important;
line-height: 46px !important;
margin-left: 40px !important;
}
.white-panel li.active {
border-radius: 24px;
border: 0px solid #4CACFF;
color: #4CACFF;
}
`
}
</style>
<div className="white-panel edu-back-white pt20 pb20 clearfix ">
<li className={category ? "" : "active"}><a href="javascript:void(0)" onClick={()=>this.changeCategory()}>全部</a></li>
<li className={category=="manage" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeCategory("manage")}>{is_current ? "我":"TA"}管理的</a></li>
<li className={category=="study" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeCategory("study")}>{is_current ? "我":"TA"}学习的</a></li>
<li className={category ? " font-16 whitepanelyslli" : "active font-16 whitepanelyslli"}><a
href="javascript:void(0)" onClick={() => this.changeCategory()} className="font-16 w32">全部</a></li>
<li className={category == "manage" ? "active font-16 whitepanelysllis" : "font-16 whitepanelysllis"}><a
href="javascript:void(0)" onClick={() => this.changeCategory("manage")}
className="font-16 w66">{is_current ? "我" : "TA"}管理的</a></li>
<li className={category == "study" ? "active font-16 whitepanelysllis" : "font-16 whitepanelysllis"}><a
href="javascript:void(0)" onClick={() => this.changeCategory("study")}
className="font-16 w66">{is_current ? "我" : "TA"}学习的</a></li>
</div>
<style>
{
` .secondNavs li {
color: #676767;
/* margin: 0px 20px; */
float: left;
}
.secondNavs li a:hover{
color: #4CACFF
}
.secondNavs li.active a{
color: #4CACFF
}
`
}
</style>
{
is_current &&
<div className="edu-back-white padding20-30 clearfix secondNav bor-top-greyE">
<li className={status ? "" : "active"}><a href="javascript:void(0)" onClick={()=>this.changeStatus()}>全部</a></li>
<li className={status=="processing" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeStatus("processing")}>正在进行</a></li>
<li className={status=="end" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeStatus("end")}>已结束</a></li>
<div className="edu-back-white padding20-30 clearfix secondNavs bor-top-greyE">
<li className={status ? "whitepanelyslliss" : "active whitepanelyslliss"}><a href="javascript:void(0)"
onClick={() => this.changeStatus()}
className="w32">全部</a></li>
<li className={status == "processing" ? "active whitepanelysllis" : "whitepanelysllis"}><a
href="javascript:void(0)" onClick={() => this.changeStatus("processing")} className="w66">正在进行</a></li>
<li className={status == "end" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
href="javascript:void(0)" onClick={() => this.changeStatus("end")} className="w66">已结束</a></li>
</div>
}
<p className="pl25 pr25 clearfix font-12 " style={{

@ -168,23 +168,82 @@ class InfosPackage extends Component{
modalSave={this.state.ModalSave}
/>
<Spin size="large" spinning={isSpin}>
<style>
{
`
.whitepanelyslli {
width: 32px !important;
height: 48px !important;
line-height: 46px !important;
}
.whitepanelyslliss {
width: 32px !important;
height: 48px !important;
line-height: 46px !important;
}
.whitepanelysllis {
width: 66px !important;
height: 48px !important;
line-height: 46px !important;
margin-left: 40px !important;
}
.white-panel li.active {
border-radius: 24px;
border: 0px solid #4CACFF;
color: #4CACFF;
}
`
}
</style>
<div className="white-panel edu-back-white pt20 pb20 clearfix ">
<li className={category ? "" : "active"}><a onClick={()=>this.changeCategory()}>全部</a></li>
<li className={category=="manage" ? "active" : ""}><a onClick={()=>this.changeCategory("manage")}>{is_current ? "我":"TA"}管理的</a></li>
<li className={category=="bidden" ? "active" : ""}><a onClick={()=>this.changeCategory("bidden")}>{is_current ? "我":"TA"}参与的</a></li>
<li className={category ? " font-16 whitepanelyslli" : "active font-16 whitepanelyslli"}><a
href="javascript:void(0)" onClick={() => this.changeCategory()} className="font-16 w32">全部</a></li>
<li className={category == "manage" ? "active font-16 whitepanelysllis" : "font-16 whitepanelysllis"}><a
href="javascript:void(0)" onClick={() => this.changeCategory("manage")}
className="font-16 w66">{is_current ? "我" : "TA"}管理的</a></li>
<li className={category == "study" ? "active font-16 whitepanelysllis" : "font-16 whitepanelysllis"}><a
href="javascript:void(0)" onClick={() => this.changeCategory("study")}
className="font-16 w66">{is_current ? "我" : "TA"}学习的</a></li>
</div>
<style>
{
` .secondNavs li {
color: #676767;
/* margin: 0px 20px; */
float: left;
}
.secondNavs li a:hover{
color: #4CACFF
}
.secondNavs li.active a{
color: #4CACFF
}
`
}
</style>
{
category=="manage"?
<div className="edu-back-white padding20-30 clearfix secondNav bor-top-greyE">
<li className={status ? "" : "active"}><a onClick={()=>this.changeStatus()}>全部</a></li>
<li className={status=="unpublished" ? "active" : ""}><a onClick={()=>this.changeStatus("unpublished")}>未发布</a></li>
<li className={status=="bidding" ? "active" : ""}><a onClick={()=>this.changeStatus("bidding")}>竞标中</a></li>
<li className={status=="finished" ? "active" : ""}><a onClick={()=>this.changeStatus("finished")}>已完成</a></li>
<div className="edu-back-white padding20-30 clearfix secondNavs bor-top-greyE">
<li className={status ? "whitepanelyslliss" : "active whitepanelyslliss"}><a
onClick={() => this.changeStatus()} className="w32">全部</a></li>
<li className={status == "unpublished " ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
onClick={() => this.changeStatus("unpublished")} className="w60">未发布</a></li>
<li className={status == "bidding" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
onClick={() => this.changeStatus("bidding")} className="w60">竞标中</a></li>
<li className={status == "finished" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
onClick={() => this.changeStatus("finished")} className="w60">已完成</a></li>
</div>: category=="bidden"?
<div className="edu-back-white padding20-30 clearfix secondNav bor-top-greyE">
<li className={status ? "" : "active"}><a onClick={()=>this.changeStatus()}>全部</a></li>
<li className={status=="bidding_lost" ? "active" : ""}><a onClick={()=>this.changeStatus("bidding_lost")}>未中标</a></li>
<li className={status=="bidding_won" ? "active" : ""}><a onClick={()=>this.changeStatus("bidding_won")}>已中标</a></li>
<div className="edu-back-white padding20-30 clearfix secondNavs bor-top-greyE">
<li className={status ? "whitepanelyslliss" : "active whitepanelyslliss"}><a
onClick={() => this.changeStatus()} className="w32">全部</a></li>
<li className={status == "bidding_lost" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
onClick={() => this.changeStatus("bidding_lost")} className="w60">未中标</a></li>
<li className={status == "bidding_won" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
onClick={() => this.changeStatus("bidding_won")} className="w60">已中标</a></li>
</div>:""
}
<p className="pl25 pr25 clearfix font-12 mb20 mt20">
@ -289,4 +348,4 @@ class InfosPackage extends Component{
)
}
}
export default InfosPackage;
export default InfosPackage;

@ -123,13 +123,24 @@ class InfosPath extends Component{
}
//排序
updatedlists(sort_direction) {
updatedlists(sort_directions) {
//是否是倒序
this.setState({
isSpin: true
});
let {category, status, page, sort_by} = this.state;
this.getCourses(category, status, sort_by, page, sort_direction);
let {category, status, page, sort_by, sort_direction} = this.state;
let sort_directiony = sort_directions;
if (sort_directions === "asc") {
if (sort_directions === sort_direction) {
sort_directiony = "desc"
}
} else if (sort_directions === "desc") {
if (sort_directions === sort_direction) {
sort_directiony = "asc"
}
}
this.getCourses(category, status, sort_by, page, sort_directiony);
}
@ -160,26 +171,97 @@ class InfosPath extends Component{
return(
<div className="educontent">
<Spin size="large" spinning={isSpin}>
<div className="white-panel edu-back-white pt20 pb20 clearfix ">
<li className={category ? "" : "active"}><a href="javascript:void(0)" onClick={()=>this.changeCategory()}>全部</a></li>
<li className={category=="manage" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeCategory("manage")}>{is_current ? "我":"TA"}管理的</a></li>
<li className={category=="study" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeCategory("study")}>{is_current ? "我":"TA"}学习的</a></li>
</div>
<style>
{
`
.whitepanelyslli {
width: 32px !important;
height: 48px !important;
line-height: 46px !important;
}
.whitepanelyslliss {
width: 32px !important;
height: 48px !important;
line-height: 46px !important;
}
.whitepanelysllis {
width: 66px !important;
height: 48px !important;
line-height: 46px !important;
margin-left: 40px !important;
}
.whitepanelysllisyt {
width: 60px !important;
height: 48px !important;
line-height: 46px !important;
margin-left: 40px !important;
}
.white-panel li.active {
border-radius: 24px;
border: 0px solid #4CACFF;
color: #4CACFF;
}
`
}
</style>
<div className="white-panel edu-back-white pt20 pb20 clearfix ">
<li className={category ? " font-16 whitepanelyslli" : "active font-16 whitepanelyslli"}><a
href="javascript:void(0)" onClick={() => this.changeCategory()} className="font-16 w32">全部</a></li>
<li className={category == "manage" ? "active font-16 whitepanelysllis" : "font-16 whitepanelysllis"}><a
href="javascript:void(0)" onClick={() => this.changeCategory("manage")}
className="font-16 w66">{is_current ? "我" : "TA"}管理的</a></li>
<li className={category == "study" ? "active font-16 whitepanelysllis" : "font-16 whitepanelysllis"}><a
href="javascript:void(0)" onClick={() => this.changeCategory("study")}
className="font-16 w66">{is_current ? "我" : "TA"}学习的</a></li>
</div>
<style>
{
` .secondNavs li {
color: #676767;
/* margin: 0px 20px; */
float: left;
}
.secondNavs li a:hover{
color: #4CACFF
}
.secondNavs li.active a{
color: #4CACFF
}
`
}
</style>
{
category && category == "manage" && is_current &&
<div className="edu-back-white padding20-30 clearfix secondNav bor-top-greyE">
<li className={status ? "" : "active"}><a href="javascript:void(0)" onClick={()=>this.changeStatus()}>全部</a></li>
<li className={status=="editing" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeStatus("editing")}>编辑中</a></li>
<li className={status=="applying" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeStatus("applying")}>待审核</a></li>
<li className={status=="published" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeStatus("published")}>已发布</a></li>
<div className="edu-back-white padding20-30 clearfix secondNavs bor-top-greyE">
<li className={status ? "whitepanelyslliss" : "active whitepanelyslliss"}><a href="javascript:void(0)"
onClick={() => this.changeStatus()}
className="w32">全部</a></li>
<li className={status == "editing" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
href="javascript:void(0)" onClick={() => this.changeStatus("editing")} className="w60">编辑中</a></li>
<li className={status == "applying" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
href="javascript:void(0)" onClick={() => this.changeStatus("applying")} className="w60">待审核</a></li>
<li className={status == "published" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
href="javascript:void(0)" onClick={() => this.changeStatus("published")} className="w60">已发布</a></li>
</div>
}
{
category && category == "study" && is_current &&
<div className="edu-back-white padding20-30 clearfix secondNav bor-top-greyE">
<li className={status ? "" : "active"}><a href="javascript:void(0)" onClick={()=>this.changeStatus()}>全部</a></li>
<li className={status=="unfinished" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeStatus("unfinished")}>未完成</a></li>
<li className={status=="finished" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeStatus("finished")}>已完成</a></li>
<div className="edu-back-white padding20-30 clearfix secondNavs bor-top-greyE">
<li className={status ? "whitepanelyslliss" : "active whitepanelyslliss"}><a href="javascript:void(0)"
onClick={() => this.changeStatus()}
className="w32">全部</a></li>
<li className={status == "unfinished" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
href="javascript:void(0)" onClick={() => this.changeStatus("unfinished")} className="w60">未完成</a></li>
<li className={status == "finished" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
href="javascript:void(0)" onClick={() => this.changeStatus("finished")} className="w60">已完成</a></li>
</div>
}
<div className="pl25 pr25 clearfix font-12 " style={{

@ -125,13 +125,23 @@ class InfosProject extends Component{
}
//排序
updatedlists(sort_direction) {
updatedlists(sort_directions) {
//是否是倒序
this.setState({
isSpin: true
});
let {category, status, page, sort_by} = this.state;
this.getCourses(category, status, page, sort_by, sort_direction);
let {category, status, page, sort_by, sort_direction} = this.state;
let sort_directiony = sort_directions;
if (sort_directions === "asc") {
if (sort_directions === sort_direction) {
sort_directiony = "desc"
}
} else if (sort_directions === "desc") {
if (sort_directions === sort_direction) {
sort_directiony = "asc"
}
}
this.getCourses(category, status, page, sort_by, sort_directiony);
}
render(){
@ -162,17 +172,82 @@ class InfosProject extends Component{
return(
<div className="educontent">
<Spin size="large" spinning={isSpin}>
<div className="white-panel edu-back-white pt20 pb20 clearfix ">
<li className={category ? "" : "active"}><a href="javascript:void(0)" onClick={()=>this.changeCategory()}>全部</a></li>
<li className={category=="manage" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeCategory("manage")}>{is_current ? "我":"TA"}管理的</a></li>
<li className={category=="study" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeCategory("study")}>{is_current ? "我":"TA"}学习的</a></li>
</div>
<style>
{
`
.whitepanelyslli {
width: 32px !important;
height: 48px !important;
line-height: 46px !important;
}
.whitepanelyslliss {
width: 32px !important;
height: 48px !important;
line-height: 46px !important;
}
.whitepanelysllis {
width: 66px !important;
height: 48px !important;
line-height: 46px !important;
margin-left: 40px !important;
}
.whitepanelysllisyt {
width: 60px !important;
height: 48px !important;
line-height: 46px !important;
margin-left: 40px !important;
}
.white-panel li.active {
border-radius: 24px;
border: 0px solid #4CACFF;
color: #4CACFF;
}
`
}
</style>
<div className="white-panel edu-back-white pt20 pb20 clearfix ">
<li className={category ? " font-16 whitepanelyslli" : "active font-16 whitepanelyslli"}><a
href="javascript:void(0)" onClick={() => this.changeCategory()} className="font-16 w32">全部</a></li>
<li className={category == "manage" ? "active font-16 whitepanelysllis" : "font-16 whitepanelysllis"}><a
href="javascript:void(0)" onClick={() => this.changeCategory("manage")}
className="font-16 w66">{is_current ? "我" : "TA"}管理的</a></li>
<li className={category == "study" ? "active font-16 whitepanelysllis" : "font-16 whitepanelysllis"}><a
href="javascript:void(0)" onClick={() => this.changeCategory("study")}
className="font-16 w66">{is_current ? "我" : "TA"}学习的</a></li>
</div>
<style>
{
` .secondNavs li {
color: #676767;
/* margin: 0px 20px; */
float: left;
}
.secondNavs li a:hover{
color: #4CACFF
}
.secondNavs li.active a{
color: #4CACFF
}
`
}
</style>
{
is_current &&
<div className="edu-back-white padding20-30 clearfix secondNav bor-top-greyE">
<li className={status ? "" : "active"}><a href="javascript:void(0)" onClick={()=>this.changeStatus()}>全部</a></li>
<li className={status=="publicly" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeStatus("publicly")}>公开</a></li>
<li className={status=="personal" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeStatus("personal")}>私有</a></li>
<div className="edu-back-white padding20-30 clearfix secondNavs bor-top-greyE">
<li className={status ? "whitepanelyslliss" : "active whitepanelyslliss"}><a href="javascript:void(0)"
onClick={() => this.changeStatus()}
className=" w32">全部</a></li>
<li className={status == "publicly" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
href="javascript:void(0)" onClick={() => this.changeStatus("publicly")} className=" w60">公开</a></li>
<li className={status == "personal" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
href="javascript:void(0)" onClick={() => this.changeStatus("personal")} className=" w60">私有</a></li>
</div>
}
<p className="pl25 pr25 clearfix font-12 " style={{

@ -45,6 +45,7 @@ class InfosShixun extends Component{
status,
sort_by,
page,
sort_direction,
per_page:this.props.is_current && category && page ==1?17:16
}}).then((result)=>{
if(result){
@ -124,13 +125,24 @@ class InfosShixun extends Component{
}
//排序
updatedlists(sort_direction) {
updatedlists(sort_directions) {
//是否是倒序
this.setState({
isSpin: true
});
let {category, status, page, sort_by} = this.state;
this.getCourses(category, status, sort_by, page, sort_direction);
let {category, status, page, sort_by, sort_direction} = this.state;
let sort_directiony = sort_directions;
if (sort_directions === "asc") {
if (sort_directions === sort_direction) {
sort_directiony = "desc"
}
} else if (sort_directions === "desc") {
if (sort_directions === sort_direction) {
sort_directiony = "asc"
}
}
this.getCourses(category, status, sort_by, page, sort_directiony);
}
render(){
@ -160,27 +172,99 @@ class InfosShixun extends Component{
return(
<div className="educontent">
<Spin size="large" spinning={isSpin}>
<div className="white-panel edu-back-white pt20 pb20 clearfix ">
<li className={category ? "" : "active"}><a href="javascript:void(0)" onClick={()=>this.changeCategory()}>全部</a></li>
<li className={category=="manage" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeCategory("manage")}>{is_current ? "我":"TA"}管理的</a></li>
<li className={category=="study" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeCategory("study")}>{is_current ? "我":"TA"}学习的</a></li>
</div>
<style>
{
`
.whitepanelyslli {
width: 32px !important;
height: 48px !important;
line-height: 46px !important;
}
.whitepanelyslliss {
width: 32px !important;
height: 48px !important;
line-height: 46px !important;
}
.whitepanelysllis {
width: 66px !important;
height: 48px !important;
line-height: 46px !important;
margin-left: 40px !important;
}
.whitepanelysllisyt {
width: 60px !important;
height: 48px !important;
line-height: 46px !important;
margin-left: 40px !important;
}
.white-panel li.active {
border-radius: 24px;
border: 0px solid #4CACFF;
color: #4CACFF;
}
`
}
</style>
<div className="white-panel edu-back-white pt20 pb20 clearfix ">
<li className={category ? " font-16 whitepanelyslli" : "active font-16 whitepanelyslli"}><a
href="javascript:void(0)" onClick={() => this.changeCategory()} className="font-16 w32">全部</a></li>
<li className={category == "manage" ? "active font-16 whitepanelysllis" : "font-16 whitepanelysllis"}><a
href="javascript:void(0)" onClick={() => this.changeCategory("manage")}
className="font-16 w66">{is_current ? "我" : "TA"}管理的</a></li>
<li className={category == "study" ? "active font-16 whitepanelysllis" : "font-16 whitepanelysllis"}><a
href="javascript:void(0)" onClick={() => this.changeCategory("study")}
className="font-16 w66">{is_current ? "我" : "TA"}学习的</a></li>
</div>
<style>
{
` .secondNavs li {
color: #676767;
/* margin: 0px 20px; */
float: left;
}
.secondNavs li a:hover{
color: #4CACFF
}
.secondNavs li.active a{
color: #4CACFF
}
`
}
</style>
{
category && category == "manage" && is_current &&
<div className="edu-back-white padding20-30 clearfix secondNav bor-top-greyE">
<li className={status ? "" : "active"}><a href="javascript:void(0)" onClick={()=>this.changeStatus()}>全部</a></li>
<li className={status=="editing" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeStatus("editing")}>编辑中</a></li>
<li className={status=="applying" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeStatus("applying")}>待审核</a></li>
<li className={status=="published" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeStatus("published")}>已发布</a></li>
<li className={status=="closed" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeStatus("closed")}>已关闭</a></li>
<div className="edu-back-white padding20-30 clearfix secondNavs bor-top-greyE">
<li className={status ? "whitepanelyslliss" : "active whitepanelyslliss"}><a href="javascript:void(0)"
onClick={() => this.changeStatus()}
className="w32">全部</a></li>
<li className={status == "editing" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
href="javascript:void(0)" onClick={() => this.changeStatus("editing")} className="w60">编辑中</a></li>
<li className={status == "applying" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
href="javascript:void(0)" onClick={() => this.changeStatus("applying")} className="w60">待审核</a></li>
<li className={status == "published" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
href="javascript:void(0)" onClick={() => this.changeStatus("published")} className="w60">已发布</a></li>
<li className={status == "closed" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
href="javascript:void(0)" onClick={() => this.changeStatus("closed")} className="w60">已关闭</a></li>
</div>
}
{
category && category == "study" && is_current &&
<div className="edu-back-white padding20-30 clearfix secondNav bor-top-greyE">
<li className={status ? "" : "active"}><a href="javascript:void(0)" onClick={()=>this.changeStatus()}>全部</a></li>
<li className={status=="processing" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeStatus("processing")}>未通关</a></li>
<li className={status=="passed" ? "active" : ""}><a href="javascript:void(0)" onClick={()=>this.changeStatus("passed")}>已通关</a></li>
<div className="edu-back-white padding20-30 clearfix secondNavs bor-top-greyE">
<li className={status ? "whitepanelyslliss" : "active whitepanelyslliss"}><a href="javascript:void(0)"
onClick={() => this.changeStatus()}
className="w32">全部</a></li>
<li className={status == "processing" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
href="javascript:void(0)" onClick={() => this.changeStatus("processing")} className="w60">未通关</a></li>
<li className={status == "passed" ? "active whitepanelysllisyt" : "whitepanelysllisyt"}><a
href="javascript:void(0)" onClick={() => this.changeStatus("passed")} className="w60">已通关</a></li>
</div>
}
<div className="pl25 pr25 clearfix font-12 " style={{

@ -5,12 +5,12 @@ import { getUrl2, isDev, ThemeContext } from 'educoder'
import axios from 'axios'
function InfoTab (props) {
function InfoTab(props) {
const theme = useContext(ThemeContext);
const { category, changeCategory, categories, right } = props;
const username = props.match.params.username
useEffect(() => {
}, [])
@ -19,7 +19,16 @@ function InfoTab (props) {
<div className="white-panel edu-back-white pt20 pb20 clearfix ">
{categories && categories.map(item => {
return (
<li key={item.key} className={category == item.key ? "active" : ''}><a href="javascript:void(0)" onClick={()=>changeCategory(item.key)}>{item.name}</a></li>
item.id === 1 ?
<li key={item.key}
className={category == item.key ? "active whitepanelysllisyt" : 'whitepanelysllisyt'}><a
href="javascript:void(0)" onClick={() => changeCategory(item.key)}
style={{width: "70px"}}>{item.name}</a></li>
:
<li key={item.key}
className={category == item.key ? "active whitepanelysllisyts" : 'whitepanelysllisyts'}><a
href="javascript:void(0)" onClick={() => changeCategory(item.key)}
style={{width: "80px"}}>{item.name}</a></li>
)
})}
{/* <li className={category ? "" : "active"}><a href="javascript:void(0)" onClick={()=>this.changeCategory()}></a></li>

@ -439,3 +439,15 @@
.h10 {
height: 10px;
}
.w32 {
width: 32px !important;
}
.w66 {
width: 66px !important;
}
.w60 {
width: 60px !important;
}

@ -193,10 +193,31 @@ function InfoVideo (props) {
}
// TODO use封装
function onSortChange(key, index) {
const _item = _items[index]
_items.splice(index, 1)
_items.unshift(_item)
setSortKey(key)
try {
const _item = _items[index];
_items.splice(index, 1);
_items.unshift(_item);
const keys = key.split('-');
const sorts = sortKey.split('-');
if (key === "published_at-desc") {
if (keys[1] === sorts[1]) {
setSortKey("published_at-asc")
} else {
setSortKey(key)
}
} else if (key === "published_at-asc") {
if (keys[1] === sorts[1]) {
setSortKey("published_at-desc")
} else {
setSortKey(key)
}
}
} catch (e) {
}
}
function getCopyText (file_url, cover_url) {
return `<video src="${file_url}" controls="true" controlslist="nodownload" width="${DEFAULT_VIDEO_WIDTH_IN_MD}" height="${DEFAULT_VIDEO_HEIGHT_IN_MD}" poster="${cover_url}">您的浏览器不支持 video 标签。</video>`
@ -259,6 +280,23 @@ function InfoVideo (props) {
.videoItem {
margin-right: 24px;
}
.white-panel li.active {
border-radius: 24px;
border: 0px solid #4CACFF;
color: #4CACFF;
}
.whitepanelysllisyt {
width: 70px !important;
height: 48px !important;
line-height: 46px !important;
}
.whitepanelysllisyts {
width: 80px !important;
height: 48px !important;
line-height: 46px !important;
margin-left: 30px;
}
`}</style>
@ -266,10 +304,12 @@ function InfoVideo (props) {
{...props}
categories={[{
key: 'all',
name: '全部视频'
name: '全部视频',
id: 1,
}, {
key: 'review',
name: '待审核视频'
name: '待审核视频',
id: 2
}]}
{...categoryObj}

@ -222,6 +222,12 @@
<div class="code-name">&amp;#xe693;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe6c0;</span>
<div class="name">关注</div>
<div class="code-name">&amp;#xe6c0;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe63c;</span>
<div class="name">礼物</div>
@ -324,6 +330,12 @@
<div class="code-name">&amp;#xe678;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe6c5;</span>
<div class="name">关注</div>
<div class="code-name">&amp;#xe6c5;</div>
</li>
<li class="dib">
<span class="icon iconfont">&#xe608;</span>
<div class="name">喇叭</div>
@ -1718,6 +1730,15 @@
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-weibiaoti105"></span>
<div class="name">
关注
</div>
<div class="code-name">.icon-weibiaoti105
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-gift"></span>
<div class="name">
@ -1871,6 +1892,15 @@
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-guanzhu"></span>
<div class="name">
关注
</div>
<div class="code-name">.icon-guanzhu
</div>
</li>
<li class="dib">
<span class="icon iconfont icon-laba"></span>
<div class="name">
@ -3740,6 +3770,14 @@
<div class="code-name">#icon-renzhengxinxi</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-weibiaoti105"></use>
</svg>
<div class="name">关注</div>
<div class="code-name">#icon-weibiaoti105</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-gift"></use>
@ -3876,6 +3914,14 @@
<div class="code-name">#icon-dashujucunchu</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-guanzhu"></use>
</svg>
<div class="name">关注</div>
<div class="code-name">#icon-guanzhu</div>
</li>
<li class="dib">
<svg class="icon svg-icon" aria-hidden="true">
<use xlink:href="#icon-laba"></use>

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -229,6 +229,13 @@
"unicode": "e693",
"unicode_decimal": 59027
},
{
"icon_id": "1214792",
"name": "关注",
"font_class": "weibiaoti105",
"unicode": "e6c0",
"unicode_decimal": 59072
},
{
"icon_id": "1221889",
"name": "礼物",
@ -348,6 +355,13 @@
"unicode": "e678",
"unicode_decimal": 59000
},
{
"icon_id": "1901672",
"name": "关注",
"font_class": "guanzhu",
"unicode": "e6c5",
"unicode_decimal": 59077
},
{
"icon_id": "1941293",
"name": "喇叭",

@ -116,6 +116,9 @@ Created by iconfont
<glyph glyph-name="renzhengxinxi" unicode="&#59027;" d="M485.648423-128c-144.376948 0-412.841368 220.864564-412.841368 429.728646L72.807056 717.817567l41.04289 0.68044c0.866014 0 92.50888 1.948532 187.059079 40.331521 96.962668 39.403649 159.532198 84.652894 160.11985 85.054972l24.495832 17.846079 24.712335-17.846079c0.587653-0.433007 63.126253-45.651323 160.11985-85.054972 94.550199-38.382989 186.193065-40.331521 187.151867-40.331521l40.857315-0.68044 0.185574-416.057992C898.582578 92.895494 630.118159-128 485.648423-128L485.648423-128M156.160928 638.051468l0-336.291893c0-161.511659 233.854778-346.374773 329.487495-346.374773 95.632717 0 329.487495 184.863115 329.487495 346.374773L815.135919 638.051468c-40.857315 4.422859-107.200193 15.588257-176.079256 43.548145-70.611091 28.702187-124.242117 59.909629-153.40824 78.498007-29.104265-18.588377-82.76622-49.79582-153.315452-78.498007C263.361121 653.608795 197.018243 642.474326 156.160928 638.051468L156.160928 638.051468M463.56506 145.413072 288.28996 294.738673l53.909387 63.404615 112.458137-95.725504 213.441585 245.886191 63.033466-54.682614L463.56506 145.413072 463.56506 145.413072M463.56506 145.413072 463.56506 145.413072z" horiz-adv-x="1024" />
<glyph glyph-name="weibiaoti105" unicode="&#59072;" d="M936.038 750.874c-109.38 118.519-286.737 118.519-396.083 0l-27.93-30.276-27.947 30.276c-109.363 118.519-286.703 118.519-396.066 0-109.38-118.511-109.38-310.647 0-429.158l27.93-30.251 396.083-365.414 396.066 365.414 27.947 30.251c109.362 118.51 109.362 310.647 0 429.158v0z" horiz-adv-x="1024" />
<glyph glyph-name="gift" unicode="&#58940;" d="M85.931-54.016c0-24.576 7.125-31.317 29.44-31.317h353.365v469.589h-382.805v-438.272zM555.264-85.333h353.365c22.357 0 29.44 6.699 29.44 31.317l-0 438.272h-382.848v-469.589zM938.667 640h-213.333c51.499 11.733 105.899 49.707 112.597 94.293 7.851 50.859-52.565 127.957-125.653 118.187-87.424-12.117-151.509-89.259-196.736-149.077-44.885 58.667-103.381 127.189-187.179 147.115-81.152 19.2-136.747-64.939-135.253-116.992 1.451-44.245 52.608-81.835 105.557-93.525h-213.333c-26.368 0-42.667-14.848-42.667-42.667v-170.581l426.667-0.085v213.333h85.333v-213.333l426.667 0.085v170.581c0 27.819-16.341 42.667-42.667 42.667zM251.648 717.824c-14.763 16.427-4.779 38.741 4.48 55.595 17.024 29.696 40.747 47.744 81.152 30.933 56.32-23.509 97.792-73.216 131.584-117.803-71.552-7.893-178.304-10.965-217.216 31.275zM562.944 687.317c34.816 44.629 75.221 89.941 131.157 117.803 58.581 28.971 113.024-49.323 85.205-86.912-21.419-28.544-89.259-31.232-125.909-32.853-30.080-1.536-60.501-0.811-90.453 1.963z" horiz-adv-x="1024" />
@ -167,6 +170,9 @@ Created by iconfont
<glyph glyph-name="dashujucunchu" unicode="&#59000;" d="M975.644444 233.24444400000004V534.7555560000001c28.444444 14.222222 51.2 42.666667 51.2 76.8 0 48.355556-36.977778 85.333333-85.333333 85.333333-19.911111 0-39.822222-8.533333-54.044444-19.911111L594.488889 830.577778C585.955556 867.555556 551.822222 896 512 896c-42.666667 0-79.644444-31.288889-85.333333-73.955556L145.066667 671.288889C130.844444 688.355556 108.088889 696.8888890000001 85.333333 696.8888890000001c-48.355556 0-85.333333-36.977778-85.333333-85.333333 0-39.822222 28.444444-73.955556 65.422222-82.488889v-290.133334C28.444444 230.39999999999998 0 196.26666699999998 0 156.44444399999998c0-48.355556 36.977778-85.333333 85.333333-85.333333 22.755556 0 45.511111 8.533333 59.733334 25.6l281.6-150.755555c5.688889-42.666667 39.822222-73.955556 85.333333-73.955556 39.822222 0 73.955556 28.444444 82.488889 65.422222l290.133333 153.6c14.222222-11.377778 34.133333-19.911111 54.044445-19.911111 48.355556 0 85.333333 36.977778 85.333333 85.333333 0 34.133333-19.911111 62.577778-48.355556 76.8z m-96.711111-14.222222l-133.688889 65.422222v199.111112l133.688889 65.422222c11.377778-11.377778 22.755556-17.066667 36.977778-19.911111v-290.133334c-14.222222-2.844444-25.6-11.377778-36.977778-19.911111zM853.333333 600.177778l-139.377777-68.266667L540.444444 631.4666669999999V731.022222c19.911111 8.533333 36.977778 22.755556 45.511112 39.822222l267.377777-142.222222v-28.444444zM520.533333 190.57777799999997l-170.666666 96.711111v193.422222l170.666666 96.711111 170.666667-96.711111v-193.422222l-170.666667-96.711111zM483.555556 731.022222v-105.244444l-167.822223-96.711111L170.666667 600.177778V611.555556v8.533333l270.222222 145.066667c8.533333-17.066667 25.6-28.444444 42.666667-34.133334zM145.066667 548.977778l147.911111-73.955556v-184.888889l-147.911111-73.955555c-5.688889 5.688889-14.222222 11.377778-22.755556 17.066666V534.7555560000001c8.533333 2.844444 14.222222 8.533333 22.755556 14.222222zM170.666667 167.822222l145.066666 73.955556 167.822223-96.711111v-105.244445c-17.066667-5.688889-34.133333-17.066667-42.666667-34.133333l-270.222222 142.222222V156.44444399999998v11.377778z m369.777777-130.844444v99.555555l176.355556 99.555556 139.377778-68.266667v-11.377778c0-5.688889 0-11.377778 2.844444-17.066666l-267.377778-142.222222c-14.222222 19.911111-31.288889 34.133333-51.2 39.822222z" horiz-adv-x="1026" />
<glyph glyph-name="guanzhu" unicode="&#59077;" d="M726.109 863.418c-83.782 0-158.255-32.582-214.109-93.091-55.855 60.509-130.327 93.091-214.109 93.091-162.909 0-297.891-144.291-297.891-321.164 0-93.091 37.236-181.527 107.055-246.691l353.745-367.709c13.964-13.964 32.582-23.273 51.2-23.273 18.618 0 37.236 9.309 51.2 23.273l358.4 363.055c65.164 65.164 107.055 158.255 107.055 251.345-4.655 176.873-139.636 321.164-302.545 321.164zM870.4 346.764l-358.4-363.055-358.4 367.709c-51.2 51.2-83.782 116.364-83.782 190.836 0 134.982 102.4 242.036 228.073 242.036 97.745 0 176.873-65.164 214.109-153.6 32.582 88.436 116.364 153.6 214.109 153.6 125.673 0 228.073-107.055 228.073-242.036 0-74.473-32.582-144.291-83.782-195.491z" horiz-adv-x="1028" />
<glyph glyph-name="laba" unicode="&#58888;" d="M858.584615 586.174359c-5.251282 5.251282-10.502564 10.502564-15.753846 13.128205-5.251282 5.251282-10.502564 10.502564-18.379487 13.128205v-10.502564c-21.005128 0-39.384615-18.379487-39.384615-39.384615v-2.625641c0-21.005128 18.379487-39.384615 39.384615-39.384616v-18.379487c26.25641-34.133333 39.384615-73.517949 39.384615-118.153846s-15.753846-86.646154-39.384615-118.153846v-15.753846c-21.005128 0-39.384615-18.379487-39.384615-39.384616v-2.625641c0-21.005128 18.379487-39.384615 39.384615-39.384615v-10.502564c7.876923 5.251282 13.128205 10.502564 21.005128 15.753846 5.251282 2.625641 10.502564 7.876923 13.128205 10.502564 52.512821 49.887179 86.646154 120.779487 86.646154 202.174359 0 78.769231-34.133333 149.661538-86.646154 199.548718z m-189.046153 191.671795h-7.876924c-7.876923 0-13.128205-2.625641-21.005128-7.876923l-330.830769-149.661539H157.538462c-44.635897 0-78.769231-34.133333-78.769231-78.76923v-317.702565c2.625641-42.010256 36.758974-76.14359 78.769231-76.143589h39.384615c21.005128 0 39.384615 18.379487 39.384615 39.384615s-15.753846 36.758974-34.133333 39.384615H236.307692c-65.641026 0-78.769231 13.128205-78.76923 78.769231v-2.625641 170.666667-7.876923c0 60.389744 10.502564 76.14359 65.641025 78.769231H315.076923c5.251282 0 10.502564 2.625641 15.753846 5.251282 2.625641 0 7.876923 2.625641 10.502564 5.251282l288.820513 131.282051v-593.394872L375.466667 213.333333c-18.379487 13.128205-42.010256 7.876923-55.138462-7.876923-13.128205-18.379487-7.876923-42.010256 7.876923-55.138461L638.030769 3.282051c7.876923-5.251282 18.379487-7.876923 26.25641-7.876923h2.625642c21.005128 0 39.384615 18.379487 39.384615 39.384616L708.923077 738.461538c0 23.630769-18.379487 39.384615-39.384615 39.384616z m-506.748718-551.384616H157.538462h5.251282z m-5.251282 315.076924h21.005128H157.538462z" horiz-adv-x="1024" />
@ -659,7 +665,7 @@ Created by iconfont
<glyph glyph-name="xuexizhongxin" unicode="&#59062;" d="M946.907429 889.690634H635.102609c-36.145292 0-68.945093-14.533168-92.91687-38.13605A131.510857 131.510857 0 0 1 449.389714 889.690634H137.591255C64.422957 889.690634 4.916472 830.184149 4.916472 757.015851v-643.472696a39.707031 39.707031 0 0 1 39.751553-39.751553h378.142211c55.149714 0 84.22241-45.348571 85.214609-46.957714 0.496099-0.871354 1.240248-1.367453 1.736348-2.238807 0.623304-0.871354 1.246609-1.615503 1.863552-2.353292 2.111602-2.493217 4.477615-4.725665 6.958112-6.716423l1.494659-1.113043c6.455652-4.35041 14.037068-6.958112 21.987378-6.958112 3.472696 0 7.078957 0.496099 10.558013 1.488298 1.488298 0.375255 2.734907 1.367453 4.096 1.863553 1.990758 0.744149 3.854311 1.615503 5.717863 2.607702 1.615503 0.998559 2.976596 2.111602 4.471255 3.231006a40.19677 40.19677 0 0 1 4.719304 4.471255c0.992199 1.119404 2.111602 2.359652 2.982957 3.606261 0.368894 0.616944 0.992199 1.113043 1.367453 1.736348 1.240248 1.990758 30.306584 47.332969 85.462659 47.332968h378.13585a39.707031 39.707031 0 0 1 39.751553 39.751553V757.015851c0.25441 73.168298-59.252075 132.674783-132.420372 132.674783zM422.931081 121.614311H50.576696V769.736348c0 29.320745 56.154634 69.275826 85.348174 69.275826h311.798459c29.320745 0 72.475031-40.082286 72.475031-69.275826v-667.12646c-21.739329 11.054112-65.841292 19.004422-97.267279 19.004423z m602.582658 0h-363.825292c-31.425988 0-57.884621-7.950311-79.63031-19.004423V769.736348c0 29.320745 27.120099 67.584 56.313639 67.584h330.879205c29.320745 0 56.141913-38.39046 56.141913-67.584v-648.122037h0.127205zM403.055304 644.197764H184.173714c-21.987379 0-39.751553-14.208795-39.751553-31.801242 0-17.586087 17.764174-31.801242 39.751553-31.801242h218.88159c21.987379 0 39.751553 14.215155 39.751553 31.801242 0 17.490683-17.764174 31.801242-39.751553 31.801242z m0-248.049689H184.173714c-21.987379 0-39.751553-14.208795-39.751553-31.801243 0-17.586087 17.764174-31.801242 39.751553-31.801242h218.88159c21.987379 0 39.751553 14.215155 39.751553 31.801242 0 17.490683-17.764174 31.801242-39.751553 31.801243z m497.517715 254.409937H681.564224c-21.987379 0-39.751553-14.208795-39.751553-31.801242 0-17.586087 17.764174-31.801242 39.751553-31.801242h218.88159c21.987379 0 39.751553 14.215155 39.751552 31.801242 0.127205 17.490683-17.636969 31.801242-39.624347 31.801242z m0-254.409937H681.564224c-21.987379 0-39.751553-14.208795-39.751553-31.801243 0-17.586087 17.764174-31.801242 39.751553-31.801242h218.88159c21.987379 0 39.751553 14.215155 39.751552 31.801242 0.127205 17.490683-17.636969 31.801242-39.624347 31.801243z m139.251279-457.638957H52.249441c-21.987379 0-39.751553-14.208795-39.751553-31.801242s17.764174-31.801242 39.751553-31.801242h987.574857c21.987379 0 39.751553 14.208795 39.751553 31.801242 0 17.490683-17.764174 31.801242-39.751553 31.801242z" horiz-adv-x="1081" />
<glyph glyph-name="tongji" unicode="&#59071;" d="M256-32.2h-62.5c-52.9 0-96 43.1-96 96V413.9c0 52.9 43.1 96 96 96H256c52.9 0 96-43.1 96-96v-350.1c0-53-43.1-96-96-96z m-62.5 478.1c-17.6 0-32-14.4-32-32v-350.1c0-17.6 14.4-32 32-32H256c17.6 0 32 14.4 32 32V413.9c0 17.6-14.4 32-32 32h-62.5zM542.2-32.2h-62.5c-52.9 0-96 43.1-96 96V704.2c0 52.9 43.1 96 96 96h62.5c52.9 0 96-43.1 96-96v-640.5c0-52.9-43-95.9-96-95.9z m-62.4 768.4c-17.6 0-32-14.4-32-32v-640.5c0-17.6 14.4-32 32-32h62.5c17.6 0 32 14.4 32 32V704.2c0 17.6-14.4 32-32 32h-62.5zM830.5-32.2H768c-52.9 0-96 43.1-96 96v479c0 52.9 43.1 96 96 96h62.5c52.9 0 96-43.1 96-96v-479c0-53-43.1-96-96-96zM768 574.7c-17.6 0-32-14.4-32-32v-479c0-17.6 14.4-32 32-32h62.5c17.6 0 32 14.4 32 32v479c0 17.6-14.4 32-32 32H768z" horiz-adv-x="1024" />
<glyph glyph-name="tongji" unicode="&#59071;" d="M210.823529 594.823529A90.352941 90.352941 0 0 0 301.176471 504.470588v-542.117647A90.352941 90.352941 0 0 0 210.823529-128h-120.470588A90.352941 90.352941 0 0 0 0-37.64705900000001v542.117647A90.352941 90.352941 0 0 0 90.352941 594.823529h120.470588z m361.411765 301.176471A90.352941 90.352941 0 0 0 662.588235 805.647059v-843.294118A90.352941 90.352941 0 0 0 572.235294-128h-120.470588A90.352941 90.352941 0 0 0 361.411765-37.64705900000001v843.294118A90.352941 90.352941 0 0 0 451.764706 896h120.470588z m361.411765-542.117647a90.352941 90.352941 0 0 0 90.352941-90.352941v-301.176471a90.352941 90.352941 0 0 0-90.352941-90.352941h-120.470588a90.352941 90.352941 0 0 0-90.352942 90.352941v301.176471A90.352941 90.352941 0 0 0 813.176471 353.88235299999997h120.470588z m-722.82353 180.705882h-120.470588a30.117647 30.117647 0 0 1-29.635765-24.69647L60.235294 504.470588v-542.117647a30.117647 30.117647 0 0 1 24.696471-29.635765L90.352941-67.76470600000005h120.470588a30.117647 30.117647 0 0 1 29.635765 24.696471L240.941176-37.64705900000001v542.117647a30.117647 30.117647 0 0 1-30.117647 30.117647z m361.411765 301.176471h-120.470588a30.117647 30.117647 0 0 1-29.635765-24.696471L421.647059 805.647059v-843.294118a30.117647 30.117647 0 0 1 24.69647-29.635765L451.764706-67.76470600000005h120.470588a30.117647 30.117647 0 0 1 29.635765 24.696471L602.352941-37.64705900000001v843.294118a30.117647 30.117647 0 0 1-30.117647 30.117647z m361.411765-542.117647h-120.470588a30.117647 30.117647 0 0 1-29.635765-24.696471L783.058824 263.529412v-301.176471a30.117647 30.117647 0 0 1 24.69647-29.635765l5.421177-0.481882h120.470588a30.117647 30.117647 0 0 1 29.635765 24.696471L963.764706-37.64705900000001v301.176471a30.117647 30.117647 0 0 1-30.117647 30.117647z" horiz-adv-x="1024" />
<glyph glyph-name="menu_voucher" unicode="&#59064;" d="M830.236-64.886H200.924c-63.104 0-114.421 51.316-114.421 114.421V364.191c0 63.104 51.316 114.421 114.421 114.421h629.313c63.104 0 114.421-51.316 114.421-114.421v-314.656c-0.001-63.105-51.317-114.421-114.422-114.421zM200.924 421.401c-31.538 0-57.21-25.672-57.21-57.21v-314.656c0-31.538 25.672-57.21 57.21-57.21h629.313c31.538 0 57.21 25.672 57.21 57.21V364.191c0 31.538-25.672 57.21-57.21 57.21H200.924zM801.631 604.848H229.529c-15.811 0-28.605 12.794-28.605 28.605s12.794 28.605 28.605 28.605h572.103c15.811 0 28.605-12.794 28.605-28.605s-12.795-28.605-28.606-28.605zM630 777.904H401.159c-15.811 0-28.605 12.794-28.605 28.605s12.794 28.605 28.605 28.605H630c15.811 0 28.605-12.794 28.605-28.605S645.812 777.904 630 777.904z" horiz-adv-x="1024" />

Before

Width:  |  Height:  |  Size: 306 KiB

After

Width:  |  Height:  |  Size: 308 KiB

Loading…
Cancel
Save