/webtrees/app/Date/ |
H A D | AbstractCalendarDate.php | 87 $this->minimum_julian_day = $date; 88 $this->maximum_julian_day = $date; 89 [$this->year, $this->month, $this->day] = $this->calendar->jdToYmd($date); 96 $this->day = (int) $date[2]; 97 $this->month = static::MONTH_TO_NUMBER[$date[1]] ?? 0; 99 if ($this->month === 0) { 100 $this->day = 0; 103 $this->year = $this->extractYear($date[0]); 106 …if ($this->month === 6 && $this->calendar instanceof JewishCalendar && !$this->calendar->isLeapYea… 107 $this->month = 7; [all …]
|
/webtrees/app/Report/ |
H A D | ReportParserGenerate.php | 196 $this->report = $report; 197 $this->report_root = $report_root; 198 $this->wt_report = $report_root; 199 $this->current_element = new ReportBaseElement(); 200 $this->vars = $vars; 201 $this->tree = $tree; 305 … if (isset($this->vars[$match[1]]['id']) && !isset($this->vars[$match[1]]['gedcom'])) { 306 $value = $this->vars[$match[1]]['id']; 312 …if ($this->process_footnote && ($this->process_ifs === 0 || $name === 'if') && ($this->process_ged… 315 if (method_exists($this, $method)) { [all …]
|
H A D | PdfRenderer.php | 77 foreach ($this->headerElements as $element) { 79 $element->render($this); 81 $this->footnotes(); 83 $this->newPage(); 95 $this->tcpdf->AddPage(); 97 foreach ($this->bodyElements as $element) { 99 $element->render($this); 101 $this->footnotes(); 103 $this->newPage(); 115 foreach ($this->printedfootnotes as $element) { [all …]
|
H A D | HtmlRenderer.php | 97 if ($this->orientation === 'landscape') { 98 $tmpw = $this->page_width; 99 $this->page_width = $this->page_height; 100 $this->page_height = $tmpw; 103 $this->noMarginWidth = $this->page_width - $this->left_margin - $this->right_margin; 105 if ($this->rtl) { 106 $this->alignRTL = 'right'; 107 $this->entityRTL = '‏'; 110 $this->default_font = 'Arial'; 112 if ($this->show_generated_by) { [all …]
|
H A D | ReportHtmlCell.php | 39 if (str_contains($this->text, '{{:ptp:}}')) { 42 $temptext = str_replace('#PAGENUM#', (string) $renderer->pageNo(), $this->text); 53 if ($renderer->getCurrentStyle() !== $this->styleName) { 54 $renderer->setCurrentStyle($this->styleName); 61 if ($this->left === ReportBaseElement::CURRENT_POSITION) { 62 $this->left = $renderer->getX(); 64 $renderer->setX($this->left); 67 if ($this->top === ReportBaseElement::CURRENT_POSITION) { 68 $this->top = $renderer->getY(); 70 $renderer->setY($this->top); [all …]
|
/webtrees/app/ |
H A D | Statistics.php | 147 $this->tree = $tree; 148 $this->gedcom_repository = new GedcomRepository($tree); 149 …$this->individual_repository = new IndividualRepository($century_service, $color_service, $tree); 150 … $this->family_repository = new FamilyRepository($century_service, $color_service, $tree); 151 $this->family_dates_repository = new FamilyDatesRepository($tree); 152 $this->media_repository = new MediaRepository($color_service, $tree); 153 $this->event_repository = new EventRepository($tree); 154 $this->user_repository = new UserRepository($tree, $user_service); 155 $this->server_repository = new ServerRepository(); 156 $this->browser_repository = new BrowserRepository(); [all …]
|
H A D | GedcomRecord.php | 106 $this->xref = $xref; 107 $this->gedcom = $gedcom; 108 $this->pending = $pending; 109 $this->tree = $tree; 110 $this->facts = $this->parseFacts(); 166 preg_match('/^0 @[^@]*@ (\w+)/', $this->gedcom(), $match); 178 return $this->xref; 188 return $this->tree; 199 return $this->pending ?? $this->gedcom; 209 return $this->pending !== null; [all …]
|
H A D | Fact.php | 187 $this->gedcom = $gedcom; 188 $this->record = $parent; 189 $this->id = $id; 190 $this->tag = $match[1]; 204 if (preg_match('/^1 ' . $this->tag . ' ?(.*(?:\n2 CONT ?.*)*)/', $this->gedcom, $match)) { 207 return Registry::elementFactory()->make($this->tag())->canonical($value); 220 if (!preg_match('/^@(' . Gedcom::REGEX_XREF . ')@$/', $this->value(), $match)) { 226 switch ($this->tag) { 229 return Registry::familyFactory()->make($xref, $this->record->tree()); 235 return Registry::individualFactory()->make($xref, $this->record->tree()); [all …]
|
H A D | Timestamp.php | 37 $this->carbon = CarbonImmutable::createFromTimestamp($timestamp, $timezone); 38 $this->carbon->locale($locale); 43 $this->carbon = clone($this->carbon); 48 return gregoriantojd($this->carbon->month, $this->carbon->day, $this->carbon->year); 53 return $this->carbon->diffForHumans(); 58 return $this->carbon->format($format); 63 return $this->carbon->isoFormat($format); 68 return $this->carbon->format('Y-m-d'); 73 return $this->carbon->format('Y-m-d H:i:s'); 78 return $this->timestamp() <=> $timestamp->timestamp(); [all …]
|
H A D | Individual.php | 83 $access_level ??= Auth::accessLevel($this->tree); 85 …return (int) $this->tree->getPreference('SHOW_LIVING_NAMES') >= $access_level || $this->canShow($a… 98 … if ((int) $this->tree->getPreference('SHOW_DEAD_PEOPLE') >= $access_level && $this->isDead()) { 100 $KEEP_ALIVE_YEARS_BIRTH = (int) $this->tree->getPreference('KEEP_ALIVE_YEARS_BIRTH'); 102 … implode('|', Gedcom::BIRTH_EVENTS) . ').*(?:\n[2-9].*)*\n2 DATE (.+)/', $this->gedcom, $matches, … 111 $KEEP_ALIVE_YEARS_DEATH = (int) $this->tree->getPreference('KEEP_ALIVE_YEARS_DEATH'); 113 … implode('|', Gedcom::DEATH_EVENTS) . ').*(?:\n[2-9].*)*\n2 DATE (.+)/', $this->gedcom, $matches, … 127 …$user_path_length = (int) $this->tree->getUserPreference(Auth::user(), UserInterface::PREF_TREE_PA… 128 …$gedcomid = $this->tree->getUserPreference(Auth::user(), UserInterface::PREF_TREE_ACCOUNT_… 131 return self::isRelated($this, $user_path_length); [all …]
|
H A D | Tree.php | 126 $this->id = $id; 127 $this->name = $name; 128 $this->title = $title; 129 $this->fact_privacy = []; 130 $this->individual_privacy = []; 131 $this->individual_fact_privacy = []; 135 ->where('gedcom_id', '=', $this->id) 144 $this->individual_fact_privacy[$row->xref][$row->tag_type] = $row->resn; 146 $this->individual_privacy[$row->xref] = $row->resn; 149 $this->fact_privacy[$row->tag_type] = $row->resn; [all …]
|
H A D | MediaFile.php | 78 $this->media = $media; 79 $this->fact_id = md5($gedcom); 82 $this->multimedia_file_refn = $match[1]; 86 $this->multimedia_format = $match[1]; 90 $this->source_media_type = $match[1]; 94 $this->descriptive_title = $match[1]; 105 return $this->multimedia_format; 115 return $this->source_media_type; 125 return $this->descriptive_title; 135 return $this->fact_id; [all …]
|
/webtrees/app/Statistics/Repository/ |
H A D | IndividualRepository.php | 82 $this->century_service = $century_service; 83 $this->color_service = $color_service; 84 $this->tree = $tree; 106 ->where('n_file', '=', $this->tree->id()) 192 return $this->commonGivenQuery('B', 'nolist', false, $threshold, $maxtoshow); 205 return $this->commonGivenQuery('B', 'nolist', true, $threshold, $maxtoshow); 218 return $this->commonGivenQuery('B', 'list', false, $threshold, $maxtoshow); 231 return $this->commonGivenQuery('B', 'list', true, $threshold, $maxtoshow); 244 return $this->commonGivenQuery('B', 'table', false, $threshold, $maxtoshow); 257 return $this->commonGivenQuery('F', 'nolist', false, $threshold, $maxtoshow); [all …]
|
H A D | FamilyRepository.php | 69 $this->century_service = $century_service; 70 $this->color_service = $color_service; 71 $this->tree = $tree; 84 ->where('f_file', '=', $this->tree->id()) 92 $family = Registry::familyFactory()->mapper($this->tree)($row); 118 return $this->familyQuery('full'); 128 return $this->familyQuery('size'); 138 return $this->familyQuery('name'); 167 ->where('f_file', '=', $this->tree->id()) 173 ->map(Registry::familyFactory()->mapper($this->tree)) [all …]
|
/webtrees/app/Census/ |
H A D | CensusOfUnitedStates1830.php | 45 new CensusColumnFullName($this, 'Name', 'Name of head of family'), 46 new CensusColumnNull($this, 'M0', 'Free white males 0-5 years'), 47 new CensusColumnNull($this, 'M5', 'Free white males 5-10 years'), 48 new CensusColumnNull($this, 'M10', 'Free white males 10-15 years'), 49 new CensusColumnNull($this, 'M15', 'Free white males 15-20 years'), 50 new CensusColumnNull($this, 'M20', 'Free white males 20-30 years'), 51 new CensusColumnNull($this, 'M30', 'Free white males 30-40 years'), 52 new CensusColumnNull($this, 'M40', 'Free white males 40-50 years'), 53 new CensusColumnNull($this, 'M50', 'Free white males 50-60 years'), 54 new CensusColumnNull($this, 'M60', 'Free white males 60-70 years'), [all …]
|
H A D | CensusOfUnitedStates1840.php | 45 new CensusColumnFullName($this, 'Name', 'Name of head of family'), 46 new CensusColumnNull($this, 'M0', 'Free white males 0-5 years'), 47 new CensusColumnNull($this, 'M5', 'Free white males 5-10 years'), 48 new CensusColumnNull($this, 'M10', 'Free white males 10-15 years'), 49 new CensusColumnNull($this, 'M15', 'Free white males 15-20 years'), 50 new CensusColumnNull($this, 'M20', 'Free white males 20-30 years'), 51 new CensusColumnNull($this, 'M30', 'Free white males 30-40 years'), 52 new CensusColumnNull($this, 'M40', 'Free white males 40-50 years'), 53 new CensusColumnNull($this, 'M50', 'Free white males 50-60 years'), 54 new CensusColumnNull($this, 'M60', 'Free white males 60-70 years'), [all …]
|
H A D | CensusOfCanada1931.php | 45 …new CensusColumnFullName($this, 'Name', 'Name of each person in family, household or institution'), 46 …new CensusColumnNull($this, 'Place of Abode', 'In rural localities give parish or township. In cit… 47 new CensusColumnNull($this, 'Own/Rent', 'Home owned or rented'), 48 … new CensusColumnNull($this, 'Value', 'If Owned give value. If rented, give rent paid per month'), 49 …new CensusColumnNull($this, 'Class', 'Class of House: Apartment, Row or Terrace, Single house, Sem… 50 …new CensusColumnNull($this, 'Materials', 'Material of Construction: Stone, Brick, Wood, Brick Vene… 51 new CensusColumnNull($this, 'Rooms', 'Rooms occupied by this family'), 52 new CensusColumnNull($this, 'Radio', 'Has this family a radio?'), 53 …new CensusColumnRelationToHeadEnglish($this, 'Relation', 'Relationship to Head of Family or househ… 54 new CensusColumnSexMF($this, 'Sex', 'Sex'), [all …]
|
H A D | CensusOfCanada1911.php | 45 …new CensusColumnFullName($this, 'Name', 'Name of each person in family, household or institution'), 46 new CensusColumnNull($this, 'Address', 'Place of Habitation'), 47 new CensusColumnSexMF($this, 'Sex', 'Sex'), 48 …new CensusColumnRelationToHeadEnglish($this, 'Relation', 'Relationship to Head of Family or househ… 49 …new CensusColumnConditionCanada($this, 'S/M/W/D/L', 'Single, Married, Widowed, Divorced or Legally… 50 new CensusColumnBirthMonth($this, 'Month', 'Month of birth'), 51 new CensusColumnBirthYear($this, 'Year', 'Year of birth'), 52 new CensusColumnAge($this, 'Age', 'Age at last birthday - on June 1, 1911'), 53 new CensusColumnBirthPlaceSimple($this, 'Birth Loc', 'Country or Place of Birth'), 54 … new CensusColumnNull($this, 'Yr. immigrated', 'Year of immigration to Canada, if an immigrant'), [all …]
|
/webtrees/app/Http/RequestHandlers/ |
H A D | ControlPanel.php | 116 $this->admin_service = $admin_service; 117 $this->housekeeping_service = $housekeeping_service; 118 $this->message_service = $message_service; 119 $this->module_service = $module_service; 120 $this->server_check_service = $server_check_service; 121 $this->tree_service = $tree_service; 122 $this->upgrade_service = $upgrade_service; 123 $this->user_service = $user_service; 133 $this->layout = 'layouts/administration'; 136 $files_to_delete = $this->housekeeping_service->deleteOldWebtreesFiles($filesystem); [all …]
|
/webtrees/tests/app/SurnameTradition/ |
H A D | LithuanianSurnameTraditionTest.php | 41 $this->surname_tradition = new LithuanianSurnameTradition(); 49 self::assertSame('//', $this->surname_tradition->defaultName()); 57 $father_fact = $this->createMock(Fact::class); 60 $father = $this->createMock(Individual::class); 63 $mother_fact = $this->createMock(Fact::class); 66 $mother = $this->createMock(Individual::class); 71 $this->surname_tradition->newChildNames($father, $mother, 'M') 80 $father_fact = $this->createMock(Fact::class); 83 $father = $this->createMock(Individual::class); 86 $mother_fact = $this->createMock(Fact::class); [all …]
|
H A D | PolishSurnameTraditionTest.php | 39 self::assertSame('//', $this->surname_tradition->defaultName()); 47 $father_fact = $this->createMock(Fact::class); 50 $father = $this->createMock(Individual::class); 53 $mother_fact = $this->createMock(Fact::class); 56 $mother = $this->createMock(Individual::class); 61 $this->surname_tradition->newChildNames($father, $mother, 'M') 70 $father_fact = $this->createMock(Fact::class); 73 $father = $this->createMock(Individual::class); 76 $mother_fact = $this->createMock(Fact::class); 79 $mother = $this->createMock(Individual::class); [all …]
|
H A D | PaternalSurnameTraditionTest.php | 38 self::assertSame('//', $this->surname_tradition->defaultName()); 46 $father_fact = $this->createMock(Fact::class); 49 $father = $this->createMock(Individual::class); 52 $mother_fact = $this->createMock(Fact::class); 55 $mother = $this->createMock(Individual::class); 60 $this->surname_tradition->newChildNames($father, $mother, 'M') 65 $this->surname_tradition->newChildNames($father, $mother, 'F') 70 $this->surname_tradition->newChildNames($father, $mother, 'U') 79 $father_fact = $this->createMock(Fact::class); 82 $father = $this->createMock(Individual::class); [all …]
|
/webtrees/tests/app/Census/ |
H A D | CensusColumnBornForeignPartsTest.php | 36 $placeMock = $this->createMock(Place::class); 45 $individual = $this->createMock(Individual::class); 46 $individual->method('getBirthPlace')->willReturn($this->getPlaceMock('London, England')); 48 $census = $this->createMock(CensusInterface::class); 58 $individual = $this->createMock(Individual::class); 59 $individual->method('getBirthPlace')->willReturn($this->getPlaceMock('Cardiff, Wales')); 61 $census = $this->createMock(CensusInterface::class); 71 $individual = $this->createMock(Individual::class); 72 … $individual->method('getBirthPlace')->willReturn($this->getPlaceMock('Edinburgh, Scotland')); 74 $census = $this->createMock(CensusInterface::class); [all …]
|
/webtrees/app/Module/ |
H A D | SlideShowModule.php | 64 $this->linked_record_service = $linked_record_service; 86 $default_start = (bool) $this->getBlockSetting($block_id, 'start'); 87 $filter_links = $this->getBlockSetting($block_id, 'filter', self::LINK_ALL); 88 $controls = $this->getBlockSetting($block_id, 'controls', '1'); 92 … $this->getBlockSetting($block_id, 'filter_audio', '0') ? SourceMediaType::VALUE_AUDIO : null, 93 … $this->getBlockSetting($block_id, 'filter_book', '1') ? SourceMediaType::VALUE_BOOK : null, 94 … $this->getBlockSetting($block_id, 'filter_card', '1') ? SourceMediaType::VALUE_CARD : null, 95 …$this->getBlockSetting($block_id, 'filter_certificate', '1') ? SourceMediaType::VALUE_CERTIFICATE … 96 … $this->getBlockSetting($block_id, 'filter_coat', '1') ? SourceMediaType::VALUE_COAT : null, 97 …$this->getBlockSetting($block_id, 'filter_document', '1') ? SourceMediaType::VALUE_DOCUMENT : null, [all …]
|
H A D | FamilyTreeStatisticsModule.php | 58 $this->module_service = $module_service; 92 $show_last_update = $this->getBlockSetting($block_id, 'show_last_update', '1'); 93 $show_common_surnames = $this->getBlockSetting($block_id, 'show_common_surnames', '1'); 94 …$number_of_surnames = (int) $this->getBlockSetting($block_id, 'number_of_surnames', self::DEFAUL… 95 $stat_indi = $this->getBlockSetting($block_id, 'stat_indi', '1'); 96 $stat_fam = $this->getBlockSetting($block_id, 'stat_fam', '1'); 97 $stat_sour = $this->getBlockSetting($block_id, 'stat_sour', '1'); 98 $stat_media = $this->getBlockSetting($block_id, 'stat_media', '1'); 99 $stat_repo = $this->getBlockSetting($block_id, 'stat_repo', '1'); 100 $stat_surname = $this->getBlockSetting($block_id, 'stat_surname', '1'); [all …]
|