db: add commit action after querying
Change-Id: Ibe39a9b999680cc1fba4eccd9fa2ed0fa41ccb00
This commit is contained in:
parent
83a525067d
commit
c59d54c427
|
@ -54,8 +54,11 @@ def find_all(model, **conditions):
|
||||||
|
|
||||||
def find_all_by_limit(query_func, model, conditions, limit, marker=None,
|
def find_all_by_limit(query_func, model, conditions, limit, marker=None,
|
||||||
marker_column=None):
|
marker_column=None):
|
||||||
return _limits(query_func, model, conditions, limit, marker,
|
query = _limits(query_func, model, conditions, limit, marker,
|
||||||
marker_column).all()
|
marker_column)
|
||||||
|
res = query.all()
|
||||||
|
query.session.commit()
|
||||||
|
return res
|
||||||
|
|
||||||
|
|
||||||
def find_by(model, **kwargs):
|
def find_by(model, **kwargs):
|
||||||
|
|
Loading…
Reference in New Issue