pwa: only enable PWA if pwa_display is standalone (#29471)
This commit is contained in:
parent
522437c8db
commit
2d4ca51241
|
@ -31,7 +31,7 @@ class AppConfig(django.apps.AppConfig):
|
|||
|
||||
def get_extra_manager_actions(self):
|
||||
from django.conf import settings
|
||||
if settings.TEMPLATE_VARS.get('pwa_display') in ('standalone', 'fullscreen'):
|
||||
if settings.TEMPLATE_VARS.get('pwa_display') == 'standalone':
|
||||
return [{'href': reverse('pwa-manager-homepage'),
|
||||
'text': _('Mobile Application (PWA)')}]
|
||||
return []
|
||||
|
|
|
@ -24,7 +24,7 @@ register = template.Library()
|
|||
|
||||
@register.simple_tag(takes_context=True)
|
||||
def pwa_navigation(context):
|
||||
if settings.TEMPLATE_VARS.get('pwa_display') not in ('standalone', 'fullscreen'):
|
||||
if settings.TEMPLATE_VARS.get('pwa_display') != 'standalone':
|
||||
return ''
|
||||
pwa_navigation_template = template.loader.get_template('combo/pwa/navigation.html')
|
||||
entries = list(PwaNavigationEntry.objects.all())
|
||||
|
|
Loading…
Reference in New Issue