修改创建编程作业作品时、链接网址

This commit is contained in:
sw 2015-07-15 14:44:58 +08:00
parent aa5255c430
commit 4ae7732762
2 changed files with 2 additions and 2 deletions

View File

@ -74,7 +74,7 @@ class HomeworkCommonController < ApplicationController
homework_detail_programing.standard_code = params[:standard_code]
question = {title:homework.name,content:homework.description}
uri = URI('http://fast.forge.trustie.net/api/questions.json')
uri = URI('http://test.gitlab.trustie.net/api/questions.json')
if params[:input] && params[:output]
params[:input].each do |k,v|
if params[:output].include? k

View File

@ -82,7 +82,7 @@ class StudentWorkController < ApplicationController
if stundet_work.save
if @homework.homework_type == 2 && @homework.homework_detail_programing #编程作业,学生提交作品后计算系统得分
url = "http://fast.forge.trustie.net/api/questions/#{@homework.homework_detail_programing.question_id}/solutions.json"
url = "http://test.gitlab.trustie.net/api/questions/#{@homework.homework_detail_programing.question_id}/solutions.json"
uri = URI(url)
solutions = {
id:stundet_work.id,