Skip to content

Commit

Permalink
Fix issue setting old field settings after upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
Tam committed Mar 20, 2019
1 parent f60ec46 commit d976c99
Show file tree
Hide file tree
Showing 3 changed files with 43 additions and 1 deletion.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 3.4.2 - 2019-03-20
### Fixed
- Fixed issue setting old field settings after upgrade.

## 3.4.1 - 2019-03-20
### Fixed
- Fixed an issue where the map field class broke after upgrading.
Expand Down
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "ether/simplemap",
"description": "A beautifully simple Map field type for Craft CMS 3",
"version": "3.4.1",
"version": "3.4.2",
"type": "craft-plugin",
"license": "MIT",
"minimum-stability": "dev",
Expand Down
38 changes: 38 additions & 0 deletions src/fields/MapField.php
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,39 @@ class MapField extends Field implements EagerLoadingFieldInterface, PreviewableF
*/
public $hideAddress = false;

/**
* @deprecated
*/
public $hideLatLng;
/**
* @deprecated
*/
public $countryRestriction;
/**
* @deprecated
*/
public $typeRestriction;
/**
* @deprecated
*/
public $boundaryRestrictionNELat;
/**
* @deprecated
*/
public $boundaryRestrictionNELng;
/**
* @deprecated
*/
public $boundaryRestrictionSWLat;
/**
* @deprecated
*/
public $boundaryRestrictionSWLng;
/**
* @deprecated
*/
public $boundary = '""';

// Methods
// =========================================================================

Expand Down Expand Up @@ -101,6 +134,11 @@ public static function supportedTranslationMethods (): array
// Methods: Instance
// -------------------------------------------------------------------------

public function setCountryRestriction ($value)
{
$this->country = $value;
}

public function rules ()
{
$rules = parent::rules();
Expand Down

0 comments on commit d976c99

Please sign in to comment.