Commit d364d0c0 authored by Aster's avatar Aster Committed by waltermazza
Browse files

General Bug Fixes and Improvements

parent d2ea19d8
......@@ -11,13 +11,13 @@ Installation
Either run
```bash
composer require elitedivision/amos-mobile-bridge
composer require arter/amos-mobile-bridge
```
or add
```
"elitedivision/amos-mobile-bridge": "~1.0"
"arter/amos-mobile-bridge": "~1.0"
```
to the require section of your `composer.json` file.
......@@ -28,7 +28,7 @@ Installation
<?php
'modules' => [
'mobilebridge' => [
'class' => 'elitedivision\amos\mobile\bridge\Module'
'class' => 'arter\amos\mobile\bridge\Module'
],
],
```
......@@ -36,5 +36,5 @@ Installation
3. Apply migrations
```bash
php yii migrate/up --migrationPath=@vendor/elitedivision/amos-mobile-bridge/src/migrations
php yii migrate/up --migrationPath=@vendor/arter/amos-mobile-bridge/src/migrations
```
\ No newline at end of file
{
"name": "elitedivision/amos-mobile-bridge",
"name": "arter/amos-mobile-bridge",
"description": "Amos 4 Mobile Compatibility Bridge",
"keywords": ["amos", "mobile", "app", "yii2"],
"homepage": "https://bitbucket.org/elite_division/amos-mobile-ridge",
"homepage": "https://bitbucket.org/arter/amos-mobile-ridge",
"type": "component",
"require": {
"php": ">=5.4.0",
"elitedivision/amos-admin":"*",
"elitedivision/amos-core":"*",
"arter/amos-admin":"*",
"arter/amos-core":"*",
"understeam/yii2-fcm": "~0.1",
"2amigos/yii2-qrcode-helper": "1.0.2",
"open2/amos-expo": "*"
},
"autoload": {
"psr-4": {
"elitedivision\\amos\\mobile\\bridge\\": "src"
"arter\\amos\\mobile\\bridge\\": "src"
}
}
}
\ No newline at end of file
<?php
/**
* Elite Division S.r.l.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\mobile\bridge
* @package arter\amos\mobile\bridge
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\mobile\bridge;
namespace arter\amos\mobile\bridge;
use elitedivision\amos\core\module\AmosModule;
use elitedivision\amos\mobile\bridge\controllers\NotificationController;
use elitedivision\amos\mobile\bridge\modules\v1\V1;
use arter\amos\core\module\AmosModule;
use arter\amos\mobile\bridge\controllers\NotificationController;
use arter\amos\mobile\bridge\modules\v1\V1;
use Yii;
use yii\base\BootstrapInterface;
use yii\base\Event;
......@@ -26,7 +22,7 @@ use yii\web\Application;
/**
* Class Module
* @package elitedivision\amos\mobile\bridge
* @package arter\amos\mobile\bridge
*/
class Module extends AmosModule implements BootstrapInterface
{
......@@ -48,7 +44,7 @@ class Module extends AmosModule implements BootstrapInterface
/**
* @inheritdoc
*/
public $controllerNamespace = 'elitedivision\amos\mobile\bridge\controllers';
public $controllerNamespace = 'arter\amos\mobile\bridge\controllers';
public $timeout = 180;
/**
......
<?php
/**
* Elite Division S.r.l.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\mobile\bridge
* @package arter\amos\mobile\bridge
* @category CategoryName
* @author Elite Division S.r.l.
*/
// Server API Key (you can get it here: https://firebase.google.com/docs/server/setup#prerequisites)
$firebaseApiKey = isset(Yii::$app->params['firebaseApiKey']) ? Yii::$app->params['firebaseApiKey'] : null;
......@@ -17,13 +13,13 @@ $firebaseApiKey = isset(Yii::$app->params['firebaseApiKey']) ? Yii::$app->params
return [
'modules' => [
'v1' => [
'class' => \elitedivision\amos\mobile\bridge\modules\v1\V1::className()
'class' => \arter\amos\mobile\bridge\modules\v1\V1::className()
]
],
'components' => [
'user' => [
'class' => 'elitedivision\amos\core\user\AmosUser',
'identityClass' => 'elitedivision\amos\mobile\bridge\modules\v1\models\User',
'class' => 'arter\amos\core\user\AmosUser',
'identityClass' => 'arter\amos\mobile\bridge\modules\v1\models\User',
'enableAutoLogin' => true,
],
'request' => [
......
<?php
/**
* Elite Division S.r.l.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\mobile\bridge
* @package arter\amos\mobile\bridge
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\mobile\bridge\controllers;
use elitedivision\amos\admin\models\UserProfile;
use elitedivision\amos\chat\models\Message;
use elitedivision\amos\comments\models\Comment;
use elitedivision\amos\comments\models\CommentReply;
use elitedivision\amos\discussioni\models\DiscussioniTopic;
use elitedivision\amos\mobile\bridge\modules\v1\models\AccessTokens;
use elitedivision\amos\mobile\bridge\modules\v1\models\ChatMessages;
use elitedivision\amos\mobile\bridge\modules\v1\models\User;
use elitedivision\amos\news\models\News;
namespace arter\amos\mobile\bridge\controllers;
use arter\amos\admin\models\UserProfile;
use arter\amos\chat\models\Message;
use arter\amos\comments\models\Comment;
use arter\amos\comments\models\CommentReply;
use arter\amos\discussioni\models\DiscussioniTopic;
use arter\amos\mobile\bridge\modules\v1\models\AccessTokens;
use arter\amos\mobile\bridge\modules\v1\models\ChatMessages;
use arter\amos\mobile\bridge\modules\v1\models\User;
use arter\amos\news\models\News;
use yii\db\ActiveQuery;
use yii\db\ActiveRecord;
use yii\rest\Controller;
......
This diff is collapsed.
This diff is collapsed.
<?php
use elitedivision\amos\admin\models\UserProfile;
use elitedivision\amos\admin\utility\UserProfileUtility;
use elitedivision\amos\core\user\User;
use elitedivision\amos\mobile\bridge\modules\v1\models\AccessTokens;
use arter\amos\admin\models\UserProfile;
use arter\amos\admin\utility\UserProfileUtility;
use arter\amos\core\user\User;
use arter\amos\mobile\bridge\modules\v1\models\AccessTokens;
use yii\db\Migration;
use yii\helpers\Console;
......
<?php
/**
* Elite Division S.r.l.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\mobile\bridge
* @package arter\amos\mobile\bridge
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\mobile\bridge\modules\v1;
namespace arter\amos\mobile\bridge\modules\v1;
use elitedivision\amos\core\module\AmosModule;
use elitedivision\amos\mobile\bridge\modules\v1\models\User;
use arter\amos\core\module\AmosModule;
use arter\amos\mobile\bridge\modules\v1\models\User;
use yii\helpers\ArrayHelper;
/**
* Class Module
* @package elitedivision\amos\mobile\bridge
* @package arter\amos\mobile\bridge
*/
class V1 extends AmosModule
{
......@@ -42,7 +38,7 @@ class V1 extends AmosModule
/**
* @inheritdoc
*/
public $controllerNamespace = 'elitedivision\amos\mobile\bridge\modules\v1\controllers';
public $controllerNamespace = 'arter\amos\mobile\bridge\modules\v1\controllers';
/**
* @return static
......
<?php
/**
* Elite Division S.r.l.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\mobile\bridge
* @package arter\amos\mobile\bridge
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\mobile\bridge\modules\v1\actions\comments;
namespace arter\amos\mobile\bridge\modules\v1\actions\comments;
use elitedivision\amos\admin\models\UserProfile;
use elitedivision\amos\comments\models\Comment;
use elitedivision\amos\comments\models\CommentInterface;
use elitedivision\amos\community\models\Community;
use elitedivision\amos\core\record\Record;
use elitedivision\amos\mobile\bridge\modules\v1\controllers\CommentsController;
use elitedivision\amos\mobile\bridge\modules\v1\models\AccessTokens;
use elitedivision\amos\mobile\bridge\modules\v1\models\User;
use arter\amos\admin\models\UserProfile;
use arter\amos\comments\models\Comment;
use arter\amos\comments\models\CommentInterface;
use arter\amos\community\models\Community;
use arter\amos\core\record\Record;
use arter\amos\mobile\bridge\modules\v1\controllers\CommentsController;
use arter\amos\mobile\bridge\modules\v1\models\AccessTokens;
use arter\amos\mobile\bridge\modules\v1\models\User;
use yii\base\Exception;
use yii\helpers\Json;
use yii\rest\Action;
......
<?php
/**
* Elite Division S.r.l.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\mobile\bridge
* @package arter\amos\mobile\bridge
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\mobile\bridge\modules\v1\actions\comments;
namespace arter\amos\mobile\bridge\modules\v1\actions\comments;
use elitedivision\amos\admin\models\UserProfile;
use elitedivision\amos\comments\models\Comment;
use elitedivision\amos\comments\models\CommentInterface;
use elitedivision\amos\community\models\Community;
use elitedivision\amos\core\record\Record;
use elitedivision\amos\mobile\bridge\modules\v1\models\AccessTokens;
use elitedivision\amos\mobile\bridge\modules\v1\models\User;
use arter\amos\admin\models\UserProfile;
use arter\amos\comments\models\Comment;
use arter\amos\comments\models\CommentInterface;
use arter\amos\community\models\Community;
use arter\amos\core\record\Record;
use arter\amos\mobile\bridge\modules\v1\models\AccessTokens;
use arter\amos\mobile\bridge\modules\v1\models\User;
use yii\base\Exception;
use yii\helpers\Json;
use yii\rest\Action;
......
<?php
/**
* Elite Division S.r.l.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\mobile\bridge
* @package arter\amos\mobile\bridge
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\mobile\bridge\modules\v1\actions\comments;
namespace arter\amos\mobile\bridge\modules\v1\actions\comments;
use elitedivision\amos\comments\models\CommentInterface;
use elitedivision\amos\comments\models\CommentReply;
use arter\amos\comments\models\CommentInterface;
use arter\amos\comments\models\CommentReply;
use Yii;
use yii\rest\Action;
......
<?php
/**
* Elite Division S.r.l.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\mobile\bridge
* @package arter\amos\mobile\bridge
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\mobile\bridge\modules\v1\actions\entitydata;
namespace arter\amos\mobile\bridge\modules\v1\actions\entitydata;
use elitedivision\amos\admin\models\UserProfile;
use elitedivision\amos\community\models\Community;
use elitedivision\amos\core\record\Record;
use elitedivision\amos\mobile\bridge\modules\v1\models\AccessTokens;
use elitedivision\amos\mobile\bridge\modules\v1\models\User;
use arter\amos\admin\models\UserProfile;
use arter\amos\community\models\Community;
use arter\amos\core\record\Record;
use arter\amos\mobile\bridge\modules\v1\models\AccessTokens;
use arter\amos\mobile\bridge\modules\v1\models\User;
use yii\base\Exception;
use yii\helpers\Json;
use yii\rest\Action;
......
<?php
/**
* Elite Division S.r.l.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\mobile\bridge
* @package arter\amos\mobile\bridge
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\mobile\bridge\modules\v1\actions\entitydata;
use elitedivision\amos\admin\models\UserProfile;
use elitedivision\amos\community\models\Community;
use elitedivision\amos\core\record\Record;
use elitedivision\amos\discussioni\models\DiscussioniTopic;
use elitedivision\amos\mobile\bridge\modules\v1\actions\entitydata\parsers\DiscussioniParser;
use elitedivision\amos\mobile\bridge\modules\v1\actions\entitydata\parsers\ItemsParser;
use elitedivision\amos\mobile\bridge\modules\v1\actions\entitydata\parsers\NewsParser;
use elitedivision\amos\mobile\bridge\modules\v1\models\AccessTokens;
use elitedivision\amos\mobile\bridge\modules\v1\models\User;
use elitedivision\amos\news\models\News;
namespace arter\amos\mobile\bridge\modules\v1\actions\entitydata;
use arter\amos\admin\models\UserProfile;
use arter\amos\community\models\Community;
use arter\amos\core\record\Record;
use arter\amos\discussioni\models\DiscussioniTopic;
use arter\amos\mobile\bridge\modules\v1\actions\entitydata\parsers\DiscussioniParser;
use arter\amos\mobile\bridge\modules\v1\actions\entitydata\parsers\ItemsParser;
use arter\amos\mobile\bridge\modules\v1\actions\entitydata\parsers\NewsParser;
use arter\amos\mobile\bridge\modules\v1\models\AccessTokens;
use arter\amos\mobile\bridge\modules\v1\models\User;
use arter\amos\news\models\News;
use yii\base\Exception;
use yii\data\ActiveDataProvider;
use yii\db\ActiveQuery;
......
<?php
/**
* Elite Division S.r.l.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\mobile\bridge
* @package arter\amos\mobile\bridge
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\mobile\bridge\modules\v1\actions\entitydata;
use elitedivision\amos\admin\models\UserProfile;
use elitedivision\amos\community\models\Community;
use elitedivision\amos\core\record\Record;
use elitedivision\amos\discussioni\models\DiscussioniTopic;
use elitedivision\amos\mobile\bridge\modules\v1\actions\entitydata\parsers\DiscussioniParser;
use elitedivision\amos\mobile\bridge\modules\v1\actions\entitydata\parsers\ItemsParser;
use elitedivision\amos\mobile\bridge\modules\v1\actions\entitydata\parsers\NewsParser;
use elitedivision\amos\mobile\bridge\modules\v1\models\AccessTokens;
use elitedivision\amos\mobile\bridge\modules\v1\models\User;
use elitedivision\amos\news\models\News;
namespace arter\amos\mobile\bridge\modules\v1\actions\entitydata;
use arter\amos\admin\models\UserProfile;
use arter\amos\community\models\Community;
use arter\amos\core\record\Record;
use arter\amos\discussioni\models\DiscussioniTopic;
use arter\amos\mobile\bridge\modules\v1\actions\entitydata\parsers\DiscussioniParser;
use arter\amos\mobile\bridge\modules\v1\actions\entitydata\parsers\ItemsParser;
use arter\amos\mobile\bridge\modules\v1\actions\entitydata\parsers\NewsParser;
use arter\amos\mobile\bridge\modules\v1\models\AccessTokens;
use arter\amos\mobile\bridge\modules\v1\models\User;
use arter\amos\news\models\News;
use yii\base\Exception;
use yii\helpers\Json;
use yii\rest\Action;
......
<?php
namespace elitedivision\amos\mobile\bridge\modules\v1\actions\entitydata\parsers;
namespace arter\amos\mobile\bridge\modules\v1\actions\entitydata\parsers;
use elitedivision\amos\core\models\ContentLikes;
use elitedivision\amos\core\models\ModelsClassname;
use arter\amos\core\models\ContentLikes;
use arter\amos\core\models\ModelsClassname;
use Yii;
class BaseParser
......
<?php
/**
* Elite Division S.r.l.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\mobile\bridge
* @package arter\amos\mobile\bridge
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\mobile\bridge\modules\v1\actions\entitydata\parsers;
namespace arter\amos\mobile\bridge\modules\v1\actions\entitydata\parsers;
use elitedivision\amos\admin\models\UserProfile;
use elitedivision\amos\core\models\ContentShared;
use elitedivision\amos\discussioni\models\DiscussioniTopic;
use elitedivision\amos\discussioni\models\search\DiscussioniTopicSearch;
use arter\amos\admin\models\UserProfile;
use arter\amos\core\models\ContentShared;
use arter\amos\discussioni\models\DiscussioniTopic;
use arter\amos\discussioni\models\search\DiscussioniTopicSearch;
use Yii;
use yii\helpers\StringHelper;
......
<?php
namespace elitedivision\amos\mobile\bridge\modules\v1\actions\entitydata\parsers;
namespace arter\amos\mobile\bridge\modules\v1\actions\entitydata\parsers;
use elitedivision\amos\admin\models\UserProfile;
use elitedivision\amos\events\models\Event;
use arter\amos\admin\models\UserProfile;
use arter\amos\events\models\Event;
use Yii;
use yii\helpers\StringHelper;
......
<?php
/**
* Elite Division S.r.l.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\mobile\bridge
* @package arter\amos\mobile\bridge
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\mobile\bridge\modules\v1\actions\entitydata\parsers;
namespace arter\amos\mobile\bridge\modules\v1\actions\entitydata\parsers;
use elitedivision\amos\news\models\search\NewsSearch;
use arter\amos\news\models\search\NewsSearch;
use Yii;
use elitedivision\amos\admin\models\UserProfile;
use elitedivision\amos\community\models\Community;
use elitedivision\amos\core\record\Record;
use elitedivision\amos\mobile\bridge\modules\v1\models\AccessTokens;
use elitedivision\amos\mobile\bridge\modules\v1\models\User;
use elitedivision\amos\news\models\News;
use arter\amos\admin\models\UserProfile;
use arter\amos\community\models\Community;
use arter\amos\core\record\Record;
use arter\amos\mobile\bridge\modules\v1\models\AccessTokens;
use arter\amos\mobile\bridge\modules\v1\models\User;
use arter\amos\news\models\News;
use yii\base\Exception;
use yii\data\ActiveDataProvider;
use yii\db\ActiveQuery;
......@@ -117,7 +113,7 @@ class ItemsParser
$itemsArray = [];
//The base class name
$baseClassName = \yii\helpers\StringHelper::basename(\elitedivision\amos\news\models\base\News::className());
$baseClassName = \yii\helpers\StringHelper::basename(\arter\amos\news\models\base\News::className());
//Read permission name
$readPremission = strtoupper($baseClassName . '_READ');
......
<?php
/**
* Elite Division S.r.l.
* OPEN 2.0
* Emilia Romagna Open Innovation
* Arter
*
* @see http://example.com Developers'community
* @license GPLv3
* @license https://opensource.org/licenses/gpl-3.0.html GNU General Public License version 3
*
* @package elitedivision\amos\mobile\bridge
* @package arter\amos\mobile\bridge
* @category CategoryName
* @author Elite Division S.r.l.
*/
namespace elitedivision\amos\mobile\bridge\modules\v1\actions\entitydata\parsers;
namespace arter\amos\mobile\bridge\modules\v1\actions\entitydata\parsers;