wtoolzargs contains core filtering and ordering logic for web applications.
Project description
wtoolzargs
wtoolzargs contains core filtering and ordering logic for web applications
Installation | Getting Up And Running | Examples | API | See Also
wtoolzargs contains core filtering and ordering logic for web applications. The main feature are:
-
Filtering and
-
ordering for SQLAlchemy models.
Installation
pip install wtoolzargs
Getting Up and Running
nox -l
Examples
import wtoolzargs
# sqlalchemy model
class Hacker(Base):
__tablename__ = "hacker"
id = Column(Integer, primary_key=True)
a = Column(String)
b = Column(String)
c = Column(String)
d = Column(String)
e = Column(String)
f = wtoolzargs.filter_(Hacker, "a eq 'a' and b eq 'b'")
res = Hacker.query.filter(f).all()
o = wtoolzargs.order(Hacker, "a asc, b desc")
res = Hacker.query.filter(f).order_by(*o).all()
API
FIXME
See Also
FIXME
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
wtoolzargs-0.1.0.tar.gz
(8.2 kB
view hashes)