-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
83 changed files
with
1,218 additions
and
650 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,8 @@ | ||
*~ | ||
phpunit.xml | ||
vendor | ||
behat.yml | ||
composer.lock | ||
node_modules/ | ||
var/ | ||
/var/ | ||
package-lock.json | ||
.idea/ | ||
.phpunit.result.cache | ||
composer.lock |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
behat/* | ||
!behat/.gitkeep | ||
logs | ||
* | ||
!.gitignore | ||
!behat/.gitkeep |
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
Empty file.
Empty file.
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"YAWIK-TEST.applications.files"},{"v":2,"key":{"permissions.view":1},"name":"permissions.view_1","sparse":false,"ns":"YAWIK-TEST.applications.files"},{"v":2,"key":{"permissions.change":1},"name":"permissions.change_1","sparse":false,"ns":"YAWIK-TEST.applications.files"}],"uuid":"f245711d3f1a46fab25f18453ba97cd0"} |
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"YAWIK-TEST.applications"},{"v":2,"key":{"job":1},"name":"job_1","sparse":false,"ns":"YAWIK-TEST.applications"},{"v":2,"key":{"user":1},"name":"user_1","sparse":false,"ns":"YAWIK-TEST.applications"},{"v":2,"key":{"_fts":"text","_ftsx":1},"name":"cv_cvFulltext","sparse":false,"weights":{"cv.preferredJob.desiredJob":1},"language_override":"language","ns":"YAWIK-TEST.applications","default_language":"english","textIndexVersion":3},{"v":2,"key":{"cv.status":1},"name":"cv.status_1","sparse":false,"ns":"YAWIK-TEST.applications"},{"v":2,"key":{"cv.contact.image":1},"name":"cv.contact.image_1","sparse":false,"ns":"YAWIK-TEST.applications"},{"v":2,"key":{"cv.preferredJob.desiredLocations.coordinates":"2dsphere"},"name":"cv.preferredJob.desiredLocations.coordinates_2dsphere","sparse":false,"ns":"YAWIK-TEST.applications","2dsphereIndexVersion":3},{"v":2,"key":{"cv.permissions.view":1},"name":"cv.permissions.view_1","sparse":false,"ns":"YAWIK-TEST.applications"},{"v":2,"key":{"cv.permissions.change":1},"name":"cv.permissions.change_1","sparse":false,"ns":"YAWIK-TEST.applications"}],"uuid":"3d1812f54a54496f8de425ee29852c48"} |
Empty file.
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"YAWIK-TEST.cvs.attachments.files"},{"v":2,"key":{"permissions.view":1},"name":"permissions.view_1","ns":"YAWIK-TEST.cvs.attachments.files","sparse":false},{"v":2,"key":{"permissions.change":1},"name":"permissions.change_1","ns":"YAWIK-TEST.cvs.attachments.files","sparse":false}],"uuid":"13837154c25f4a649778cc7d82cf9967"} |
Empty file.
Empty file.
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"YAWIK-TEST.cvs.contact.images.files"},{"v":2,"key":{"permissions.view":1},"name":"permissions.view_1","sparse":false,"ns":"YAWIK-TEST.cvs.contact.images.files"},{"v":2,"key":{"permissions.change":1},"name":"permissions.change_1","sparse":false,"ns":"YAWIK-TEST.cvs.contact.images.files"}],"uuid":"f175548bd16244458c464b06886b3341"} |
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"YAWIK-TEST.cvs"},{"v":2,"key":{"_fts":"text","_ftsx":1},"name":"cvFulltext","ns":"YAWIK-TEST.cvs","weights":{"preferredJob.desiredJob":1},"default_language":"english","language_override":"language","sparse":false,"textIndexVersion":3},{"v":2,"key":{"status":1},"name":"status_1","ns":"YAWIK-TEST.cvs","sparse":false},{"v":2,"key":{"contact.image":1},"name":"contact.image_1","sparse":false,"ns":"YAWIK-TEST.cvs"},{"v":2,"key":{"preferredJob.desiredLocations.coordinates":"2dsphere"},"name":"preferredJob.desiredLocations.coordinates_2dsphere","sparse":false,"ns":"YAWIK-TEST.cvs","2dsphereIndexVersion":3},{"v":2,"key":{"permissions.view":1},"name":"permissions.view_1","sparse":false,"ns":"YAWIK-TEST.cvs"},{"v":2,"key":{"permissions.change":1},"name":"permissions.change_1","sparse":false,"ns":"YAWIK-TEST.cvs"}],"uuid":"a0b4c254cb43474f9b64850c2aeeffbc"} |
Empty file.
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"YAWIK-TEST.jobs"},{"v":2,"key":{"datePublishStart.date":1},"name":"datePublishStart.date_1","ns":"YAWIK-TEST.jobs","sparse":false},{"v":2,"key":{"applyId":1},"name":"applyId_1","sparse":false,"ns":"YAWIK-TEST.jobs"},{"v":2,"key":{"organization":1},"name":"organization_1","ns":"YAWIK-TEST.jobs","sparse":false},{"v":2,"key":{"user":1},"name":"user_1","sparse":false,"ns":"YAWIK-TEST.jobs"},{"v":2,"key":{"status":1},"name":"status_1","sparse":false,"ns":"YAWIK-TEST.jobs"},{"v":2,"key":{"locations.coordinates":"2dsphere"},"name":"locations.coordinates_2dsphere","sparse":false,"ns":"YAWIK-TEST.jobs","2dsphereIndexVersion":3},{"v":2,"key":{"permissions.view":1},"name":"permissions.view_1","sparse":false,"ns":"YAWIK-TEST.jobs"},{"v":2,"key":{"permissions.change":1},"name":"permissions.change_1","sparse":false,"ns":"YAWIK-TEST.jobs"},{"v":2,"key":{"_fts":"text","_ftsx":1},"name":"templateValues_fulltext","ns":"YAWIK-TEST.jobs","weights":{"templateValues.benefits":1,"templateValues.description":1,"templateValues.qualifications":1,"templateValues.requirements":1,"templateValues.title":1},"sparse":false,"language_override":"lang_index","default_language":"english","textIndexVersion":3}],"uuid":"d776edd7997345b38e2dc13d6931bb35"} |
Empty file.
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"YAWIK-TEST.jobs.snapshots2"},{"v":2,"key":{"datePublishStart.date":1},"name":"datePublishStart.date_1","sparse":false,"ns":"YAWIK-TEST.jobs.snapshots2"},{"v":2,"key":{"applyId":1},"name":"applyId_1","sparse":false,"ns":"YAWIK-TEST.jobs.snapshots2"},{"v":2,"key":{"organization":1},"name":"organization_1","sparse":false,"ns":"YAWIK-TEST.jobs.snapshots2"},{"v":2,"key":{"user":1},"name":"user_1","sparse":false,"ns":"YAWIK-TEST.jobs.snapshots2"},{"v":2,"key":{"status":1},"name":"status_1","sparse":false,"ns":"YAWIK-TEST.jobs.snapshots2"},{"v":2,"key":{"locations.coordinates":"2dsphere"},"name":"locations.coordinates_2dsphere","sparse":false,"ns":"YAWIK-TEST.jobs.snapshots2","2dsphereIndexVersion":3},{"v":2,"key":{"permissions.view":1},"name":"permissions.view_1","sparse":false,"ns":"YAWIK-TEST.jobs.snapshots2"},{"v":2,"key":{"permissions.change":1},"name":"permissions.change_1","sparse":false,"ns":"YAWIK-TEST.jobs.snapshots2"},{"v":2,"key":{"_fts":"text","_ftsx":1},"name":"templateValues_fulltext","sparse":false,"ns":"YAWIK-TEST.jobs.snapshots2","weights":{"templateValues.benefits":1,"templateValues.description":1,"templateValues.qualifications":1,"templateValues.requirements":1,"templateValues.title":1},"language_override":"lang_index","default_language":"english","textIndexVersion":3}],"uuid":"4701e9b311ef4fe486d2646da5682508"} |
Binary file not shown.
Empty file.
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"YAWIK-TEST.organizations.images.files"},{"v":2,"key":{"permissions.view":1},"name":"permissions.view_1","sparse":false,"ns":"YAWIK-TEST.organizations.images.files"},{"v":2,"key":{"permissions.change":1},"name":"permissions.change_1","sparse":false,"ns":"YAWIK-TEST.organizations.images.files"}],"uuid":"32628fdd874c45a280e683caf2db41d6"} |
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"YAWIK-TEST.organizations"},{"v":2,"key":{"_fts":"text","_ftsx":1},"name":"fulltext","sparse":false,"ns":"YAWIK-TEST.organizations","weights":{"_organizationName":1},"default_language":"english","language_override":"language","textIndexVersion":3},{"v":2,"key":{"externalId":1},"name":"externalId_1","sparse":false,"ns":"YAWIK-TEST.organizations"},{"v":2,"key":{"user":1},"name":"user_1","sparse":false,"ns":"YAWIK-TEST.organizations"},{"v":2,"key":{"permissions.view":1},"name":"permissions.view_1","sparse":false,"ns":"YAWIK-TEST.organizations"},{"v":2,"key":{"permissions.change":1},"name":"permissions.change_1","sparse":false,"ns":"YAWIK-TEST.organizations"}],"uuid":"ef5e499625854e2c966f20cc75d7e188"} |
Binary file not shown.
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"YAWIK-TEST.organizations.names"}],"uuid":"2644dc63ef1c447386c8c934fa824d73"} |
Binary file not shown.
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"YAWIK-TEST.simpleimport.crawler"}],"uuid":"50dd6f3dcdb94db69471a000ccc3fdee"} |
Binary file not shown.
Empty file.
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"YAWIK-TEST.users.images.files"},{"v":2,"key":{"permissions.view":1},"name":"permissions.view_1","sparse":false,"ns":"YAWIK-TEST.users.images.files"},{"v":2,"key":{"permissions.change":1},"name":"permissions.change_1","ns":"YAWIK-TEST.users.images.files","sparse":false}],"uuid":"d541a8e2874e4a958081e13980c82dd0"} |
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 |
---|---|---|
@@ -0,0 +1 @@ | ||
{"options":{},"indexes":[{"v":2,"key":{"_id":1},"name":"_id_","ns":"YAWIK-TEST.users"},{"v":2,"key":{"_fts":"text","_ftsx":1},"name":"fulltext","sparse":false,"weights":{"info.email":1,"info.firstName":1,"info.lastName":1,"login":1,"role":1},"language_override":"language","ns":"YAWIK-TEST.users","default_language":"english","textIndexVersion":3},{"v":2,"unique":true,"key":{"login":1},"name":"login_1","sparse":true,"ns":"YAWIK-TEST.users"},{"v":2,"key":{"status":1},"name":"status_1","sparse":false,"ns":"YAWIK-TEST.users"}],"uuid":"1c93d5d600ce459195e37c640970d0f0"} |
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 |
---|---|---|
@@ -0,0 +1,33 @@ | ||
<?php | ||
|
||
declare(strict_types=1); | ||
|
||
namespace SimpleImport\Bridge\Geocoder\Factory; | ||
|
||
|
||
use Interop\Container\ContainerInterface; | ||
use SimpleImport\Options\ModuleOptions; | ||
use Zend\Cache\Psr\SimpleCache\SimpleCacheDecorator; | ||
use Zend\Cache\StorageFactory; | ||
use Zend\ServiceManager\Factory\FactoryInterface; | ||
|
||
class CacheFactory implements FactoryInterface | ||
{ | ||
public function __invoke(ContainerInterface $container, $requestedName, array $options = null) | ||
{ | ||
/* @var \SimpleImport\Options\ModuleOptions $options */ | ||
$options = $container->get(ModuleOptions::SERVICE_ID); | ||
$config = $options->getCache(); | ||
|
||
if('filesystem' === $config['adapter']['name']){ | ||
$cacheDir = $config['adapter']['options']['cacheDir']; | ||
if(!is_dir($cacheDir)){ | ||
mkdir($cacheDir, 0777, true); | ||
} | ||
} | ||
$storage = StorageFactory::factory($config); | ||
$cache = new SimpleCacheDecorator($storage); | ||
|
||
return $cache; | ||
} | ||
} |
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 |
---|---|---|
@@ -0,0 +1,20 @@ | ||
<?php | ||
|
||
|
||
namespace SimpleImport\Bridge\Geocoder\Factory; | ||
|
||
|
||
use Geocoder\Provider\Cache\ProviderCache; | ||
use Interop\Container\ContainerInterface; | ||
use Zend\ServiceManager\Factory\FactoryInterface; | ||
|
||
class CacheProviderFactory implements FactoryInterface | ||
{ | ||
public function __invoke(ContainerInterface $container, $requestedName, array $options = null) | ||
{ | ||
$cache = $container->get('SimpleImport/Geocoder/Cache'); | ||
$realProvider = $container->get('SimpleImport/Geocoder/Provider'); | ||
|
||
return new ProviderCache($realProvider, $cache); | ||
} | ||
} |
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 |
---|---|---|
@@ -0,0 +1,54 @@ | ||
<?php | ||
|
||
|
||
namespace SimpleImport\Bridge\Geocoder\Factory; | ||
|
||
|
||
use Geocoder\Provider\GoogleMaps\GoogleMaps as GoogleMapsProvider; | ||
use GuzzleHttp\Client as GuzzleClient; | ||
use Http\Adapter\Guzzle6\Client as HttpClient; | ||
use Http\Client\Common\PluginClient; | ||
use Interop\Container\ContainerInterface; | ||
use Zend\ServiceManager\Factory\FactoryInterface; | ||
|
||
class ProviderFactory implements FactoryInterface | ||
{ | ||
/** | ||
* @param ContainerInterface $container | ||
* @param string $requestedName | ||
* @param array|null $options | ||
* | ||
* @return GoogleMapsProvider|object | ||
*/ | ||
public function __invoke(ContainerInterface $container, $requestedName, array $options = null) | ||
{ | ||
/** @var \SimpleImport\Options\ModuleOptions $moduleOptions */ | ||
$moduleOptions = $container->get('SimpleImport/Options/Module'); | ||
|
||
$httpAdapter = $this->createHttpAdapter(); | ||
$region = $moduleOptions->getGeocodeRegion(); | ||
$apiKey = $moduleOptions->getGeocodeGoogleApiKey(); | ||
$pluginClient = new PluginClient($httpAdapter); | ||
|
||
$provider = new GoogleMapsProvider( | ||
$pluginClient, | ||
$region, | ||
$apiKey | ||
); | ||
|
||
return $provider; | ||
} | ||
|
||
private function createHttpAdapter() | ||
{ | ||
$config = [ | ||
'timeout' => 2.0, | ||
'verify' => false, | ||
]; | ||
|
||
$guzzle = new GuzzleClient($config); | ||
$adapter = new HttpClient($guzzle); | ||
|
||
return $adapter; | ||
} | ||
} |
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
Oops, something went wrong.