{"action":"closed","issue":{"url":"https://api.github.com/repos/fisharebest/webtrees/issues/1153","repository_url":"https://api.github.com/repos/fisharebest/webtrees","labels_url":"https://api.github.com/repos/fisharebest/webtrees/issues/1153/labels{/name}","comments_url":"https://api.github.com/repos/fisharebest/webtrees/issues/1153/comments","events_url":"https://api.github.com/repos/fisharebest/webtrees/issues/1153/events","html_url":"https://github.com/fisharebest/webtrees/issues/1153","id":197623881,"number":1153,"title":"FTB Compatibility Problems","user":{"login":"miqrogroove","id":1371835,"avatar_url":"https://avatars.githubusercontent.com/u/1371835?v=3","gravatar_id":"","url":"https://api.github.com/users/miqrogroove","html_url":"https://github.com/miqrogroove","followers_url":"https://api.github.com/users/miqrogroove/followers","following_url":"https://api.github.com/users/miqrogroove/following{/other_user}","gists_url":"https://api.github.com/users/miqrogroove/gists{/gist_id}","starred_url":"https://api.github.com/users/miqrogroove/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/miqrogroove/subscriptions","organizations_url":"https://api.github.com/users/miqrogroove/orgs","repos_url":"https://api.github.com/users/miqrogroove/repos","events_url":"https://api.github.com/users/miqrogroove/events{/privacy}","received_events_url":"https://api.github.com/users/miqrogroove/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2016-12-26T22:29:11Z","updated_at":"2016-12-29T17:09:55Z","closed_at":"2016-12-29T17:09:55Z","body":"When importing GEDCOM produced by FTB, some of the built-in fields don't show up in webtrees.  I've needed the following hacks so far, and I hope some or all of them can be incorporated into the official code.\r\n\r\nIn GedcomTag.php:\r\n```\r\n\t\tcase '_ALBUM':\r\n\t\t\treturn 'Album ID number';  //For grouping photos.\r\n\t\tcase '_COMPLETE':\r\n\t\t\treturn 'Research is complete';  //Can be 'Y' for individuals.\r\n\t\tcase '_DATE':\r\n\t\t\treturn I18N::translate('Date');  //For photos.\r\n\t\tcase '_FILESIZE':\r\n\t\t\treturn I18N::translate('File size');  //Photo size in bytes.\r\n\t\tcase '_FORMERNAME':\r\n\t\t\treturn 'Former last name';  //For individuals (names)\r\n\t\tcase '_PHOTO_RIN':\r\n\t\t\treturn 'Photo record ID';\r\n\t\tcase '_PLACE':\r\n\t\t\treturn I18N::translate('Place');  //For photos.\r\n\t\tcase '_RNAME':\r\n\t\t\treturn 'Religious name';  //For individuals (names)\r\n\t\tcase '_UPD':\r\n\t\t\treturn 'Last Update';  //Date and time for individuals and family records.\r\n```\r\n\r\nIn medialist.php to show Date and Place for each photo:\r\n```\r\n\t\t\t\tif ($mediaobject->fileExists()) {\r\n\t\t\t\t\t$facts = $mediaobject->getFacts();\r\n\t\t\t\t\tforeach ($facts as $fact) {\r\n\t\t\t\t\t\t$type = $fact->getTag();\r\n\t\t\t\t\t\tif ('_PLACE' == $type or '_DATE' == $type) {\r\n\t\t\t\t\t\t\techo GedcomTag::getLabelValue($type, $fact->getValue());\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\r\n```\r\n\r\nin FunctionsPrintFacts::printMainMedia() to show Date and Place for each photo:\r\n\r\n```\r\n\t\t\t\t\t$facts = $media->getFacts();\r\n\t\t\t\t\tforeach ($facts as $fact) {\r\n\t\t\t\t\t\t$type = $fact->getTag();\r\n\t\t\t\t\t\tif ('_PLACE' == $type or '_DATE' == $type) {\r\n\t\t\t\t\t\t\techo GedcomTag::getLabelValue($type, $fact->getValue());\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\techo GedcomTag::getLabelValue('FORM', $media->mimeType());\r\n```\r\n\r\nI've also hacked medialist.php and QueryMedia.php to allow searching by album name, but that was previously discussed and rejected for webtrees."}}
{"actor":{"display_login":"fisharebest"}}