Update fgu_sync.rake.
This commit is contained in:
parent
0eae8b354e
commit
2acf3030f4
|
@ -329,7 +329,9 @@ namespace :fgu_sync do
|
||||||
av.save
|
av.save
|
||||||
end
|
end
|
||||||
dt["courses"].each do |course|
|
dt["courses"].each do |course|
|
||||||
course_html += "<a data-year='#{course["year"].to_i + 1911}' data-sem='#{course["sem"]}' href='#{course["course_url"]}' target='_blank'>#{course["course_id"]} #{course["course_name"]}</a><br />"
|
course_url = course["course_url"]
|
||||||
|
course_url.gsub!(/http:\/\/(.*\.fgu\.edu\.tw)/, 'https://\1')
|
||||||
|
course_html += "<a data-year='#{course["year"].to_i + 1911}' data-sem='#{course["sem"]}' href='#{course_url}' target='_blank'>#{course["course_id"]} #{course["course_name"]}</a><br />"
|
||||||
av.value= {:en => course_html, :zh_tw => course_html}
|
av.value= {:en => course_html, :zh_tw => course_html}
|
||||||
av.save
|
av.save
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue