Skip to content
Snippets Groups Projects
Commit be5ea59d authored by Milo Hivert's avatar Milo Hivert
Browse files

premerge

parents 8592feae d6251e37
Branches
No related tags found
No related merge requests found
File deleted
File added
......@@ -7,6 +7,7 @@ import requests
import json
# from cryptography.fernet import Fernet
from django.core.mail import send_mail
def connexion(request):
......@@ -67,6 +68,10 @@ def commande_passee(request, requete):
mail = r.json()['email']
commande=commande_crepe.objects.create(adresse_livraison=L[4], crepe_nature=L[0], crepe_nutella=L[1], crepe_sucre=L[2], crepe_confiture=L[3],commanditaire=utilisateur.objects.get(email=mail))
commande.save()
#send_mail('commande crêpes',
# 'Nouvelle commande',
# 'stepgifimstuck@gmail.com',
# ['stepgifimstuck@gmail.com'])
return redirect(mes_commandes)
def mes_commandes(request):
......@@ -92,9 +97,8 @@ def annuler(request, pkrequete):
commande_crepe.objects.filter(pk=pkrequete).delete()
return redirect(mes_commandes)
def prendre_en_charge(request, pkrequete):
test=check(request)
if test[0]:
test=check(request)
if test[0]:
mail=test[1]['email']
......@@ -232,72 +236,6 @@ def addtodb():
#"alexia.lanore@student-cs.fr",
#"ninon.atienza@student-cs.fr",
#"raphael.levisse@student-cs.fr",
#"lilian.marsal@student-cs.fr",
#"joel.carles-gonzalez@student-cs.fr",
#"hamza.errahj@student-cs.fr",
#"oussama.arrayech@student-cs.fr",
#"ludovic.mulat@student-cs.fr",
#"theophile.rousselle@student-cs.fr",
#"maxime.anno@student-cs.fr",
#"elise.meissirel@student-cs.fr",
#"arnaud.destarac@student-cs.fr",
#"barthelemy.arminjon@student-cs.fr",
#"etienne.camus@student-cs.fr",
#"alban.pinet@student-cs.fr",
#"octave.pignet@student-cs.fr",
#"sacha.cario@student-cs.fr",
#"antoine.cheneau@student-cs.fr",
#"pierre.gourdou@student-cs.fr",
#"rayan.lebbadi@student-cs.fr",
#"emma.guetta@student-cs.fr",
#"antoine.manyeres@student-cs.fr",
#"quentin.granier@student-cs.fr",
#"benjamin.boutier@student-cs.fr",
#"anas.slaoui@student-cs.fr",
#"ploum.cayla@student-cs.fr",
#"maite.robert@student-cs.fr",
#"matthieu.antoine@student-cs.fr",
#"arthur.bernard2@student-cs.fr",
#"riade.bhih@student-cs.fr",
#"thierry.aba@student-cs.fr",
#"cecile.mentz@student-cs.fr",
#"clement.marechal@student-cs.fr",
#"sebastien.louis@student-cs.fr",
#"leo.fagard@student-cs.fr",
#"felix.regnier@student-cs.fr",
#"moustapha.hashem@student-cs.fr",
#"charlotte.jouffre@student-cs.fr",
#"xavier.bodard@student-cs.fr",
#"luis.bottraud@student-cs.fr",
#"robin.truffinet@student-cs.fr",
#"lancelot.michea@student-cs.fr",
#"olivier.beck@student-cs.fr",
#"simon.delalande@student-cs.fr",
#"cornelia.huller@student-cs.fr",
#"pierre-amaury.laforcade@student-cs.fr",
#"louis.viennot@student-cs.fr",
#"melen.le-corre@student-cs.fr",
#"thibault.henique@student-cs.fr",
#"leo.molinier@student-cs.fr",
#"mehdi.mouden@student-cs.fr",
#"yann.duchesne@student-cs.fr",
#"kiria.filleul@student-cs.fr",
#"othman.benmoussa@student-cs.fr",
#"erhart.jean@student-cs.fr",
#"adrien.peccenini@student-cs.fr",
#"margaux.falliondalmonte@student-cs.fr",
#"maxime.archambault@student-cs.fr",
#"thomas.bougnon@student-cs.fr",
#"titouan.benard@student-cs.fr",
#"mathilde.loume@student-cs.fr",
#"ilyass.guenfoudi@student-cs.fr",
#"jack.royer@student-cs.fr",
#"paul.ferreol@student-cs.fr",
#"jad.zarzour@student-cs.fr",
#"leonard.corre@student-cs.fr",
#"arthur.groussin@student-cs.fr",
#"robin.charleuf@student-cs.fr",
#"thibault.rousset@student-cs.fr",
"mateo.dufresne-d-amico@student-cs.fr",
"arthur.besnault@student-cs.fr",
"louis.jacquemart@student-cs.fr",
......
File added
......@@ -29,7 +29,7 @@ DEBUG = True
ALLOWED_HOSTS = ["138.195.139.213", "localhost", "astegifetobegif.cs-campus.fr", "*"]
ALLOWED_HOSTS = ["138.195.139.213", "localhost", "astegifetobegif.cs-campus.fr", "*"]
# Application definition
......@@ -136,8 +136,8 @@ ENCRYPTED_COOKIE_KEYS = ['HZJSZGQU3fiJaG53Ha1jYZGZkxrqGDF3m-nZN3fhe46=']
SESSION_COOKIE_SECURE = False
EMAIL_HOST = 'smtp.gmail.com'
EMAIL_PORT = 465
EMAIL_PORT = 587
EMAIL_HOST_USER = 'stepgifimstuck@gmail.com'
EMAIL_HOST_PASSWORD = 'hotlineCrepesLeS'
EMAIL_USE_TLS = False
EMAIL_USE_SSL = True
\ No newline at end of file
EMAIL_USE_TLS = True
EMAIL_USE_SSL = False
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment