from django.urls import path
from.views import  Stock_Min, index,pdp,appros,production,login_view,refresh_data,Cbn,prd_pdp_detail,pdp_semulat
from django.contrib.auth.decorators import login_required
from . import views
from django.contrib.auth import views as auth_views
app_name = 'produits'
urlpatterns = [
    path('', login_view, name='login'),
    path('index/', login_required(index), name = 'index'),
    path('pdp/',login_required(pdp),name = 'pdp'),
    path('prd_pdp_detail/',login_required(prd_pdp_detail),name = 'prd_pdp_detail'),
    path('appros/',login_required(appros),name = 'appros'),
    path('Can_prd/',login_required(production),name = 'can_prd'),
    path('Stock_min/',login_required(Stock_Min),name = 'stock_min'),
    path('Cbn/',login_required(Cbn),name = 'Cbn'),
    path('pdp_semulat/',login_required(pdp_semulat),name = 'pdp_semulat'),
    path('logout/', auth_views.LogoutView.as_view(), name='logout'),
    path('refresh/',refresh_data, name='refresh'),

    
]