Browse Source

HUE-6094 [jobsub] Set is_hue_4 flag

Jenny Kim 8 years ago
parent
commit
04c1db1b16
2 changed files with 4 additions and 4 deletions
  1. 1 1
      apps/jobsub/src/jobsub/templates/designs.mako
  2. 3 3
      apps/jobsub/src/jobsub/views.py

+ 1 - 1
apps/jobsub/src/jobsub/templates/designs.mako

@@ -60,7 +60,7 @@ ${ commonheader(None, "jobsub", user, request) | n,unicode }
   % if is_hue_4:
     <div class="alert">
       ${ _('This is the old Job Editor, it is recommended to instead use the new ') }
-        <a href="${ url('notebook:editor') }?type=shell" target="_blank">${_('Editor')}</a>
+        <a href="${ url('notebook:editor') }" target="_blank">${_('Editor')}</a>
     </div>
   % endif
 

+ 3 - 3
apps/jobsub/src/jobsub/views.py

@@ -28,11 +28,10 @@ is a "job submission".  Submissions can be "watched".
 import logging
 import time as py_time
 
-from django.core import urlresolvers
-from django.shortcuts import redirect
 from django.utils.translation import ugettext as _
 
 from desktop import appmanager
+from desktop.conf import IS_HUE_4
 from desktop.lib.django_util import render, render_json
 from desktop.lib.exceptions import StructuredException
 from desktop.lib.exceptions_renderable import PopupException
@@ -107,7 +106,8 @@ def list_designs(request):
       'currentuser': request.user,
       'owner': owner,
       'name': name,
-      'apps': appmanager.get_apps_dict()
+      'apps': appmanager.get_apps_dict(),
+      'is_hue_4': IS_HUE_4.get()
     })