mirror of
https://github.com/Manuel83/craftbeerpi3
synced 2026-08-09 18:52:40 +02:00
- Import KBH
- Import BeerXML - Import REST API - Migration DB - Set Default Screen after Start - Cleanup
This commit is contained in:
@@ -24,11 +24,9 @@ class ConfigView(BaseView):
|
||||
update_data = {"name": data["name"], "value": data["value"]}
|
||||
|
||||
if self.api.cache.get(self.cache_key) is not None:
|
||||
#self.pre_post_callback(self.api.cache.get(self.cache_key)[name])
|
||||
print self.api.cache.get(self.cache_key)[name]
|
||||
self.api.cache.get(self.cache_key)[name].__dict__.update(**update_data)
|
||||
m = self.model.update(**self.api.cache.get(self.cache_key)[name].__dict__)
|
||||
self.post_put_callback(self.api.cache.get(self.cache_key)[name])
|
||||
self._post_put_callback(self.api.cache.get(self.cache_key)[name])
|
||||
return json.dumps(self.api.cache.get(self.cache_key)[name].__dict__)
|
||||
|
||||
@route('/<id>', methods=["GET"])
|
||||
@@ -54,6 +52,6 @@ class ConfigView(BaseView):
|
||||
|
||||
@cbpi.initalizer(order=1)
|
||||
def init(cbpi):
|
||||
print "INITIALIZE CONFIG MODULE"
|
||||
|
||||
ConfigView.register(cbpi.app, route_base='/api/config')
|
||||
ConfigView.init_cache()
|
||||
|
||||
Reference in New Issue
Block a user