order persons view by tag name
This commit is contained in:
@@ -94,7 +94,7 @@ class PersonForm(FlaskForm):
|
|||||||
@app.route("/persons", methods=["GET"])
|
@app.route("/persons", methods=["GET"])
|
||||||
@login_required
|
@login_required
|
||||||
def persons():
|
def persons():
|
||||||
persons = Person.query.all()
|
persons = Person.query.order_by(Person.tag).all()
|
||||||
# get the num matches for each person too, and allow link for it
|
# get the num matches for each person too, and allow link for it
|
||||||
stats = list( db.session.execute( "select p.tag, count(f.id) from person p, face f, face_file_link ffl, face_refimg_link frl, person_refimg_link prl where p.id = prl.person_id and prl.refimg_id = frl.refimg_id and frl.face_id = ffl.face_id and ffl.face_id = f.id group by p.tag" ) )
|
stats = list( db.session.execute( "select p.tag, count(f.id) from person p, face f, face_file_link ffl, face_refimg_link frl, person_refimg_link prl where p.id = prl.person_id and prl.refimg_id = frl.refimg_id and frl.face_id = ffl.face_id and ffl.face_id = f.id group by p.tag" ) )
|
||||||
for p in persons:
|
for p in persons:
|
||||||
|
|||||||
Reference in New Issue
Block a user