Skip to content

Commit

Permalink
fixed issue with not being able to select every possible entry type
Browse files Browse the repository at this point in the history
  • Loading branch information
nfourtythree committed Mar 16, 2016
1 parent 342617b commit 17fdd4c
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 3 deletions.
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,13 @@ When creating a new field the extra options for `EntryType` will appear when sel

## Entries Subset Changelog

### 0.5.2 -- 2016.03.16

* Issue with not returning every entry type

### 0.5.1 -- 2016.03.14

* Initial release
* Issue with error when no types are selected

### 0.5.0 -- 2016.02.17

Expand Down
3 changes: 2 additions & 1 deletion fieldtypes/EntriesSubsetFieldType.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,9 @@ public function getSettingsHtml()
public function getEntryTypeOptions()
{
$sectionIds = craft()->sections->getAllSectionIds();
$entryTypes = array();
foreach ($sectionIds as $id) {
$entryTypes = craft()->sections->getEntryTypesBySectionId($id);
$entryTypes = array_merge($entryTypes, craft()->sections->getEntryTypesBySectionId($id));
}

$entryTypeOptions = array(array('label' => Craft::t('All Entry Types'), 'value' => '*'));
Expand Down
10 changes: 9 additions & 1 deletion releases.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,18 @@
[
{
"version": "0.5.2",
"downloadUrl": "https://github.com/nfourtythree/entriessubset/archive/master.zip",
"date": "2016-03-16T13:34:00.111Z",
"notes": [
"[Fixed] Not returning every possible entry type"
]
},
{
"version": "0.5.1",
"downloadUrl": "https://github.com/nfourtythree/entriessubset/archive/master.zip",
"date": "2016-03-14T12:00:00.111Z",
"notes": [
"[Added] Initial release"
"[fixed] Issue with error when no types are selected"
]
},
{
Expand Down

0 comments on commit 17fdd4c

Please sign in to comment.