eve

Combination of two fields to be unique in Python Eve

Combination of two fields to be unique in Python Eve Question: In Python Eve framework, is it possible to have a condition which checks combination of two fields to be unique? For example the below definition restricts only firstname and lastname to be unique for items in the resource. people = { # ‘title’ tag …

Total answers: 3

How to add to a list type in Python Eve without replacing old values

How to add to a list type in Python Eve without replacing old values Question: I have a very similar setup to the person in this question: How do I update a list data_relation in Python Eve with a users resource and a friends sub-resource of list type. users = { … ‘friends’: { ‘type’: …

Total answers: 3

Is there url_for() in eve?

Is there url_for() in eve? Question: We know in Flask, there is url_for() for endpoint, like url_for(‘edit’, _external=True) I what to ask what’s the best practice in python eve ? Asked By: Gladuo || Source Answers: Since eve is Flask application url_for works well. e.g. $ python manage.py shell In [1]: from flask import url_for …

Total answers: 1