diff options
author | Michael Wood <michael.g.wood@intel.com> | 2016-07-21 14:43:27 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-07-26 08:10:36 +0100 |
commit | ef627d0ab8f5cf2fc72005393e76047cb623ff3d (patch) | |
tree | ae0067545010621d688baea77197ec50c7db7acc /bitbake/lib/toaster/orm/models.py | |
parent | ffc78d329d6fed9ae9a0db470d30033069b42f8f (diff) | |
download | openembedded-core-contrib-ef627d0ab8f5cf2fc72005393e76047cb623ff3d.tar.gz |
bitbake: toaster: Replace references to LayerSource models
Replace references to the now deprecated layersource models across
Toaster with the new enums for layer source types.
(Bitbake rev: 48c09c62eb979d840132e58144f0d81ffee675b1)
Signed-off-by: Michael Wood <michael.g.wood@intel.com>
Signed-off-by: Elliot Smith <elliot.smith@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/toaster/orm/models.py')
-rw-r--r-- | bitbake/lib/toaster/orm/models.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/bitbake/lib/toaster/orm/models.py b/bitbake/lib/toaster/orm/models.py index 1daec9c25a..34ea28c270 100644 --- a/bitbake/lib/toaster/orm/models.py +++ b/bitbake/lib/toaster/orm/models.py @@ -1287,6 +1287,14 @@ class LayerSource(object): (TYPE_BUILD, "build"), ) + def types_dict(): + """ Turn the TYPES enums into a simple dictionary """ + dictionary = {} + for key in LayerSource.__dict__: + if "TYPE" in key: + dictionary[key] = getattr(LayerSource, key) + return dictionary + class Layer(models.Model): |