diff --git a/admin/helpers/compiler/c_Fields.php b/admin/helpers/compiler/c_Fields.php index b1d3f468f..255592109 100644 --- a/admin/helpers/compiler/c_Fields.php +++ b/admin/helpers/compiler/c_Fields.php @@ -1512,6 +1512,11 @@ class Fields extends Structure // load the php for the custom field file $fieldAttributes['custom']['phpx'][$phpLine] = ComponentbuilderHelper::getBetween($field['settings']->xml, $property['name'] . '="', '"'); } + elseif ($property['name'] === 'prime_php' && $setCustom) + { + // load the php for the custom field file + $fieldAttributes['custom']['prime_php'] = (int) ComponentbuilderHelper::getBetween($field['settings']->xml, $property['name'] . '="', '"'); + } elseif ($property['name'] === 'extends' && $setCustom) { // load the class that is being extended @@ -2139,8 +2144,8 @@ class Fields extends Structure public function setCustomFieldTypeFile($data, $viewName_list, $viewName_single) { - // make sure it is not already been build - if (!isset($this->fileContentDynamic['customfield_' . $data['type']]) || !ComponentbuilderHelper::checkArray($this->fileContentDynamic['customfield_' . $data['type']])) + // make sure it is not already been build or if it is prime + if ((isset($data['custom']['prime_php']) && $data['custom']['prime_php'] == 1) || !isset($this->fileContentDynamic['customfield_' . $data['type']]) || !ComponentbuilderHelper::checkArray($this->fileContentDynamic['customfield_' . $data['type']])) { // first build the custom field type file $target = array('admin' => 'customfield'); diff --git a/admin/models/fields/servers.php b/admin/models/fields/servers.php index 29253f076..ed35dfbc4 100644 --- a/admin/models/fields/servers.php +++ b/admin/models/fields/servers.php @@ -151,7 +151,7 @@ class JFormFieldServers extends JFormFieldList { $db = JFactory::getDBO(); $query = $db->getQuery(true); - $query->select($db->quoteName(array('a.id','a.name','a.protocol'),array('id','cronjob_backup_server_name', 'protocol'))); + $query->select($db->quoteName(array('a.id','a.name','a.protocol'),array('id','name', 'protocol'))); $query->from($db->quoteName('#__componentbuilder_server', 'a')); $query->where($db->quoteName('a.published') . ' >= 1'); $query->order('a.name ASC'); @@ -164,7 +164,7 @@ class JFormFieldServers extends JFormFieldList foreach($items as $item) { $item->protocol = ($item->protocol == 2) ? JText::_('SFTP') : JText::_('FTP'); - $options[] = JHtml::_('select.option', $item->id, $item->cronjob_backup_server_name.' ['.$item->protocol.']'); + $options[] = JHtml::_('select.option', $item->id, $item->name.' ['.$item->protocol.']'); } } return $options; diff --git a/admin/sql/install.mysql.utf8.sql b/admin/sql/install.mysql.utf8.sql index 366410bd6..932497305 100644 --- a/admin/sql/install.mysql.utf8.sql +++ b/admin/sql/install.mysql.utf8.sql @@ -1465,7 +1465,7 @@ INSERT INTO `#__componentbuilder_fieldtype` (`id`, `catid`, `description`, `name (3, '', 'The checkbox form field type provides a single checkbox. If the parameter has a saved value this is selected when the page is first loaded. If not, the default value (if any) is selected.', 'Checkbox', '{\"properties0\":{\"name\":\"type\",\"example\":\"checkbox\",\"adjustable\":\"0\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) must be checkbox\"},\"properties1\":{\"name\":\"name\",\"example\":\"show_title\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) is the unique name of the parameter.\"},\"properties2\":{\"name\":\"label\",\"example\":\"Show title\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"1\",\"description\":\"(mandatory) (translatable) is the descriptive title of the field.\"},\"properties3\":{\"name\":\"value\",\"example\":\"1\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) is the value of the parameter if this checkbox is set (usually 1).\"},\"properties4\":{\"name\":\"default\",\"example\":\"\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) is the default value (usually 0 or 1).\"},\"properties5\":{\"name\":\"required\",\"example\":\"\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) The field must be filled before submitting the form.\"},\"properties6\":{\"name\":\"description\",\"example\":\"Show the title of the item\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"1\",\"description\":\"(optional) (translatable) is text that will be shown as a tooltip when the user moves the mouse over the label.\"},\"properties7\":{\"name\":\"class\",\"example\":\"inputbox\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) is a CSS class name for the HTML form field. If omitted this will default to \'inputbox\'.\"},\"properties8\":{\"name\":\"showon\",\"example\":\"\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) show this field on the bases of the value in another field.\"}}', 'provides a single checkbox to be checked or unchecked', '', 1, 2, '', ''), (4, '', 'The checkboxes form field type provides a set of checkboxes. Note: unlike most standard form field types, such as textfield or checkbox, this field is not an \"out of the box\" solution. It will create checkboxes for you, and submit their values in form of ', 'Checkboxes', '{\"properties0\":{\"name\":\"type\",\"example\":\"checkboxes\",\"adjustable\":\"0\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) must be checkboxs\"},\"properties1\":{\"name\":\"name\",\"example\":\"toppings\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) is the unique name of the parameter.\"},\"properties2\":{\"name\":\"label\",\"example\":\"Select Toppings\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"1\",\"description\":\"(optional) (translatable) is the descriptive title of the field.\"},\"properties3\":{\"name\":\"option\",\"example\":\"anch|Anchovies,chor|Chorizo,on|Onions,mush|Mushrooms\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) set the options of this radio. Separate options with commas and use the pipe symbol to separate value from text.\"},\"properties4\":{\"name\":\"default\",\"example\":\"\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) is the default value.\"},\"properties5\":{\"name\":\"description\",\"example\":\"Select the topping of your choice\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"1\",\"description\":\"(optional) (translatable) is text that will be shown as a tooltip when the user moves the mouse over the label.\"},\"properties6\":{\"name\":\"required\",\"example\":\"\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) The field must be filled before submitting the form.\"},\"properties7\":{\"name\":\"class\",\"example\":\"\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) is a CSS class name for the HTML form field. If omitted this will default to \'inputbox\'.\"},\"properties8\":{\"name\":\"showon\",\"example\":\"\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) show this field on the bases of the value in another field.\"}}', 'provides unlimited checkboxes that can be used for multi-select.', '', 1, 2, '', ''), (5, '', 'Provides a color picker. Enter the color as #ff00ff or pick it from the palet.', 'Color', '{\"properties0\":{\"name\":\"type\",\"example\":\"color\",\"adjustable\":\"0\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) must be color.\"},\"properties1\":{\"name\":\"name\",\"example\":\"backgroundcolor\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) is the unique name of the parameter.\"},\"properties2\":{\"name\":\"default\",\"example\":\"#FFFFFF\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) provides a color when not set.\"},\"properties3\":{\"name\":\"label\",\"example\":\"Background\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"1\",\"description\":\"(mandatory) (translatable) is the descriptive title of the field.\"},\"properties4\":{\"name\":\"description\",\"example\":\"Select the background color here.\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"1\",\"description\":\"(optional) (translatable) tooltip for the form field.\"},\"properties5\":{\"name\":\"required\",\"example\":\"\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) The field must be filled before submitting the form.\"},\"properties6\":{\"name\":\"showon\",\"example\":\"\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) show this field on the bases of the value in another field.\"}}', 'provides a color picker when clicking the input box.', '', 1, 2, '', ''), -(6, '', 'The list form field type provides a drop down list or a list box of other current component table entries. If the field has a saved value this is selected when the page is first loaded. If not, the default value (if any) is selected.', 'Custom', '{\"properties0\":{\"name\":\"type\",\"example\":\"subjects\",\"mandatory\":\"1\",\"description\":\"(mandatory) can be anything, just not the same as any other default Joomla field type.\"},\"properties1\":{\"name\":\"name\",\"example\":\"subject\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"description\":\"(mandatory) is the unique name of the field.\"},\"properties2\":{\"name\":\"label\",\"example\":\"Select a Subject\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"1\",\"description\":\"(mandatory) (translatable) is the descriptive title of the field.\"},\"properties3\":{\"name\":\"description\",\"example\":\"\",\"adjustable\":\"1\",\"translatable\":\"1\",\"description\":\"(optional) (translatable) is text that will be shown as a tooltip when the user moves the mouse over the drop-down box.\"},\"properties40\":{\"name\":\"message\",\"example\":\"\",\"adjustable\":\"1\",\"translatable\":\"1\",\"description\":\"(optional) (translatable) is text that will be shown as error on validation.\"},\"properties4\":{\"name\":\"class\",\"example\":\"list_class\",\"adjustable\":\"1\",\"description\":\"(optional) is a CSS class name for the HTML form field. If omitted this will default to \'inputbox\'.\"},\"properties5\":{\"name\":\"multiple\",\"example\":\"false\",\"adjustable\":\"1\",\"description\":\"(optional) is whether multiple items can be selected at the same time (true or false).\"},\"properties6\":{\"name\":\"default\",\"example\":\"0\",\"adjustable\":\"1\",\"description\":\"(optional) (not translatable) is the default value.\"},\"properties7\":{\"name\":\"required\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) The field must be filled before submitting the form.\"},\"properties41\":{\"name\":\"validate\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) The validation method for the form field. This value will determine which method is used to validate the value for a field.\"},\"properties8\":{\"name\":\"readonly\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) The field cannot be changed and will automatically inherit the default value\"},\"properties9\":{\"name\":\"disabled\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) The field cannot be changed and will automatically inherit the default value - it will also not submit\"},\"properties10\":{\"name\":\"showon\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) show this field on the bases of the value in another field.\"},\"properties11\":{\"name\":\"onchange\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) HTML equivalent attribute (javascript use)\"},\"properties12\":{\"name\":\"extends\",\"example\":\"list\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"description\":\"The JFormField sub class that should be extended. The options are (\'list\',\'radio\',\'checkboxes\')\"},\"properties13\":{\"name\":\"button\",\"example\":\"true\",\"adjustable\":\"1\",\"description\":\"(optional) to add new button next to field in edit view\"},\"properties14\":{\"name\":\"table\",\"example\":\"#__###component###_subject\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"description\":\"(mandatory) The table being linked to. \"},\"properties15\":{\"name\":\"component\",\"example\":\"com_###component###\",\"mandatory\":\"1\",\"description\":\"(mandatory) The name of the component where this table is found. Must be com_users\"},\"properties16\":{\"name\":\"view\",\"example\":\"subject\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"description\":\"(mandatory) The single view name if the place this field is added.\"},\"properties17\":{\"name\":\"views\",\"example\":\"subjects\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"description\":\"(mandatory) The list view name if the place this field is added.\"},\"properties18\":{\"name\":\"value_field\",\"example\":\"name\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"description\":\"(mandatory) The name of the text field in table linked to.\"},\"properties19\":{\"name\":\"key_field\",\"example\":\"id\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"description\":\"(mandatory) The field from the linked table to save in this table as the unique key.\"},\"properties20\":{\"name\":\"type_php_1\",\"example\":\"$db = JFactory::getDBO();\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties21\":{\"name\":\"type_php_2\",\"example\":\"$query = $db->getQuery(true);\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties22\":{\"name\":\"type_php_3\",\"example\":\"$query->select($db->quoteName(array(\'a.###ID###\',\'a.###TEXT###\'),array(\'###ID###\',\'###CODE_TEXT###\')));\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties23\":{\"name\":\"type_php_4\",\"example\":\"$query->from($db->quoteName(\'###TABLE###\', \'a\'));\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties24\":{\"name\":\"type_php_5\",\"example\":\"$query->where($db->quoteName(\'a.published\') . \' = 1\');\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties25\":{\"name\":\"type_php_6\",\"example\":\"$query->order(\'a.###TEXT### ASC\');\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties26\":{\"name\":\"type_php_7\",\"example\":\"$db->setQuery((string)$query);\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties27\":{\"name\":\"type_php_8\",\"example\":\"$items = $db->loadObjectList();\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties28\":{\"name\":\"type_php_9\",\"example\":\"$options = array();\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties29\":{\"name\":\"type_php_10\",\"example\":\"if ($items)\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties30\":{\"name\":\"type_php_11\",\"example\":\"{\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties31\":{\"name\":\"type_php_12\",\"example\":\"\\\\t$options[] = JHtml::_(\'select.option\', \'\', \'Select an option\');\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties32\":{\"name\":\"type_php_13\",\"example\":\"\\\\tforeach($items as $item)\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties33\":{\"name\":\"type_php_14\",\"example\":\"\\\\t{\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties34\":{\"name\":\"type_php_15\",\"example\":\"\\\\t\\\\t$options[] = JHtml::_(\'select.option\', $item->###ID###, $item->###CODE_TEXT###);\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties35\":{\"name\":\"type_php_16\",\"example\":\"\\\\t}\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties36\":{\"name\":\"type_php_17\",\"example\":\"}\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties37\":{\"name\":\"type_php_18\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties38\":{\"name\":\"type_php_19\",\"example\":\"return $options;\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"}}', 'provides a drop down list of items entries.', '', 1, 6, '', ''), +(6, '', 'The list form field type provides a drop down list or a list box of other current component table entries. If the field has a saved value this is selected when the page is first loaded. If not, the default value (if any) is selected.', 'Custom', '{\"properties0\":{\"name\":\"type\",\"example\":\"subjects\",\"mandatory\":\"1\",\"description\":\"(mandatory) can be anything, just not the same as any other default Joomla field type.\"},\"properties1\":{\"name\":\"name\",\"example\":\"subject\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"description\":\"(mandatory) is the unique name of the field.\"},\"properties2\":{\"name\":\"label\",\"example\":\"Select a Subject\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"1\",\"description\":\"(mandatory) (translatable) is the descriptive title of the field.\"},\"properties3\":{\"name\":\"description\",\"example\":\"\",\"adjustable\":\"1\",\"translatable\":\"1\",\"description\":\"(optional) (translatable) is text that will be shown as a tooltip when the user moves the mouse over the drop-down box.\"},\"properties4\":{\"name\":\"message\",\"example\":\"\",\"adjustable\":\"1\",\"translatable\":\"1\",\"description\":\"(optional) (translatable) is text that will be shown as error on validation.\"},\"properties5\":{\"name\":\"class\",\"example\":\"list_class\",\"adjustable\":\"1\",\"description\":\"(optional) is a CSS class name for the HTML form field. If omitted this will default to \'inputbox\'.\"},\"properties6\":{\"name\":\"multiple\",\"example\":\"false\",\"adjustable\":\"1\",\"description\":\"(optional) is whether multiple items can be selected at the same time (true or false).\"},\"properties7\":{\"name\":\"default\",\"example\":\"0\",\"adjustable\":\"1\",\"description\":\"(optional) (not translatable) is the default value.\"},\"properties8\":{\"name\":\"required\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) The field must be filled before submitting the form.\"},\"properties9\":{\"name\":\"validate\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) The validation method for the form field. This value will determine which method is used to validate the value for a field.\"},\"properties10\":{\"name\":\"readonly\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) The field cannot be changed and will automatically inherit the default value\"},\"properties11\":{\"name\":\"disabled\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) The field cannot be changed and will automatically inherit the default value - it will also not submit\"},\"properties12\":{\"name\":\"showon\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) show this field on the bases of the value in another field.\"},\"properties13\":{\"name\":\"onchange\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) HTML equivalent attribute (javascript use)\"},\"properties14\":{\"name\":\"extends\",\"example\":\"list\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"description\":\"The JFormField sub class that should be extended. The options are (\'list\',\'radio\',\'checkboxes\')\"},\"properties15\":{\"name\":\"button\",\"example\":\"true\",\"adjustable\":\"1\",\"description\":\"(optional) to add new button next to field in edit view\"},\"properties16\":{\"name\":\"table\",\"example\":\"#__###component###_subject\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"description\":\"(mandatory) The table being linked to. \"},\"properties17\":{\"name\":\"component\",\"example\":\"com_###component###\",\"mandatory\":\"1\",\"description\":\"(mandatory) The name of the component where this table is found. Must be com_users\"},\"properties18\":{\"name\":\"view\",\"example\":\"subject\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"description\":\"(mandatory) The single view name if the place this field is added.\"},\"properties19\":{\"name\":\"views\",\"example\":\"subjects\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"description\":\"(mandatory) The list view name if the place this field is added.\"},\"properties20\":{\"name\":\"value_field\",\"example\":\"name\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"description\":\"(mandatory) The name of the text field in table linked to.\"},\"properties21\":{\"name\":\"key_field\",\"example\":\"id\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"description\":\"(mandatory) The field from the linked table to save in this table as the unique key.\"},\"properties22\":{\"name\":\"prime_php\",\"example\":\"1\",\"adjustable\":\"1\",\"description\":\"This field makes sure that the PHP used here is used to build the field type, and other are custom fields with the same field type are ignored. So to avoid that they over write the PHP added here. You should only have one prime per\\/type. To disable remove the field or set to 0\"},\"properties23\":{\"name\":\"type_php_1\",\"example\":\"$db = JFactory::getDBO();\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties24\":{\"name\":\"type_php_2\",\"example\":\"$query = $db->getQuery(true);\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties25\":{\"name\":\"type_php_3\",\"example\":\"$query->select($db->quoteName(array(\'a.###ID###\',\'a.###TEXT###\'),array(\'###ID###\',\'###CODE_TEXT###\')));\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties26\":{\"name\":\"type_php_4\",\"example\":\"$query->from($db->quoteName(\'###TABLE###\', \'a\'));\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties27\":{\"name\":\"type_php_5\",\"example\":\"$query->where($db->quoteName(\'a.published\') . \' = 1\');\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties28\":{\"name\":\"type_php_6\",\"example\":\"$query->order(\'a.###TEXT### ASC\');\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties29\":{\"name\":\"type_php_7\",\"example\":\"$db->setQuery((string)$query);\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties30\":{\"name\":\"type_php_8\",\"example\":\"$items = $db->loadObjectList();\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties31\":{\"name\":\"type_php_9\",\"example\":\"$options = array();\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties32\":{\"name\":\"type_php_10\",\"example\":\"if ($items)\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties33\":{\"name\":\"type_php_11\",\"example\":\"{\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties34\":{\"name\":\"type_php_12\",\"example\":\"\\\\t$options[] = JHtml::_(\'select.option\', \'\', \'Select an option\');\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties35\":{\"name\":\"type_php_13\",\"example\":\"\\\\tforeach($items as $item)\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties36\":{\"name\":\"type_php_14\",\"example\":\"\\\\t{\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties37\":{\"name\":\"type_php_15\",\"example\":\"\\\\t\\\\t$options[] = JHtml::_(\'select.option\', $item->###ID###, $item->###CODE_TEXT###);\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties38\":{\"name\":\"type_php_16\",\"example\":\"\\\\t}\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties39\":{\"name\":\"type_php_17\",\"example\":\"}\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties40\":{\"name\":\"type_php_18\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"},\"properties41\":{\"name\":\"type_php_19\",\"example\":\"return $options;\",\"adjustable\":\"1\",\"description\":\"The php for the getOptions method.\"}}', 'provides a drop down list of items entries.', '', 1, 8, '', ''), (7, '', 'The a list of users that can be targeting one or more groups and excluded users that already belongs to an item in a view.', 'CustomUser', '{\"properties0\":{\"name\":\"type\",\"example\":\"staffusers\",\"adjustable\":\"0\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) can be anything, just not the same as any other default Joomla field type.\"},\"properties1\":{\"name\":\"name\",\"example\":\"staff\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) is the unique name of the field.\"},\"properties2\":{\"name\":\"label\",\"example\":\"Staff\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"1\",\"description\":\"(mandatory) (translatable) is the descriptive title of the field.\"},\"properties3\":{\"name\":\"description\",\"example\":\"\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"1\",\"description\":\"(optional) (translatable) is text that will be shown as a tooltip when the user moves the mouse over the drop-down box.\"},\"properties4\":{\"name\":\"class\",\"example\":\"\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) is a CSS class name for the HTML form field. If omitted this will default to \'inputbox\'.\"},\"properties5\":{\"name\":\"multiple\",\"example\":\"false\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) is whether multiple items can be selected at the same time (true or false).\"},\"properties6\":{\"name\":\"required\",\"example\":\"\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) The field must be filled before submitting the form.\"},\"properties7\":{\"name\":\"readonly\",\"example\":\"\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) The field cannot be changed and will automatically inherit the default value\"},\"properties8\":{\"name\":\"disabled\",\"example\":\"\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) The field cannot be changed and will automatically inherit the default value - it will also not submit\"},\"properties9\":{\"name\":\"default\",\"example\":\"\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"1\",\"description\":\"\"},\"properties10\":{\"name\":\"hint\",\"example\":\"select a user\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"1\",\"description\":\"\"},\"properties11\":{\"name\":\"showon\",\"example\":\"\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"(optional) show this field on the bases of the value in another field.\"},\"properties12\":{\"name\":\"extends\",\"example\":\"user\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"The JFormField sub class that should be extended. The options are (\'list\',\'radio\',\'checkboxes\')\"},\"properties13\":{\"name\":\"table\",\"example\":\"#__users\",\"adjustable\":\"0\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) The table being linked to. Must be #__users\"},\"properties14\":{\"name\":\"component\",\"example\":\"com_users\",\"adjustable\":\"0\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) The name of the component where this table is found. Must be com_users\"},\"properties15\":{\"name\":\"view\",\"example\":\"###view###\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) The single view name if the place this field is added.\"},\"properties16\":{\"name\":\"views\",\"example\":\"###views###\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) The list view name if the place this field is added.\"},\"properties17\":{\"name\":\"value_field\",\"example\":\"name\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) The name of the text field in table linked to.\"},\"properties18\":{\"name\":\"key_field\",\"example\":\"id\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) The field from the linked table to save in this table as the unique key.\"},\"properties19\":{\"name\":\"type_php_1\",\"example\":\"\\/\\/ set the groups array\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getGroups method.\"},\"properties20\":{\"name\":\"type_php_2\",\"example\":\"$groups = JComponentHelper::getParams(\'com_###component###\')->get(\'###type###\');\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getGroups method.\"},\"properties21\":{\"name\":\"type_php_3\",\"example\":\"return $groups;\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getGroups method.\"},\"properties22\":{\"name\":\"type_phpx_1\",\"example\":\"\\/\\/ To ensure that there is only one record per user\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getExcluded method.\"},\"properties23\":{\"name\":\"type_phpx_2\",\"example\":\"\\/\\/ Get a db connection.\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getExcluded method.\"},\"properties24\":{\"name\":\"type_phpx_3\",\"example\":\"$db = JFactory::getDbo();\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getExcluded method.\"},\"properties25\":{\"name\":\"type_phpx_4\",\"example\":\"\\/\\/ Create a new query object.\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getExcluded method.\"},\"properties26\":{\"name\":\"type_phpx_5\",\"example\":\"$query = $db->getQuery(true);\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getExcluded method.\"},\"properties27\":{\"name\":\"type_phpx_6\",\"example\":\"\\/\\/ Select all records from the #__###component###_###view### table from ###CODE### column\\\".\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getExcluded method.\"},\"properties28\":{\"name\":\"type_phpx_7\",\"example\":\"$query->select($db->quoteName(\'###CODE###\'));\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getExcluded method.\"},\"properties29\":{\"name\":\"type_phpx_8\",\"example\":\"$query->from($db->quoteName(\'#__###component###_###view###\'));\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getExcluded method.\"},\"properties30\":{\"name\":\"type_phpx_9\",\"example\":\"$db->setQuery($query);\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getExcluded method.\"},\"properties31\":{\"name\":\"type_phpx_10\",\"example\":\"$db->execute();\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getExcluded method.\"},\"properties32\":{\"name\":\"type_phpx_11\",\"example\":\"$found = $db->getNumRows();\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getExcluded method.\"},\"properties33\":{\"name\":\"type_phpx_12\",\"example\":\"if ($found)\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getExcluded method.\"},\"properties34\":{\"name\":\"type_phpx_13\",\"example\":\"{\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getExcluded method.\"},\"properties35\":{\"name\":\"type_phpx_14\",\"example\":\"\\\\t\\/\\/ return all users already used\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getExcluded method.\"},\"properties36\":{\"name\":\"type_phpx_15\",\"example\":\"\\\\treturn array_unique($db->loadColumn());\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getExcluded method.\"},\"properties37\":{\"name\":\"type_phpx_16\",\"example\":\"}\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getExcluded method.\"},\"properties38\":{\"name\":\"type_phpx_17\",\"example\":\"return null;\",\"adjustable\":\"1\",\"mandatory\":\"0\",\"translatable\":\"0\",\"description\":\"The php for the getExcluded method.\"}}', 'Provides list of users.', '', 1, 2, '', ''), (8, '', 'The Editor field type provides a WYSIWYG editor.', 'Editor', '{\"properties0\":{\"name\":\"type\",\"example\":\"editor\",\"mandatory\":\"1\",\"description\":\"(mandatory) must be editor.\"},\"properties1\":{\"name\":\"name\",\"example\":\"mytextblock\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"description\":\"(mandatory) is the unique name of the parameter.\"},\"properties2\":{\"name\":\"label\",\"example\":\"Test Field\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"1\",\"description\":\"(mandatory) (translatable) is the descriptive title of the field.\"},\"properties3\":{\"name\":\"default\",\"example\":\"Some text\",\"adjustable\":\"1\",\"description\":\"(optional) (not translatable) is the default value.\"},\"properties16\":{\"name\":\"message\",\"example\":\"\",\"adjustable\":\"1\",\"translatable\":\"1\",\"description\":\"(optional) (translatable) is text that will be shown as error on validation.\"},\"properties4\":{\"name\":\"width\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) defines the width (in pixels) of the wysiwyg editor and defaults to 100%.\"},\"properties5\":{\"name\":\"height\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) defines the height (in pixels) of the wysiwyg editor and defaults to 250px.\"},\"properties6\":{\"name\":\"cols\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) defines the width of the editor (in columns).\"},\"properties7\":{\"name\":\"rows\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) defines the height of the editor (in rows).\"},\"properties8\":{\"name\":\"buttons\",\"example\":\"false\",\"adjustable\":\"1\",\"description\":\"(optional) can be an array of plugin buttons to be excluded or set to false. The default editors-xtd are: article, image, pagebreak and readmore.\"},\"properties9\":{\"name\":\"hide\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) array of plugin buttons to be hidden. eg... set buttons=\\\"true\\\" hide=\\\"readmore,pagebreak\\\"\"},\"properties10\":{\"name\":\"editor\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"specifies the editor to be used and can include two options (editor=\\\"desired|alternative\\\")\"},\"properties11\":{\"name\":\"filter\",\"example\":\"safehtml\",\"adjustable\":\"1\",\"description\":\"(optional) allow the system to save certain html tags or raw data.\"},\"properties12\":{\"name\":\"required\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) The field must be filled before submitting the form.\"},\"properties15\":{\"name\":\"validate\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) The validation method for the form field. This value will determine which method is used to validate the value for a field.\"},\"properties13\":{\"name\":\"showon\",\"example\":\"\",\"adjustable\":\"1\",\"description\":\"(optional) show this field on the bases of the value in another field.\"}}', 'provides an editor area field.', '', 1, 5, '', ''), (9, '', 'The hidden form field type provides a hidden field for saving a field whose value cannot be altered directly by a user in the Administrator (it can be altered in code or by editing the params.ini file). If the parameter has a saved value this is entered i', 'Hidden', '{\"properties0\":{\"name\":\"type\",\"example\":\"hidden\",\"adjustable\":\"0\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) must be hidden.\"},\"properties1\":{\"name\":\"name\",\"example\":\"mysecretvariable\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) is the unique name of the field.\"},\"properties2\":{\"name\":\"default\",\"example\":\"1\",\"adjustable\":\"1\",\"mandatory\":\"1\",\"translatable\":\"0\",\"description\":\"(mandatory) is the data which needs to be collected.\"}}', 'provides a hidden field for saving a form field whose value cannot be altered directly by a user.', '', 1, 1, '', ''),