app/soc/logic/models/base.py
changeset 2161 3b5e0e0880cd
parent 2030 a21ee5f0591d
child 2190 399fc9411abc
equal deleted inserted replaced
2160:3f9dd37d98a8 2161:3b5e0e0880cd
   174     The default implementation uses the scope and link_id as key values.
   174     The default implementation uses the scope and link_id as key values.
   175     """
   175     """
   176 
   176 
   177     return ['scope_path', 'link_id']
   177     return ['scope_path', 'link_id']
   178 
   178 
   179   def getKeySuffix(self, entity):
       
   180     """Returns a suffix for the specified entity or None if no entity specified.
       
   181 
       
   182     Args:
       
   183       entity: the entity for which to get the suffix
       
   184     """
       
   185 
       
   186     if not entity:
       
   187       return None
       
   188 
       
   189     key_values = self.getKeyValuesFromEntity(entity)
       
   190     suffix = '/'.join(key_values)
       
   191 
       
   192     return suffix
       
   193 
       
   194   def getKeyFieldsFromFields(self, dictionary):
   179   def getKeyFieldsFromFields(self, dictionary):
   195     """Does any required massaging and filtering of dictionary.
   180     """Does any required massaging and filtering of dictionary.
   196 
   181 
   197     The resulting dictionary contains just the key names, and has any
   182     The resulting dictionary contains just the key names, and has any
   198     required translations/modifications performed.
   183     required translations/modifications performed.