Local changes

This commit is contained in:
PCoder 2023-12-13 10:39:10 +05:30
parent 8099e5e46a
commit 264745f40f
3 changed files with 12 additions and 12 deletions

View File

@ -236,6 +236,7 @@ class WhyDataCenterLightView(IndexView):
template_name = "datacenterlight/whydatacenterlight.html"
@method_decorator(decorator=never_cache, name='get')
class PaymentOrderView(FormView):
template_name = 'datacenterlight/landing_payment.html'
@ -313,12 +314,10 @@ class PaymentOrderView(FormView):
return context
@cache_control(no_cache=True, must_revalidate=True, no_store=True)
def get(self, request, *args, **kwargs):
request.session.pop('vat_validation_status')
request.session.pop('card_id')
request.session.pop('token')
request.session.pop('id_payment_method')
for k in ['vat_validation_status', 'card_id', 'token', 'id_payment_method']:
if k in request.session:
request.session.pop(k)
logger.debug("Session: %s" % str(request.session))
for key, value in request.session.items():
logger.debug("Session: %s %s" % (key, value))

View File

@ -54,7 +54,8 @@ INSTALLED_APPS = [
'filer',
'datacenterlight',
'opennebula_api',
'sekizai'
'sekizai',
'webhook'
]
MIDDLEWARE = [

View File

@ -51,7 +51,7 @@ from django.views.static import serve as static_serve
urlpatterns = [
path('admin/', admin.site.urls),
re_path('^admin/', admin.site.urls),
re_path(r'^index.html$', LandingView.as_view()),
# re_path(r'^open_api/', include('opennebula_api.urls', namespace='opennebula_api',), name="opennebula_api"),
re_path(r'^railshosting/', RailsHostingView.as_view(), name="rails.hosting"),
@ -63,12 +63,12 @@ urlpatterns = [
path('i18n/', include('django.conf.urls.i18n')), # Language switcher URL
re_path(r'^cms/', include('cms.urls')),
]
# urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
urlpatterns += i18n_patterns(
# Add other internationalized patterns here if needed
)
# urlpatterns += i18n_patterns(
#
# # Add other internationalized patterns here if needed
# )