]> git.parisson.com Git - teleforma.git/commitdiff
various record bugfix
authorGuillaume Pellerin <yomguy@parisson.com>
Thu, 11 Jul 2013 15:42:37 +0000 (17:42 +0200)
committerGuillaume Pellerin <yomguy@parisson.com>
Thu, 11 Jul 2013 15:42:37 +0000 (17:42 +0200)
teleforma/templates/teleforma/course_conference_audio.html
teleforma/views/core.py

index e1e0a92b973429914d0d366d656ae2bfbff170b8..bdd0648982e3af75196b817e4da99f6c2f752e1e 100644 (file)
@@ -8,7 +8,7 @@
     var conferenceUtils = {
         stop : function(id){
             json([id],'teleforma.conference_stop',function(){
-                location.href = '{% url teleforma-home %}';});
+                location.href = '{% url teleforma-conference-record %}';});
         }}
 
     jQuery(window).ready(function(){
index 3782c2f5ae36ade54e47195ec5c791b80ede6207..8adef8d40d39c86481e9817ffe8a4ffcc68b6a71 100644 (file)
@@ -149,6 +149,8 @@ def get_host(request):
     host = request.META['HTTP_HOST']
     if ':' in host:
         host = host.split(':')[0]
+    if host == 'localhost':
+        host = '127.0.0.1'
     return host
 
 def get_periods(user):
@@ -531,6 +533,8 @@ class ConferenceRecordView(FormView):
         except:
             pass
 
+        return super(ConferenceRecordView, self).form_valid(form)
+
     def snapshot(self, url, dir):
         width = 160
         height = 90
@@ -539,7 +543,7 @@ class ConferenceRecordView(FormView):
         f = open(path, 'w')
         f.write(img.read())
         f.close()
-        command = '/usr/bin/dwebp ' + path + ' -o ' + dir + os.sep + 'preview.png &'
+        command = 'dwebp ' + path + ' -o ' + dir + os.sep + 'preview.png &'
         os.system(command)
 
     @method_decorator(login_required)