comparison sat/plugins/plugin_exp_list_of_interest.py @ 2936:782612c7854b

plugin list interests: add "namespace" in serialised data
author Goffi <goffi@goffi.org>
date Fri, 03 May 2019 20:44:55 +0200
parents 47df940738a7
children ef554aca3eb1
comparison
equal deleted inserted replaced
2935:4f600b4ae819 2936:782612c7854b
159 def _listInterestsSerialise(self, interests_data): 159 def _listInterestsSerialise(self, interests_data):
160 interests = [] 160 interests = []
161 for item_elt in interests_data[0]: 161 for item_elt in interests_data[0]:
162 interest_data = {} 162 interest_data = {}
163 interest_elt = item_elt.interest 163 interest_elt = item_elt.interest
164 if interest_elt.hasAttribute(u'namespace'):
165 interest_data[u'namespace'] = interest_elt.getAttribute(u'namespace')
164 if interest_elt.hasAttribute(u'name'): 166 if interest_elt.hasAttribute(u'name'):
165 interest_data[u'name'] = interest_elt.getAttribute(u'name') 167 interest_data[u'name'] = interest_elt.getAttribute(u'name')
166 if interest_elt.hasAttribute(u'thumb_url'): 168 if interest_elt.hasAttribute(u'thumb_url'):
167 interest_data[u'thumb_url'] = interest_elt.getAttribute(u'thumb_url') 169 interest_data[u'thumb_url'] = interest_elt.getAttribute(u'thumb_url')
168 elt = interest_elt.firstChildElement() 170 elt = interest_elt.firstChildElement()