Closed Jefferson49 closed 2 years ago
Further tests showed that the same applies to fathers also and it does not depend on the 2 SURN tag. All children with different names than the parent listed in the branches list seem to be shown as empty entries.
if her children do not have the same surname, the children of this mother are shown as empty list items in the Lists/Branches view.
By design, the branches list only shows individuals with the selected surname.
It shows "..." for children with with different surnames, so you can see where the family name disappears.
Unless I misunderstand you, this is working as intended.
When looking at the generated webtrees site for the first time, it looked very surprising to me and I tried to find a reason in my specific data. However, I now understand that it is intended and what is the logic behind it.
For my purposes, a configuration switch would be nice, in order to suppress children with different names. However, I can live with the current status and it is not a high priority.
I have added a CSS class wt-branch-split
to these individuals.
You can hide them using CSS in the control panel. .wt-branch-split { display:none; }
Thank you very much for this simple and good solution! I just tested it by copying the changed line of BranchesListModule.php to my 2.0.19 file and also by putting the CSS code into my custom theme. Afterwards, the empty children do not show up any more. Great!
I have installed 2.1 beta 2 and tried the same theme and CSS like in 2.0, which contains ".wt-branch-split { display:none; }". However, it seems that the "empty" branches do not hide in the 2.1 beta environment.
Like mentioned above, I had copied the changed line of BranchesListModule.php with the additional "wt-branch-split" class to the 2.0 code and it worked fine within 2.0.
Do I need to adjust something in the CSS of the theme or change some code in the theme to use it in 2.1? At the moment, I have just copied my 2.0 theme into the 2.1 beta environment.
It works for me.
Can you post a URL where I can see this?
For testing purposes, I installed 2.1 beta 2 on my Synology NAS and observed the described issue in this environment. In order to provide a public URL to you, I copied the 2.1 beta 2 installation as a 1:1 copy to my web site. Surprisingly, the CSS code works in this environment without any problems. Therefore, it is not an 2.1 issue. Further testing also showed that the ".wt-branch-split { display:none; }" CSS code does not work with 2.0 on the Synology NAS either. Therefore, the issue seems to be related to the NAS server configuration.
The NAS configuration is as follows. Due to the Synology environment, I have no root access:
The background would be interesting to understand. However, the priority is very low because the related CSS works on my production environment (public web space), which is my primary goal.
Use the developer tools in your browser. The answer should be obvious.
Without seeing what is happening, it is very difficult to guess.
I checked different views in different environments with the development tools and could find HTML with and other without the "wt-branch-split" class.
After that, I re-checked all my custom modules and versions of BranchesListModule.php and found an inconsistency with the versions . After bringing all environments to the right file versions, it worked.
I am sorry. It was obviously my fault in combination with some browser caching behaviour.
Good news is that the CSS based switch is working fine with the provided 2.1 version. Thank you very much for your support!
Observed with webtrees 2.0.19. If a mother is assigned a surname with the 2 SURN Gedcom structure and if her children do not have the same surname, the children of this mother are shown as empty list items in the Lists/Branches view.
Gedcom: 1 NAME Mary /Johnson/ 2 SURN Johnson
Example view (scroll down to find empty list items): http://www.familienforschung-hemprich.de/webtrees2/index.php?route=%2Fwebtrees2%2Ftree%2Fhemprich%2Fbranches%2FHemprich&language=en-GB