?
avatar infograf768
infograf768
6 Mar 2017

@laoneo @Bakual

While making the PR #14369 I found out that although the Label is useful for the tabset, I could not find a usage for the Description.

Do we really need to keep that in? It looks to me that Note is enough here.
xml, db column + code in the helpers/fields.php

avatar infograf768 infograf768 - open - 6 Mar 2017
avatar joomla-cms-bot joomla-cms-bot - change - 6 Mar 2017
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 6 Mar 2017
avatar coolcat-creations
coolcat-creations - comment - 6 Mar 2017

Yes, it´s like an intro above the fields

avatar infograf768
infograf768 - comment - 6 Mar 2017

The only usage I could see is adding in the tmpl as translatable (as Note is not).

									<span class="small break-word">
										<?php if ($item->note) : ?>
											<?php echo JText::sprintf('JGLOBAL_LIST_NOTE', $this->escape($item->note)); ?>
										<?php endif; ?>
									</span>
									<?php if ($item->description) : ?>
										<div class="small">
											<?php echo JText::_($this->escape($item->description)); ?>
										</div>
									<?php endif; ?>

to get something like

screen shot 2017-03-06 at 09 50 39

when the description is a lang string constant and we do have that string in the language.
For above:
screen shot 2017-03-06 at 09 51 56

string:
COM_CONTENT_FIELDS_ARTICLE_DESC="Description du champ"

avatar infograf768
infograf768 - comment - 6 Mar 2017

Yes, it´s the tooltip of the field

Nope. I am talking about the Field Group Fieldset and not the field.

if (!$description)
				{
					$key = strtoupper($component . '_FIELDS_' . $section . '_DESC');

					if ($lang->hasKey($key))
					{
						$description = $key;
					}
				}
avatar coolcat-creations
coolcat-creations - comment - 6 Mar 2017

Yes i edited my reply immediately when i saw it, can you recheck my post above?

avatar infograf768
infograf768 - comment - 6 Mar 2017

Ah... Well hidden feature... Closing.

avatar infograf768 infograf768 - change - 6 Mar 2017
Status New Closed
Closed_Date 0000-00-00 00:00:00 2017-03-06 09:14:43
Closed_By infograf768
avatar infograf768 infograf768 - close - 6 Mar 2017

Add a Comment

Login with GitHub to post a comment