Fixed the getFieldName method to always fall back to global name if none is set in the xml.

This commit is contained in:
Llewellyn van der Merwe 2018-03-11 04:59:46 +02:00
parent ee949fbe6e
commit 1991a46689
No known key found for this signature in database
GPG Key ID: CAD7B16D27AF28C5
4 changed files with 13 additions and 8 deletions

View File

@ -2346,7 +2346,13 @@ class Get
}
else
{
$name = ComponentbuilderHelper::safeString(ComponentbuilderHelper::getBetween($field['settings']->xml, 'name="', '"'));
// get value from xml
$xml = ComponentbuilderHelper::safeString(ComponentbuilderHelper::getBetween($field['settings']->xml, 'name="', '"'));
// check if a value was found
if (ComponentbuilderHelper::checkString($xml))
{
$name = $xml;
}
}
// exit foreach loop
break;

View File

@ -12866,7 +12866,6 @@ class Interpretation extends Fields
'###views###' => $listViewName);
$view = '';
$viewType = 0;
// set the custom table key
$dbkey = 'g';
foreach ($this->componentData->config as $field)

View File

@ -2114,14 +2114,12 @@ COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_CREATED_DATE_DESC="The date this Compo
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_CREATED_DATE_LABEL="Created Date"
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_DEFAULT_VIEW_DESCRIPTION="Select only one."
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_DEFAULT_VIEW_LABEL="Default View"
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_DESCRIPTION="if view uses Access,<br />should default be public."
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_EDIT="Editing the Component Site Views"
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_ERROR_UNIQUE_ALIAS="Another Component Site Views has the same alias."
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_ID="Id"
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_JOOMLA_COMPONENT="Joomla Component"
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_JOOMLA_COMPONENT_DESCRIPTION="Select a Joomla Component"
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_JOOMLA_COMPONENT_LABEL="Component"
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_LABEL="Public Access"
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_MENU_DESCRIPTION="Select if the view should show have a menu link."
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_MENU_LABEL="Add Menu"
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_METADATA_DESCRIPTION="Select if this view should have metadata."
@ -2135,6 +2133,8 @@ COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_NOTE_ON_SITE_VIEWS_DESCRIPTION="Do not
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_NOTE_ON_SITE_VIEWS_LABEL="Setting Site Views"
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_ORDERING_LABEL="Ordering"
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_PERMISSION="Permissions"
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_PUBLIC_ACCESS_DESCRIPTION="if view uses Access,<br />should default be public."
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_PUBLIC_ACCESS_LABEL="Public Access"
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_PUBLISHING="Publishing"
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_SAVE_WARNING="Alias already existed so a number was added at the end. You can re-edit the Component Site Views to customise the alias."
COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_SITEVIEW="Siteview"

View File

@ -152,13 +152,13 @@
required="false"
description="COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_ACCESS_DESCRIPTION"
class="inputbox" />
<!-- Field. Type: Checkbox. (joomla)-->
<!-- Public_access Field. Type: Checkbox. (joomla)-->
<field type="checkbox"
name="show_title"
label="COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_LABEL"
name="public_access"
label="COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_PUBLIC_ACCESS_LABEL"
value="1"
required="false"
description="COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_DESCRIPTION"
description="COM_COMPONENTBUILDER_COMPONENT_SITE_VIEWS_PUBLIC_ACCESS_DESCRIPTION"
class="inputbox" />
</form>
</field>