Skip to content

Commit

Permalink
Adding field/group specific save message.
Browse files Browse the repository at this point in the history
Fixing "All States" filter.
  • Loading branch information
Thomas Hunziker committed Dec 3, 2016
1 parent 6e15909 commit c4becd9
Show file tree
Hide file tree
Showing 5 changed files with 22 additions and 2 deletions.
9 changes: 9 additions & 0 deletions administrator/components/com_fields/controllers/field.php
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,15 @@ class FieldsControllerField extends JControllerForm

private $component;

/**
* The prefix to use with controller messages.
*
* @var string
* @since __DEPLOY_VERSION__
*/
protected $text_prefix = 'COM_FIELDS_FIELD';

/**
* Class constructor.
*
Expand Down
9 changes: 9 additions & 0 deletions administrator/components/com_fields/controllers/group.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,15 @@
*/
class FieldsControllerGroup extends JControllerForm
{
/**
* The prefix to use with controller messages.
*
* @var string
* @since __DEPLOY_VERSION__
*/
protected $text_prefix = 'COM_FIELDS_GROUP';

/**
* The extension for which the group applies.
*
Expand Down
2 changes: 1 addition & 1 deletion administrator/components/com_fields/models/fields.php
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,7 @@ protected function getListQuery()
$query->where('(a.group_id = 0 OR g.state = ' . (int) $state . ')');
}
}
else
elseif (!$state)
{
$query->where('a.state IN (0, 1)');

Expand Down
2 changes: 1 addition & 1 deletion administrator/components/com_fields/models/groups.php
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ protected function getListQuery()
{
$query->where('a.state = ' . (int) $state);
}
else
elseif (!$state)
{
$query->where('a.state IN (0, 1)');
}
Expand Down
2 changes: 2 additions & 0 deletions administrator/language/en-GB/en-GB.com_fields.ini
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ COM_FIELDS_GROUP_PERMISSION_EDITVALUE_DESC="Who can edit the field value in the
COM_FIELDS_GROUP_PERMISSION_EDIT_DESC="New setting for <strong>edit actions</strong> on this field group and the calculated setting based on the parent extension permissions."
COM_FIELDS_MUSTCONTAIN_A_TITLE_FIELD="Field must have a title."
COM_FIELDS_MUSTCONTAIN_A_TITLE_GROUP="Field Group must have a title."
COM_FIELDS_FIELD_SAVE_SUCCESS="Field successfully saved"
COM_FIELDS_FIELD_N_ITEMS_ARCHIVED="%d fields successfully archived"
COM_FIELDS_FIELD_N_ITEMS_ARCHIVED_1="%d field successfully archived"
COM_FIELDS_FIELD_N_ITEMS_CHECKED_IN="%d fields successfully checked in"
Expand All @@ -69,6 +70,7 @@ COM_FIELDS_FIELD_N_ITEMS_TRASHED="%d fields successfully trashed"
COM_FIELDS_FIELD_N_ITEMS_TRASHED_1="%d field successfully trashed"
COM_FIELDS_FIELD_N_ITEMS_UNPUBLISHED="%d fields successfully unpublished"
COM_FIELDS_FIELD_N_ITEMS_UNPUBLISHED_1="%d field successfully unpublished"
COM_FIELDS_GROUP_SAVE_SUCCESS="Field Group successfully saved"
COM_FIELDS_GROUP_N_ITEMS_ARCHIVED="%d field groups successfully archived"
COM_FIELDS_GROUP_N_ITEMS_ARCHIVED_1="%d field group successfully archived"
COM_FIELDS_GROUP_N_ITEMS_CHECKED_IN="%d field groups successfully checked in"
Expand Down

0 comments on commit c4becd9

Please sign in to comment.