Corrected script submission, to better manage the json/html format

This commit is contained in:
echarp 2020-02-09 17:49:15 +01:00
parent 59de7c9e5c
commit c3d386ff48
3 changed files with 2 additions and 5 deletions

View File

@ -78,9 +78,6 @@ class Event < ApplicationRecord
before_validation on: :create do
self.submission_time = Time.zone.now
self.decision_time = Time.zone.now
# Populate submitter using contact info if absent
self.submitter ||= contact
end
before_validation on: :update do

View File

@ -1 +1 @@
3.5
3.6

View File

@ -315,7 +315,7 @@ def SubmitEvent(event, testOutputFile):
curl.setopt(curl.WRITEFUNCTION, contents.write)
if testOutputFile:
curl.setopt (curl.URL, baseUrl + 'events/preview')
curl.setopt (curl.URL, baseUrl + 'events/preview?format=html')
else:
curl.setopt (curl.URL, baseUrl + 'events')