Update individuals in website

I’ve added images to the birth, death and mariage gallery and added the number of the certificate in description of the corresponding birth, death and mariage section. To get a good overview of what certicate I’m missing I want to edit gramps\plugins\webreport\person.py but I always get errors when I want to open the website part in Gramps. Probably because I’m trying to access another object.
Can anyone help me with this one please? I’m not very familiar with Python and the objects in Gramps …
What I want to accomplish is when I open individuals.html I get 3 extra columns with an icon when the certificate is added in the gallery with as alt-text the certificatenumber I added in the description.

What kind of error do you get ?

No errors for now but I don’t get any mediapaths. This is what I’ve added so far:
photolist = self.person.get_media_list()
if photolist:
photo_handle = photolist[0].get_reference_handle()
photo = self.r_db.get_media_from_handle(photo_handle)
fullpath = media_path_full(self.r_db, photo.get_path())
tcell = fullpath
else:
tcell = " "
samerow = True
trow += Html(“td”, class_=“ColumnName”,
inline=samerow) + tcell

I’m trying to get the filepaths of the media so I can check if it contains a certain string but first step is to get the filepaths and that does not work for now :slight_smile:
It fills my tcell with   for now.

Ok, I get something … whatever I put: photo.get_description, photo.get_path, … I always get the date of death

                for photo_ref in self.person.get_media_list():
                    photo = self.r_db.get_media_from_handle(photo_ref.ref)
                    if photo:
                        #media_list += event.get_media_list()
                        fullpath = media_path_full(self.r_db, photo.get_path())
                        tcell = fullpath
                    else:
                        tcell = " "
                samerow  = True
                trow += Html("td", class_="ColumnName",
                         inline=samerow) + tcell

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.