-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Upgrade to namespaces, SilverStripe 4
- Loading branch information
Showing
7 changed files
with
58 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,27 @@ | ||
{ | ||
"name": "silvershop/geocoding", | ||
"description": "Geocoding support for SilverShop.", | ||
"type": "silverstripe-module", | ||
"type": "silverstripe-vendormodule", | ||
"keywords": ["silverstripe", "ecommerce", "shop", "geocoding", "address", "ip"], | ||
"license": "BSD2", | ||
"extra": { | ||
"installer-name": "silvershop-geocoding" | ||
}, | ||
"require": { | ||
"silvershop/core": "*", | ||
"betterbrief/silverstripe-googlemapfield": "~1.2", | ||
"silvershop/core": "^3", | ||
"betterbrief/silverstripe-googlemapfield": "^2", | ||
"willdurand/geocoder": "~2.8.0" | ||
} | ||
}, | ||
"license": "BSD-3-Clause", | ||
"authors": [ { | ||
"name": "SilverShop Contributors", | ||
"homepage": "https://github.com/silvershop/silvershop-stock/graphs/contributors" | ||
}], | ||
"extra": { | ||
"branch-alias": { | ||
"dev-master": "2.x-dev" | ||
} | ||
}, | ||
"autoload": { | ||
"psr-4": { | ||
"SilverShop\\Geocoding\\": "src/", | ||
"SilverShop\\Geocoding\\Tests\\": "tests/unit/" | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,12 @@ | ||
<?php | ||
|
||
/** | ||
* @package silvershop-geocoding | ||
*/ | ||
namespace SilverShop\Geocoding; | ||
|
||
use SilverStripe\Forms\FieldList; | ||
use SilverStripe\ORM\DataExtension; | ||
use SilverShop\Model\Address; | ||
use Exception; | ||
|
||
class AddressGeocoding extends DataExtension | ||
{ | ||
|
||
|
@@ -75,7 +79,7 @@ public function geocodeAddress() | |
$this->owner->Latitude = $geocoded->getLatitude(); | ||
$this->owner->Longitude = $geocoded->getLongitude(); | ||
} catch (Exception $e) { | ||
SS_Log::log($e, SS_Log::ERR); | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
wilr
Author
Contributor
|
||
|
||
} | ||
} | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
I'm guessing this was removed because it was noisy - it certainly is for me for one of my sites.
But I'm thinking what about re-introducing it, making it configurable, and defaulting it to
SS_Log::Notice
orSS_Log::Info
?