diff --git a/framework/src/Maveriks/WebApplication.php b/framework/src/Maveriks/WebApplication.php index 21c9473e1..4296a8fac 100644 --- a/framework/src/Maveriks/WebApplication.php +++ b/framework/src/Maveriks/WebApplication.php @@ -254,6 +254,8 @@ class WebApplication $authenticationClass = 'ProcessMaker\\Services\\OAuth2\\Server'; // $accessControlClass - contains the class name that validate the Access Control for Restler $accessControlClass = 'ProcessMaker\\Policies\\AccessControl'; + // $controlUnderUpdating - ControlUnderUpdating sends an error signal 503 to report that the application is in update + $controlUnderUpdating = 'ProcessMaker\\Policies\\ControlUnderUpdating'; // $pmOauthClientId - contains PM Local OAuth Id (Web Designer) $pmOauthClientId = 'x-pm-local-client'; @@ -301,6 +303,8 @@ class WebApplication $this->rest->addAuthenticationClass($authenticationClass, ''); // adding $accessControlClass to Restler $this->rest->addAuthenticationClass($accessControlClass); + // adding $controlUnderUpdating to Restler + $this->rest->addAuthenticationClass($controlUnderUpdating); // Setting database connection source list($host, $port) = strpos(DB_HOST, ':') !== false ? explode(':', DB_HOST) : array(DB_HOST, ''); diff --git a/workflow/engine/classes/model/map/NotificationDeviceMapBuilder.php b/workflow/engine/classes/model/map/NotificationDeviceMapBuilder.php index 97a2a9823..403ec193f 100644 --- a/workflow/engine/classes/model/map/NotificationDeviceMapBuilder.php +++ b/workflow/engine/classes/model/map/NotificationDeviceMapBuilder.php @@ -71,7 +71,7 @@ class NotificationDeviceMapBuilder $tMap->addColumn('SYS_LANG', 'SysLang', 'string', CreoleTypes::VARCHAR, false, 10); - $tMap->addColumn('DEV_REG_ID', 'DevRegId', 'string', CreoleTypes::VARCHAR, true, 150); + $tMap->addColumn('DEV_REG_ID', 'DevRegId', 'string', CreoleTypes::VARCHAR, true, 255); $tMap->addColumn('DEV_TYPE', 'DevType', 'string', CreoleTypes::VARCHAR, true, 50); diff --git a/workflow/engine/config/schema.xml b/workflow/engine/config/schema.xml index 3e16c46f2..cbfc3271e 100644 --- a/workflow/engine/config/schema.xml +++ b/workflow/engine/config/schema.xml @@ -5543,7 +5543,7 @@ - + diff --git a/workflow/engine/data/mysql/schema.sql b/workflow/engine/data/mysql/schema.sql index 7a4bfe380..ed28ed375 100644 --- a/workflow/engine/data/mysql/schema.sql +++ b/workflow/engine/data/mysql/schema.sql @@ -3077,7 +3077,7 @@ CREATE TABLE `NOTIFICATION_DEVICE` `DEV_UID` VARCHAR(32) default '' NOT NULL, `USR_UID` VARCHAR(32) default '' NOT NULL, `SYS_LANG` VARCHAR(10) default '', - `DEV_REG_ID` VARCHAR(150) default '' NOT NULL, + `DEV_REG_ID` VARCHAR(255) default '' NOT NULL, `DEV_TYPE` VARCHAR(50) default '' NOT NULL, `DEV_CREATE` DATETIME NOT NULL, `DEV_UPDATE` DATETIME NOT NULL, diff --git a/workflow/engine/src/ProcessMaker/Policies/ControlUnderUpdating.php b/workflow/engine/src/ProcessMaker/Policies/ControlUnderUpdating.php new file mode 100644 index 000000000..c40363912 --- /dev/null +++ b/workflow/engine/src/ProcessMaker/Policies/ControlUnderUpdating.php @@ -0,0 +1,66 @@ +