forked from kompetenzinventar/ki-backend
added model and migration for resume
This commit is contained in:
24
ki/resume.py
24
ki/resume.py
@ -1,7 +1,14 @@
|
||||
# SPDX-FileCopyrightText: WTF Kooperative eG <https://wtf-eg.de/>
|
||||
#
|
||||
# SPDX-License-Identifier: AGPL-3.0-or-later
|
||||
|
||||
from flask import Blueprint
|
||||
from ki.token_auth import token_auth
|
||||
from ki.resume_models import Resume
|
||||
|
||||
bp_resume = Blueprint('resume', __name__,
|
||||
template_folder='templates')
|
||||
template_folder='templates')
|
||||
|
||||
|
||||
@bp_resume.route('/')
|
||||
@token_auth
|
||||
@ -9,20 +16,17 @@ def show(page):
|
||||
"""
|
||||
return the list of resumes as object with data array inside
|
||||
"""
|
||||
return jsonify()
|
||||
pass
|
||||
|
||||
|
||||
@bp_resume.route("/<resume_id>")
|
||||
@token_auth
|
||||
def get_resume(resume_id):
|
||||
"""
|
||||
lookup for resume with resume_id, check if its from this user and provide its contents
|
||||
in the appropriate format
|
||||
lookup for resume with resume_id, check if its from this user
|
||||
and provide its contents in the appropriate format
|
||||
shall support 'format' parameter with values of 'html', 'pdf'
|
||||
if no parameter is given, json is returned
|
||||
"""
|
||||
return jsonify(
|
||||
id=resume_id
|
||||
)
|
||||
|
||||
|
||||
|
||||
r = Resume()
|
||||
return r.to_dict()
|
||||
|
Reference in New Issue
Block a user