This commit is contained in:
Kenneth Kehl
2023-08-29 14:54:30 -07:00
parent 19dcd7a48b
commit 1ecb747c6d
588 changed files with 34091 additions and 23580 deletions
+8 -5
View File
@@ -7,12 +7,15 @@ from app.v2.templates import v2_templates_blueprint
from app.v2.templates.templates_schemas import get_all_template_request
@v2_templates_blueprint.route("", methods=['GET'])
@v2_templates_blueprint.route("", methods=["GET"])
def get_templates():
data = validate(request.args.to_dict(), get_all_template_request)
templates = templates_dao.dao_get_all_templates_for_service(authenticated_service.id, data.get('type'))
templates = templates_dao.dao_get_all_templates_for_service(
authenticated_service.id, data.get("type")
)
return jsonify(
templates=[template.serialize_for_v2() for template in templates]
), 200
return (
jsonify(templates=[template.serialize_for_v2() for template in templates]),
200,
)