Skip to content

Commit

Permalink
Revert "Allow user format option"
Browse files Browse the repository at this point in the history
This reverts commit 45035a0.
  • Loading branch information
DaveSch-gramps committed Oct 9, 2023
1 parent 45035a0 commit 3360b13
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 11 deletions.
8 changes: 4 additions & 4 deletions gramps/plugins/webreport/basepage.py
Original file line number Diff line number Diff line change
Expand Up @@ -949,7 +949,7 @@ def append_to_place_lat_long(self, place, event, place_lat_long):
data[3] == place_handle and data[4] == event_date for data in place_lat_long
)
if not found:
placetitle = _pd.display(self.r_db, place)
placetitle = _pd.display(self.r_db, place, fmt=0)
latitude = place.get_latitude()
longitude = place.get_longitude()
if latitude and longitude:
Expand Down Expand Up @@ -1085,7 +1085,7 @@ def get_event_data(self, evt, evt_ref, uplink, gid=None):

place_hyper = None
if place:
place_name = _pd.display(self.r_db, place, evt.get_date_object())
place_name = _pd.display(self.r_db, place, evt.get_date_object(), fmt=0)
place_hyper = self.place_link(place_handle, place_name, uplink=uplink)

evt_desc = evt.get_description()
Expand Down Expand Up @@ -1157,7 +1157,7 @@ def dump_ordinance(self, ldsobj, ldssealedtype, toggle=True):
if place_handle:
place = self.r_db.get_place_from_handle(place_handle)
if place:
place_title = _pd.display(self.r_db, place)
place_title = _pd.display(self.r_db, place, fmt=0)
place_hyper = self.place_link(
place_handle,
place_title,
Expand Down Expand Up @@ -2307,7 +2307,7 @@ def media_ref_rect_regions(self, handle, linkurl=True):
_linkurl = self.report.build_url_fname_html(_obj.handle, "evt", True)
elif classname == "Place":
_obj = self.r_db.get_place_from_handle(newhandle)
_name = _pd.display(self.r_db, _obj)
_name = _pd.display(self.r_db, _obj, fmt=0)
if not _name:
_name = self._("Unknown")
_linkurl = self.report.build_url_fname_html(newhandle, "plc", True)
Expand Down
4 changes: 2 additions & 2 deletions gramps/plugins/webreport/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -539,8 +539,8 @@ def sort_places(dbase, handle_list, rlocale=glocale):
else:
continue
place = dbase.get_place_from_handle(hdle)
pname = _pd.display(dbase, place)
apname = _pd.display_event(dbase, event)
pname = _pd.display(dbase, place, fmt=0)
apname = _pd.display_event(dbase, event, fmt=0)

pname_sub[pname].append(hdle)
pname_sub[apname].append((hdle, pname, cname, sname))
Expand Down
2 changes: 1 addition & 1 deletion gramps/plugins/webreport/narrativeweb.py
Original file line number Diff line number Diff line change
Expand Up @@ -1003,7 +1003,7 @@ def _add_place(self, place_handle, bkref_class, bkref_handle, event):
else:
name = ""
if config.get("preferences.place-auto"):
place_name = _pd.display_event(self._db, event)
place_name = _pd.display_event(self._db, event, fmt=0)
if event:
cplace_name = place_name.split()[-1]
if len(place_name.split()) > 1:
Expand Down
4 changes: 2 additions & 2 deletions gramps/plugins/webreport/person.py
Original file line number Diff line number Diff line change
Expand Up @@ -1841,14 +1841,14 @@ def display_ind_general(self):
birth = self.r_db.get_event_from_handle(birth_ref.ref)
if birth:
birth_date = birth.get_date_object()
p_birth = _pd.display_event(self.r_db, birth)
p_birth = _pd.display_event(self.r_db, birth, fmt=0)

death_ref = self.person.get_death_ref()
p_death = ""
if death_ref:
death = self.r_db.get_event_from_handle(death_ref.ref)
if death:
p_death = _pd.display_event(self.r_db, death)
p_death = _pd.display_event(self.r_db, death, fmt=0)

death_date = _find_death_date(self.r_db, self.person)
if birth_date and birth_date is not Date.EMPTY:
Expand Down
4 changes: 2 additions & 2 deletions gramps/plugins/webreport/place.py
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ def display_pages(self, the_lang, the_title):
p_fname += self.ext
plc_dict = (p_fname, place_name, place.gramps_id, None)
self.report.obj_dict[Place][place_ref] = plc_dict
p_name = _pd.display(self.r_db, place)
p_name = _pd.display(self.r_db, place, fmt=0)
cplace_name = p_name.split()[-1]
if len(place_name.split()) > 1:
splace_name = place_name.split()[-2]
Expand Down Expand Up @@ -430,7 +430,7 @@ def placepage(self, report, the_lang, the_title, place_handle, place_name):
BasePage.__init__(self, report, the_lang, the_title, place.get_gramps_id())
self.bibli = Bibliography()
ldatec = place.get_change_time()
apname = _pd.display(self.r_db, place)
apname = _pd.display(self.r_db, place, fmt=0)

# if place_name: # != apname: # store only the primary named page
output_file, sio = self.report.create_file(place_handle, "plc")
Expand Down

0 comments on commit 3360b13

Please sign in to comment.