Skip to content

Commit 2e0bb31

Browse files
Merge pull request #193 from OpenDSA/textbook-url
textbook url fixed
2 parents 594fff7 + 7b74a7d commit 2e0bb31

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

app/assets/javascripts/textbooks.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@
192192
messages = check_completeness(true);
193193
if (messages.length !== 0) {
194194
form_alert(messages);
195-
$('#btn-submit-co').prop('disabled', false);
195+
$('#btn-gen-textbook').prop('disabled', false);
196196
return;
197197
}
198198
organization_id = $('#organization-select').val();

app/views/courses/show.html.haml

+4-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,10 @@
6464
- course = Course.find_by(id:offering.course_id)
6565
- organization = Organization.find_by(id:course.organization_id)
6666
- term = Term.find_by(id:offering.term_id)
67-
= ENV["config_api_link"].gsub("/api/configure/","/Books/#{organization.slug}/#{course.slug}/#{term.slug}/#{offering.label}/html/index.html")
67+
- if ENV["config_api_link"] == "staging"
68+
= "https://opendsax.cs.vt.edu/ODSA/" + "/Books/#{organization.slug}/#{course.slug}/#{term.slug}/#{offering.label}/html/"
69+
- else
70+
= ENV["config_api_link"].gsub("/api/configure/","/Books/#{organization.slug}/#{course.slug}/#{term.slug}/#{offering.label}/html/index.html")
6871
%td
6972
- inst_book = InstBook.find_by(course_offering_id:offering.id)
7073
- form_name = 'compile_book_' + inst_book.id.to_s

0 commit comments

Comments
 (0)