website contact
This commit is contained in:
@@ -13,7 +13,7 @@ from app.api.services import (
|
||||
SubscriptionsService,
|
||||
CommonDataService,
|
||||
OfficeCustomerService,
|
||||
GenerativesService, OfficeUsersService, OfficeTemplatesService, OfficeCountryService
|
||||
GenerativesService, OfficeUsersService, OfficeTemplatesService, OfficeCountryService, WebsiteService
|
||||
)
|
||||
from app.api.services.comments import CommentsService
|
||||
from app.models import Country
|
||||
@@ -391,6 +391,20 @@ def test_check():
|
||||
# response = ProductsService.process_request(data)
|
||||
return {"status": "ok"}, 200
|
||||
|
||||
# ======================================================
|
||||
@api.route('/website/contact', methods=['POST'])
|
||||
def website_contact():
|
||||
data = request.get_json()
|
||||
|
||||
# Save Website Contact Data
|
||||
result = WebsiteService.save_web_contact_data(data)
|
||||
|
||||
# # Check if result is a tuple (error response)
|
||||
# if isinstance(result, tuple):
|
||||
# return jsonify(result[0]), result[1]
|
||||
|
||||
return jsonify(result)
|
||||
|
||||
|
||||
# ======================================================
|
||||
@api.route('/office/login', methods=['POST'])
|
||||
|
||||
Reference in New Issue
Block a user