mirror of
https://github.com/yweber/lodel2.git
synced 2026-07-09 00:40:49 +02:00
[#61] Added the return as a dict in the get method of LeDataSource
This commit is contained in:
parent
89b13c5d91
commit
765a4e5830
1 changed files with 3 additions and 3 deletions
|
|
@ -1,7 +1,7 @@
|
|||
#-*- coding: utf-8 -*-
|
||||
|
||||
from ledatasource import LeDataSource
|
||||
from mosql.db import Database
|
||||
from mosql.db import Database, all_to_dicts
|
||||
from mosql.query import select
|
||||
|
||||
from Lodel.utils.mosql import *
|
||||
|
|
@ -23,11 +23,11 @@ class LeDataSourceSQL(LeDataSource):
|
|||
class_name = emclass.name
|
||||
type_name = emtype.name
|
||||
|
||||
tablename = ""
|
||||
tablename = "" # TODO
|
||||
where_filters = self._prepare_filters(filters)
|
||||
query = select(tablename, where=where_filters, select=field_list)
|
||||
self.db.execute(query)
|
||||
pass
|
||||
return all_to_dicts(self.db)
|
||||
|
||||
def _prepare_filters(self, filters):
|
||||
prepared_filters = {}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue