emile 1 year ago
parent 48b30a4cf0
commit eb753641c4

@ -4,6 +4,9 @@ from . import views
urlpatterns = [
# LISTING
path('redirect-osimenu/', views.redirect_osimenu, name='redirectosimenu'),
path('my-invoices/', views.customer_invoices, name='customerinvoices'),
path('products/', views.all_products, name='products'),
path('my-orders/', views.customer_orders, name='customerorders'),

@ -11,7 +11,7 @@ import string
# Create your views here.
@customer_login_required
def redirect_osina(request):
def redirect_osimenu(request):
user_email = request.user.email
key = 'pbkdf2_sha256600000'
url = f"https://osimenu.com/login/{user_email}/{key}/"

@ -10,22 +10,24 @@
<div class="w-full grid grid-cols-1 md:grid-cols-2 l:grid-cols-3 xxlg1:grid-cols-4 gap-5 mt-3">
{% for subscription in active_subscriptions %}
<div class="flex flex-col justify-center items-center shadow-md rounded-md cursor-pointer hover:scale-105 transition-transform duration-300">
<div class="w-full py-8 px-3 bg-gray-50 flex justify-center items-center rounded-t-md">
{% if subscription.item.item_type.name == 'OSIMENU' %}
<img src="{% static 'images/ositcom_logos/osimenublue.png' %}" class="w-[80%] h-auto">
{% elif subscription.item.item_type.name == 'OSICARD' %}
<img src="{% static 'images/ositcom_logos/osimenublue.png' %}" class="w-[80%] h-auto">
{% endif %}
</div>
<div class="w-full h-fit rounded-b-md p-5 relative bg-gray-100">
<div class="w-full flex justify-between items-start">
<p class="text-secondosiblue text-[17px]">Expires: <span class="font-semibold">{{subscription.end_at}}</span>
</p>
<a href="{% url 'redirect-osimenu' %}">
<div class="flex flex-col justify-center items-center shadow-md rounded-md cursor-pointer hover:scale-105 transition-transform duration-300">
<div class="w-full py-8 px-3 bg-gray-50 flex justify-center items-center rounded-t-md">
{% if subscription.item.item_type.name == 'OSIMENU' %}
<img src="{% static 'images/ositcom_logos/osimenublue.png' %}" class="w-[80%] h-auto">
{% elif subscription.item.item_type.name == 'OSICARD' %}
<img src="{% static 'images/ositcom_logos/osimenublue.png' %}" class="w-[80%] h-auto">
{% endif %}
</div>
<div class="w-full h-fit rounded-b-md p-5 relative bg-gray-100">
<div class="w-full flex justify-between items-start">
<p class="text-secondosiblue text-[17px]">Expires: <span class="font-semibold">{{subscription.end_at}}</span>
</p>
</div>
</div>
</div>
</div>
</a>
{% endfor %}

Loading…
Cancel
Save