X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=sfa%2Fstorage%2Fmodel.py;h=e490251b459da10f1a94a3fc0831a4c6483f9045;hb=867d1db7373df4a85422e2461866c98ad362b711;hp=972040e61e7450ed80ac186b376109e1bc7df921;hpb=e01e525da053decb1a69c85eae79512709d89f1d;p=sfa.git diff --git a/sfa/storage/model.py b/sfa/storage/model.py index 972040e6..e490251b 100644 --- a/sfa/storage/model.py +++ b/sfa/storage/model.py @@ -316,9 +316,11 @@ class SliverAllocation(Base,AlchemyObj): sliver_id = Column(String, primary_key=True) allocation_state = Column(String) - def __init__(self, sliver_id, allocation_state): - self.sliver_id = sliver_id - self.allocation_state = allocation_state + def __init__(self, **kwds): + if 'sliver_id' in kwds: + self.sliver_id = kwds['sliver_id'] + if 'allocation_state' in kwds: + self.allocation_state = kwds['allocation_state'] def __repr__(self): result = "