mirror of
https://github.com/yawaflua/SusMarket.git
synced 2025-12-09 20:19:31 +02:00
залил
This commit is contained in:
@@ -1,6 +1,7 @@
|
|||||||
import hashlib
|
import hashlib
|
||||||
|
|
||||||
from django.http import JsonResponse, HttpRequest, HttpResponse
|
from django.http import JsonResponse, HttpRequest, HttpResponse
|
||||||
|
from django.views.decorators.csrf import csrf_exempt
|
||||||
from django.shortcuts import render
|
from django.shortcuts import render
|
||||||
|
|
||||||
from SusMarketBackend.models import Category, Product, Review, User
|
from SusMarketBackend.models import Category, Product, Review, User
|
||||||
@@ -34,6 +35,7 @@ def register_user(request: HttpRequest):
|
|||||||
return HttpResponse('{error: "You doing not right"}')
|
return HttpResponse('{error: "You doing not right"}')
|
||||||
|
|
||||||
|
|
||||||
|
@csrf_exempt
|
||||||
def post_review(request: HttpRequest):
|
def post_review(request: HttpRequest):
|
||||||
if request.method == "POST":
|
if request.method == "POST":
|
||||||
commentary = request.POST["commentary"]
|
commentary = request.POST["commentary"]
|
||||||
|
|||||||
Reference in New Issue
Block a user