Fix preislister config
This commit is contained in:
parent
00d4c81b28
commit
c7a140843d
|
@ -15,6 +15,7 @@ import shutil
|
||||||
sys.path.insert(0, '../client-barcode') # TODO
|
sys.path.insert(0, '../client-barcode') # TODO
|
||||||
from freitagslib.network import _request
|
from freitagslib.network import _request
|
||||||
from freitagslib.item import Item
|
from freitagslib.item import Item
|
||||||
|
from freitagslib.settings import settings, Settings
|
||||||
|
|
||||||
|
|
||||||
_NAME_BLACKLIST = ('foo', )
|
_NAME_BLACKLIST = ('foo', )
|
||||||
|
@ -38,6 +39,9 @@ if __name__ == '__main__':
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
output_filename = sys.argv[1]
|
output_filename = sys.argv[1]
|
||||||
|
|
||||||
|
if not settings.load('../client-barcode/freitagskasse.conf'):
|
||||||
|
sys.exit(1)
|
||||||
|
|
||||||
content = _request('buyable/item/', None, method='GET')
|
content = _request('buyable/item/', None, method='GET')
|
||||||
doc = json.loads(content)
|
doc = json.loads(content)
|
||||||
items = [Item(e) for e in doc]
|
items = [Item(e) for e in doc]
|
||||||
|
|
Loading…
Reference in New Issue