Solving conflicts with the last changes in develop branch
This commit is contained in:
@@ -15,7 +15,7 @@ jobs:
|
||||
name: Run Test Units
|
||||
command: |
|
||||
mkdir coverage
|
||||
vendor/phpunit/phpunit/phpunit --testdox-html coverage/result.html --coverage-html coverage --verbose tests/unit/
|
||||
vendor/phpunit/phpunit/phpunit --stop-on-failure --testdox-html coverage/result.html --coverage-html coverage --verbose tests/unit/
|
||||
- store_artifacts:
|
||||
path: coverage
|
||||
destination: coverage
|
||||
|
||||
26
database/factories/AppDelayFactory.php
Normal file
26
database/factories/AppDelayFactory.php
Normal file
@@ -0,0 +1,26 @@
|
||||
<?php
|
||||
|
||||
use Faker\Generator as Faker;
|
||||
|
||||
$factory->define(\ProcessMaker\Model\AppDelay::class, function (Faker $faker) {
|
||||
$actions = ['CANCEL', 'PAUSE', 'REASSIGN'];
|
||||
return [
|
||||
'APP_DELAY_UID' => G::generateUniqueID(),
|
||||
'PRO_UID' => G::generateUniqueID(),
|
||||
'APP_UID' => G::generateUniqueID(),
|
||||
'APP_NUMBER' => $faker->unique()->numberBetween(1000),
|
||||
'APP_THREAD_INDEX' => 1,
|
||||
'APP_DEL_INDEX' => $faker->unique()->numberBetween(10),
|
||||
'APP_TYPE' => $faker->randomElement($actions),
|
||||
'APP_STATUS' => 'TO_DO',
|
||||
'APP_NEXT_TASK' => 0,
|
||||
'APP_DELEGATION_USER' => G::generateUniqueID(),
|
||||
'APP_ENABLE_ACTION_USER' => G::generateUniqueID(),
|
||||
'APP_ENABLE_ACTION_DATE' => $faker->dateTime(),
|
||||
'APP_DISABLE_ACTION_USER' => G::generateUniqueID(),
|
||||
'APP_DISABLE_ACTION_DATE' => $faker->dateTime(),
|
||||
'APP_AUTOMATIC_DISABLED_DATE' => '',
|
||||
'APP_DELEGATION_USER_ID' => $faker->unique()->numberBetween(1000),
|
||||
'PRO_ID' => $faker->unique()->numberBetween(1000),
|
||||
];
|
||||
});
|
||||
@@ -90,25 +90,3 @@ $factory->state(\ProcessMaker\Model\EmailServerModel::class, 'GMAILAPI', functio
|
||||
'OAUTH_REFRESH_TOKEN' => $faker->regexify("/[a-z]{7}[a-zA-Z0-9]{355}==/")
|
||||
];
|
||||
});
|
||||
|
||||
$factory->state(\ProcessMaker\Model\EmailServerModel::class, 'OPENMAIL', function ($faker) {
|
||||
return [
|
||||
'MESS_UID' => G::generateUniqueID(),
|
||||
'MESS_ENGINE' => 'OPENMAIL',
|
||||
'MESS_PORT' => 0,
|
||||
'MESS_INCOMING_SERVER' => '',
|
||||
'MESS_INCOMING_PORT' => 0,
|
||||
'MESS_RAUTH' => 1,
|
||||
'MESS_ACCOUNT' => $faker->email,
|
||||
'MESS_PASSWORD' => $faker->password,
|
||||
'MESS_FROM_MAIL' => $faker->email,
|
||||
'MESS_FROM_NAME' => $faker->name,
|
||||
'SMTPSECURE' => 'ssl',
|
||||
'MESS_TRY_SEND_INMEDIATLY' => 0,
|
||||
'MAIL_TO' => $faker->email,
|
||||
'MESS_DEFAULT' => 0,
|
||||
'OAUTH_CLIENT_ID' => '',
|
||||
'OAUTH_CLIENT_SECRET' => '',
|
||||
'OAUTH_REFRESH_TOKEN' => ''
|
||||
];
|
||||
});
|
||||
|
||||
@@ -3,18 +3,49 @@
|
||||
* Model factory for a list unassigned
|
||||
*/
|
||||
use Faker\Generator as Faker;
|
||||
use ProcessMaker\Model\Application;
|
||||
use ProcessMaker\Model\Process;
|
||||
use ProcessMaker\Model\Task;
|
||||
use ProcessMaker\Model\User;
|
||||
|
||||
$factory->define(\ProcessMaker\Model\ListUnassigned::class, function(Faker $faker) {
|
||||
$app = factory(\ProcessMaker\Model\Application::class)->states('foreign_keys')->create();
|
||||
$user = factory(\ProcessMaker\Model\User::class)->create();
|
||||
$process = \ProcessMaker\Model\Process::where('PRO_UID', $app->PRO_UID)->first();
|
||||
$task = $process->tasks->first();
|
||||
return [
|
||||
'APP_UID' => G::generateUniqueID(),
|
||||
'DEL_INDEX' => 2,
|
||||
'TAS_UID' => G::generateUniqueID(),
|
||||
'PRO_UID' => G::generateUniqueID(),
|
||||
'APP_NUMBER' => $faker->unique()->numberBetween(1000),
|
||||
'APP_TITLE' => $faker->sentence(3),
|
||||
'APP_PRO_TITLE' => $faker->sentence(3),
|
||||
'APP_TAS_TITLE' => $faker->sentence(3),
|
||||
'DEL_PREVIOUS_USR_USERNAME' => $faker->name,
|
||||
'DEL_PREVIOUS_USR_FIRSTNAME' => $faker->firstName,
|
||||
'DEL_PREVIOUS_USR_LASTNAME' => $faker->lastName,
|
||||
'APP_UPDATE_DATE' => $faker->dateTime(),
|
||||
'DEL_PREVIOUS_USR_UID' => G::generateUniqueID(),
|
||||
'DEL_DELEGATE_DATE' => $faker->dateTime(),
|
||||
'DEL_DUE_DATE' => $faker->dateTime(),
|
||||
'DEL_PRIORITY' => 3,
|
||||
'PRO_ID' => $faker->unique()->numberBetween(1000),
|
||||
'TAS_ID' => $faker->unique()->numberBetween(1000),
|
||||
];
|
||||
});
|
||||
|
||||
$factory->state(\ProcessMaker\Model\ListUnassigned::class, 'foreign_keys', function (Faker $faker) {
|
||||
$process = factory(Process::class)->create();
|
||||
$app = factory(Application::class)->create(['PRO_UID' => $process->PRO_UID]);
|
||||
$user = factory(User::class)->create();
|
||||
$task = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE', // Define a self-service type
|
||||
'TAS_GROUP_VARIABLE' => '',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
|
||||
return [
|
||||
'APP_UID' => $app->APP_UID,
|
||||
'DEL_INDEX' => 1,
|
||||
'DEL_INDEX' => 2,
|
||||
'TAS_UID' => $task->TAS_UID,
|
||||
'PRO_UID' => $app->PRO_UID,
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'APP_NUMBER' => $app->APP_NUMBER,
|
||||
'APP_TITLE' => $app->APP_TITLE,
|
||||
'APP_PRO_TITLE' => $process->PRO_TITLE,
|
||||
|
||||
16
database/factories/StepFactory.php
Normal file
16
database/factories/StepFactory.php
Normal file
@@ -0,0 +1,16 @@
|
||||
<?php
|
||||
|
||||
use Faker\Generator as Faker;
|
||||
|
||||
$factory->define(\ProcessMaker\Model\Step::class, function (Faker $faker) {
|
||||
return [
|
||||
'STEP_UID' => G::generateUniqueID(),
|
||||
'PRO_UID' => G::generateUniqueID(),
|
||||
'TAS_UID' => G::generateUniqueID(),
|
||||
'STEP_TYPE_OBJ' => 'DYNAFORM',
|
||||
'STEP_UID_OBJ' => '0',
|
||||
'STEP_CONDITION' => 'None',
|
||||
'STEP_POSITION' => 0,
|
||||
'STEP_MODE' => 'EDIT'
|
||||
];
|
||||
});
|
||||
13
database/factories/UserReportingFactory.php
Normal file
13
database/factories/UserReportingFactory.php
Normal file
@@ -0,0 +1,13 @@
|
||||
<?php
|
||||
|
||||
use Faker\Generator as Faker;
|
||||
|
||||
$factory->define(\ProcessMaker\Model\UserReporting::class, function (Faker $faker) {
|
||||
return [
|
||||
'USR_UID' => G::generateUniqueID(),
|
||||
'TAS_UID' => G::generateUniqueID(),
|
||||
'PRO_UID' => G::generateUniqueID(),
|
||||
'MONTH' => 12,
|
||||
'YEAR' => 2020,
|
||||
];
|
||||
});
|
||||
@@ -6075,6 +6075,7 @@ class G
|
||||
|
||||
/**
|
||||
* Add log of execution of triggers
|
||||
*
|
||||
* @param $data
|
||||
* @param string $error
|
||||
* @param string $typeError
|
||||
@@ -6082,24 +6083,22 @@ class G
|
||||
*/
|
||||
public static function logTriggerExecution($data, $error = 'NO-ERROR', $typeError = '', $executionTime = 0)
|
||||
{
|
||||
if ((!empty($data['_CODE_']) || $typeError == 'FATAL_ERROR') && isset($data['_DATA_TRIGGER_']) &&
|
||||
!isset($data['_DATA_TRIGGER_']['_TRI_LOG_'])
|
||||
) {
|
||||
if ((!empty($data['_CODE_']) || $typeError == 'FATAL_ERROR') && empty($data['_DATA_TRIGGER_']['_TRI_LOG_'])) {
|
||||
$lg = Bootstrap::getDefaultContextLog();
|
||||
$lg['TRI_TITLE'] = isset($data['_DATA_TRIGGER_']['TRI_TITLE']) ? $data['_DATA_TRIGGER_']['TRI_TITLE'] : '';
|
||||
$lg['TRI_UID'] = isset($data['_DATA_TRIGGER_']['TRI_UID']) ? $data['_DATA_TRIGGER_']['TRI_UID'] : '';
|
||||
$lg['TRI_CODE'] = isset($data['_DATA_TRIGGER_']['TRI_WEBBOT']) ? $data['_DATA_TRIGGER_']['TRI_WEBBOT'] : '';
|
||||
$lg['TRI_EXECUTION_TIME'] = $executionTime;
|
||||
$lg['TRI_MSG_ERROR'] = $error;
|
||||
$lg['APP_UID'] = isset($data['APPLICATION']) ? $data['APPLICATION'] : '';
|
||||
$lg['PRO_UID'] = isset($data['PROCESS']) ? $data['PROCESS'] : '';
|
||||
$lg['TAS_UID'] = isset($data['TASK']) ? $data['TASK'] : '';
|
||||
$lg['USR_UID'] = isset($data['USER_LOGGED']) ? $data['USER_LOGGED'] : '';
|
||||
$lg['triTitle'] = isset($data['_DATA_TRIGGER_']['TRI_TITLE']) ? $data['_DATA_TRIGGER_']['TRI_TITLE'] : '';
|
||||
$lg['triUid'] = isset($data['_DATA_TRIGGER_']['TRI_UID']) ? $data['_DATA_TRIGGER_']['TRI_UID'] : '';
|
||||
$lg['triCode'] = isset($data['_DATA_TRIGGER_']['TRI_WEBBOT']) ? $data['_DATA_TRIGGER_']['TRI_WEBBOT'] : '';
|
||||
$lg['triExecutionTime'] = $executionTime;
|
||||
$lg['triMessageError'] = $error;
|
||||
$lg['appUid'] = isset($data['APPLICATION']) ? $data['APPLICATION'] : '';
|
||||
$lg['proUid'] = isset($data['PROCESS']) ? $data['PROCESS'] : '';
|
||||
$lg['tasUid'] = isset($data['TASK']) ? $data['TASK'] : '';
|
||||
$lg['usrUid'] = isset($data['USER_LOGGED']) ? $data['USER_LOGGED'] : '';
|
||||
|
||||
Bootstrap::registerMonolog(
|
||||
(empty($sError)) ? 'TriggerExecution' : 'TriggerExecutionError',
|
||||
(empty($sError)) ? 200 : 400,
|
||||
(empty($sError)) ? 'Trigger Execution' : 'Trigger Execution Error',
|
||||
(empty($error)) ? 'TriggerExecution' : 'TriggerExecutionError',
|
||||
(empty($error)) ? 200 : 400,
|
||||
(empty($error)) ? 'Trigger Execution' : 'Trigger Execution Error',
|
||||
$lg,
|
||||
$lg['workspace'],
|
||||
'processmaker.log'
|
||||
|
||||
457
tests/resources/p1normal-2.pmx
Normal file
457
tests/resources/p1normal-2.pmx
Normal file
@@ -0,0 +1,457 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<ProcessMaker-Project version="3.0">
|
||||
<metadata>
|
||||
<meta key="vendor_version"><![CDATA[(Branch develop)]]></meta>
|
||||
<meta key="vendor_version_code">Michelangelo</meta>
|
||||
<meta key="export_timestamp">1581967381</meta>
|
||||
<meta key="export_datetime"><![CDATA[2020-02-17T19:23:01+00:00]]></meta>
|
||||
<meta key="export_server_addr"><![CDATA[172.16.3.67:8091]]></meta>
|
||||
<meta key="export_server_os">Linux</meta>
|
||||
<meta key="export_server_php_version">70314</meta>
|
||||
<meta key="workspace">workflow</meta>
|
||||
<meta key="name">p1normal-2</meta>
|
||||
<meta key="uid">2901603085e4ae7e3604aa4076057940</meta>
|
||||
</metadata>
|
||||
<definition class="BPMN">
|
||||
<table name="ACTIVITY">
|
||||
<record>
|
||||
<act_uid>1504066335e4ae80c9dfa36023087714</act_uid>
|
||||
<prj_uid>2901603085e4ae7e3604aa4076057940</prj_uid>
|
||||
<pro_uid>9851695265e4ae7e362d623005016495</pro_uid>
|
||||
<act_name>Task 1</act_name>
|
||||
<act_type>TASK</act_type>
|
||||
<act_is_for_compensation>0</act_is_for_compensation>
|
||||
<act_start_quantity>1</act_start_quantity>
|
||||
<act_completion_quantity>0</act_completion_quantity>
|
||||
<act_task_type>EMPTY</act_task_type>
|
||||
<act_implementation></act_implementation>
|
||||
<act_instantiate>0</act_instantiate>
|
||||
<act_script_type></act_script_type>
|
||||
<act_script></act_script>
|
||||
<act_loop_type>EMPTY</act_loop_type>
|
||||
<act_test_before>0</act_test_before>
|
||||
<act_loop_maximum>0</act_loop_maximum>
|
||||
<act_loop_condition>0</act_loop_condition>
|
||||
<act_loop_cardinality>0</act_loop_cardinality>
|
||||
<act_loop_behavior>0</act_loop_behavior>
|
||||
<act_is_adhoc>0</act_is_adhoc>
|
||||
<act_is_collapsed>0</act_is_collapsed>
|
||||
<act_completion_condition>0</act_completion_condition>
|
||||
<act_ordering>0</act_ordering>
|
||||
<act_cancel_remaining_instances>1</act_cancel_remaining_instances>
|
||||
<act_protocol>0</act_protocol>
|
||||
<act_method>0</act_method>
|
||||
<act_is_global>0</act_is_global>
|
||||
<act_referer>0</act_referer>
|
||||
<act_default_flow>0</act_default_flow>
|
||||
<act_master_diagram>0</act_master_diagram>
|
||||
<bou_uid>4754816355e4ae80c9edc72099129795</bou_uid>
|
||||
<dia_uid>9636628415e4ae7e3624dc3037395819</dia_uid>
|
||||
<element_uid>1504066335e4ae80c9dfa36023087714</element_uid>
|
||||
<bou_element>6454338745e4ae7e4c76cd0081476745</bou_element>
|
||||
<bou_element_type>bpmnActivity</bou_element_type>
|
||||
<bou_x>149</bou_x>
|
||||
<bou_y>85</bou_y>
|
||||
<bou_width>150</bou_width>
|
||||
<bou_height>75</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
</table>
|
||||
<table name="ARTIFACT"/>
|
||||
<table name="BOUND">
|
||||
<record>
|
||||
<bou_uid>1362127075e4ae80ca52e44078025638</bou_uid>
|
||||
<prj_uid>2901603085e4ae7e3604aa4076057940</prj_uid>
|
||||
<dia_uid>9636628415e4ae7e3624dc3037395819</dia_uid>
|
||||
<element_uid>4992899745e4ae80ca4eb50099975191</element_uid>
|
||||
<bou_element>6454338745e4ae7e4c76cd0081476745</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>71</bou_x>
|
||||
<bou_y>106</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<bou_uid>4754816355e4ae80c9edc72099129795</bou_uid>
|
||||
<prj_uid>2901603085e4ae7e3604aa4076057940</prj_uid>
|
||||
<dia_uid>9636628415e4ae7e3624dc3037395819</dia_uid>
|
||||
<element_uid>1504066335e4ae80c9dfa36023087714</element_uid>
|
||||
<bou_element>6454338745e4ae7e4c76cd0081476745</bou_element>
|
||||
<bou_element_type>bpmnActivity</bou_element_type>
|
||||
<bou_x>149</bou_x>
|
||||
<bou_y>85</bou_y>
|
||||
<bou_width>150</bou_width>
|
||||
<bou_height>75</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<bou_uid>8131500245e4ae80ca6b257014649755</bou_uid>
|
||||
<prj_uid>2901603085e4ae7e3604aa4076057940</prj_uid>
|
||||
<dia_uid>9636628415e4ae7e3624dc3037395819</dia_uid>
|
||||
<element_uid>9261250285e4ae80ca66b69047886070</element_uid>
|
||||
<bou_element>6454338745e4ae7e4c76cd0081476745</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>340</bou_x>
|
||||
<bou_y>106</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
</table>
|
||||
<table name="DATA"/>
|
||||
<table name="DIAGRAM">
|
||||
<record>
|
||||
<dia_uid>9636628415e4ae7e3624dc3037395819</dia_uid>
|
||||
<prj_uid>2901603085e4ae7e3604aa4076057940</prj_uid>
|
||||
<dia_name>p1normal-2</dia_name>
|
||||
<dia_is_closable>0</dia_is_closable>
|
||||
</record>
|
||||
</table>
|
||||
<table name="DOCUMENTATION"/>
|
||||
<table name="EVENT">
|
||||
<record>
|
||||
<evn_uid>4992899745e4ae80ca4eb50099975191</evn_uid>
|
||||
<prj_uid>2901603085e4ae7e3604aa4076057940</prj_uid>
|
||||
<pro_uid>9851695265e4ae7e362d623005016495</pro_uid>
|
||||
<evn_name></evn_name>
|
||||
<evn_type>START</evn_type>
|
||||
<evn_marker>EMPTY</evn_marker>
|
||||
<evn_is_interrupting>1</evn_is_interrupting>
|
||||
<evn_attached_to></evn_attached_to>
|
||||
<evn_cancel_activity>0</evn_cancel_activity>
|
||||
<evn_activity_ref></evn_activity_ref>
|
||||
<evn_wait_for_completion>0</evn_wait_for_completion>
|
||||
<evn_error_name></evn_error_name>
|
||||
<evn_error_code></evn_error_code>
|
||||
<evn_escalation_name></evn_escalation_name>
|
||||
<evn_escalation_code></evn_escalation_code>
|
||||
<evn_condition></evn_condition>
|
||||
<evn_message>LEAD</evn_message>
|
||||
<evn_operation_name></evn_operation_name>
|
||||
<evn_operation_implementation_ref></evn_operation_implementation_ref>
|
||||
<evn_time_date></evn_time_date>
|
||||
<evn_time_cycle></evn_time_cycle>
|
||||
<evn_time_duration></evn_time_duration>
|
||||
<evn_behavior>CATCH</evn_behavior>
|
||||
<bou_uid>1362127075e4ae80ca52e44078025638</bou_uid>
|
||||
<dia_uid>9636628415e4ae7e3624dc3037395819</dia_uid>
|
||||
<element_uid>4992899745e4ae80ca4eb50099975191</element_uid>
|
||||
<bou_element>6454338745e4ae7e4c76cd0081476745</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>71</bou_x>
|
||||
<bou_y>106</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<evn_uid>9261250285e4ae80ca66b69047886070</evn_uid>
|
||||
<prj_uid>2901603085e4ae7e3604aa4076057940</prj_uid>
|
||||
<pro_uid>9851695265e4ae7e362d623005016495</pro_uid>
|
||||
<evn_name></evn_name>
|
||||
<evn_type>END</evn_type>
|
||||
<evn_marker>EMPTY</evn_marker>
|
||||
<evn_is_interrupting>1</evn_is_interrupting>
|
||||
<evn_attached_to></evn_attached_to>
|
||||
<evn_cancel_activity>0</evn_cancel_activity>
|
||||
<evn_activity_ref></evn_activity_ref>
|
||||
<evn_wait_for_completion>0</evn_wait_for_completion>
|
||||
<evn_error_name></evn_error_name>
|
||||
<evn_error_code></evn_error_code>
|
||||
<evn_escalation_name></evn_escalation_name>
|
||||
<evn_escalation_code></evn_escalation_code>
|
||||
<evn_condition></evn_condition>
|
||||
<evn_message></evn_message>
|
||||
<evn_operation_name></evn_operation_name>
|
||||
<evn_operation_implementation_ref></evn_operation_implementation_ref>
|
||||
<evn_time_date></evn_time_date>
|
||||
<evn_time_cycle></evn_time_cycle>
|
||||
<evn_time_duration></evn_time_duration>
|
||||
<evn_behavior>THROW</evn_behavior>
|
||||
<bou_uid>8131500245e4ae80ca6b257014649755</bou_uid>
|
||||
<dia_uid>9636628415e4ae7e3624dc3037395819</dia_uid>
|
||||
<element_uid>9261250285e4ae80ca66b69047886070</element_uid>
|
||||
<bou_element>6454338745e4ae7e4c76cd0081476745</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>340</bou_x>
|
||||
<bou_y>106</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
</table>
|
||||
<table name="EXTENSION"/>
|
||||
<table name="FLOW">
|
||||
<record>
|
||||
<flo_uid>6083885985e4ae80ca89b78043675914</flo_uid>
|
||||
<prj_uid>2901603085e4ae7e3604aa4076057940</prj_uid>
|
||||
<dia_uid>9636628415e4ae7e3624dc3037395819</dia_uid>
|
||||
<flo_type>SEQUENCE</flo_type>
|
||||
<flo_name> </flo_name>
|
||||
<flo_element_origin>1504066335e4ae80c9dfa36023087714</flo_element_origin>
|
||||
<flo_element_origin_type>bpmnActivity</flo_element_origin_type>
|
||||
<flo_element_origin_port>0</flo_element_origin_port>
|
||||
<flo_element_dest>9261250285e4ae80ca66b69047886070</flo_element_dest>
|
||||
<flo_element_dest_type>bpmnEvent</flo_element_dest_type>
|
||||
<flo_element_dest_port>0</flo_element_dest_port>
|
||||
<flo_is_inmediate>1</flo_is_inmediate>
|
||||
<flo_condition></flo_condition>
|
||||
<flo_x1>300</flo_x1>
|
||||
<flo_y1>123</flo_y1>
|
||||
<flo_x2>340</flo_x2>
|
||||
<flo_y2>123</flo_y2>
|
||||
<flo_state><![CDATA[[{"x":300,"y":123},{"x":340,"y":123}]]]></flo_state>
|
||||
<flo_position>1</flo_position>
|
||||
</record>
|
||||
<record>
|
||||
<flo_uid>9279534135e4ae80ca889d2096180961</flo_uid>
|
||||
<prj_uid>2901603085e4ae7e3604aa4076057940</prj_uid>
|
||||
<dia_uid>9636628415e4ae7e3624dc3037395819</dia_uid>
|
||||
<flo_type>SEQUENCE</flo_type>
|
||||
<flo_name> </flo_name>
|
||||
<flo_element_origin>4992899745e4ae80ca4eb50099975191</flo_element_origin>
|
||||
<flo_element_origin_type>bpmnEvent</flo_element_origin_type>
|
||||
<flo_element_origin_port>0</flo_element_origin_port>
|
||||
<flo_element_dest>1504066335e4ae80c9dfa36023087714</flo_element_dest>
|
||||
<flo_element_dest_type>bpmnActivity</flo_element_dest_type>
|
||||
<flo_element_dest_port>0</flo_element_dest_port>
|
||||
<flo_is_inmediate>1</flo_is_inmediate>
|
||||
<flo_condition></flo_condition>
|
||||
<flo_x1>104</flo_x1>
|
||||
<flo_y1>123</flo_y1>
|
||||
<flo_x2>149</flo_x2>
|
||||
<flo_y2>123</flo_y2>
|
||||
<flo_state><![CDATA[[{"x":104,"y":123},{"x":149,"y":123}]]]></flo_state>
|
||||
<flo_position>1</flo_position>
|
||||
</record>
|
||||
</table>
|
||||
<table name="GATEWAY"/>
|
||||
<table name="LANE"/>
|
||||
<table name="LANESET"/>
|
||||
<table name="PARTICIPANT"/>
|
||||
<table name="PROCESS">
|
||||
<record>
|
||||
<pro_uid>9851695265e4ae7e362d623005016495</pro_uid>
|
||||
<prj_uid>2901603085e4ae7e3604aa4076057940</prj_uid>
|
||||
<dia_uid>9636628415e4ae7e3624dc3037395819</dia_uid>
|
||||
<pro_name>p1normal-2</pro_name>
|
||||
<pro_type>NONE</pro_type>
|
||||
<pro_is_executable>0</pro_is_executable>
|
||||
<pro_is_closed>0</pro_is_closed>
|
||||
<pro_is_subprocess>0</pro_is_subprocess>
|
||||
</record>
|
||||
</table>
|
||||
<table name="PROJECT">
|
||||
<record>
|
||||
<prj_uid>2901603085e4ae7e3604aa4076057940</prj_uid>
|
||||
<prj_name>p1normal-2</prj_name>
|
||||
<prj_description></prj_description>
|
||||
<prj_target_namespace></prj_target_namespace>
|
||||
<prj_expresion_language></prj_expresion_language>
|
||||
<prj_type_language></prj_type_language>
|
||||
<prj_exporter></prj_exporter>
|
||||
<prj_exporter_version></prj_exporter_version>
|
||||
<prj_create_date><![CDATA[2020-02-17 19:22:11]]></prj_create_date>
|
||||
<prj_update_date><![CDATA[2020-02-17 19:22:52]]></prj_update_date>
|
||||
<prj_author>00000000000000000000000000000001</prj_author>
|
||||
<prj_author_version></prj_author_version>
|
||||
<prj_original_source></prj_original_source>
|
||||
</record>
|
||||
</table>
|
||||
</definition>
|
||||
<definition class="workflow">
|
||||
<table name="process">
|
||||
<record>
|
||||
<pro_uid>2901603085e4ae7e3604aa4076057940</pro_uid>
|
||||
<pro_title>p1normal-2</pro_title>
|
||||
<pro_description></pro_description>
|
||||
<pro_parent>2901603085e4ae7e3604aa4076057940</pro_parent>
|
||||
<pro_time>1</pro_time>
|
||||
<pro_timeunit>DAYS</pro_timeunit>
|
||||
<pro_status>ACTIVE</pro_status>
|
||||
<pro_status_id>1</pro_status_id>
|
||||
<pro_type_day></pro_type_day>
|
||||
<pro_type>NORMAL</pro_type>
|
||||
<pro_assignment>FALSE</pro_assignment>
|
||||
<pro_show_map>0</pro_show_map>
|
||||
<pro_show_message>0</pro_show_message>
|
||||
<pro_subprocess>0</pro_subprocess>
|
||||
<pro_tri_create></pro_tri_create>
|
||||
<pro_tri_open></pro_tri_open>
|
||||
<pro_tri_deleted></pro_tri_deleted>
|
||||
<pro_tri_canceled></pro_tri_canceled>
|
||||
<pro_tri_paused></pro_tri_paused>
|
||||
<pro_tri_reassigned></pro_tri_reassigned>
|
||||
<pro_tri_unpaused></pro_tri_unpaused>
|
||||
<pro_type_process>PUBLIC</pro_type_process>
|
||||
<pro_show_delegate>0</pro_show_delegate>
|
||||
<pro_show_dynaform>0</pro_show_dynaform>
|
||||
<pro_category></pro_category>
|
||||
<pro_sub_category></pro_sub_category>
|
||||
<pro_industry>0</pro_industry>
|
||||
<pro_update_date><![CDATA[2020-02-17 19:22:52]]></pro_update_date>
|
||||
<pro_create_date><![CDATA[2020-02-17 19:22:11]]></pro_create_date>
|
||||
<pro_create_user>00000000000000000000000000000001</pro_create_user>
|
||||
<pro_height>5000</pro_height>
|
||||
<pro_width>10000</pro_width>
|
||||
<pro_title_x>0</pro_title_x>
|
||||
<pro_title_y>0</pro_title_y>
|
||||
<pro_debug>0</pro_debug>
|
||||
<pro_dynaforms></pro_dynaforms>
|
||||
<pro_derivation_screen_tpl></pro_derivation_screen_tpl>
|
||||
<pro_cost>0</pro_cost>
|
||||
<pro_unit_cost></pro_unit_cost>
|
||||
<pro_itee>1</pro_itee>
|
||||
<pro_action_done><![CDATA[a:1:{i:0;s:41:"GATEWAYTOGATEWAY_DELETE_CORRUPTED_RECORDS";}]]></pro_action_done>
|
||||
<category_id>0</category_id>
|
||||
<pro_category_label>No Category</pro_category_label>
|
||||
<pro_bpmn>1</pro_bpmn>
|
||||
</record>
|
||||
</table>
|
||||
<table name="tasks">
|
||||
<record>
|
||||
<pro_uid>2901603085e4ae7e3604aa4076057940</pro_uid>
|
||||
<pro_id>0</pro_id>
|
||||
<tas_uid>1504066335e4ae80c9dfa36023087714</tas_uid>
|
||||
<tas_title>Task 1</tas_title>
|
||||
<tas_description></tas_description>
|
||||
<tas_def_title></tas_def_title>
|
||||
<tas_def_subject_message></tas_def_subject_message>
|
||||
<tas_def_proc_code></tas_def_proc_code>
|
||||
<tas_def_message></tas_def_message>
|
||||
<tas_def_description></tas_def_description>
|
||||
<tas_type>NORMAL</tas_type>
|
||||
<tas_duration>1</tas_duration>
|
||||
<tas_delay_type></tas_delay_type>
|
||||
<tas_temporizer>0</tas_temporizer>
|
||||
<tas_type_day></tas_type_day>
|
||||
<tas_timeunit>DAYS</tas_timeunit>
|
||||
<tas_alert>FALSE</tas_alert>
|
||||
<tas_priority_variable></tas_priority_variable>
|
||||
<tas_assign_type>BALANCED</tas_assign_type>
|
||||
<tas_assign_variable><![CDATA[@@SYS_NEXT_USER_TO_BE_ASSIGNED]]></tas_assign_variable>
|
||||
<tas_group_variable></tas_group_variable>
|
||||
<tas_mi_instance_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCE]]></tas_mi_instance_variable>
|
||||
<tas_mi_complete_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCES_COMPLETE]]></tas_mi_complete_variable>
|
||||
<tas_assign_location>FALSE</tas_assign_location>
|
||||
<tas_assign_location_adhoc>FALSE</tas_assign_location_adhoc>
|
||||
<tas_transfer_fly>FALSE</tas_transfer_fly>
|
||||
<tas_last_assigned>0</tas_last_assigned>
|
||||
<tas_user>0</tas_user>
|
||||
<tas_can_upload>FALSE</tas_can_upload>
|
||||
<tas_view_upload>FALSE</tas_view_upload>
|
||||
<tas_view_additional_documentation>FALSE</tas_view_additional_documentation>
|
||||
<tas_can_cancel>FALSE</tas_can_cancel>
|
||||
<tas_owner_app>FALSE</tas_owner_app>
|
||||
<stg_uid></stg_uid>
|
||||
<tas_can_pause>FALSE</tas_can_pause>
|
||||
<tas_can_send_message>TRUE</tas_can_send_message>
|
||||
<tas_can_delete_docs>FALSE</tas_can_delete_docs>
|
||||
<tas_self_service>FALSE</tas_self_service>
|
||||
<tas_start>TRUE</tas_start>
|
||||
<tas_to_last_user>FALSE</tas_to_last_user>
|
||||
<tas_send_last_email>FALSE</tas_send_last_email>
|
||||
<tas_derivation>NORMAL</tas_derivation>
|
||||
<tas_posx>149</tas_posx>
|
||||
<tas_posy>85</tas_posy>
|
||||
<tas_width>110</tas_width>
|
||||
<tas_height>60</tas_height>
|
||||
<tas_color></tas_color>
|
||||
<tas_evn_uid></tas_evn_uid>
|
||||
<tas_boundary></tas_boundary>
|
||||
<tas_derivation_screen_tpl></tas_derivation_screen_tpl>
|
||||
<tas_selfservice_timeout>0</tas_selfservice_timeout>
|
||||
<tas_selfservice_time>0</tas_selfservice_time>
|
||||
<tas_selfservice_time_unit></tas_selfservice_time_unit>
|
||||
<tas_selfservice_trigger_uid></tas_selfservice_trigger_uid>
|
||||
<tas_selfservice_execution>EVERY_TIME</tas_selfservice_execution>
|
||||
<tas_not_email_from_format>0</tas_not_email_from_format>
|
||||
<tas_offline>FALSE</tas_offline>
|
||||
<tas_email_server_uid></tas_email_server_uid>
|
||||
<tas_auto_root>FALSE</tas_auto_root>
|
||||
<tas_receive_server_uid></tas_receive_server_uid>
|
||||
<tas_receive_last_email>FALSE</tas_receive_last_email>
|
||||
<tas_receive_email_from_format>0</tas_receive_email_from_format>
|
||||
<tas_receive_message_type>text</tas_receive_message_type>
|
||||
<tas_receive_message_template>alert_message.html</tas_receive_message_template>
|
||||
<tas_receive_subject_message></tas_receive_subject_message>
|
||||
<tas_receive_message></tas_receive_message>
|
||||
<tas_average></tas_average>
|
||||
<tas_sdv></tas_sdv>
|
||||
</record>
|
||||
</table>
|
||||
<table name="routes">
|
||||
<record>
|
||||
<rou_uid>7485895665e4ae80caf6d26036797829</rou_uid>
|
||||
<rou_parent>0</rou_parent>
|
||||
<pro_uid>2901603085e4ae7e3604aa4076057940</pro_uid>
|
||||
<tas_uid>1504066335e4ae80c9dfa36023087714</tas_uid>
|
||||
<rou_next_task>-1</rou_next_task>
|
||||
<rou_case>1</rou_case>
|
||||
<rou_type>SEQUENTIAL</rou_type>
|
||||
<rou_default>0</rou_default>
|
||||
<rou_condition></rou_condition>
|
||||
<rou_to_last_user>FALSE</rou_to_last_user>
|
||||
<rou_optional>FALSE</rou_optional>
|
||||
<rou_send_email>TRUE</rou_send_email>
|
||||
<rou_sourceanchor>1</rou_sourceanchor>
|
||||
<rou_targetanchor>0</rou_targetanchor>
|
||||
<rou_to_port>1</rou_to_port>
|
||||
<rou_from_port>2</rou_from_port>
|
||||
<rou_evn_uid></rou_evn_uid>
|
||||
<gat_uid></gat_uid>
|
||||
</record>
|
||||
</table>
|
||||
<table name="lanes"/>
|
||||
<table name="gateways"/>
|
||||
<table name="inputs"/>
|
||||
<table name="outputs"/>
|
||||
<table name="dynaforms"/>
|
||||
<table name="steps"/>
|
||||
<table name="triggers"/>
|
||||
<table name="taskusers"/>
|
||||
<table name="groupwfs"/>
|
||||
<table name="steptriggers"/>
|
||||
<table name="dbconnections"/>
|
||||
<table name="reportTables"/>
|
||||
<table name="reportTablesVars"/>
|
||||
<table name="stepSupervisor"/>
|
||||
<table name="objectPermissions"/>
|
||||
<table name="subProcess"/>
|
||||
<table name="caseTracker"/>
|
||||
<table name="caseTrackerObject"/>
|
||||
<table name="stage"/>
|
||||
<table name="fieldCondition"/>
|
||||
<table name="event"/>
|
||||
<table name="caseScheduler"/>
|
||||
<table name="processCategory"/>
|
||||
<table name="taskExtraProperties"/>
|
||||
<table name="processUser"/>
|
||||
<table name="processVariables"/>
|
||||
<table name="webEntry"/>
|
||||
<table name="webEntryEvent"/>
|
||||
<table name="messageType"/>
|
||||
<table name="messageTypeVariable"/>
|
||||
<table name="messageEventDefinition"/>
|
||||
<table name="scriptTask"/>
|
||||
<table name="timerEvent"/>
|
||||
<table name="emailEvent"/>
|
||||
<table name="filesManager"/>
|
||||
<table name="abeConfiguration"/>
|
||||
<table name="elementTask"/>
|
||||
</definition>
|
||||
<workflow-files/>
|
||||
</ProcessMaker-Project>
|
||||
211
tests/unit/gulliver/system/CodeScannerTest.php
Normal file
211
tests/unit/gulliver/system/CodeScannerTest.php
Normal file
@@ -0,0 +1,211 @@
|
||||
<?php
|
||||
|
||||
namespace Tests\unit\gulliver\system;
|
||||
|
||||
use CodeScanner;
|
||||
use G;
|
||||
use ProcessMaker\Core\System;
|
||||
use Tests\TestCase;
|
||||
|
||||
/**
|
||||
* @coversDefaultClass \CodeScanner
|
||||
*
|
||||
* This test require have the following configurations enable:
|
||||
* @link https://wiki.processmaker.com/Plugin_Trigger_Code_Security_Scanner_v2
|
||||
*/
|
||||
class CodeScannerTest extends TestCase
|
||||
{
|
||||
private $backupEnvIni;
|
||||
private $pathBlackListIni;
|
||||
private $pathEnvIni;
|
||||
private $pathPlugin;
|
||||
private $pluginName = 'pmTest'; // Define the name of the plugin for the test
|
||||
|
||||
/**
|
||||
* Call the setUp parent method and create some *.ini files
|
||||
*/
|
||||
public function setUp()
|
||||
{
|
||||
parent::setUp(); // TODO: Change the autogenerated stub
|
||||
|
||||
// Define the path of blacklist.ini
|
||||
$this->pathBlackListIni = PATH_CONFIG . "blacklist.ini";
|
||||
|
||||
// Creating a custom Blacklist
|
||||
if (!file_exists($this->pathBlackListIni)) {
|
||||
$myfile = fopen($this->pathBlackListIni, "w");
|
||||
fwrite($myfile, ";Classes
|
||||
;=======
|
||||
DashletInterface
|
||||
|
||||
;Functions
|
||||
;=========
|
||||
eval
|
||||
exec
|
||||
assert
|
||||
preg_replace
|
||||
create_function
|
||||
|
||||
;Information Disclosure
|
||||
;======================
|
||||
phpinfo
|
||||
posix_mkfifo
|
||||
posix_getlogin
|
||||
posix_ttyname
|
||||
getenv
|
||||
get_current_user
|
||||
proc_get_status
|
||||
get_cfg_var
|
||||
disk_free_space
|
||||
disk_total_space
|
||||
diskfreespace
|
||||
getcwd
|
||||
getmygid
|
||||
getmyinode
|
||||
getmypid
|
||||
getmyuid");
|
||||
}
|
||||
|
||||
// Define the path of env.ini
|
||||
$this->pathEnvIni = PATH_CONFIG . "env.ini";
|
||||
|
||||
// Create a backup of the current env.ini
|
||||
if (file_exists($this->pathEnvIni)) {
|
||||
$this->backupEnvIni = file_get_contents($this->pathEnvIni);
|
||||
}
|
||||
|
||||
// Configuring the env.ini file
|
||||
file_put_contents($this->pathEnvIni, "enable_blacklist = 1;");
|
||||
|
||||
// Define the path of the plugin
|
||||
$this->pathPlugin = PATH_PLUGINS . $this->pluginName . PATH_SEP;
|
||||
|
||||
// Create the plugin
|
||||
G::mk_dir($this->pathPlugin, 0777);
|
||||
|
||||
// Add a file into the plugin
|
||||
if (!file_exists($this->pathPlugin . "test_1.php")) {
|
||||
// Create a file in the plugin with PHP code
|
||||
$myfile = fopen($this->pathPlugin . "test_1.php", "w");
|
||||
fwrite($myfile, "<?php
|
||||
phpinfo();"
|
||||
);
|
||||
}
|
||||
|
||||
// Add a file into the plugin
|
||||
if (!file_exists($this->pathPlugin . "test_2.php")) {
|
||||
// Create a file in the plugin with PHP code
|
||||
$myfile = fopen($this->pathPlugin . "test_2.php", "w");
|
||||
fwrite($myfile, "<?php
|
||||
phpinfo();"
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Call the tearDown parent method and remove some files created
|
||||
*/
|
||||
public function tearDown()
|
||||
{
|
||||
parent::tearDown();
|
||||
|
||||
// Remove the plugin created
|
||||
G::rm_dir($this->pathPlugin);
|
||||
|
||||
// Remove the blacklist created
|
||||
G::rm_dir($this->pathBlackListIni);
|
||||
|
||||
// Restore the backup of the env.ini
|
||||
file_put_contents($this->pathEnvIni, $this->backupEnvIni);
|
||||
}
|
||||
|
||||
/**
|
||||
* It test the scope obtained with null parameter
|
||||
*
|
||||
* @covers ::__construct()
|
||||
* @covers ::getScope()
|
||||
* @test
|
||||
*/
|
||||
public function it_check_get_scope_configured()
|
||||
{
|
||||
$configurations = System::getSystemConfiguration('', '', config("system.workspace"));
|
||||
|
||||
// Instance with null parameter
|
||||
$codeScanner = new CodeScanner(null);
|
||||
$scope = $codeScanner->getScope();
|
||||
$this->assertEquals($scope, explode(',', str_replace(' ', '', $configurations['code_scanner_scope'])));
|
||||
|
||||
// Instance with string parameter
|
||||
$codeScanner = new CodeScanner(config("system.workspace"));
|
||||
$scope = $codeScanner->getScope();
|
||||
$this->assertEquals($scope, explode(',', str_replace(' ', '', $configurations['code_scanner_scope'])));
|
||||
|
||||
// Instance with bool parameter
|
||||
$codeScanner = new CodeScanner(true);
|
||||
$scope = $codeScanner->getScope();
|
||||
$this->isEmpty($scope);
|
||||
}
|
||||
|
||||
/**
|
||||
* It tests disable code without black list
|
||||
*
|
||||
* @covers ::__construct()
|
||||
* @covers ::checkDisabledCode()
|
||||
* @test
|
||||
*/
|
||||
public function it_check_disabled_code_without_blacklist()
|
||||
{
|
||||
// If the blacklist.ini was created we need to remove
|
||||
G::rm_dir($this->pathBlackListIni);
|
||||
|
||||
// Instance with default parameter
|
||||
$codeScanner = new CodeScanner();
|
||||
$phpCode = 'phpinfo();';
|
||||
|
||||
// parameter SOURCE
|
||||
$result = $codeScanner->checkDisabledCode('SOURCE', $phpCode);
|
||||
$this->assertEmpty($result);
|
||||
|
||||
// parameter FILE
|
||||
$result = $codeScanner->checkDisabledCode('FILE', $this->pathPlugin . 'test_1.php');
|
||||
$this->assertEmpty($result);
|
||||
|
||||
// parameter PATH
|
||||
$result = $codeScanner->checkDisabledCode('PATH', $this->pathPlugin);
|
||||
$this->assertEmpty($result);
|
||||
}
|
||||
|
||||
/**
|
||||
* It tests disable code with black list
|
||||
* This test require two configurations enable_blacklist and blacklist.ini
|
||||
*
|
||||
* @covers ::__construct()
|
||||
* @covers ::checkDisabledCode()
|
||||
* @covers ::checkDisabledCodeInSource()
|
||||
* @test
|
||||
*/
|
||||
public function it_check_disabled_code()
|
||||
{
|
||||
// Check if the blacklist.ini was created
|
||||
if (file_exists($this->pathBlackListIni)) {
|
||||
$codeScanner = new CodeScanner();
|
||||
$phpCode = 'phpinfo();';
|
||||
|
||||
// parameter SOURCE
|
||||
$result = $codeScanner->checkDisabledCode('SOURCE', $phpCode);
|
||||
$this->assertNotEmpty($result);
|
||||
|
||||
// parameter FILE
|
||||
$result = $codeScanner->checkDisabledCode('FILE', $this->pathPlugin . 'test_1.php');
|
||||
$this->assertNotEmpty($result);
|
||||
|
||||
// parameter PATH
|
||||
$result = $codeScanner->checkDisabledCode('PATH', $this->pathPlugin);
|
||||
$this->assertNotEmpty($result);
|
||||
} else {
|
||||
$this->markTestIncomplete(
|
||||
'Please check the configurations to the Code Security Scanner'
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -3,8 +3,12 @@
|
||||
namespace Tests\unit\gulliver\system;
|
||||
|
||||
use G;
|
||||
use MonologProvider;
|
||||
use Tests\TestCase;
|
||||
|
||||
/**
|
||||
* @coversDefaultClass \G
|
||||
*/
|
||||
class gTest extends TestCase
|
||||
{
|
||||
/**
|
||||
@@ -350,4 +354,27 @@ class gTest extends TestCase
|
||||
$this->assertContains($word, $res);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* It tests if the errors related to the trigger execution was registered
|
||||
*
|
||||
* @covers ::logTriggerExecution
|
||||
* @test
|
||||
*/
|
||||
public function it_check_log_trigger_execution()
|
||||
{
|
||||
$data = [];
|
||||
$error = 'This is some error';
|
||||
$_SESSION['_DATA_TRIGGER_']['_TRI_LOG_'] = false;
|
||||
G::logTriggerExecution($data, $error, 'FATAL_ERROR', 60);
|
||||
$log = MonologProvider::getSingleton('TriggerExecutionError', 'processmaker.log', true);
|
||||
$this->assertNotEmpty($log->getPathFile());
|
||||
$this->assertTrue($_SESSION['_DATA_TRIGGER_']['_TRI_LOG_']);
|
||||
|
||||
$_SESSION['_DATA_TRIGGER_']['_TRI_LOG_'] = false;
|
||||
G::logTriggerExecution($data, '', '', 100);
|
||||
$log = MonologProvider::getSingleton('TriggerExecution', 'processmaker.log', true);
|
||||
$this->assertNotEmpty($log->getPathFile());
|
||||
$this->assertFalse($_SESSION['_DATA_TRIGGER_']['_TRI_LOG_']);
|
||||
}
|
||||
}
|
||||
370
tests/unit/workflow/engine/classes/CasesTest.php
Normal file
370
tests/unit/workflow/engine/classes/CasesTest.php
Normal file
@@ -0,0 +1,370 @@
|
||||
<?php
|
||||
|
||||
namespace Tests\unit\workflow\engine\classes;
|
||||
|
||||
use Cases;
|
||||
use ProcessMaker\Model\Application;
|
||||
use ProcessMaker\Model\Delegation;
|
||||
use ProcessMaker\Model\Process;
|
||||
use ProcessMaker\Model\Step;
|
||||
use Tests\TestCase;
|
||||
|
||||
class CasesTest extends TestCase
|
||||
{
|
||||
protected $preserveGlobalState = false;
|
||||
protected $runTestInSeparateProcess = true;
|
||||
|
||||
/**
|
||||
* Call setUp method
|
||||
*/
|
||||
public function setUp()
|
||||
{
|
||||
parent::setUp(); // TODO: Change the autogenerated stub
|
||||
}
|
||||
|
||||
/**
|
||||
* Test getNextStep method with no steps
|
||||
*
|
||||
* @covers \Cases::getNextStep()
|
||||
* @test
|
||||
*/
|
||||
public function it_should_test_get_next_step_method()
|
||||
{
|
||||
$process = factory(Process::class)->create();
|
||||
$application = factory(Application::class)->create(['PRO_UID' => $process->PRO_UID]);
|
||||
$appDelegation = factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'DEL_INDEX' => 2,
|
||||
'DEL_PREVIOUS' => $appDelegation->DEL_INDEX
|
||||
]);
|
||||
$cases = new Cases();
|
||||
$res = $cases->getNextStep($process->PRO_UID, $application->APP_UID, $appDelegation->DEL_INDEX);
|
||||
|
||||
$this->assertCount(4, $res);
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests the getNextStep method with step
|
||||
*
|
||||
* @covers \Cases::getNextStep()
|
||||
* @test
|
||||
*/
|
||||
public function it_should_test_get_next_step_method_position()
|
||||
{
|
||||
$process = factory(Process::class)->create();
|
||||
$application = factory(Application::class)->create(['PRO_UID' => $process->PRO_UID]);
|
||||
$appDelegation = factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'DEL_INDEX' => 2,
|
||||
'DEL_PREVIOUS' => $appDelegation->DEL_INDEX
|
||||
]);
|
||||
factory(Step::class)->create([
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'TAS_UID' => $appDelegation->TAS_UID,
|
||||
'STEP_POSITION' => 2,
|
||||
'STEP_CONDITION' => '1 == 1'
|
||||
]);
|
||||
$cases = new Cases();
|
||||
$res = $cases->getNextStep($process->PRO_UID, $application->APP_UID, $appDelegation->DEL_INDEX, 1);
|
||||
$this->assertCount(4, $res);
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests the getNextStep method with output document
|
||||
*
|
||||
* @covers \Cases::getNextStep()
|
||||
* @test
|
||||
*/
|
||||
public function it_should_test_get_next_step_method_output_document()
|
||||
{
|
||||
$process = factory(Process::class)->create();
|
||||
$application = factory(Application::class)->create(['PRO_UID' => $process->PRO_UID]);
|
||||
$appDelegation = factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'DEL_INDEX' => 2,
|
||||
'DEL_PREVIOUS' => $appDelegation->DEL_INDEX
|
||||
]);
|
||||
factory(Step::class)->create([
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'TAS_UID' => $appDelegation->TAS_UID,
|
||||
'STEP_POSITION' => 2,
|
||||
'STEP_CONDITION' => '1 == 1',
|
||||
'STEP_TYPE_OBJ' => 'OUTPUT_DOCUMENT'
|
||||
]);
|
||||
$cases = new Cases();
|
||||
$res = $cases->getNextStep($process->PRO_UID, $application->APP_UID, $appDelegation->DEL_INDEX, 1);
|
||||
$this->assertCount(4, $res);
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests the getNextStep method with input document
|
||||
*
|
||||
* @covers \Cases::getNextStep()
|
||||
* @test
|
||||
*/
|
||||
public function it_should_test_get_next_step_method_input_document()
|
||||
{
|
||||
$process = factory(Process::class)->create();
|
||||
$application = factory(Application::class)->create(['PRO_UID' => $process->PRO_UID]);
|
||||
$appDelegation = factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'DEL_INDEX' => 2,
|
||||
'DEL_PREVIOUS' => $appDelegation->DEL_INDEX
|
||||
]);
|
||||
factory(Step::class)->create([
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'TAS_UID' => $appDelegation->TAS_UID,
|
||||
'STEP_POSITION' => 2,
|
||||
'STEP_CONDITION' => '1 == 1',
|
||||
'STEP_TYPE_OBJ' => 'INPUT_DOCUMENT'
|
||||
]);
|
||||
$cases = new Cases();
|
||||
$res = $cases->getNextStep($process->PRO_UID, $application->APP_UID, $appDelegation->DEL_INDEX, 1);
|
||||
$this->assertCount(4, $res);
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests the getNextStep method with external document
|
||||
*
|
||||
* @covers \Cases::getNextStep()
|
||||
* @test
|
||||
*/
|
||||
public function it_should_test_get_next_step_method_external()
|
||||
{
|
||||
$process = factory(Process::class)->create();
|
||||
$application = factory(Application::class)->create(['PRO_UID' => $process->PRO_UID]);
|
||||
$appDelegation = factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'DEL_INDEX' => 2,
|
||||
'DEL_PREVIOUS' => $appDelegation->DEL_INDEX
|
||||
]);
|
||||
factory(Step::class)->create([
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'TAS_UID' => $appDelegation->TAS_UID,
|
||||
'STEP_POSITION' => 2,
|
||||
'STEP_CONDITION' => '1 == 1',
|
||||
'STEP_TYPE_OBJ' => 'EXTERNAL'
|
||||
]);
|
||||
$cases = new Cases();
|
||||
$res = $cases->getNextStep($process->PRO_UID, $application->APP_UID, $appDelegation->DEL_INDEX, 1);
|
||||
$this->assertCount(4, $res);
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests the getNextStep method with message step
|
||||
*
|
||||
* @covers \Cases::getNextStep()
|
||||
* @test
|
||||
*/
|
||||
public function it_should_test_get_next_step_method_message()
|
||||
{
|
||||
$process = factory(Process::class)->create();
|
||||
$application = factory(Application::class)->create(['PRO_UID' => $process->PRO_UID]);
|
||||
$appDelegation = factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'DEL_INDEX' => 2,
|
||||
'DEL_PREVIOUS' => $appDelegation->DEL_INDEX
|
||||
]);
|
||||
factory(Step::class)->create([
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'TAS_UID' => $appDelegation->TAS_UID,
|
||||
'STEP_POSITION' => 2,
|
||||
'STEP_CONDITION' => '1 == 1',
|
||||
'STEP_TYPE_OBJ' => 'MESSAGE'
|
||||
]);
|
||||
$cases = new Cases();
|
||||
$res = $cases->getNextStep($process->PRO_UID, $application->APP_UID, $appDelegation->DEL_INDEX, 1);
|
||||
$this->assertCount(4, $res);
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests the getNextStep method when the step does not exist
|
||||
*
|
||||
* @covers \Cases::getNextStep()
|
||||
* @test
|
||||
*/
|
||||
public function it_should_test_get_next_step_method_step_does_not_exists()
|
||||
{
|
||||
$process = factory(Process::class)->create();
|
||||
$application = factory(Application::class)->create(['PRO_UID' => $process->PRO_UID]);
|
||||
$appDelegation = factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'DEL_INDEX' => 2,
|
||||
'DEL_PREVIOUS' => $appDelegation->DEL_INDEX
|
||||
]);
|
||||
$cases = new Cases();
|
||||
$this->expectExceptionMessage("**ID_STEP_DOES_NOT_EXIST**");
|
||||
$res = $cases->getNextStep($process->PRO_UID, $application->APP_UID, $appDelegation->DEL_INDEX, 1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests the getNextStep method when there is an exception
|
||||
*
|
||||
* @covers \Cases::getNextStep()
|
||||
* @test
|
||||
*/
|
||||
public function it_should_test_get_next_step_method_step_exception()
|
||||
{
|
||||
$cases = new Cases();
|
||||
$this->expectExceptionMessage("The Application row '' doesn't exist!");
|
||||
$res = $cases->getNextStep();
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests the getNextStep method when the result is false
|
||||
*
|
||||
* @covers \Cases::getNextStep()
|
||||
* @test
|
||||
*/
|
||||
public function it_should_test_get_next_step_method_step_false()
|
||||
{
|
||||
$process = factory(Process::class)->create();
|
||||
$application = factory(Application::class)->create();
|
||||
$appDelegation = factory(Delegation::class)->create();
|
||||
$cases = new Cases();
|
||||
$res = $cases->getNextStep($process->PRO_UID, $application->APP_UID, $appDelegation->DEL_INDEX);
|
||||
$this->assertFalse($res);
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests the getNextStep method when there is a gmail account
|
||||
*
|
||||
* @covers \Cases::getNextStep()
|
||||
* @test
|
||||
*/
|
||||
public function it_should_test_get_next_step_method_gmail()
|
||||
{
|
||||
$_SESSION['gmail'] = '';
|
||||
$process = factory(Process::class)->create();
|
||||
$application = factory(Application::class)->create(['PRO_UID' => $process->PRO_UID]);
|
||||
$appDelegation = factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'DEL_INDEX' => 2,
|
||||
'DEL_PREVIOUS' => $appDelegation->DEL_INDEX
|
||||
]);
|
||||
factory(Step::class)->create([
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'TAS_UID' => $appDelegation->TAS_UID,
|
||||
'STEP_POSITION' => 2,
|
||||
'STEP_CONDITION' => '1 == 1',
|
||||
'STEP_TYPE_OBJ' => 'MESSAGE'
|
||||
]);
|
||||
$cases = new Cases();
|
||||
$res = $cases->getNextStep($process->PRO_UID, $application->APP_UID, $appDelegation->DEL_INDEX, 1);
|
||||
$this->assertCount(4, $res);
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests the getNextStep method when there is a gmail account related to the next step
|
||||
*
|
||||
* @covers \Cases::getNextStep()
|
||||
* @test
|
||||
*/
|
||||
public function it_should_test_get_next_step_method_gmail_nextstep()
|
||||
{
|
||||
$_SESSION['gmail'] = '';
|
||||
$process = factory(Process::class)->create();
|
||||
$application = factory(Application::class)->create(['PRO_UID' => $process->PRO_UID]);
|
||||
$appDelegation = factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'DEL_INDEX' => 2,
|
||||
'DEL_PREVIOUS' => $appDelegation->DEL_INDEX
|
||||
]);
|
||||
factory(Step::class)->create([
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'TAS_UID' => $appDelegation->TAS_UID,
|
||||
'STEP_POSITION' => 1,
|
||||
'STEP_CONDITION' => '1 == 1',
|
||||
'STEP_TYPE_OBJ' => 'MESSAGE'
|
||||
]);
|
||||
$cases = new Cases();
|
||||
$res = $cases->getNextStep($process->PRO_UID, $application->APP_UID, $appDelegation->DEL_INDEX, 1);
|
||||
$this->assertCount(4, $res);
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests the getNextStep method when the step condition is empty
|
||||
*
|
||||
* @covers \Cases::getNextStep()
|
||||
* @test
|
||||
*/
|
||||
public function it_should_test_get_next_step_method_condition_empty()
|
||||
{
|
||||
$_SESSION['gmail'] = '';
|
||||
$process = factory(Process::class)->create();
|
||||
$application = factory(Application::class)->create(['PRO_UID' => $process->PRO_UID]);
|
||||
$appDelegation = factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
factory(Delegation::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'DEL_INDEX' => 2,
|
||||
'DEL_PREVIOUS' => $appDelegation->DEL_INDEX
|
||||
]);
|
||||
factory(Step::class)->create([
|
||||
'PRO_UID' => $process->PRO_UID,
|
||||
'TAS_UID' => $appDelegation->TAS_UID,
|
||||
'STEP_POSITION' => 2,
|
||||
'STEP_CONDITION' => '',
|
||||
'STEP_TYPE_OBJ' => 'MESSAGE'
|
||||
]);
|
||||
$cases = new Cases();
|
||||
$res = $cases->getNextStep($process->PRO_UID, $application->APP_UID, $appDelegation->DEL_INDEX, 1);
|
||||
$this->assertCount(4, $res);
|
||||
}
|
||||
|
||||
/**
|
||||
* Call the tearDown method
|
||||
*/
|
||||
public function tearDown()
|
||||
{
|
||||
// The parent method needs to be override due to errors appearing
|
||||
}
|
||||
}
|
||||
@@ -438,24 +438,6 @@ class ProcessesTest extends TestCase
|
||||
*/
|
||||
public function it_should_get_workflow_data()
|
||||
{
|
||||
/**
|
||||
* To perform the test this requires a valid installation and its respective license.
|
||||
*
|
||||
* In the file "workflow/engine/classes/WorkspaceTools.php",
|
||||
* these lines need the db.php file.
|
||||
*
|
||||
* public function __construct($workspaceName)
|
||||
* {
|
||||
* $this->name = $workspaceName;
|
||||
* $this->path = PATH_DB . $this->name;
|
||||
* $this->dbPath = $this->path . '/db.php';
|
||||
* if ($this->workspaceExists()) {
|
||||
* $this->getDBInfo();
|
||||
* }
|
||||
* $this->setListContentMigrateTable();
|
||||
* }
|
||||
*/
|
||||
$this->markTestIncomplete("To perform the test this requires a valid installation and its respective license.");
|
||||
$process = factory(\ProcessMaker\Model\Process::class)->create();
|
||||
$processes = new Processes();
|
||||
$result = $processes->getWorkflowData($process->PRO_UID);
|
||||
|
||||
@@ -17,12 +17,20 @@ class ReportTablesTest extends TestCase
|
||||
/**
|
||||
* Sets up the unit tests.
|
||||
*/
|
||||
protected function setUp()
|
||||
public function setUp()
|
||||
{
|
||||
$this->markTestIncomplete();//@todo: Please correct this unit test
|
||||
parent::setUp();
|
||||
$_SERVER["REQUEST_URI"] = "";
|
||||
}
|
||||
|
||||
/**
|
||||
* Tear down the unit tests.
|
||||
*/
|
||||
public function tearDown()
|
||||
{
|
||||
parent::tearDown();
|
||||
}
|
||||
|
||||
/**
|
||||
* Check if the "populateTable" function returns an array value if entered all parameters.
|
||||
* @test
|
||||
@@ -31,7 +39,7 @@ class ReportTablesTest extends TestCase
|
||||
public function it_should_populating_data_with_all_parameters()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 1);
|
||||
$result = $this->prepareData($tableName);
|
||||
$connectionShortName = 'wf';
|
||||
$type = 'NORMAL';
|
||||
$fields = $result->fields;
|
||||
@@ -61,7 +69,7 @@ class ReportTablesTest extends TestCase
|
||||
public function it_should_populating_data_with_all_parameters_with_type_is_grid()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 18, true);
|
||||
$result = $this->prepareData($tableName, true);
|
||||
$connectionShortName = 'wf';
|
||||
$type = 'GRID';
|
||||
$fields = $result->fields;
|
||||
@@ -100,7 +108,7 @@ class ReportTablesTest extends TestCase
|
||||
public function it_should_populating_data_with_all_parameters_with_type_is_grid_null()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 19, true);
|
||||
$result = $this->prepareData($tableName, true);
|
||||
$connectionShortName = 'wf';
|
||||
$type = 'GRID';
|
||||
$fields = $result->fields;
|
||||
@@ -130,7 +138,7 @@ class ReportTablesTest extends TestCase
|
||||
public function this_should_populate_the_reports_table_only_with_the_mandatory_parameter_tableName()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 2);
|
||||
$result = $this->prepareData($tableName);
|
||||
|
||||
$reportTables = new ReportTables();
|
||||
$reportTables->populateTable($tableName);
|
||||
@@ -156,7 +164,7 @@ class ReportTablesTest extends TestCase
|
||||
public function this_should_populate_the_reports_table_with_the_connectionShortName_parameter()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 3);
|
||||
$result = $this->prepareData($tableName);
|
||||
$connectionShortName = 'wf';
|
||||
|
||||
$reportTables = new ReportTables();
|
||||
@@ -183,7 +191,7 @@ class ReportTablesTest extends TestCase
|
||||
public function this_should_populate_the_reports_table_with_the_connectionShortName_parameter_is_null()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 8);
|
||||
$result = $this->prepareData($tableName);
|
||||
$connectionShortName = null;
|
||||
|
||||
$reportTables = new ReportTables();
|
||||
@@ -210,7 +218,7 @@ class ReportTablesTest extends TestCase
|
||||
public function this_should_populate_the_reports_table_with_the_connectionShortName_parameter_is_incorrect_value()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 9);
|
||||
$result = $this->prepareData($tableName);
|
||||
$connectionShortName = G::generateUniqueID();
|
||||
|
||||
$reportTables = new ReportTables();
|
||||
@@ -237,7 +245,7 @@ class ReportTablesTest extends TestCase
|
||||
public function this_should_populate_the_reports_table_with_the_parameters_connectionShortName_type()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 4);
|
||||
$result = $this->prepareData($tableName);
|
||||
$connectionShortName = 'wf';
|
||||
$type = 'NORMAL';
|
||||
|
||||
@@ -265,7 +273,7 @@ class ReportTablesTest extends TestCase
|
||||
public function this_should_populate_the_reports_table_with_the_parameters_connectionShortName_type_is_grid()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 11);
|
||||
$result = $this->prepareData($tableName);
|
||||
$connectionShortName = 'wf';
|
||||
$type = 'GRID';
|
||||
|
||||
@@ -293,7 +301,7 @@ class ReportTablesTest extends TestCase
|
||||
public function this_should_populate_the_reports_table_with_the_parameters_connectionShortName_type_is_null()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 10);
|
||||
$result = $this->prepareData($tableName);
|
||||
$connectionShortName = 'wf';
|
||||
$type = null;
|
||||
|
||||
@@ -321,7 +329,7 @@ class ReportTablesTest extends TestCase
|
||||
public function this_should_populate_the_reports_table_with_the_parameters_connectionShortName_type_fields()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 5);
|
||||
$result = $this->prepareData($tableName);
|
||||
$connectionShortName = 'wf';
|
||||
$type = 'NORMAL';
|
||||
$fields = $result->fields;
|
||||
@@ -350,7 +358,7 @@ class ReportTablesTest extends TestCase
|
||||
public function this_should_populate_the_reports_table_with_the_parameters_connectionShortName_type_fields_is_null()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 12);
|
||||
$result = $this->prepareData($tableName);
|
||||
$connectionShortName = 'wf';
|
||||
$type = 'NORMAL';
|
||||
$fields = null;
|
||||
@@ -379,7 +387,7 @@ class ReportTablesTest extends TestCase
|
||||
public function this_should_populate_the_reports_table_with_the_parameters_connectionShortName_type_fields_is_empty_array()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 13);
|
||||
$result = $this->prepareData($tableName);
|
||||
$connectionShortName = 'wf';
|
||||
$type = 'NORMAL';
|
||||
$fields = [];
|
||||
@@ -408,7 +416,7 @@ class ReportTablesTest extends TestCase
|
||||
public function this_should_populate_the_reports_table_with_the_parameters_connectionShortName_type_fields_is_incorrect_value()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 14);
|
||||
$result = $this->prepareData($tableName);
|
||||
$connectionShortName = 'wf';
|
||||
$type = 'NORMAL';
|
||||
$fields = "";
|
||||
@@ -437,7 +445,7 @@ class ReportTablesTest extends TestCase
|
||||
public function this_should_populate_the_reports_table_with_the_parameters_connectionShortName_type_fields_proUid()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 6);
|
||||
$result = $this->prepareData($tableName);
|
||||
$connectionShortName = 'wf';
|
||||
$type = 'NORMAL';
|
||||
$fields = $result->fields;
|
||||
@@ -467,7 +475,7 @@ class ReportTablesTest extends TestCase
|
||||
public function this_should_populate_the_reports_table_with_the_parameters_connectionShortName_type_fields_proUid_is_null()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 15);
|
||||
$result = $this->prepareData($tableName);
|
||||
$connectionShortName = 'wf';
|
||||
$type = 'NORMAL';
|
||||
$fields = $result->fields;
|
||||
@@ -497,7 +505,7 @@ class ReportTablesTest extends TestCase
|
||||
public function this_should_populate_the_reports_table_with_the_parameters_connectionShortName_type_fields_proUid_grid()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 7);
|
||||
$result = $this->prepareData($tableName);
|
||||
$connectionShortName = 'wf';
|
||||
$type = 'NORMAL';
|
||||
$fields = $result->fields;
|
||||
@@ -528,7 +536,7 @@ class ReportTablesTest extends TestCase
|
||||
public function this_should_populate_the_reports_table_with_the_parameters_connectionShortName_type_fields_proUid_grid_if_null()
|
||||
{
|
||||
$tableName = 'TestReportTable';
|
||||
$result = $this->prepareData($tableName, 16);
|
||||
$result = $this->prepareData($tableName);
|
||||
$connectionShortName = 'wf';
|
||||
$type = 'NORMAL';
|
||||
$fields = $result->fields;
|
||||
@@ -649,8 +657,14 @@ class ReportTablesTest extends TestCase
|
||||
* @param boolean $grid
|
||||
* @return object
|
||||
*/
|
||||
private function prepareData($tableName, $applicationNumber, $grid = null)
|
||||
private function prepareData($tableName, $grid = null)
|
||||
{
|
||||
$applicationNumber = Application::max('APP_NUMBER');
|
||||
if (is_null($applicationNumber)) {
|
||||
$applicationNumber = 0;
|
||||
}
|
||||
$applicationNumber = $applicationNumber + 1;
|
||||
|
||||
$faker = Faker\Factory::create();
|
||||
$date = $faker->dateTime();
|
||||
|
||||
|
||||
@@ -190,47 +190,6 @@ class SpoolRunTest extends TestCase
|
||||
$this->assertTrue($expected);
|
||||
}
|
||||
|
||||
/**
|
||||
* This test uses the OPENMAIL option in a simple way.
|
||||
* @test
|
||||
* @covers \SpoolRun::__construct()
|
||||
* @covers \SpoolRun::setData()
|
||||
* @covers \SpoolRun::setConfig()
|
||||
* @covers \SpoolRun::sendMail()
|
||||
* @covers \SpoolRun::handleMail()
|
||||
*/
|
||||
public function it_should_handle_open_mail_option()
|
||||
{
|
||||
$this->markTestIncomplete("The OPENMAIL depends on the package class but this is not found in the environment.");
|
||||
|
||||
$appMsgUid = G::generateUniqueID();
|
||||
factory(AppMessage::class)->create([
|
||||
'APP_MSG_UID' => $appMsgUid
|
||||
]);
|
||||
|
||||
$emailServer = factory(EmailServerModel::class)->states('OPENMAIL')->make();
|
||||
|
||||
$config = $emailServer->toArray();
|
||||
|
||||
$faker = Factory::create();
|
||||
$spoolRun = new SpoolRun();
|
||||
$spoolRun->setData(
|
||||
$appMsgUid,
|
||||
$faker->title,
|
||||
$faker->companyEmail,
|
||||
$faker->freeEmail,
|
||||
$faker->text(),
|
||||
$faker->dateTime()->format('Y-m-d H:i:s'),
|
||||
$faker->companyEmail,
|
||||
$faker->freeEmail
|
||||
);
|
||||
$spoolRun->setConfig($config);
|
||||
|
||||
$expected = $spoolRun->sendMail();
|
||||
|
||||
$this->assertTrue($expected);
|
||||
}
|
||||
|
||||
/**
|
||||
* This test ensures that characters that are not utf8 are converted properly,
|
||||
* for subject and body fields.
|
||||
|
||||
@@ -11,11 +11,12 @@ use ProcessMaker\Model\EmailServerModel;
|
||||
use ProcessMaker\Model\Process;
|
||||
use ProcessMaker\Model\Task;
|
||||
use ProcessMaker\Model\User;
|
||||
use ProcessMaker\Model\UserReporting;
|
||||
use ProcessMaker\Util\WsMessageResponse;
|
||||
use Tests\TestCase;
|
||||
|
||||
/**
|
||||
* Class WsBase
|
||||
* Class WsBaseTest
|
||||
*
|
||||
* @coversDefaultClass WsBase
|
||||
*/
|
||||
@@ -862,14 +863,27 @@ class WsBaseTest extends TestCase
|
||||
}
|
||||
|
||||
/**
|
||||
* Review the cancel case with one thread open
|
||||
* Review the cancel case with one thread open was executed successfully
|
||||
*
|
||||
* @covers WsBase::cancelCase()
|
||||
* @test
|
||||
*/
|
||||
public function it_should_cancel_case()
|
||||
{
|
||||
$application = factory(Application::class)->create([
|
||||
// Definition for avoid the error: Trying to get property 'aUserInfo' of non-object in the action buildAppDelayRow()
|
||||
global $RBAC;
|
||||
$user = User::where('USR_ID', '=', 1)->get()->first();
|
||||
$_SESSION['USER_LOGGED'] = $user['USR_UID'];
|
||||
$RBAC = RBAC::getSingleton(PATH_DATA, session_id());
|
||||
$RBAC->initRBAC();
|
||||
$RBAC->loadUserRolePermission('PROCESSMAKER', $_SESSION['USER_LOGGED']);
|
||||
|
||||
// Create the data related to the cancel a case
|
||||
$task = factory(Task::class)->create();
|
||||
factory(UserReporting::class)->create([
|
||||
'TAS_UID' => $task->TAS_UID
|
||||
]);
|
||||
$application = factory(Application::class)->states('foreign_keys')->create([
|
||||
'APP_STATUS_ID' => 2,
|
||||
'APP_STATUS' => 'TO_DO'
|
||||
]);
|
||||
@@ -881,6 +895,8 @@ class WsBaseTest extends TestCase
|
||||
'DEL_INDEX' => 2
|
||||
]);
|
||||
$delegation = factory(Delegation::class)->states('foreign_keys')->create([
|
||||
'TAS_UID' => $task->TAS_UID,
|
||||
'PRO_UID' => $application->PRO_UID,
|
||||
'APP_NUMBER' => $application->APP_NUMBER,
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'DEL_THREAD_STATUS' => 'OPEN',
|
||||
@@ -888,38 +904,38 @@ class WsBaseTest extends TestCase
|
||||
]);
|
||||
|
||||
$ws = new WsBase();
|
||||
// todo: the action Case::cancelCase() use Propel queries
|
||||
$response = (object)$ws->cancelCase($delegation->APP_UID, $delegation->DEL_INDEX, $delegation->USR_UID);
|
||||
$this->assertNotEmpty($response);
|
||||
$this->markTestIncomplete(
|
||||
'This test was not fully implemented.'
|
||||
);
|
||||
$this->assertObjectHasAttribute('status_code', $response);
|
||||
$this->assertEquals($response->message, G::LoadTranslation("ID_COMMAND_EXECUTED_SUCCESSFULLY"));
|
||||
}
|
||||
|
||||
/**
|
||||
* Review the cancel case with parallel threads
|
||||
* Review the cancel case with parallel threads was executed successfully
|
||||
*
|
||||
* @covers WsBase::cancelCase()
|
||||
* @test
|
||||
*/
|
||||
public function it_should_cancel_case_parallel()
|
||||
{
|
||||
$application = factory(Application::class)->create([
|
||||
// Definition for avoid the error: Trying to get property 'aUserInfo' of non-object in the action buildAppDelayRow()
|
||||
global $RBAC;
|
||||
$user = User::where('USR_ID', '=', 1)->get()->first();
|
||||
$_SESSION['USER_LOGGED'] = $user['USR_UID'];
|
||||
$RBAC = RBAC::getSingleton(PATH_DATA, session_id());
|
||||
$RBAC->initRBAC();
|
||||
$RBAC->loadUserRolePermission('PROCESSMAKER', $_SESSION['USER_LOGGED']);
|
||||
|
||||
// Create the data related to the cancel a case
|
||||
$task = factory(Task::class)->create();
|
||||
factory(UserReporting::class)->create([
|
||||
'TAS_UID' => $task->TAS_UID
|
||||
]);
|
||||
$application = factory(Application::class)->states('foreign_keys')->create([
|
||||
'APP_STATUS_ID' => 2,
|
||||
'APP_STATUS' => 'TO_DO'
|
||||
]);
|
||||
factory(AppThread::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'APP_THREAD_INDEX' => 1,
|
||||
'APP_THREAD_PARENT' => 1,
|
||||
'APP_THREAD_STATUS' => 'OPEN',
|
||||
'DEL_INDEX' => 1
|
||||
]);
|
||||
factory(Delegation::class)->states('foreign_keys')->create([
|
||||
'APP_NUMBER' => $application->APP_NUMBER,
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'DEL_THREAD_STATUS' => 'OPEN'
|
||||
]);
|
||||
// Create the first thread
|
||||
factory(AppThread::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'APP_THREAD_INDEX' => 2,
|
||||
@@ -927,20 +943,67 @@ class WsBaseTest extends TestCase
|
||||
'APP_THREAD_STATUS' => 'OPEN',
|
||||
'DEL_INDEX' => 2
|
||||
]);
|
||||
factory(Delegation::class)->states('foreign_keys')->create([
|
||||
'TAS_UID' => $task->TAS_UID,
|
||||
'PRO_UID' => $application->PRO_UID,
|
||||
'APP_NUMBER' => $application->APP_NUMBER,
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'DEL_THREAD_STATUS' => 'OPEN',
|
||||
'DEL_INDEX' => 2,
|
||||
]);
|
||||
// Create the second thread
|
||||
factory(AppThread::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'APP_THREAD_INDEX' => 3,
|
||||
'APP_THREAD_PARENT' => 1,
|
||||
'APP_THREAD_STATUS' => 'OPEN',
|
||||
'DEL_INDEX' => 3
|
||||
]);
|
||||
$delegation = factory(Delegation::class)->states('foreign_keys')->create([
|
||||
'TAS_UID' => $task->TAS_UID,
|
||||
'PRO_UID' => $application->PRO_UID,
|
||||
'APP_NUMBER' => $application->APP_NUMBER,
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'DEL_THREAD_STATUS' => 'OPEN',
|
||||
'DEL_INDEX' => 3,
|
||||
]);
|
||||
|
||||
$ws = new WsBase();
|
||||
$response = (object)$ws->cancelCase($delegation->APP_UID, null, null);
|
||||
$this->assertNotEmpty($response);
|
||||
$this->assertObjectHasAttribute('status_code', $response);
|
||||
$this->assertEquals($response->message, G::LoadTranslation("ID_COMMAND_EXECUTED_SUCCESSFULLY"));
|
||||
}
|
||||
|
||||
/**
|
||||
* Review the cancel case when the applications does not exist
|
||||
*
|
||||
* @covers WsBase::cancelCase()
|
||||
* @test
|
||||
*/
|
||||
public function it_tried_cancel_an_undefined_case()
|
||||
{
|
||||
$fakeApp = G::generateUniqueID();
|
||||
$application = factory(Application::class)->create([
|
||||
'APP_STATUS_ID' => 2,
|
||||
'APP_STATUS' => 'TO_DO'
|
||||
]);
|
||||
factory(AppThread::class)->create([
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'APP_THREAD_INDEX' => 1,
|
||||
'APP_THREAD_PARENT' => 1,
|
||||
'APP_THREAD_STATUS' => 'OPEN',
|
||||
'DEL_INDEX' => 2
|
||||
]);
|
||||
$delegation = factory(Delegation::class)->states('foreign_keys')->create([
|
||||
'APP_NUMBER' => $application->APP_NUMBER,
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'DEL_THREAD_STATUS' => 'OPEN',
|
||||
'DEL_INDEX' => 2,
|
||||
]);
|
||||
|
||||
$ws = new WsBase();
|
||||
// todo: the action Case::cancelCase() use Propel queries
|
||||
$response = (object)$ws->cancelCase($delegation->APP_UID, null, null);
|
||||
$this->assertNotEmpty($response);
|
||||
// Stop here and mark this test as incomplete.
|
||||
$this->markTestIncomplete(
|
||||
'This test was not fully implemented.'
|
||||
);
|
||||
$response = (object)$ws->cancelCase($fakeApp, $delegation->DEL_INDEX, $delegation->USR_UID);
|
||||
$this->assertEquals($response->status_code, 100);
|
||||
$this->assertEquals($response->message, "The Application row '$fakeApp' doesn't exist!");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -82,6 +82,7 @@ define ('DB_REPORT_PASS', '" . env('DB_PASSWORD') . "' );");
|
||||
*/
|
||||
public function it_should_test_big_int_id()
|
||||
{
|
||||
$this->markTestIncomplete();
|
||||
$reportTable = new ReportTable();
|
||||
|
||||
//PM table with a bigint id
|
||||
@@ -192,6 +193,7 @@ define ('DB_REPORT_PASS', '" . env('DB_PASSWORD') . "' );");
|
||||
*/
|
||||
public function it_should_test_var_char_id()
|
||||
{
|
||||
$this->markTestIncomplete();
|
||||
$reportTable = new ReportTable();
|
||||
|
||||
//PM table with a char id
|
||||
@@ -302,6 +304,7 @@ define ('DB_REPORT_PASS', '" . env('DB_PASSWORD') . "' );");
|
||||
*/
|
||||
public function it_should_test_integer_id()
|
||||
{
|
||||
$this->markTestIncomplete();
|
||||
$reportTable = new ReportTable();
|
||||
|
||||
//PM table with an integer id
|
||||
@@ -412,6 +415,7 @@ define ('DB_REPORT_PASS', '" . env('DB_PASSWORD') . "' );");
|
||||
*/
|
||||
public function it_should_test_smallint_id()
|
||||
{
|
||||
$this->markTestIncomplete();
|
||||
$reportTable = new ReportTable();
|
||||
|
||||
//PM table with a smallint id
|
||||
@@ -521,6 +525,7 @@ define ('DB_REPORT_PASS', '" . env('DB_PASSWORD') . "' );");
|
||||
*/
|
||||
public function it_should_test_tinyint_id()
|
||||
{
|
||||
$this->markTestIncomplete();
|
||||
$reportTable = new ReportTable();
|
||||
|
||||
//PM table with a tinyint id
|
||||
@@ -630,6 +635,7 @@ define ('DB_REPORT_PASS', '" . env('DB_PASSWORD') . "' );");
|
||||
*/
|
||||
public function it_should_test_varchar_id()
|
||||
{
|
||||
$this->markTestIncomplete();
|
||||
$reportTable = new ReportTable();
|
||||
|
||||
//PM table with a varchar id
|
||||
@@ -738,6 +744,7 @@ define ('DB_REPORT_PASS', '" . env('DB_PASSWORD') . "' );");
|
||||
*/
|
||||
public function it_should_test_varchar_id_filter()
|
||||
{
|
||||
$this->markTestIncomplete();
|
||||
$reportTable = new ReportTable();
|
||||
|
||||
//PM table with a varchar id
|
||||
@@ -891,6 +898,7 @@ define ('DB_REPORT_PASS', '" . env('DB_PASSWORD') . "' );");
|
||||
*/
|
||||
public function it_should_test_varchar_id_rows()
|
||||
{
|
||||
$this->markTestIncomplete();
|
||||
$reportTable = new ReportTable();
|
||||
|
||||
//PM table with a varchar id
|
||||
|
||||
@@ -7,6 +7,8 @@ use Faker\Factory;
|
||||
use G;
|
||||
use ProcessMaker\BusinessModel\EmailServer;
|
||||
use ProcessMaker\Model\EmailServerModel;
|
||||
use ProcessMaker\Model\User;
|
||||
use RBAC;
|
||||
use Tests\TestCase;
|
||||
|
||||
class EmailServerTest extends TestCase
|
||||
@@ -52,6 +54,20 @@ class EmailServerTest extends TestCase
|
||||
];
|
||||
}
|
||||
|
||||
/**
|
||||
* Load default user session.
|
||||
* @global object $RBAC
|
||||
*/
|
||||
private function loadUserSession()
|
||||
{
|
||||
global $RBAC;
|
||||
$user = User::where('USR_ID', '=', 1)->get()->first();
|
||||
$_SESSION['USER_LOGGED'] = $user['USR_UID'];
|
||||
$RBAC = RBAC::getSingleton(PATH_DATA, session_id());
|
||||
$RBAC->initRBAC();
|
||||
$RBAC->loadUserRolePermission('PROCESSMAKER', $_SESSION['USER_LOGGED']);
|
||||
}
|
||||
|
||||
/**
|
||||
* This creates a record in the EMAIL_SERVER table.
|
||||
* @test
|
||||
@@ -59,6 +75,8 @@ class EmailServerTest extends TestCase
|
||||
*/
|
||||
public function it_should_create()
|
||||
{
|
||||
$this->loadUserSession();
|
||||
|
||||
$faker = $this->faker;
|
||||
$expected = $this->getDataForEmailServerRegistry();
|
||||
$this->emailServer->setContextLog([
|
||||
@@ -88,6 +106,8 @@ class EmailServerTest extends TestCase
|
||||
*/
|
||||
public function it_should_update()
|
||||
{
|
||||
$this->loadUserSession();
|
||||
|
||||
$faker = $this->faker;
|
||||
$emailServer = factory(EmailServerModel::class)->create($this->getDataForEmailServerRegistry());
|
||||
$data = $emailServer->toArray();
|
||||
@@ -259,6 +279,10 @@ class EmailServerTest extends TestCase
|
||||
*/
|
||||
public function it_should_test_the_send_test_mail_method()
|
||||
{
|
||||
$string = ini_get("sendmail_path");
|
||||
if (!is_executable($string)) {
|
||||
$this->markTestIncomplete($string . " not found");
|
||||
}
|
||||
// The data that will be sent to the method
|
||||
$data = [
|
||||
"FROM_EMAIL" => "admin@processmaker.com",
|
||||
|
||||
@@ -1,129 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace Tests\unit\workflow\engine\src\ProcessMaker\BusinessModel;
|
||||
|
||||
use ProcessMaker\BusinessModel\Language;
|
||||
use System;
|
||||
use Tests\TestCase;
|
||||
|
||||
/**
|
||||
* Test the ProcessMaker\BusinessModel\Language class.
|
||||
*/
|
||||
class LanguageTest extends TestCase
|
||||
{
|
||||
/**
|
||||
* @var Language
|
||||
*/
|
||||
protected $object;
|
||||
private $translationEnv;
|
||||
|
||||
/**
|
||||
* Sets up the unit tests.
|
||||
*/
|
||||
protected function setUp()
|
||||
{
|
||||
$this->markTestIncomplete();//@todo: Please correct this unit test
|
||||
$this->getBaseUri();
|
||||
$this->object = new Language;
|
||||
$this->translationEnv = PATH_DATA . "META-INF" . PATH_SEP . "translations.env";
|
||||
file_exists($this->translationEnv) ? unlink($this->translationEnv) : false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get base uri for rest applications.
|
||||
* @return string
|
||||
*/
|
||||
private function getBaseUri()
|
||||
{
|
||||
$_SERVER = $this->getServerInformation();
|
||||
$baseUri = System::getServerProtocolHost();
|
||||
|
||||
return $baseUri;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get server information.
|
||||
* @return object
|
||||
*/
|
||||
private function getServerInformation()
|
||||
{
|
||||
$pathData = PATH_DATA . "sites" . PATH_SEP . config("system.workspace") . PATH_SEP . ".server_info";
|
||||
$content = file_get_contents($pathData);
|
||||
$serverInfo = unserialize($content);
|
||||
|
||||
return $serverInfo;
|
||||
}
|
||||
|
||||
/**
|
||||
* Test default languages
|
||||
*
|
||||
* @category HOR-3209:1
|
||||
* @covers ProcessMaker\BusinessModel\Language::getLanguageList
|
||||
*/
|
||||
public function testGetLanguageList()
|
||||
{
|
||||
$list = $this->object->getLanguageList();
|
||||
$expected = [
|
||||
'LANG_ID' => 'en',
|
||||
'LANG_NAME' => 'English',
|
||||
];
|
||||
$this->assertContains($expected, $list);
|
||||
}
|
||||
|
||||
/**
|
||||
* Test installed languages
|
||||
*
|
||||
* @category HOR-3209:2
|
||||
* @covers ProcessMaker\BusinessModel\Language::getLanguageList
|
||||
*/
|
||||
public function testGetLanguageListInstalled()
|
||||
{
|
||||
$this->installLanguage('es', __DIR__ . '/processmaker.es.po');
|
||||
$list = $this->object->getLanguageList();
|
||||
$english = [
|
||||
'LANG_ID' => 'en',
|
||||
'LANG_NAME' => 'English',
|
||||
];
|
||||
$this->assertContains($english, $list);
|
||||
|
||||
$spanish = [
|
||||
'LANG_ID' => 'es-ES',
|
||||
'LANG_NAME' => 'Spanish (Spain)',
|
||||
];
|
||||
$this->assertContains($spanish, $list);
|
||||
|
||||
$this->uninstallLanguage('es', __DIR__ . '/processmaker.es.po');
|
||||
$list2 = $this->object->getLanguageList();
|
||||
$this->assertContains($english, $list2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Install a language to the system.
|
||||
*
|
||||
* @param type $lanId
|
||||
* @param type $filename
|
||||
*/
|
||||
private function installLanguage($lanId, $filename)
|
||||
{
|
||||
copy($filename, PATH_CORE . 'content/translations/' . basename($filename));
|
||||
$language = \LanguagePeer::retrieveByPK($lanId);
|
||||
$language->setLanEnabled(1);
|
||||
$language->save();
|
||||
file_exists($this->translationEnv) ? unlink($this->translationEnv) : false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Uninstall a language from the system.
|
||||
*
|
||||
* @param type $lanId
|
||||
* @param type $filename
|
||||
*/
|
||||
private function uninstallLanguage($lanId, $filename)
|
||||
{
|
||||
unlink(PATH_CORE . 'content/translations/' . basename($filename));
|
||||
$language = \LanguagePeer::retrieveByPK($lanId);
|
||||
$language->setLanEnabled(0);
|
||||
$language->save();
|
||||
file_exists($this->translationEnv) ? unlink($this->translationEnv) : false;
|
||||
}
|
||||
}
|
||||
@@ -1,970 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<ProcessMaker-Project version="3.0">
|
||||
<metadata>
|
||||
<meta key="vendor_version"><![CDATA[(Branch feature/HOR-3214)]]></meta>
|
||||
<meta key="vendor_version_code">Michelangelo</meta>
|
||||
<meta key="export_timestamp">1496335122</meta>
|
||||
<meta key="export_datetime"><![CDATA[2017-06-01T16:38:42+00:00]]></meta>
|
||||
<meta key="export_server_addr"><![CDATA[::1:8084]]></meta>
|
||||
<meta key="export_server_os">Darwin</meta>
|
||||
<meta key="export_server_php_version">50621</meta>
|
||||
<meta key="export_version">4</meta>
|
||||
<meta key="workspace">hor3207</meta>
|
||||
<meta key="name">WebEntry2</meta>
|
||||
<meta key="uid">56559353559303a3cc06e80025826369</meta>
|
||||
</metadata>
|
||||
<definition class="BPMN">
|
||||
<table name="ACTIVITY">
|
||||
<record>
|
||||
<act_uid>16965000459303a4c2a3e43075058476</act_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<pro_uid>10245485859303a3ce163f0020070533</pro_uid>
|
||||
<act_name>Task 1</act_name>
|
||||
<act_type>TASK</act_type>
|
||||
<act_is_for_compensation>0</act_is_for_compensation>
|
||||
<act_start_quantity>1</act_start_quantity>
|
||||
<act_completion_quantity>0</act_completion_quantity>
|
||||
<act_task_type>EMPTY</act_task_type>
|
||||
<act_implementation></act_implementation>
|
||||
<act_instantiate>0</act_instantiate>
|
||||
<act_script_type></act_script_type>
|
||||
<act_script></act_script>
|
||||
<act_loop_type>EMPTY</act_loop_type>
|
||||
<act_test_before>0</act_test_before>
|
||||
<act_loop_maximum>0</act_loop_maximum>
|
||||
<act_loop_condition>0</act_loop_condition>
|
||||
<act_loop_cardinality>0</act_loop_cardinality>
|
||||
<act_loop_behavior>0</act_loop_behavior>
|
||||
<act_is_adhoc>0</act_is_adhoc>
|
||||
<act_is_collapsed>0</act_is_collapsed>
|
||||
<act_completion_condition>0</act_completion_condition>
|
||||
<act_ordering>0</act_ordering>
|
||||
<act_cancel_remaining_instances>0</act_cancel_remaining_instances>
|
||||
<act_protocol>0</act_protocol>
|
||||
<act_method>0</act_method>
|
||||
<act_is_global>0</act_is_global>
|
||||
<act_referer>0</act_referer>
|
||||
<act_default_flow>0</act_default_flow>
|
||||
<act_master_diagram>0</act_master_diagram>
|
||||
<bou_uid>23262040759303a4c2afa43054385721</bou_uid>
|
||||
<dia_uid>95673127759303a3cd58577062950932</dia_uid>
|
||||
<element_uid>16965000459303a4c2a3e43075058476</element_uid>
|
||||
<bou_element>6151488955930424aafa4f9007578435</bou_element>
|
||||
<bou_element_type>bpmnActivity</bou_element_type>
|
||||
<bou_x>255</bou_x>
|
||||
<bou_y>79</bou_y>
|
||||
<bou_width>150</bou_width>
|
||||
<bou_height>75</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<act_uid>79146780259303a4c3c4224096542966</act_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<pro_uid>10245485859303a3ce163f0020070533</pro_uid>
|
||||
<act_name>WEBENTRY</act_name>
|
||||
<act_type>TASK</act_type>
|
||||
<act_is_for_compensation>0</act_is_for_compensation>
|
||||
<act_start_quantity>1</act_start_quantity>
|
||||
<act_completion_quantity>0</act_completion_quantity>
|
||||
<act_task_type>EMPTY</act_task_type>
|
||||
<act_implementation></act_implementation>
|
||||
<act_instantiate>0</act_instantiate>
|
||||
<act_script_type></act_script_type>
|
||||
<act_script></act_script>
|
||||
<act_loop_type>EMPTY</act_loop_type>
|
||||
<act_test_before>0</act_test_before>
|
||||
<act_loop_maximum>0</act_loop_maximum>
|
||||
<act_loop_condition>0</act_loop_condition>
|
||||
<act_loop_cardinality>0</act_loop_cardinality>
|
||||
<act_loop_behavior>0</act_loop_behavior>
|
||||
<act_is_adhoc>0</act_is_adhoc>
|
||||
<act_is_collapsed>0</act_is_collapsed>
|
||||
<act_completion_condition>0</act_completion_condition>
|
||||
<act_ordering>0</act_ordering>
|
||||
<act_cancel_remaining_instances>0</act_cancel_remaining_instances>
|
||||
<act_protocol>0</act_protocol>
|
||||
<act_method>0</act_method>
|
||||
<act_is_global>0</act_is_global>
|
||||
<act_referer>0</act_referer>
|
||||
<act_default_flow>0</act_default_flow>
|
||||
<act_master_diagram>0</act_master_diagram>
|
||||
<bou_uid>77250327259303a4c3cc125070295918</bou_uid>
|
||||
<dia_uid>95673127759303a3cd58577062950932</dia_uid>
|
||||
<element_uid>79146780259303a4c3c4224096542966</element_uid>
|
||||
<bou_element>6151488955930424aafa4f9007578435</bou_element>
|
||||
<bou_element_type>bpmnActivity</bou_element_type>
|
||||
<bou_x>100</bou_x>
|
||||
<bou_y>206</bou_y>
|
||||
<bou_width>150</bou_width>
|
||||
<bou_height>75</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
</table>
|
||||
<table name="ARTIFACT">
|
||||
<record>
|
||||
<art_uid>18366688859303c0a73a8d0090992063</art_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<pro_uid>10245485859303a3ce163f0020070533</pro_uid>
|
||||
<art_type>TEXT_ANNOTATION</art_type>
|
||||
<art_name><![CDATA[UPDATE BPMN_ACTIVITY SET ACT_UID=(SELECT TAS_UID FROM WEB_ENTRY) where ACT_NAME='WEBENTRY';]]></art_name>
|
||||
<art_category_ref></art_category_ref>
|
||||
<bou_uid>66326200359303c0a746ff6019098980</bou_uid>
|
||||
<dia_uid>95673127759303a3cd58577062950932</dia_uid>
|
||||
<element_uid>18366688859303c0a73a8d0090992063</element_uid>
|
||||
<bou_element>6151488955930424aafa4f9007578435</bou_element>
|
||||
<bou_element_type>bpmnArtifact</bou_element_type>
|
||||
<bou_x>100</bou_x>
|
||||
<bou_y>359</bou_y>
|
||||
<bou_width>633</bou_width>
|
||||
<bou_height>45</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<art_uid>92334024059303bba6cd636030770915</art_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<pro_uid>10245485859303a3ce163f0020070533</pro_uid>
|
||||
<art_type>TEXT_ANNOTATION</art_type>
|
||||
<art_name><![CDATA[UPDATE BPMN_BOUND SET ELEMENT_UID=(SELECT TAS_UID FROM WEB_ENTRY) where ELEMENT_UID=(SELECT ACT_UID FROM BPMN_ACTIVITY WHERE ACT_NAME='WEBENTRY');]]></art_name>
|
||||
<art_category_ref></art_category_ref>
|
||||
<bou_uid>94266112859303bba6df059082224962</bou_uid>
|
||||
<dia_uid>95673127759303a3cd58577062950932</dia_uid>
|
||||
<element_uid>92334024059303bba6cd636030770915</element_uid>
|
||||
<bou_element>6151488955930424aafa4f9007578435</bou_element>
|
||||
<bou_element_type>bpmnArtifact</bou_element_type>
|
||||
<bou_x>100</bou_x>
|
||||
<bou_y>288</bou_y>
|
||||
<bou_width>639</bou_width>
|
||||
<bou_height>69</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
</table>
|
||||
<table name="BOUND">
|
||||
<record>
|
||||
<bou_uid>23262040759303a4c2afa43054385721</bou_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<dia_uid>95673127759303a3cd58577062950932</dia_uid>
|
||||
<element_uid>16965000459303a4c2a3e43075058476</element_uid>
|
||||
<bou_element>6151488955930424aafa4f9007578435</bou_element>
|
||||
<bou_element_type>bpmnActivity</bou_element_type>
|
||||
<bou_x>255</bou_x>
|
||||
<bou_y>79</bou_y>
|
||||
<bou_width>150</bou_width>
|
||||
<bou_height>75</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<bou_uid>28502816559303b2aa999f4011952694</bou_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<dia_uid>95673127759303a3cd58577062950932</dia_uid>
|
||||
<element_uid>55623600259303b2aa8c2b3006040225</element_uid>
|
||||
<bou_element>6151488955930424aafa4f9007578435</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>508</bou_x>
|
||||
<bou_y>100</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<bou_uid>37327513759303a4c48fb05001608425</bou_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<dia_uid>95673127759303a3cd58577062950932</dia_uid>
|
||||
<element_uid>26331855259303a4c486358089637672</element_uid>
|
||||
<bou_element>6151488955930424aafa4f9007578435</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>100</bou_x>
|
||||
<bou_y>100</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<bou_uid>66326200359303c0a746ff6019098980</bou_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<dia_uid>95673127759303a3cd58577062950932</dia_uid>
|
||||
<element_uid>18366688859303c0a73a8d0090992063</element_uid>
|
||||
<bou_element>6151488955930424aafa4f9007578435</bou_element>
|
||||
<bou_element_type>bpmnArtifact</bou_element_type>
|
||||
<bou_x>100</bou_x>
|
||||
<bou_y>359</bou_y>
|
||||
<bou_width>633</bou_width>
|
||||
<bou_height>45</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<bou_uid>77250327259303a4c3cc125070295918</bou_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<dia_uid>95673127759303a3cd58577062950932</dia_uid>
|
||||
<element_uid>79146780259303a4c3c4224096542966</element_uid>
|
||||
<bou_element>6151488955930424aafa4f9007578435</bou_element>
|
||||
<bou_element_type>bpmnActivity</bou_element_type>
|
||||
<bou_x>100</bou_x>
|
||||
<bou_y>206</bou_y>
|
||||
<bou_width>150</bou_width>
|
||||
<bou_height>75</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<bou_uid>94266112859303bba6df059082224962</bou_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<dia_uid>95673127759303a3cd58577062950932</dia_uid>
|
||||
<element_uid>92334024059303bba6cd636030770915</element_uid>
|
||||
<bou_element>6151488955930424aafa4f9007578435</bou_element>
|
||||
<bou_element_type>bpmnArtifact</bou_element_type>
|
||||
<bou_x>100</bou_x>
|
||||
<bou_y>288</bou_y>
|
||||
<bou_width>639</bou_width>
|
||||
<bou_height>69</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
</table>
|
||||
<table name="DATA"/>
|
||||
<table name="DIAGRAM">
|
||||
<record>
|
||||
<dia_uid>95673127759303a3cd58577062950932</dia_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<dia_name>WebEntry2</dia_name>
|
||||
<dia_is_closable>0</dia_is_closable>
|
||||
</record>
|
||||
</table>
|
||||
<table name="DOCUMENTATION"/>
|
||||
<table name="EVENT">
|
||||
<record>
|
||||
<evn_uid>55623600259303b2aa8c2b3006040225</evn_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<pro_uid>10245485859303a3ce163f0020070533</pro_uid>
|
||||
<evn_name></evn_name>
|
||||
<evn_type>END</evn_type>
|
||||
<evn_marker>EMPTY</evn_marker>
|
||||
<evn_is_interrupting>1</evn_is_interrupting>
|
||||
<evn_attached_to></evn_attached_to>
|
||||
<evn_cancel_activity>0</evn_cancel_activity>
|
||||
<evn_activity_ref></evn_activity_ref>
|
||||
<evn_wait_for_completion>0</evn_wait_for_completion>
|
||||
<evn_error_name></evn_error_name>
|
||||
<evn_error_code></evn_error_code>
|
||||
<evn_escalation_name></evn_escalation_name>
|
||||
<evn_escalation_code></evn_escalation_code>
|
||||
<evn_condition></evn_condition>
|
||||
<evn_message></evn_message>
|
||||
<evn_operation_name></evn_operation_name>
|
||||
<evn_operation_implementation_ref></evn_operation_implementation_ref>
|
||||
<evn_time_date></evn_time_date>
|
||||
<evn_time_cycle></evn_time_cycle>
|
||||
<evn_time_duration></evn_time_duration>
|
||||
<evn_behavior>THROW</evn_behavior>
|
||||
<bou_uid>28502816559303b2aa999f4011952694</bou_uid>
|
||||
<dia_uid>95673127759303a3cd58577062950932</dia_uid>
|
||||
<element_uid>55623600259303b2aa8c2b3006040225</element_uid>
|
||||
<bou_element>6151488955930424aafa4f9007578435</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>508</bou_x>
|
||||
<bou_y>100</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<evn_uid>26331855259303a4c486358089637672</evn_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<pro_uid>10245485859303a3ce163f0020070533</pro_uid>
|
||||
<evn_name><![CDATA[webentry (do not recreate the webentry)]]></evn_name>
|
||||
<evn_type>START</evn_type>
|
||||
<evn_marker>EMPTY</evn_marker>
|
||||
<evn_is_interrupting>1</evn_is_interrupting>
|
||||
<evn_attached_to></evn_attached_to>
|
||||
<evn_cancel_activity>0</evn_cancel_activity>
|
||||
<evn_activity_ref></evn_activity_ref>
|
||||
<evn_wait_for_completion>0</evn_wait_for_completion>
|
||||
<evn_error_name></evn_error_name>
|
||||
<evn_error_code></evn_error_code>
|
||||
<evn_escalation_name></evn_escalation_name>
|
||||
<evn_escalation_code></evn_escalation_code>
|
||||
<evn_condition></evn_condition>
|
||||
<evn_message>LEAD</evn_message>
|
||||
<evn_operation_name></evn_operation_name>
|
||||
<evn_operation_implementation_ref></evn_operation_implementation_ref>
|
||||
<evn_time_date></evn_time_date>
|
||||
<evn_time_cycle></evn_time_cycle>
|
||||
<evn_time_duration></evn_time_duration>
|
||||
<evn_behavior>CATCH</evn_behavior>
|
||||
<bou_uid>37327513759303a4c48fb05001608425</bou_uid>
|
||||
<dia_uid>95673127759303a3cd58577062950932</dia_uid>
|
||||
<element_uid>26331855259303a4c486358089637672</element_uid>
|
||||
<bou_element>6151488955930424aafa4f9007578435</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>100</bou_x>
|
||||
<bou_y>100</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
</table>
|
||||
<table name="EXTENSION"/>
|
||||
<table name="FLOW">
|
||||
<record>
|
||||
<flo_uid>24433461759303a4c4dc2e6055592083</flo_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<dia_uid>95673127759303a3cd58577062950932</dia_uid>
|
||||
<flo_type>SEQUENCE</flo_type>
|
||||
<flo_name> </flo_name>
|
||||
<flo_element_origin>26331855259303a4c486358089637672</flo_element_origin>
|
||||
<flo_element_origin_type>bpmnEvent</flo_element_origin_type>
|
||||
<flo_element_origin_port>0</flo_element_origin_port>
|
||||
<flo_element_dest>16965000459303a4c2a3e43075058476</flo_element_dest>
|
||||
<flo_element_dest_type>bpmnActivity</flo_element_dest_type>
|
||||
<flo_element_dest_port>0</flo_element_dest_port>
|
||||
<flo_is_inmediate>1</flo_is_inmediate>
|
||||
<flo_condition></flo_condition>
|
||||
<flo_x1>133</flo_x1>
|
||||
<flo_y1>117</flo_y1>
|
||||
<flo_x2>255</flo_x2>
|
||||
<flo_y2>117</flo_y2>
|
||||
<flo_state><![CDATA[[{"x":133,"y":117},{"x":255,"y":117}]]]></flo_state>
|
||||
<flo_position>1</flo_position>
|
||||
</record>
|
||||
<record>
|
||||
<flo_uid>47236448759303b2ac3b488085814197</flo_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<dia_uid>95673127759303a3cd58577062950932</dia_uid>
|
||||
<flo_type>SEQUENCE</flo_type>
|
||||
<flo_name> </flo_name>
|
||||
<flo_element_origin>16965000459303a4c2a3e43075058476</flo_element_origin>
|
||||
<flo_element_origin_type>bpmnActivity</flo_element_origin_type>
|
||||
<flo_element_origin_port>0</flo_element_origin_port>
|
||||
<flo_element_dest>55623600259303b2aa8c2b3006040225</flo_element_dest>
|
||||
<flo_element_dest_type>bpmnEvent</flo_element_dest_type>
|
||||
<flo_element_dest_port>0</flo_element_dest_port>
|
||||
<flo_is_inmediate>1</flo_is_inmediate>
|
||||
<flo_condition></flo_condition>
|
||||
<flo_x1>406</flo_x1>
|
||||
<flo_y1>117</flo_y1>
|
||||
<flo_x2>508</flo_x2>
|
||||
<flo_y2>117</flo_y2>
|
||||
<flo_state><![CDATA[[{"x":406,"y":117},{"x":508,"y":117}]]]></flo_state>
|
||||
<flo_position>1</flo_position>
|
||||
</record>
|
||||
</table>
|
||||
<table name="GATEWAY"/>
|
||||
<table name="LANE"/>
|
||||
<table name="LANESET"/>
|
||||
<table name="PARTICIPANT"/>
|
||||
<table name="PROCESS">
|
||||
<record>
|
||||
<pro_uid>10245485859303a3ce163f0020070533</pro_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<dia_uid>95673127759303a3cd58577062950932</dia_uid>
|
||||
<pro_name>WebEntry2</pro_name>
|
||||
<pro_type>NONE</pro_type>
|
||||
<pro_is_executable>0</pro_is_executable>
|
||||
<pro_is_closed>0</pro_is_closed>
|
||||
<pro_is_subprocess>0</pro_is_subprocess>
|
||||
</record>
|
||||
</table>
|
||||
<table name="PROJECT">
|
||||
<record>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<prj_name>WebEntry2</prj_name>
|
||||
<prj_description></prj_description>
|
||||
<prj_target_namespace></prj_target_namespace>
|
||||
<prj_expresion_language></prj_expresion_language>
|
||||
<prj_type_language></prj_type_language>
|
||||
<prj_exporter></prj_exporter>
|
||||
<prj_exporter_version></prj_exporter_version>
|
||||
<prj_create_date><![CDATA[2017-06-01 16:01:00]]></prj_create_date>
|
||||
<prj_update_date><![CDATA[2017-06-01 16:38:38]]></prj_update_date>
|
||||
<prj_author>00000000000000000000000000000001</prj_author>
|
||||
<prj_author_version></prj_author_version>
|
||||
<prj_original_source></prj_original_source>
|
||||
</record>
|
||||
</table>
|
||||
</definition>
|
||||
<definition class="workflow">
|
||||
<table name="process">
|
||||
<record>
|
||||
<pro_uid>56559353559303a3cc06e80025826369</pro_uid>
|
||||
<pro_title>WebEntry2</pro_title>
|
||||
<pro_description></pro_description>
|
||||
<pro_parent>56559353559303a3cc06e80025826369</pro_parent>
|
||||
<pro_time>1</pro_time>
|
||||
<pro_timeunit>DAYS</pro_timeunit>
|
||||
<pro_status>ACTIVE</pro_status>
|
||||
<pro_type_day></pro_type_day>
|
||||
<pro_type>NORMAL</pro_type>
|
||||
<pro_assignment>FALSE</pro_assignment>
|
||||
<pro_show_map>0</pro_show_map>
|
||||
<pro_show_message>0</pro_show_message>
|
||||
<pro_subprocess>0</pro_subprocess>
|
||||
<pro_tri_create></pro_tri_create>
|
||||
<pro_tri_open></pro_tri_open>
|
||||
<pro_tri_deleted></pro_tri_deleted>
|
||||
<pro_tri_canceled></pro_tri_canceled>
|
||||
<pro_tri_paused></pro_tri_paused>
|
||||
<pro_tri_reassigned></pro_tri_reassigned>
|
||||
<pro_tri_unpaused></pro_tri_unpaused>
|
||||
<pro_type_process>PUBLIC</pro_type_process>
|
||||
<pro_show_delegate>0</pro_show_delegate>
|
||||
<pro_show_dynaform>0</pro_show_dynaform>
|
||||
<pro_category></pro_category>
|
||||
<pro_sub_category></pro_sub_category>
|
||||
<pro_industry>0</pro_industry>
|
||||
<pro_update_date><![CDATA[2017-06-01 16:38:38]]></pro_update_date>
|
||||
<pro_create_date><![CDATA[2017-06-01 16:01:00]]></pro_create_date>
|
||||
<pro_create_user>00000000000000000000000000000001</pro_create_user>
|
||||
<pro_height>5000</pro_height>
|
||||
<pro_width>10000</pro_width>
|
||||
<pro_title_x>0</pro_title_x>
|
||||
<pro_title_y>0</pro_title_y>
|
||||
<pro_debug>0</pro_debug>
|
||||
<pro_dynaforms><![CDATA[a:1:{s:7:"PROCESS";s:0:"";}]]></pro_dynaforms>
|
||||
<pro_derivation_screen_tpl></pro_derivation_screen_tpl>
|
||||
<pro_cost>0</pro_cost>
|
||||
<pro_unit_cost><![CDATA[$]]></pro_unit_cost>
|
||||
<pro_itee>1</pro_itee>
|
||||
<pro_action_done><![CDATA[a:1:{i:0;s:41:"GATEWAYTOGATEWAY_DELETE_CORRUPTED_RECORDS";}]]></pro_action_done>
|
||||
<pro_category_label>No Category</pro_category_label>
|
||||
<pro_bpmn>1</pro_bpmn>
|
||||
</record>
|
||||
</table>
|
||||
<table name="tasks">
|
||||
<record>
|
||||
<pro_uid>56559353559303a3cc06e80025826369</pro_uid>
|
||||
<tas_uid>16965000459303a4c2a3e43075058476</tas_uid>
|
||||
<tas_title>Task 1</tas_title>
|
||||
<tas_description></tas_description>
|
||||
<tas_def_title></tas_def_title>
|
||||
<tas_def_subject_message></tas_def_subject_message>
|
||||
<tas_def_proc_code></tas_def_proc_code>
|
||||
<tas_def_message></tas_def_message>
|
||||
<tas_def_description></tas_def_description>
|
||||
<tas_type>NORMAL</tas_type>
|
||||
<tas_duration>1</tas_duration>
|
||||
<tas_delay_type></tas_delay_type>
|
||||
<tas_temporizer>0</tas_temporizer>
|
||||
<tas_type_day></tas_type_day>
|
||||
<tas_timeunit>DAYS</tas_timeunit>
|
||||
<tas_alert>FALSE</tas_alert>
|
||||
<tas_priority_variable></tas_priority_variable>
|
||||
<tas_assign_type>BALANCED</tas_assign_type>
|
||||
<tas_assign_variable><![CDATA[@@SYS_NEXT_USER_TO_BE_ASSIGNED]]></tas_assign_variable>
|
||||
<tas_group_variable></tas_group_variable>
|
||||
<tas_mi_instance_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCE]]></tas_mi_instance_variable>
|
||||
<tas_mi_complete_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCES_COMPLETE]]></tas_mi_complete_variable>
|
||||
<tas_assign_location>FALSE</tas_assign_location>
|
||||
<tas_assign_location_adhoc>FALSE</tas_assign_location_adhoc>
|
||||
<tas_transfer_fly>FALSE</tas_transfer_fly>
|
||||
<tas_last_assigned>00000000000000000000000000000001</tas_last_assigned>
|
||||
<tas_user>0</tas_user>
|
||||
<tas_can_upload>FALSE</tas_can_upload>
|
||||
<tas_view_upload>FALSE</tas_view_upload>
|
||||
<tas_view_additional_documentation>FALSE</tas_view_additional_documentation>
|
||||
<tas_can_cancel>FALSE</tas_can_cancel>
|
||||
<tas_owner_app>FALSE</tas_owner_app>
|
||||
<stg_uid></stg_uid>
|
||||
<tas_can_pause>FALSE</tas_can_pause>
|
||||
<tas_can_send_message>TRUE</tas_can_send_message>
|
||||
<tas_can_delete_docs>FALSE</tas_can_delete_docs>
|
||||
<tas_self_service>FALSE</tas_self_service>
|
||||
<tas_start>TRUE</tas_start>
|
||||
<tas_to_last_user>FALSE</tas_to_last_user>
|
||||
<tas_send_last_email>FALSE</tas_send_last_email>
|
||||
<tas_derivation>NORMAL</tas_derivation>
|
||||
<tas_posx>255</tas_posx>
|
||||
<tas_posy>79</tas_posy>
|
||||
<tas_width>110</tas_width>
|
||||
<tas_height>60</tas_height>
|
||||
<tas_color></tas_color>
|
||||
<tas_evn_uid></tas_evn_uid>
|
||||
<tas_boundary></tas_boundary>
|
||||
<tas_derivation_screen_tpl></tas_derivation_screen_tpl>
|
||||
<tas_selfservice_timeout>0</tas_selfservice_timeout>
|
||||
<tas_selfservice_time>0</tas_selfservice_time>
|
||||
<tas_selfservice_time_unit></tas_selfservice_time_unit>
|
||||
<tas_selfservice_trigger_uid></tas_selfservice_trigger_uid>
|
||||
<tas_selfservice_execution>EVERY_TIME</tas_selfservice_execution>
|
||||
<tas_not_email_from_format>0</tas_not_email_from_format>
|
||||
<tas_offline>FALSE</tas_offline>
|
||||
<tas_email_server_uid></tas_email_server_uid>
|
||||
<tas_auto_root>FALSE</tas_auto_root>
|
||||
<tas_receive_server_uid></tas_receive_server_uid>
|
||||
<tas_receive_last_email>FALSE</tas_receive_last_email>
|
||||
<tas_receive_email_from_format>0</tas_receive_email_from_format>
|
||||
<tas_receive_message_type>text</tas_receive_message_type>
|
||||
<tas_receive_message_template>alert_message.html</tas_receive_message_template>
|
||||
<tas_receive_subject_message></tas_receive_subject_message>
|
||||
<tas_receive_message></tas_receive_message>
|
||||
<tas_average></tas_average>
|
||||
<tas_sdv></tas_sdv>
|
||||
</record>
|
||||
<record>
|
||||
<pro_uid>56559353559303a3cc06e80025826369</pro_uid>
|
||||
<tas_uid>79146780259303a4c3c4224096542966</tas_uid>
|
||||
<tas_title>WEBENTRY</tas_title>
|
||||
<tas_description></tas_description>
|
||||
<tas_def_title></tas_def_title>
|
||||
<tas_def_subject_message></tas_def_subject_message>
|
||||
<tas_def_proc_code></tas_def_proc_code>
|
||||
<tas_def_message></tas_def_message>
|
||||
<tas_def_description></tas_def_description>
|
||||
<tas_type>NORMAL</tas_type>
|
||||
<tas_duration>1</tas_duration>
|
||||
<tas_delay_type></tas_delay_type>
|
||||
<tas_temporizer>0</tas_temporizer>
|
||||
<tas_type_day></tas_type_day>
|
||||
<tas_timeunit>DAYS</tas_timeunit>
|
||||
<tas_alert>FALSE</tas_alert>
|
||||
<tas_priority_variable></tas_priority_variable>
|
||||
<tas_assign_type>BALANCED</tas_assign_type>
|
||||
<tas_assign_variable><![CDATA[@@SYS_NEXT_USER_TO_BE_ASSIGNED]]></tas_assign_variable>
|
||||
<tas_group_variable></tas_group_variable>
|
||||
<tas_mi_instance_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCE]]></tas_mi_instance_variable>
|
||||
<tas_mi_complete_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCES_COMPLETE]]></tas_mi_complete_variable>
|
||||
<tas_assign_location>FALSE</tas_assign_location>
|
||||
<tas_assign_location_adhoc>FALSE</tas_assign_location_adhoc>
|
||||
<tas_transfer_fly>FALSE</tas_transfer_fly>
|
||||
<tas_last_assigned>0</tas_last_assigned>
|
||||
<tas_user>0</tas_user>
|
||||
<tas_can_upload>FALSE</tas_can_upload>
|
||||
<tas_view_upload>FALSE</tas_view_upload>
|
||||
<tas_view_additional_documentation>FALSE</tas_view_additional_documentation>
|
||||
<tas_can_cancel>FALSE</tas_can_cancel>
|
||||
<tas_owner_app>FALSE</tas_owner_app>
|
||||
<stg_uid></stg_uid>
|
||||
<tas_can_pause>FALSE</tas_can_pause>
|
||||
<tas_can_send_message>TRUE</tas_can_send_message>
|
||||
<tas_can_delete_docs>FALSE</tas_can_delete_docs>
|
||||
<tas_self_service>FALSE</tas_self_service>
|
||||
<tas_start>FALSE</tas_start>
|
||||
<tas_to_last_user>FALSE</tas_to_last_user>
|
||||
<tas_send_last_email>FALSE</tas_send_last_email>
|
||||
<tas_derivation>NORMAL</tas_derivation>
|
||||
<tas_posx>100</tas_posx>
|
||||
<tas_posy>206</tas_posy>
|
||||
<tas_width>110</tas_width>
|
||||
<tas_height>60</tas_height>
|
||||
<tas_color></tas_color>
|
||||
<tas_evn_uid></tas_evn_uid>
|
||||
<tas_boundary></tas_boundary>
|
||||
<tas_derivation_screen_tpl></tas_derivation_screen_tpl>
|
||||
<tas_selfservice_timeout>0</tas_selfservice_timeout>
|
||||
<tas_selfservice_time>0</tas_selfservice_time>
|
||||
<tas_selfservice_time_unit></tas_selfservice_time_unit>
|
||||
<tas_selfservice_trigger_uid></tas_selfservice_trigger_uid>
|
||||
<tas_selfservice_execution>EVERY_TIME</tas_selfservice_execution>
|
||||
<tas_not_email_from_format>0</tas_not_email_from_format>
|
||||
<tas_offline>FALSE</tas_offline>
|
||||
<tas_email_server_uid></tas_email_server_uid>
|
||||
<tas_auto_root>FALSE</tas_auto_root>
|
||||
<tas_receive_server_uid></tas_receive_server_uid>
|
||||
<tas_receive_last_email>FALSE</tas_receive_last_email>
|
||||
<tas_receive_email_from_format>0</tas_receive_email_from_format>
|
||||
<tas_receive_message_type>text</tas_receive_message_type>
|
||||
<tas_receive_message_template>alert_message.html</tas_receive_message_template>
|
||||
<tas_receive_subject_message></tas_receive_subject_message>
|
||||
<tas_receive_message></tas_receive_message>
|
||||
<tas_average></tas_average>
|
||||
<tas_sdv></tas_sdv>
|
||||
</record>
|
||||
<record>
|
||||
<pro_uid>56559353559303a3cc06e80025826369</pro_uid>
|
||||
<tas_uid>wee-1855259303a4c486358089637672</tas_uid>
|
||||
<tas_title>WEBENTRY</tas_title>
|
||||
<tas_description></tas_description>
|
||||
<tas_def_title></tas_def_title>
|
||||
<tas_def_subject_message></tas_def_subject_message>
|
||||
<tas_def_proc_code></tas_def_proc_code>
|
||||
<tas_def_message></tas_def_message>
|
||||
<tas_def_description></tas_def_description>
|
||||
<tas_type>WEBENTRYEVENT</tas_type>
|
||||
<tas_duration>1</tas_duration>
|
||||
<tas_delay_type></tas_delay_type>
|
||||
<tas_temporizer>0</tas_temporizer>
|
||||
<tas_type_day></tas_type_day>
|
||||
<tas_timeunit>DAYS</tas_timeunit>
|
||||
<tas_alert>FALSE</tas_alert>
|
||||
<tas_priority_variable></tas_priority_variable>
|
||||
<tas_assign_type>BALANCED</tas_assign_type>
|
||||
<tas_assign_variable><![CDATA[@@SYS_NEXT_USER_TO_BE_ASSIGNED]]></tas_assign_variable>
|
||||
<tas_group_variable></tas_group_variable>
|
||||
<tas_mi_instance_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCE]]></tas_mi_instance_variable>
|
||||
<tas_mi_complete_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCES_COMPLETE]]></tas_mi_complete_variable>
|
||||
<tas_assign_location>FALSE</tas_assign_location>
|
||||
<tas_assign_location_adhoc>FALSE</tas_assign_location_adhoc>
|
||||
<tas_transfer_fly>FALSE</tas_transfer_fly>
|
||||
<tas_last_assigned>00000000000000000000000000000001</tas_last_assigned>
|
||||
<tas_user>0</tas_user>
|
||||
<tas_can_upload>FALSE</tas_can_upload>
|
||||
<tas_view_upload>FALSE</tas_view_upload>
|
||||
<tas_view_additional_documentation>FALSE</tas_view_additional_documentation>
|
||||
<tas_can_cancel>FALSE</tas_can_cancel>
|
||||
<tas_owner_app>FALSE</tas_owner_app>
|
||||
<stg_uid></stg_uid>
|
||||
<tas_can_pause>FALSE</tas_can_pause>
|
||||
<tas_can_send_message>TRUE</tas_can_send_message>
|
||||
<tas_can_delete_docs>FALSE</tas_can_delete_docs>
|
||||
<tas_self_service>FALSE</tas_self_service>
|
||||
<tas_start>TRUE</tas_start>
|
||||
<tas_to_last_user>FALSE</tas_to_last_user>
|
||||
<tas_send_last_email>FALSE</tas_send_last_email>
|
||||
<tas_derivation>NORMAL</tas_derivation>
|
||||
<tas_posx>100</tas_posx>
|
||||
<tas_posy>206</tas_posy>
|
||||
<tas_width>110</tas_width>
|
||||
<tas_height>60</tas_height>
|
||||
<tas_color></tas_color>
|
||||
<tas_evn_uid></tas_evn_uid>
|
||||
<tas_boundary></tas_boundary>
|
||||
<tas_derivation_screen_tpl></tas_derivation_screen_tpl>
|
||||
<tas_selfservice_timeout>0</tas_selfservice_timeout>
|
||||
<tas_selfservice_time>0</tas_selfservice_time>
|
||||
<tas_selfservice_time_unit></tas_selfservice_time_unit>
|
||||
<tas_selfservice_trigger_uid></tas_selfservice_trigger_uid>
|
||||
<tas_selfservice_execution>EVERY_TIME</tas_selfservice_execution>
|
||||
<tas_not_email_from_format>0</tas_not_email_from_format>
|
||||
<tas_offline>FALSE</tas_offline>
|
||||
<tas_email_server_uid></tas_email_server_uid>
|
||||
<tas_auto_root>FALSE</tas_auto_root>
|
||||
<tas_receive_server_uid></tas_receive_server_uid>
|
||||
<tas_receive_last_email>FALSE</tas_receive_last_email>
|
||||
<tas_receive_email_from_format>0</tas_receive_email_from_format>
|
||||
<tas_receive_message_type>text</tas_receive_message_type>
|
||||
<tas_receive_message_template>alert_message.html</tas_receive_message_template>
|
||||
<tas_receive_subject_message></tas_receive_subject_message>
|
||||
<tas_receive_message></tas_receive_message>
|
||||
<tas_average></tas_average>
|
||||
<tas_sdv></tas_sdv>
|
||||
</record>
|
||||
</table>
|
||||
<table name="routes">
|
||||
<record>
|
||||
<rou_uid>3831401275930430f03a230048632351</rou_uid>
|
||||
<rou_parent>0</rou_parent>
|
||||
<pro_uid>56559353559303a3cc06e80025826369</pro_uid>
|
||||
<tas_uid>wee-1855259303a4c486358089637672</tas_uid>
|
||||
<rou_next_task>16965000459303a4c2a3e43075058476</rou_next_task>
|
||||
<rou_case>1</rou_case>
|
||||
<rou_type>SEQUENTIAL</rou_type>
|
||||
<rou_default>0</rou_default>
|
||||
<rou_condition></rou_condition>
|
||||
<rou_to_last_user>FALSE</rou_to_last_user>
|
||||
<rou_optional>FALSE</rou_optional>
|
||||
<rou_send_email>TRUE</rou_send_email>
|
||||
<rou_sourceanchor>1</rou_sourceanchor>
|
||||
<rou_targetanchor>0</rou_targetanchor>
|
||||
<rou_to_port>1</rou_to_port>
|
||||
<rou_from_port>2</rou_from_port>
|
||||
<rou_evn_uid></rou_evn_uid>
|
||||
<gat_uid></gat_uid>
|
||||
</record>
|
||||
<record>
|
||||
<rou_uid>3902368125930430ed2b640062056095</rou_uid>
|
||||
<rou_parent>0</rou_parent>
|
||||
<pro_uid>56559353559303a3cc06e80025826369</pro_uid>
|
||||
<tas_uid>16965000459303a4c2a3e43075058476</tas_uid>
|
||||
<rou_next_task>-1</rou_next_task>
|
||||
<rou_case>1</rou_case>
|
||||
<rou_type>SEQUENTIAL</rou_type>
|
||||
<rou_default>0</rou_default>
|
||||
<rou_condition></rou_condition>
|
||||
<rou_to_last_user>FALSE</rou_to_last_user>
|
||||
<rou_optional>FALSE</rou_optional>
|
||||
<rou_send_email>TRUE</rou_send_email>
|
||||
<rou_sourceanchor>1</rou_sourceanchor>
|
||||
<rou_targetanchor>0</rou_targetanchor>
|
||||
<rou_to_port>1</rou_to_port>
|
||||
<rou_from_port>2</rou_from_port>
|
||||
<rou_evn_uid></rou_evn_uid>
|
||||
<gat_uid></gat_uid>
|
||||
</record>
|
||||
</table>
|
||||
<table name="lanes"/>
|
||||
<table name="gateways"/>
|
||||
<table name="inputs">
|
||||
<record>
|
||||
<inp_doc_uid>48678504459303b80421e58048206875</inp_doc_uid>
|
||||
<pro_uid>56559353559303a3cc06e80025826369</pro_uid>
|
||||
<inp_doc_title>input</inp_doc_title>
|
||||
<inp_doc_description></inp_doc_description>
|
||||
<inp_doc_form_needed>VIRTUAL</inp_doc_form_needed>
|
||||
<inp_doc_original>ORIGINAL</inp_doc_original>
|
||||
<inp_doc_published>PRIVATE</inp_doc_published>
|
||||
<inp_doc_versioning>0</inp_doc_versioning>
|
||||
<inp_doc_destination_path></inp_doc_destination_path>
|
||||
<inp_doc_tags>INPUT</inp_doc_tags>
|
||||
<inp_doc_type_file><![CDATA[.*]]></inp_doc_type_file>
|
||||
<inp_doc_max_filesize>0</inp_doc_max_filesize>
|
||||
<inp_doc_max_filesize_unit>KB</inp_doc_max_filesize_unit>
|
||||
</record>
|
||||
</table>
|
||||
<table name="outputs">
|
||||
<record>
|
||||
<out_doc_uid>62358602359303ca88ac523084167406</out_doc_uid>
|
||||
<out_doc_title>Output doc step</out_doc_title>
|
||||
<out_doc_description>Generated</out_doc_description>
|
||||
<out_doc_filename>output</out_doc_filename>
|
||||
<out_doc_template><![CDATA[<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html>
|
||||
<head>
|
||||
</head>
|
||||
<body>
|
||||
<p>Generated at WebEntry 2.0 by @@NAME</p>
|
||||
<p>Your code is: @@CODE</p>
|
||||
<p></p>
|
||||
<p></p>
|
||||
</body>
|
||||
</html>]]></out_doc_template>
|
||||
<pro_uid>56559353559303a3cc06e80025826369</pro_uid>
|
||||
<out_doc_report_generator>TCPDF</out_doc_report_generator>
|
||||
<out_doc_landscape>0</out_doc_landscape>
|
||||
<out_doc_media>Letter</out_doc_media>
|
||||
<out_doc_left_margin>20</out_doc_left_margin>
|
||||
<out_doc_right_margin>20</out_doc_right_margin>
|
||||
<out_doc_top_margin>20</out_doc_top_margin>
|
||||
<out_doc_bottom_margin>20</out_doc_bottom_margin>
|
||||
<out_doc_generate>BOTH</out_doc_generate>
|
||||
<out_doc_type>HTML</out_doc_type>
|
||||
<out_doc_current_revision></out_doc_current_revision>
|
||||
<out_doc_field_mapping></out_doc_field_mapping>
|
||||
<out_doc_versioning>1</out_doc_versioning>
|
||||
<out_doc_destination_path></out_doc_destination_path>
|
||||
<out_doc_tags></out_doc_tags>
|
||||
<out_doc_pdf_security_enabled>0</out_doc_pdf_security_enabled>
|
||||
<out_doc_pdf_security_open_password></out_doc_pdf_security_open_password>
|
||||
<out_doc_pdf_security_owner_password></out_doc_pdf_security_owner_password>
|
||||
<out_doc_pdf_security_permissions></out_doc_pdf_security_permissions>
|
||||
<out_doc_open_type>1</out_doc_open_type>
|
||||
</record>
|
||||
</table>
|
||||
<table name="dynaforms">
|
||||
<record>
|
||||
<dyn_uid>31190541559303cd9b08df8014656617</dyn_uid>
|
||||
<dyn_title>form2</dyn_title>
|
||||
<dyn_description></dyn_description>
|
||||
<pro_uid>56559353559303a3cc06e80025826369</pro_uid>
|
||||
<dyn_type>xmlform</dyn_type>
|
||||
<dyn_filename><![CDATA[56559353559303a3cc06e80025826369/31190541559303cd9b08df8014656617]]></dyn_filename>
|
||||
<dyn_content><![CDATA[{"name":"form2","description":"","items":[{"type":"form","variable":"","var_uid":"","dataType":"","id":"31190541559303cd9b08df8014656617","name":"form2","description":"","mode":"edit","script":"","language":"en","externalLibs":"","printable":false,"items":[[{"type":"title","id":"title0000000001","label":"title_1","colSpan":12}],[{"type":"subtitle","id":"subtitle0000000001","label":"subtitle_1","colSpan":12}],[{"type":"text","variable":"CODE","var_uid":"42858539059303ceaaa5438089098655","dataType":"string","protectedValue":true,"id":"CODE","name":"CODE","label":"Your code","defaultValue":"","placeholder":"","hint":"","required":false,"textTransform":"none","validate":"","validateMessage":"","maxLength":1000,"formula":"","mode":"parent","operation":"","datasource":"database","dbConnection":"workflow","dbConnectionLabel":"PM Database","sql":"","dataVariable":"","var_name":"CODE","colSpan":12}],[{"type":"submit","id":"submit0000000001","name":"submit0000000001","label":"Next Step","colSpan":12}]],"variables":[{"var_uid":"42858539059303ceaaa5438089098655","prj_uid":"56559353559303a3cc06e80025826369","var_name":"CODE","var_field_type":"string","var_field_size":10,"var_label":"string","var_dbconnection":"workflow","var_dbconnection_label":"PM Database","var_sql":"","var_null":0,"var_default":"","var_accepted_values":"[]","inp_doc_uid":""}]}]}]]></dyn_content>
|
||||
<dyn_label></dyn_label>
|
||||
<dyn_version>2</dyn_version>
|
||||
<dyn_update_date><![CDATA[2017-06-01 16:12:59]]></dyn_update_date>
|
||||
</record>
|
||||
<record>
|
||||
<dyn_uid>88922857259303a5ce1f887010389343</dyn_uid>
|
||||
<dyn_title>form1</dyn_title>
|
||||
<dyn_description></dyn_description>
|
||||
<pro_uid>56559353559303a3cc06e80025826369</pro_uid>
|
||||
<dyn_type>xmlform</dyn_type>
|
||||
<dyn_filename><![CDATA[56559353559303a3cc06e80025826369/88922857259303a5ce1f887010389343]]></dyn_filename>
|
||||
<dyn_content><![CDATA[{"name":"form1","description":"","items":[{"type":"form","variable":"","var_uid":"","dataType":"","id":"88922857259303a5ce1f887010389343","name":"form1","description":"","mode":"edit","script":"","language":"en","externalLibs":"","printable":false,"items":[[{"type":"title","id":"title0000000001","label":"WebEntry 2.0","colSpan":12}],[{"type":"subtitle","id":"subtitle0000000001","label":"First Step","colSpan":12}],[{"type":"text","variable":"NAME","var_uid":"94396334059303c77612577074716073","dataType":"string","protectedValue":false,"id":"NAME","name":"NAME","label":"Your name","defaultValue":"","placeholder":"","hint":"","required":false,"textTransform":"none","validate":"","validateMessage":"","maxLength":1000,"formula":"","mode":"parent","operation":"","datasource":"database","dbConnection":"workflow","dbConnectionLabel":"PM Database","sql":"","dataVariable":"","var_name":"NAME","colSpan":12}],[{"type":"submit","id":"submit0000000001","name":"submit0000000001","label":"Next Step","colSpan":12}]],"variables":[{"var_uid":"94396334059303c77612577074716073","prj_uid":"56559353559303a3cc06e80025826369","var_name":"NAME","var_field_type":"string","var_field_size":10,"var_label":"string","var_dbconnection":"workflow","var_dbconnection_label":"PM Database","var_sql":"","var_null":0,"var_default":"","var_accepted_values":"[]","inp_doc_uid":""}]}]}]]></dyn_content>
|
||||
<dyn_label></dyn_label>
|
||||
<dyn_version>2</dyn_version>
|
||||
<dyn_update_date><![CDATA[2017-06-01 16:10:49]]></dyn_update_date>
|
||||
</record>
|
||||
</table>
|
||||
<table name="steps">
|
||||
<record>
|
||||
<step_uid>13911436659303d139063e4090444439</step_uid>
|
||||
<pro_uid>56559353559303a3cc06e80025826369</pro_uid>
|
||||
<tas_uid>wee-1855259303a4c486358089637672</tas_uid>
|
||||
<step_type_obj>DYNAFORM</step_type_obj>
|
||||
<step_uid_obj>31190541559303cd9b08df8014656617</step_uid_obj>
|
||||
<step_condition></step_condition>
|
||||
<step_position>2</step_position>
|
||||
<step_mode>EDIT</step_mode>
|
||||
</record>
|
||||
<record>
|
||||
<step_uid>40852133559303ccfe1a382002839416</step_uid>
|
||||
<pro_uid>56559353559303a3cc06e80025826369</pro_uid>
|
||||
<tas_uid>wee-1855259303a4c486358089637672</tas_uid>
|
||||
<step_type_obj>OUTPUT_DOCUMENT</step_type_obj>
|
||||
<step_uid_obj>62358602359303ca88ac523084167406</step_uid_obj>
|
||||
<step_condition></step_condition>
|
||||
<step_position>4</step_position>
|
||||
<step_mode>EDIT</step_mode>
|
||||
</record>
|
||||
<record>
|
||||
<step_uid>56695174459303a69ded370094811544</step_uid>
|
||||
<pro_uid>56559353559303a3cc06e80025826369</pro_uid>
|
||||
<tas_uid>wee-1855259303a4c486358089637672</tas_uid>
|
||||
<step_type_obj>DYNAFORM</step_type_obj>
|
||||
<step_uid_obj>88922857259303a5ce1f887010389343</step_uid_obj>
|
||||
<step_condition></step_condition>
|
||||
<step_position>1</step_position>
|
||||
<step_mode>EDIT</step_mode>
|
||||
</record>
|
||||
<record>
|
||||
<step_uid>96569604359303b9ae8d584027424919</step_uid>
|
||||
<pro_uid>56559353559303a3cc06e80025826369</pro_uid>
|
||||
<tas_uid>wee-1855259303a4c486358089637672</tas_uid>
|
||||
<step_type_obj>INPUT_DOCUMENT</step_type_obj>
|
||||
<step_uid_obj>48678504459303b80421e58048206875</step_uid_obj>
|
||||
<step_condition></step_condition>
|
||||
<step_position>3</step_position>
|
||||
<step_mode>EDIT</step_mode>
|
||||
</record>
|
||||
</table>
|
||||
<table name="triggers">
|
||||
<record>
|
||||
<tri_uid>34990214159303d842fbfd6017869869</tri_uid>
|
||||
<tri_title>Generate Code</tri_title>
|
||||
<tri_description></tri_description>
|
||||
<pro_uid>56559353559303a3cc06e80025826369</pro_uid>
|
||||
<tri_type>SCRIPT</tri_type>
|
||||
<tri_webbot><![CDATA[@@CODE = uniqid("TRI_");]]></tri_webbot>
|
||||
<tri_param></tri_param>
|
||||
</record>
|
||||
</table>
|
||||
<table name="taskusers"/>
|
||||
<table name="groupwfs"/>
|
||||
<table name="steptriggers">
|
||||
<record>
|
||||
<step_uid>13911436659303d139063e4090444439</step_uid>
|
||||
<tas_uid>wee-1855259303a4c486358089637672</tas_uid>
|
||||
<tri_uid>34990214159303d842fbfd6017869869</tri_uid>
|
||||
<st_type>BEFORE</st_type>
|
||||
<st_condition></st_condition>
|
||||
<st_position>1</st_position>
|
||||
</record>
|
||||
</table>
|
||||
<table name="dbconnections"/>
|
||||
<table name="reportTables"/>
|
||||
<table name="reportTablesVars"/>
|
||||
<table name="stepSupervisor"/>
|
||||
<table name="objectPermissions"/>
|
||||
<table name="subProcess"/>
|
||||
<table name="caseTracker"/>
|
||||
<table name="caseTrackerObject"/>
|
||||
<table name="stage"/>
|
||||
<table name="fieldCondition"/>
|
||||
<table name="event"/>
|
||||
<table name="caseScheduler"/>
|
||||
<table name="processCategory"/>
|
||||
<table name="taskExtraProperties"/>
|
||||
<table name="processUser"/>
|
||||
<table name="processVariables">
|
||||
<record>
|
||||
<var_uid>42858539059303ceaaa5438089098655</var_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<var_name>CODE</var_name>
|
||||
<var_field_type>string</var_field_type>
|
||||
<var_field_size>10</var_field_size>
|
||||
<var_label>string</var_label>
|
||||
<var_dbconnection>workflow</var_dbconnection>
|
||||
<var_sql></var_sql>
|
||||
<var_null>0</var_null>
|
||||
<var_default></var_default>
|
||||
<var_accepted_values><![CDATA[[]]]></var_accepted_values>
|
||||
<inp_doc_uid></inp_doc_uid>
|
||||
</record>
|
||||
<record>
|
||||
<var_uid>94396334059303c77612577074716073</var_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<var_name>NAME</var_name>
|
||||
<var_field_type>string</var_field_type>
|
||||
<var_field_size>10</var_field_size>
|
||||
<var_label>string</var_label>
|
||||
<var_dbconnection>workflow</var_dbconnection>
|
||||
<var_sql></var_sql>
|
||||
<var_null>0</var_null>
|
||||
<var_default></var_default>
|
||||
<var_accepted_values><![CDATA[[]]]></var_accepted_values>
|
||||
<inp_doc_uid></inp_doc_uid>
|
||||
</record>
|
||||
</table>
|
||||
<table name="webEntry"/>
|
||||
<table name="webEntryEvent">
|
||||
<record>
|
||||
<wee_uid>77353010159303a6a3cbe28043190607</wee_uid>
|
||||
<prj_uid>56559353559303a3cc06e80025826369</prj_uid>
|
||||
<evn_uid>26331855259303a4c486358089637672</evn_uid>
|
||||
<act_uid>16965000459303a4c2a3e43075058476</act_uid>
|
||||
<dyn_uid>88922857259303a5ce1f887010389343</dyn_uid>
|
||||
<usr_uid></usr_uid>
|
||||
<wee_title>26331855259303a4c486358089637672</wee_title>
|
||||
<wee_description></wee_description>
|
||||
<wee_status>ENABLED</wee_status>
|
||||
<wee_we_uid>81407840459303a6a09dcc4087975719</wee_we_uid>
|
||||
<wee_we_tas_uid>wee-1855259303a4c486358089637672</wee_we_tas_uid>
|
||||
<wee_we_url>26331855259303a4c486358089637672.php</wee_we_url>
|
||||
<we_custom_title></we_custom_title>
|
||||
<we_type>MULTIPLE</we_type>
|
||||
<we_authentication>LOGIN_REQUIRED</we_authentication>
|
||||
<we_hide_information_bar>0</we_hide_information_bar>
|
||||
<we_callback>PROCESSMAKER</we_callback>
|
||||
<we_callback_url></we_callback_url>
|
||||
<we_link_generation>DEFAULT</we_link_generation>
|
||||
<we_link_skin></we_link_skin>
|
||||
<we_link_language></we_link_language>
|
||||
<we_link_domain></we_link_domain>
|
||||
<tas_uid>wee-1855259303a4c486358089637672</tas_uid>
|
||||
</record>
|
||||
</table>
|
||||
<table name="messageType"/>
|
||||
<table name="messageTypeVariable"/>
|
||||
<table name="messageEventDefinition"/>
|
||||
<table name="scriptTask"/>
|
||||
<table name="timerEvent"/>
|
||||
<table name="emailEvent"/>
|
||||
<table name="filesManager">
|
||||
<record>
|
||||
<prf_uid>73977577559303b4563ed83089686045</prf_uid>
|
||||
<pro_uid>56559353559303a3cc06e80025826369</pro_uid>
|
||||
<usr_uid>00000000000000000000000000000001</usr_uid>
|
||||
<prf_update_usr_uid></prf_update_usr_uid>
|
||||
<prf_path><![CDATA[/Users/davidcallizaya/NetBeansProjects/processmaker0/shared/sites/hor3207/mailTemplates/56559353559303a3cc06e80025826369/actionsByEmail.html]]></prf_path>
|
||||
<prf_type>file</prf_type>
|
||||
<prf_editable>1</prf_editable>
|
||||
<prf_create_date><![CDATA[2017-06-01 16:05:25]]></prf_create_date>
|
||||
<prf_update_date></prf_update_date>
|
||||
</record>
|
||||
</table>
|
||||
<table name="abeConfiguration"/>
|
||||
<table name="elementTask"/>
|
||||
</definition>
|
||||
<workflow-files>
|
||||
<file target="dynaforms">
|
||||
<file_name>form2</file_name>
|
||||
<file_path><![CDATA[56559353559303a3cc06e80025826369/31190541559303cd9b08df8014656617.xml]]></file_path>
|
||||
<file_content><![CDATA[PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPGR5bmFGb3JtIHR5cGU9InhtbGZvcm0iIG5hbWU9IjU2NTU5MzUzNTU5MzAzYTNjYzA2ZTgwMDI1ODI2MzY5LzMxMTkwNTQxNTU5MzAzY2Q5YjA4ZGY4MDE0NjU2NjE3IiB3aWR0aD0iNTAwIiBlbmFibGV0ZW1wbGF0ZT0iMCIgbW9kZT0iIiBuZXh0c3RlcHNhdmU9InByb21wdCI+CjwvZHluYUZvcm0+]]></file_content>
|
||||
</file>
|
||||
<file target="dynaforms">
|
||||
<file_name>form1</file_name>
|
||||
<file_path><![CDATA[56559353559303a3cc06e80025826369/88922857259303a5ce1f887010389343.xml]]></file_path>
|
||||
<file_content><![CDATA[PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPGR5bmFGb3JtIHR5cGU9InhtbGZvcm0iIG5hbWU9IjU2NTU5MzUzNTU5MzAzYTNjYzA2ZTgwMDI1ODI2MzY5Lzg4OTIyODU3MjU5MzAzYTVjZTFmODg3MDEwMzg5MzQzIiB3aWR0aD0iNTAwIiBlbmFibGV0ZW1wbGF0ZT0iMCIgbW9kZT0iIiBuZXh0c3RlcHNhdmU9InByb21wdCI+CjwvZHluYUZvcm0+]]></file_content>
|
||||
</file>
|
||||
<file target="templates">
|
||||
<file_name>actionsByEmail.html</file_name>
|
||||
<file_path><![CDATA[56559353559303a3cc06e80025826369/actionsByEmail.html]]></file_path>
|
||||
<file_content><![CDATA[PHRhYmxlIHN0eWxlPSJiYWNrZ3JvdW5kLWNvbG9yOiB3aGl0ZTsgZm9udC1mYW1pbHk6IEFyaWFsLEhlbHZldGljYSxzYW5zLXNlcmlmOyBjb2xvcjogYmxhY2s7IGZvbnQtc2l6ZTogMTFweDsgdGV4dC1hbGlnbjogbGVmdDsiIGNlbGxwYWRkaW5nPSIxMCIgY2VsbHNwYWNpbmc9IjAiIHdpZHRoPSIxMDAlIj4NCjx0cj4NCiAgPHRkIHN0eWxlPSJmb250LXNpemU6IDE0cHg7Ij48Yj5BQ1RJT05TIEJZIEVNQUlMPC9iPjwvdGQ+DQo8L3RyPg0KPHRyPg0KICA8dGQgc3R5bGU9InZlcnRpY2FsLWFsaWduOm1pZGRsZTsiPg0KCSAgPGhyPg0KCSAgPGJyIC8+DQoJICBAI19fQUJFX18NCiAgICA8YnIgLz4NCgkJPGJyIC8+DQoJCTxocj48Yj5UaGlzIEJ1c2luZXNzIFByb2Nlc3MgaXMgcG93ZXJlZCBieSBQcm9jZXNzTWFrZXIuPGI+DQoJCTxiciAvPg0KCQk8YSBocmVmPSJodHRwOi8vd3d3LnByb2Nlc3NtYWtlci5jb20iIHN0eWxlPSJjb2xvcjojYzQwMDAwOyI+d3d3LnByb2Nlc3NtYWtlci5jb208L2E+DQoJCTxiciAvPg0KICA8L3RkPg0KPC90cj4NCjwvdGFibGU+]]></file_content>
|
||||
</file>
|
||||
<file target="public">
|
||||
<file_name>26331855259303a4c486358089637672Info.php</file_name>
|
||||
<file_path><![CDATA[56559353559303a3cc06e80025826369/26331855259303a4c486358089637672Info.php]]></file_path>
|
||||
<file_content><![CDATA[PD9waHAKCiRHX1BVQkxJU0ggPSBuZXcgUHVibGlzaGVyKCk7CiRzaG93ID0gImxvZ2luL3Nob3dNZXNzYWdlIjsKJG1lc3NhZ2UgPSAiIjsKaWYgKGlzc2V0KCRfU0VTU0lPTlsiX193ZWJFbnRyeVN1Y2Nlc3NfXyJdKSkgewogICAgJHNob3cgPSAibG9naW4vc2hvd0luZm8iOwogICAgJG1lc3NhZ2UgPSAkX1NFU1NJT05bIl9fd2ViRW50cnlTdWNjZXNzX18iXTsKfSBlbHNlIHsKICAgICRzaG93ID0gImxvZ2luL3Nob3dNZXNzYWdlIjsKICAgICRtZXNzYWdlID0gJF9TRVNTSU9OWyJfX3dlYkVudHJ5RXJyb3JfXyJdOwp9CiRHX1BVQkxJU0gtPkFkZENvbnRlbnQoInhtbGZvcm0iLCAieG1sZm9ybSIsICRzaG93LCAiIiwgJG1lc3NhZ2UpOwpHOjpSZW5kZXJQYWdlKCJwdWJsaXNoIiwgImJsYW5rIik7Cgo=]]></file_content>
|
||||
</file>
|
||||
</workflow-files>
|
||||
</ProcessMaker-Project>
|
||||
@@ -1,773 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace Tests\unit\workflow\engine\src\ProcessMaker\BusinessModel;
|
||||
|
||||
use G;
|
||||
use ProcessMaker\BusinessModel\WebEntryEvent;
|
||||
use ProcessMaker\Importer\XmlImporter;
|
||||
use System;
|
||||
use Tests\WorkflowTestCase;
|
||||
|
||||
/**
|
||||
* WebEntryEventTest test
|
||||
*/
|
||||
class WebEntryEventTest extends WorkflowTestCase
|
||||
{
|
||||
const SKIP_VALUE = '&SKIP_VALUE%';
|
||||
|
||||
/**
|
||||
* @var WebEntryEvent $object
|
||||
*/
|
||||
protected $object;
|
||||
private $processUid;
|
||||
private $processUid2;
|
||||
private $adminUid = '00000000000000000000000000000001';
|
||||
private $customTitle = 'CUSTOM TITLE';
|
||||
private $domain = 'http://domain.localhost';
|
||||
|
||||
/**
|
||||
* Sets up the unit test.
|
||||
*/
|
||||
protected function setUp()
|
||||
{
|
||||
//to do: This is excluded because requires more changes
|
||||
$this->markTestIncomplete();
|
||||
|
||||
$this->getBaseUri();
|
||||
$this->setupDB();
|
||||
$this->processUid = $this->import(__DIR__ . '/WebEntryEventTest.pmx');
|
||||
$this->processUid2 = $this->import(__DIR__ . '/WebEntryEventTest2.pmx');
|
||||
$this->object = new WebEntryEvent();
|
||||
$this->setTranslation('ID_INVALID_VALUE_CAN_NOT_BE_EMPTY', 'ID_INVALID_VALUE_CAN_NOT_BE_EMPTY({0})');
|
||||
$this->setTranslation('ID_UNDEFINED_VALUE_IS_REQUIRED', 'ID_UNDEFINED_VALUE_IS_REQUIRED({0})');
|
||||
$this->setTranslation('ID_WEB_ENTRY_EVENT_DOES_NOT_EXIST', 'ID_WEB_ENTRY_EVENT_DOES_NOT_EXIST({0})');
|
||||
$this->setTranslation('ID_INVALID_VALUE_ONLY_ACCEPTS_VALUES', 'ID_INVALID_VALUE_ONLY_ACCEPTS_VALUES({0},{1})');
|
||||
$this->setTranslation('ID_DYNAFORM_IS_NOT_ASSIGNED_TO_ACTIVITY', 'ID_DYNAFORM_IS_NOT_ASSIGNED_TO_ACTIVITY({0},{1})');
|
||||
}
|
||||
|
||||
/**
|
||||
* Tears down the unit test.
|
||||
*/
|
||||
protected function tearDown()
|
||||
{
|
||||
$this->clearTranslations();
|
||||
}
|
||||
|
||||
/**
|
||||
* Get base uri for rest applications.
|
||||
* @return string
|
||||
*/
|
||||
private function getBaseUri()
|
||||
{
|
||||
$_SERVER = $this->getServerInformation();
|
||||
$baseUri = System::getServerProtocolHost();
|
||||
|
||||
return $baseUri;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get server information.
|
||||
* @return object
|
||||
*/
|
||||
private function getServerInformation()
|
||||
{
|
||||
$pathData = PATH_DATA . "sites" . PATH_SEP . config("system.workspace") . PATH_SEP . ".server_info";
|
||||
$content = file_get_contents($pathData);
|
||||
$serverInfo = unserialize($content);
|
||||
|
||||
return $serverInfo;
|
||||
}
|
||||
|
||||
/**
|
||||
* @covers ProcessMaker\BusinessModel\WebEntryEvent::getWebEntryEvents
|
||||
* @category HOR-3207:5
|
||||
*/
|
||||
public function testGetWebEntryEvents()
|
||||
{
|
||||
$entryEvents = $this->object->getWebEntryEvents($this->processUid);
|
||||
$this->assertCount(2, $entryEvents);
|
||||
$this->assertNotNull($entryEvents[0]['TAS_UID']);
|
||||
$this->assertNull($entryEvents[0]['WE_CUSTOM_TITLE']);
|
||||
$this->assertEquals($entryEvents[0]['WE_AUTHENTICATION'], 'ANONYMOUS');
|
||||
$this->assertEquals($entryEvents[0]['WE_HIDE_INFORMATION_BAR'], '1');
|
||||
$this->assertEquals($entryEvents[0]['WE_CALLBACK'], 'PROCESSMAKER');
|
||||
$this->assertNull($entryEvents[0]['WE_CALLBACK_URL']);
|
||||
$this->assertEquals($entryEvents[0]['WE_LINK_GENERATION'], 'DEFAULT');
|
||||
$this->assertNull($entryEvents[0]['WE_LINK_SKIN']);
|
||||
$this->assertNull($entryEvents[0]['WE_LINK_LANGUAGE']);
|
||||
$this->assertNull($entryEvents[0]['WE_LINK_DOMAIN']);
|
||||
}
|
||||
|
||||
/**
|
||||
* @covers ProcessMaker\BusinessModel\WebEntryEvent::getAllWebEntryEvents
|
||||
*/
|
||||
public function testGetAllWebEntryEvents()
|
||||
{
|
||||
$entryEvents = $this->object->getAllWebEntryEvents();
|
||||
$this->assertCount(3, $entryEvents);
|
||||
$this->assertNull($entryEvents[0]['WE_CUSTOM_TITLE']);
|
||||
$this->assertEquals($entryEvents[0]['WE_AUTHENTICATION'], 'ANONYMOUS');
|
||||
$this->assertEquals($entryEvents[0]['WE_HIDE_INFORMATION_BAR'], '1');
|
||||
$this->assertEquals($entryEvents[0]['WE_CALLBACK'], 'PROCESSMAKER');
|
||||
$this->assertNull($entryEvents[0]['WE_CALLBACK_URL']);
|
||||
$this->assertEquals($entryEvents[0]['WE_LINK_GENERATION'], 'DEFAULT');
|
||||
$this->assertNull($entryEvents[0]['WE_LINK_SKIN']);
|
||||
$this->assertNull($entryEvents[0]['WE_LINK_LANGUAGE']);
|
||||
$this->assertNull($entryEvents[0]['WE_LINK_DOMAIN']);
|
||||
}
|
||||
|
||||
/**
|
||||
* @covers ProcessMaker\BusinessModel\WebEntryEvent::getWebEntryEvent
|
||||
* @category HOR-3207:6
|
||||
*/
|
||||
public function testGetWebEntryEvent()
|
||||
{
|
||||
$entryEvents = $this->object->getWebEntryEvents($this->processUid);
|
||||
$entry = $this->object->getWebEntryEvent($entryEvents[0]['WEE_UID']);
|
||||
$this->assertEquals($entryEvents[0], $entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* Duplicated web entry
|
||||
* @cover ProcessMaker\BusinessModel\WebEntryEvent::create
|
||||
* @category HOR-3207:7,HOR-3207:2
|
||||
*/
|
||||
public function testCreateSingleNonAuthAlreadyRegistered()
|
||||
{
|
||||
$this->expectException(\Exception::class);
|
||||
$this->expectExceptionMessage('**ID_WEB_ENTRY_EVENT_ALREADY_REGISTERED**');
|
||||
$entryEvents = $this->object->getWebEntryEvents($this->processUid);
|
||||
$dynaform = $this->getADynaform();
|
||||
$this->object->create(
|
||||
$this->processUid, $this->adminUid,
|
||||
[
|
||||
'EVN_UID' => $entryEvents[0]['EVN_UID'],
|
||||
'ACT_UID' => $entryEvents[0]['ACT_UID'],
|
||||
'DYN_UID' => $dynaform->getDynUid(),
|
||||
'WEE_STATUS' => 'ENABLED',
|
||||
'USR_UID' => $this->adminUid,
|
||||
'WEE_TITLE' => $entryEvents[0]['EVN_UID'],
|
||||
]
|
||||
);
|
||||
$this->assertEquals(
|
||||
$this->getSimpleWebEntryUrl($webEntry), $entryEvent['WEE_URL'],
|
||||
'Wrong single web entry url (backward compativility)'
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a new empty single non auth WE
|
||||
* @cover ProcessMaker\BusinessModel\WebEntryEvent::create
|
||||
* @category HOR-3207:7
|
||||
*/
|
||||
public function testCreateSingleNonAuth()
|
||||
{
|
||||
$processUid = $this->processUid2;
|
||||
$entryEvents = $this->object->getWebEntryEvents($processUid);
|
||||
list($webEntry, $entryEvent) = $this->createWebEntryEvent(
|
||||
$processUid, $entryEvents,
|
||||
[
|
||||
'DYN_UID' => $entryEvents[0]['DYN_UID'],
|
||||
]
|
||||
);
|
||||
$this->assertEquals(
|
||||
$this->getSimpleWebEntryUrl($webEntry), $entryEvent['WEE_URL'],
|
||||
'Wrong single web entry url (backward compativility)'
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a new empty multiple non auth WE
|
||||
* @cover ProcessMaker\BusinessModel\WebEntryEvent::create
|
||||
* @category HOR-3207:7
|
||||
*/
|
||||
public function testCreateNewMultipleNonAuth()
|
||||
{
|
||||
$processUid = $this->processUid2;
|
||||
$entryEvents = $this->object->getWebEntryEvents($processUid);
|
||||
$this->createWebEntryEvent(
|
||||
$processUid,
|
||||
$entryEvents,
|
||||
[
|
||||
'WE_TYPE' => "MULTIPLE",
|
||||
'WE_CUSTOM_TITLE' => $this->customTitle,
|
||||
'WE_AUTHENTICATION' => 'ANONYMOUS',
|
||||
'WE_HIDE_INFORMATION_BAR' => "0",
|
||||
'WE_CALLBACK' => "PROCESSMAKER",
|
||||
'WE_CALLBACK_URL' => "http://domain.localhost/callback",
|
||||
'WE_LINK_GENERATION' => "ADVANCED",
|
||||
'WE_LINK_SKIN' => SYS_SKIN,
|
||||
'WE_LINK_LANGUAGE' => SYS_LANG,
|
||||
'WE_LINK_DOMAIN' => $this->domain,
|
||||
'WEE_STATUS' => 'DISABLED',
|
||||
]
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete a webentry
|
||||
* @cover ProcessMaker\BusinessModel\WebEntryEvent::delete
|
||||
* @category HOR-3207:9
|
||||
*/
|
||||
public function testDelete()
|
||||
{
|
||||
$processUid = $this->processUid;
|
||||
$criteria = new \Criteria;
|
||||
$criteria->add(\WebEntryPeer::PRO_UID, $processUid);
|
||||
$entryEvents = $this->object->getWebEntryEvents($processUid);
|
||||
$fistWebEntryUid = $entryEvents[0]['WEE_UID'];
|
||||
$this->assertCount(2, $entryEvents);
|
||||
$this->assertCount(2, \WebEntryPeer::doSelect($criteria));
|
||||
$this->object->delete($entryEvents[0]['WEE_UID']);
|
||||
$entryEvents = $this->object->getWebEntryEvents($processUid);
|
||||
$this->assertCount(1, $entryEvents);
|
||||
$this->assertCount(1, \WebEntryPeer::doSelect($criteria));
|
||||
$this->object->delete($entryEvents[0]['WEE_UID']);
|
||||
$entryEvents = $this->object->getWebEntryEvents($processUid);
|
||||
$this->assertCount(0, $entryEvents);
|
||||
$this->assertCount(0, \WebEntryPeer::doSelect($criteria));
|
||||
$this->expectException(\Exception::class);
|
||||
$this->object->delete($fistWebEntryUid);
|
||||
}
|
||||
|
||||
/**
|
||||
* Create different combinations of WE
|
||||
* @cover ProcessMaker\BusinessModel\WebEntryEvent::create
|
||||
* @category HOR-3207:7
|
||||
*/
|
||||
public function testCreate()
|
||||
{
|
||||
/* @var $webEntry \WebEntry */
|
||||
$processUid = $this->processUid2;
|
||||
$entryEvents = $this->object->getWebEntryEvents($processUid);
|
||||
$this->assertCount(1, $entryEvents);
|
||||
$rows = $this->getCombinationsFor([
|
||||
'WE_LINK_GENERATION' => ['DEFAULT', 'ADVANCED'],
|
||||
'WEE_STATUS' => ['ENABLED', null],
|
||||
'WE_TYPE' => ['MULTIPLE'],
|
||||
'WE_LINK_SKIN' => [SYS_SKIN],
|
||||
'WE_LINK_LANGUAGE' => [SYS_LANG],
|
||||
'WE_LINK_DOMAIN' => ['domain.localhost'],
|
||||
]);
|
||||
$criteria = new \Criteria();
|
||||
$criteria->add(\BpmnEventPeer::PRJ_UID, $processUid);
|
||||
$criteria->add(\BpmnEventPeer::EVN_NAME, 'simple start');
|
||||
$event = \BpmnEventPeer::doSelectOne($criteria);
|
||||
foreach ($rows as $row) {
|
||||
try {
|
||||
$data = [
|
||||
'EVN_UID' => $event->getEvnUid(),
|
||||
'ACT_UID' => $entryEvents[0]['ACT_UID'],
|
||||
'USR_UID' => $this->adminUid,
|
||||
'WEE_TITLE' => $event->getEvnUid(),
|
||||
];
|
||||
foreach ($row as $key => $value) {
|
||||
if (isset($value)) {
|
||||
$data[$key] = $value;
|
||||
}
|
||||
}
|
||||
$this->object->create($processUid, $this->adminUid, $data);
|
||||
$entryEvents2 = $this->object->getWebEntryEvents($processUid);
|
||||
foreach ($entryEvents2 as $entryEvent) {
|
||||
if ($entryEvent['EVN_UID'] === $event->getEvnUid()) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
$webEntry = $this->getWebEntry($entryEvent);
|
||||
$this->assertCount(2, $entryEvents2,
|
||||
'Expected 2 events after create');
|
||||
$this->object->delete($entryEvent['WEE_UID']);
|
||||
foreach ($data as $key => $value) {
|
||||
$this->assertEquals($value, $entryEvent[$key], ">$key<");
|
||||
}
|
||||
} catch (\PHPUnit_Framework_ExpectationFailedException $e) {
|
||||
if (
|
||||
$row['WE_LINK_GENERATION'] === 'DEFAULT' &&
|
||||
preg_match('/>WEE_URL</', $e->getMessage())
|
||||
) {
|
||||
$this->assertEquals(
|
||||
$this->getSimpleWebEntryUrl($webEntry),
|
||||
$entryEvent['WEE_URL'],
|
||||
'Wrong single web entry url (backward compativility)'
|
||||
);
|
||||
} else {
|
||||
throw $e;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a WE with invalid parameters
|
||||
* @cover ProcessMaker\BusinessModel\WebEntryEvent::create
|
||||
* @category HOR-3207:7,HOR-3207:2
|
||||
*/
|
||||
public function testInvalidCreate()
|
||||
{
|
||||
$processUid = $this->processUid2;
|
||||
$entryEvents = $this->object->getWebEntryEvents($processUid);
|
||||
$this->expectException(\Exception::class);
|
||||
$this->expectExceptionMessageRegExp('/(Please enter a valid value for (WE_TYPE|WE_AUTHENTICATION|WE_CALLBACK|WE_LINK_GENERATION)\s*){4,4}/');
|
||||
$this->createWebEntryEvent(
|
||||
$processUid, $entryEvents,
|
||||
[
|
||||
'WEE_URL' => $this->domain."/sys".config("system.workspace")."/".SYS_LANG."/".SYS_SKIN."/".$processUid."/custom.php",
|
||||
'WE_TYPE' => "NOT-VALID-SINGLE",
|
||||
'WE_CUSTOM_TITLE' => $this->customTitle,
|
||||
'WE_AUTHENTICATION' => 'NOT-VALID-ANONYMOUS',
|
||||
'WE_HIDE_INFORMATION_BAR' => "0",
|
||||
'WE_CALLBACK' => "NOT-VALID-PROCESSMAKER",
|
||||
'WE_CALLBACK_URL' => "http://domain.localhost/callback",
|
||||
'WE_LINK_GENERATION' => "NOT-VALID-ADVANCED",
|
||||
'WE_LINK_SKIN' => SYS_SKIN,
|
||||
'WE_LINK_LANGUAGE' => SYS_LANG,
|
||||
'WE_LINK_DOMAIN' => $this->domain,
|
||||
]
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Update different combinations of web entries
|
||||
* @throws \PHPUnit_Framework_ExpectationFailedException
|
||||
* @cover ProcessMaker\BusinessModel\WebEntryEvent::update
|
||||
* @category HOR-3207:8
|
||||
*/
|
||||
public function testUpdate()
|
||||
{
|
||||
$processUid = $this->processUid;
|
||||
$entryEvents = $this->object->getWebEntryEvents($processUid);
|
||||
$entryEvent = $entryEvents[0];
|
||||
$webEntryEventUid = $entryEvent['WEE_UID'];
|
||||
$userUidUpdater = $this->adminUid;
|
||||
|
||||
$criteria = new \Criteria;
|
||||
$criteria->add(\DynaformPeer::PRO_UID, $processUid);
|
||||
$dynaforms = \DynaformPeer::doSelect($criteria);
|
||||
$dynaformIds = [null];
|
||||
foreach ($dynaforms as $dyn) {
|
||||
$dynaformIds[] = $dyn->getDynUid();
|
||||
}
|
||||
|
||||
$rows = $this->getCombinationsFor([
|
||||
'WE_LINK_GENERATION' => ['DEFAULT', 'ADVANCED'],
|
||||
'DYN_UID' => $dynaformIds,
|
||||
'USR_UID' => [null, $this->adminUid, static::SKIP_VALUE],
|
||||
'WE_LINK_SKIN' => [SYS_SKIN],
|
||||
'WE_LINK_LANGUAGE' => [SYS_LANG],
|
||||
'WE_LINK_DOMAIN' => [$this->domain],
|
||||
]);
|
||||
foreach ($rows as $row) {
|
||||
try {
|
||||
$this->object->update($webEntryEventUid, $userUidUpdater, $row);
|
||||
$entryEvent = $this->object->getWebEntryEvent($webEntryEventUid);
|
||||
$webEntry = $this->getWebEntry($entryEvent);
|
||||
foreach ($row as $key => $value) {
|
||||
$this->assertEquals($value, $entryEvent[$key], ">$key<");
|
||||
}
|
||||
} catch (\PHPUnit_Framework_ExpectationFailedException $e) {
|
||||
if (
|
||||
$row['WE_LINK_GENERATION'] === 'DEFAULT' &&
|
||||
preg_match('/>WEE_URL</', $e->getMessage())
|
||||
) {
|
||||
$this->assertEquals(
|
||||
$this->getSimpleWebEntryUrl($webEntry),
|
||||
$entryEvent['WEE_URL'],
|
||||
'Wrong single web entry url (backward compativility)'
|
||||
);
|
||||
} else {
|
||||
throw $e;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Update WE with invalid parameters
|
||||
* @cover ProcessMaker\BusinessModel\WebEntryEvent::update
|
||||
* @category HOR-3207:8,HOR-3207:2
|
||||
*/
|
||||
public function testInvalidUpdate()
|
||||
{
|
||||
$processUid = $this->processUid;
|
||||
$entryEvents = $this->object->getWebEntryEvents($processUid);
|
||||
$entryEvent = $entryEvents[0];
|
||||
$webEntryEventUid = $entryEvent['WEE_UID'];
|
||||
$userUidUpdater = $this->adminUid;
|
||||
|
||||
$this->expectException(\Exception::class);
|
||||
$this->expectExceptionMessageRegExp('/(Please enter a valid value for (WE_TYPE|WE_AUTHENTICATION|WE_CALLBACK|WE_LINK_GENERATION)\s*){4,4}/');
|
||||
$this->object->update(
|
||||
$webEntryEventUid,
|
||||
$userUidUpdater,
|
||||
[
|
||||
'WEE_URL' => $this->domain."/sys".config("system.workspace")."/".SYS_LANG."/".SYS_SKIN."/".$processUid."/custom.php",
|
||||
'WE_TYPE' => "NOT-VALID-SINGLE",
|
||||
'WE_CUSTOM_TITLE' => $this->customTitle,
|
||||
'WE_AUTHENTICATION' => 'NOT-VALID-ANONYMOUS',
|
||||
'WE_HIDE_INFORMATION_BAR' => "0",
|
||||
'WE_CALLBACK' => "NOT-VALID-PROCESSMAKER",
|
||||
'WE_CALLBACK_URL' => "http://domain.localhost/callback",
|
||||
'WE_LINK_GENERATION' => "NOT-VALID-ADVANCED",
|
||||
'WE_LINK_SKIN' => SYS_SKIN,
|
||||
'WE_LINK_LANGUAGE' => SYS_LANG,
|
||||
'WE_LINK_DOMAIN' => $this->domain,
|
||||
]
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Required USR_UID
|
||||
* @cover ProcessMaker\BusinessModel\WebEntryEvent::update
|
||||
* @category HOR-3207:2
|
||||
*/
|
||||
public function testUsrUidNotRequiredIfLoginRequired()
|
||||
{
|
||||
$processUid = $this->processUid2;
|
||||
$entryEvents = $this->object->getWebEntryEvents($processUid);
|
||||
list($webEntry, $entryEvent) = $this->createWebEntryEvent(
|
||||
$processUid, $entryEvents,
|
||||
[
|
||||
'WE_AUTHENTICATION' => 'LOGIN_REQUIRED',
|
||||
'DYN_UID' => $entryEvents[0]['DYN_UID'],
|
||||
'USR_UID' => null,
|
||||
]
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Required fields
|
||||
* @cover ProcessMaker\BusinessModel\WebEntryEvent::create
|
||||
* @category HOR-3207:2
|
||||
*/
|
||||
public function testRequiredFields()
|
||||
{
|
||||
$processUid = $this->processUid2;
|
||||
$entryEvents = $this->object->getWebEntryEvents($processUid);
|
||||
$dynaform = $this->getADynaform($processUid);
|
||||
$criteria = new \Criteria();
|
||||
$criteria->add(\BpmnEventPeer::PRJ_UID, $processUid);
|
||||
$criteria->add(\BpmnEventPeer::EVN_NAME, 'simple start');
|
||||
$event = \BpmnEventPeer::doSelectOne($criteria);
|
||||
//EVN_UID
|
||||
try {
|
||||
$data = [
|
||||
];
|
||||
$this->object->create($processUid, $this->adminUid, $data);
|
||||
} catch (\Exception $e) {
|
||||
$this->assertEquals('ID_INVALID_VALUE_CAN_NOT_BE_EMPTY($arrayData)',
|
||||
$e->getMessage());
|
||||
}
|
||||
//EVN_UID
|
||||
try {
|
||||
$data = [
|
||||
'WE_CUSTOM_TITLE' => $this->customTitle,
|
||||
];
|
||||
$this->object->create($processUid, $this->adminUid, $data);
|
||||
} catch (\Exception $e) {
|
||||
$this->assertEquals('ID_UNDEFINED_VALUE_IS_REQUIRED(EVN_UID)',
|
||||
$e->getMessage());
|
||||
}
|
||||
//ACT_UID
|
||||
try {
|
||||
$data = [
|
||||
'EVN_UID' => $event->getEvnUid(),
|
||||
];
|
||||
$this->object->create($processUid, $this->adminUid, $data);
|
||||
} catch (\Exception $e) {
|
||||
$this->assertEquals('ID_UNDEFINED_VALUE_IS_REQUIRED(ACT_UID)',
|
||||
$e->getMessage());
|
||||
}
|
||||
//DYN_UID
|
||||
try {
|
||||
$data = [
|
||||
'EVN_UID' => $event->getEvnUid(),
|
||||
'ACT_UID' => $entryEvents[0]['ACT_UID'],
|
||||
];
|
||||
$this->object->create($processUid, $this->adminUid, $data);
|
||||
} catch (\Exception $e) {
|
||||
$this->assertEquals('ID_UNDEFINED_VALUE_IS_REQUIRED(DYN_UID)',
|
||||
$e->getMessage());
|
||||
}
|
||||
//USR_UID (WE_AUTHENTICATION=ANONYMOUS)
|
||||
try {
|
||||
$data = [
|
||||
'EVN_UID' => $event->getEvnUid(),
|
||||
'ACT_UID' => $entryEvents[0]['ACT_UID'],
|
||||
'DYN_UID' => $dynaform->getDynUid(),
|
||||
];
|
||||
$this->object->create($processUid, $this->adminUid, $data);
|
||||
} catch (\Exception $e) {
|
||||
$this->assertEquals('ID_UNDEFINED_VALUE_IS_REQUIRED(USR_UID)',
|
||||
$e->getMessage());
|
||||
}
|
||||
//WEE_TITLE
|
||||
try {
|
||||
$data = [
|
||||
'EVN_UID' => $event->getEvnUid(),
|
||||
'ACT_UID' => $entryEvents[0]['ACT_UID'],
|
||||
'DYN_UID' => $dynaform->getDynUid(),
|
||||
'USR_UID' => $this->adminUid,
|
||||
];
|
||||
$this->object->create($processUid, $this->adminUid, $data);
|
||||
} catch (\Exception $e) {
|
||||
$this->assertEquals('ID_INVALID_VALUE_CAN_NOT_BE_EMPTY(WEE_TITLE)',
|
||||
$e->getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests importing a BPMN with WE2 information.
|
||||
* The import maintain the UIDs.
|
||||
*
|
||||
* @cover ProcessMaker\BusinessModel\WebEntryEvent
|
||||
*/
|
||||
public function testImportProcessWithWE2()
|
||||
{
|
||||
$proUid = $this->import(__DIR__.'/WebEntry2-multi-login.pmx');
|
||||
$this->assertNotEmpty($proUid);
|
||||
$taskCriteria = new \Criteria;
|
||||
$taskCriteria->add(\TaskPeer::PRO_UID, $proUid);
|
||||
$taskCriteria->add(\TaskPeer::TAS_UID, "wee-%", \Criteria::LIKE);
|
||||
$task = \TaskPeer::doSelectOne($taskCriteria);
|
||||
//Check steps
|
||||
$criteria = new \Criteria;
|
||||
$criteria->add(\StepPeer::TAS_UID, $task->getTasUid());
|
||||
$criteria->addAscendingOrderByColumn(\StepPeer::STEP_POSITION);
|
||||
$steps = [];
|
||||
$stepWithTrigger = 1;
|
||||
$uidStepWithTrigger = null;
|
||||
foreach (\StepPeer::doSelect($criteria) as $index => $step) {
|
||||
$steps[]=$step->getStepTypeObj();
|
||||
if ($index == $stepWithTrigger) {
|
||||
$uidStepWithTrigger = $step->getStepUid();
|
||||
}
|
||||
}
|
||||
$this->assertEquals(
|
||||
["DYNAFORM", "DYNAFORM", "INPUT_DOCUMENT", "OUTPUT_DOCUMENT"],
|
||||
$steps
|
||||
);
|
||||
//Check triggers
|
||||
$criteriaTri = new \Criteria;
|
||||
$criteriaTri->add(\StepTriggerPeer::TAS_UID, $task->getTasUid());
|
||||
$criteriaTri->add(\StepTriggerPeer::STEP_UID, $uidStepWithTrigger);
|
||||
$criteriaTri->addAscendingOrderByColumn(\StepTriggerPeer::ST_POSITION);
|
||||
$triggers = [];
|
||||
foreach (\StepTriggerPeer::doSelect($criteriaTri) as $stepTri) {
|
||||
$triggers[]=[$stepTri->getStepUid(), $stepTri->getStType()];
|
||||
}
|
||||
$this->assertEquals(
|
||||
[[$uidStepWithTrigger, "BEFORE"]],
|
||||
$triggers
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests importing a BPMN with WE2 information.
|
||||
* The import regenerates the UIDs.
|
||||
*
|
||||
* @cover ProcessMaker\BusinessModel\WebEntryEvent
|
||||
*/
|
||||
public function testImportProcessWithWE2WithRegenUid()
|
||||
{
|
||||
$proUid = $this->import(__DIR__.'/WebEntry2-multi-login.pmx', true);
|
||||
$this->assertNotEmpty($proUid);
|
||||
$taskCriteria = new \Criteria;
|
||||
$taskCriteria->add(\TaskPeer::PRO_UID, $proUid);
|
||||
$taskCriteria->add(\TaskPeer::TAS_UID, "wee-%", \Criteria::LIKE);
|
||||
$task = \TaskPeer::doSelectOne($taskCriteria);
|
||||
//Check steps
|
||||
$criteria = new \Criteria;
|
||||
$criteria->add(\StepPeer::TAS_UID, $task->getTasUid());
|
||||
$criteria->addAscendingOrderByColumn(\StepPeer::STEP_POSITION);
|
||||
$steps = [];
|
||||
$stepWithTrigger = 1;
|
||||
$uidStepWithTrigger = null;
|
||||
foreach (\StepPeer::doSelect($criteria) as $index => $step) {
|
||||
$steps[]=$step->getStepTypeObj();
|
||||
if ($index == $stepWithTrigger) {
|
||||
$uidStepWithTrigger = $step->getStepUid();
|
||||
}
|
||||
}
|
||||
$this->assertEquals(
|
||||
["DYNAFORM", "DYNAFORM", "INPUT_DOCUMENT", "OUTPUT_DOCUMENT"],
|
||||
$steps
|
||||
);
|
||||
//Check triggers
|
||||
$criteriaTri = new \Criteria;
|
||||
$criteriaTri->add(\StepTriggerPeer::TAS_UID, $task->getTasUid());
|
||||
$criteriaTri->add(\StepTriggerPeer::STEP_UID, $uidStepWithTrigger);
|
||||
$criteriaTri->addAscendingOrderByColumn(\StepTriggerPeer::ST_POSITION);
|
||||
$triggers = [];
|
||||
foreach (\StepTriggerPeer::doSelect($criteriaTri) as $stepTri) {
|
||||
$triggers[]=[$stepTri->getStepUid(), $stepTri->getStType()];
|
||||
}
|
||||
$this->assertEquals(
|
||||
[[$uidStepWithTrigger, "BEFORE"]],
|
||||
$triggers
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* @covers ProcessMaker\BusinessModel\WebEntryEvent::generateLink
|
||||
* @category HOR-3210:5
|
||||
*/
|
||||
public function testGenerateLinkSingleDefaultAnonymous()
|
||||
{
|
||||
$processUid = $this->processUid;
|
||||
$entryEvents = $this->object->getWebEntryEvents($processUid);
|
||||
$webEntry = $this->getWebEntry($entryEvents[0]);
|
||||
$link = $this->object->generateLink($processUid, $entryEvents[0]['WEE_UID']);
|
||||
$this->assertEquals($this->getSimpleWebEntryUrl($webEntry), $link);
|
||||
}
|
||||
|
||||
/**
|
||||
* @covers ProcessMaker\BusinessModel\WebEntryEvent::generateLink
|
||||
* @category HOR-3210:5
|
||||
*/
|
||||
public function testGenerateLinkMultipleAnon()
|
||||
{
|
||||
$processUid = $this->processUid2;
|
||||
$entryEvents = $this->object->getWebEntryEvents($processUid);
|
||||
$this->assertCount(1, $entryEvents,
|
||||
'Expected 1 event with web entry in process WebEntry2');
|
||||
$criteria = new \Criteria();
|
||||
$criteria->add(\BpmnEventPeer::PRJ_UID, $processUid);
|
||||
$criteria->add(\BpmnEventPeer::EVN_NAME, 'simple start');
|
||||
$event = \BpmnEventPeer::doSelectOne($criteria);
|
||||
$data = [
|
||||
'EVN_UID' => $event->getEvnUid(),
|
||||
'ACT_UID' => $entryEvents[0]['ACT_UID'],
|
||||
'WE_AUTHENTICATION' => 'ANONYMOUS',
|
||||
'USR_UID' => $this->adminUid,
|
||||
'WE_TYPE' => 'MULTIPLE',
|
||||
'WEE_TITLE' => $event->getEvnUid(),
|
||||
];
|
||||
$this->object->create($processUid, $this->adminUid, $data);
|
||||
$entryEvents2 = $this->object->getWebEntryEvents($processUid);
|
||||
foreach ($entryEvents2 as $entryEvent) {
|
||||
if ($entryEvent['EVN_UID'] === $event->getEvnUid()) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
$webEntry = $this->getWebEntry($entryEvent);
|
||||
$link = $this->object->generateLink($processUid, $entryEvent['WEE_UID']);
|
||||
$this->assertEquals($this->getSimpleWebEntryUrl($webEntry), $link);
|
||||
}
|
||||
|
||||
/**
|
||||
* @covers ProcessMaker\BusinessModel\WebEntryEvent::generateLink
|
||||
* @category HOR-3210:5
|
||||
*/
|
||||
public function testGenerateLinkForMissingWE()
|
||||
{
|
||||
$processUid = $this->processUid;
|
||||
$this->expectException(\Exception::class);
|
||||
$this->expectExceptionMessage('ID_WEB_ENTRY_EVENT_DOES_NOT_EXIST(WEE_UID)');
|
||||
$link = $this->object->generateLink($processUid, 'INVALID-UID');
|
||||
}
|
||||
|
||||
/**
|
||||
* get a dynaform
|
||||
* @return type
|
||||
*/
|
||||
private function getADynaform($processUid = null)
|
||||
{
|
||||
$criteria = new \Criteria;
|
||||
$criteria->add(\DynaformPeer::PRO_UID,
|
||||
$processUid ? $processUid : $this->processUid);
|
||||
return \DynaformPeer::doSelectOne($criteria);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get a WebEntry from a WebEntryEvent array
|
||||
* @param type $webEntryEvent
|
||||
* @return \WebEntry
|
||||
*/
|
||||
private function getWebEntry($webEntryEvent)
|
||||
{
|
||||
$wee = \WebEntryEventPeer::retrieveByPK($webEntryEvent['WEE_UID']);
|
||||
return \WebEntryPeer::retrieveByPK($wee->getWeeWeUid());
|
||||
}
|
||||
|
||||
/**
|
||||
* The default generated WebEntryUrl.
|
||||
*
|
||||
* @param \WebEntry $we
|
||||
* @return type
|
||||
*/
|
||||
private function getSimpleWebEntryUrl(\WebEntry $we)
|
||||
{
|
||||
return (\G::is_https() ? "https://" : "http://").
|
||||
$_SERVER["HTTP_HOST"]."/sys".config("system.workspace")."/".
|
||||
SYS_LANG."/".SYS_SKIN."/".$we->getProUid()."/".$we->getWeData();
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a WebEntryEvent using some default properties.
|
||||
*
|
||||
* @param type $processUid
|
||||
* @param type $entryEvents
|
||||
* @param type $config
|
||||
* @return type
|
||||
*/
|
||||
private function createWebEntryEvent($processUid, $entryEvents, $config)
|
||||
{
|
||||
$this->assertCount(1, $entryEvents,
|
||||
'Expected 1 event with web entry in process WebEntry2');
|
||||
$criteria = new \Criteria();
|
||||
$criteria->add(\BpmnEventPeer::PRJ_UID, $processUid);
|
||||
$criteria->add(\BpmnEventPeer::EVN_NAME, 'simple start');
|
||||
$event = \BpmnEventPeer::doSelectOne($criteria);
|
||||
$data = [
|
||||
'EVN_UID' => $event->getEvnUid(),
|
||||
'ACT_UID' => $entryEvents[0]['ACT_UID'],
|
||||
'WEE_STATUS' => 'ENABLED',
|
||||
'USR_UID' => $this->adminUid,
|
||||
'WEE_TITLE' => $event->getEvnUid(),
|
||||
];
|
||||
foreach ($config as $key => $value) {
|
||||
$data[$key] = $value;
|
||||
}
|
||||
$this->object->create($processUid, $this->adminUid, $data);
|
||||
$entryEvents2 = $this->object->getWebEntryEvents($processUid);
|
||||
foreach ($entryEvents2 as $entryEvent) {
|
||||
if ($entryEvent['EVN_UID'] === $event->getEvnUid()) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
$webEntry = $this->getWebEntry($entryEvent);
|
||||
$this->assertCount(2, $entryEvents2, 'Expected 2 events after create');
|
||||
foreach ($data as $key => $value) {
|
||||
$this->assertEquals($value, $entryEvent[$key], "> $key");
|
||||
}
|
||||
return [$webEntry, $entryEvent];
|
||||
}
|
||||
|
||||
/**
|
||||
* Create combination rows
|
||||
* @param type $combinations
|
||||
* @return array
|
||||
*/
|
||||
private function getCombinationsFor($combinations = [])
|
||||
{
|
||||
$j = 1;
|
||||
foreach ($combinations as $key => $values) {
|
||||
$j*=count($values);
|
||||
}
|
||||
$rows = [];
|
||||
for ($i = 0; $i < $j; $i++) {
|
||||
$row = [];
|
||||
$ii = $i;
|
||||
foreach ($combinations as $key => $values) {
|
||||
$c = count($values);
|
||||
$value = $values[$ii % $c];
|
||||
if (static::SKIP_VALUE !== $value) {
|
||||
$row[$key] = $value;
|
||||
}
|
||||
$ii = floor($ii / $c);
|
||||
}
|
||||
$rows[] = $row;
|
||||
}
|
||||
return $rows;
|
||||
}
|
||||
}
|
||||
@@ -1,802 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<ProcessMaker-Project version="3.0">
|
||||
<metadata>
|
||||
<meta key="vendor_version"><![CDATA[(Branch feature/HOR-3207)]]></meta>
|
||||
<meta key="vendor_version_code">Michelangelo</meta>
|
||||
<meta key="export_timestamp">1495111434</meta>
|
||||
<meta key="export_datetime"><![CDATA[2017-05-18T12:43:54+00:00]]></meta>
|
||||
<meta key="export_server_addr"><![CDATA[127.0.0.1:8080]]></meta>
|
||||
<meta key="export_server_os">Darwin</meta>
|
||||
<meta key="export_server_php_version">50621</meta>
|
||||
<meta key="export_version">1</meta>
|
||||
<meta key="workspace">hor3207a</meta>
|
||||
<meta key="name">WebEntryEvent</meta>
|
||||
<meta key="uid">441299927591d969ff284b7005303758</meta>
|
||||
</metadata>
|
||||
<definition class="BPMN">
|
||||
<table name="ACTIVITY">
|
||||
<record>
|
||||
<act_uid>382310413591d96b6cb34d7077964801</act_uid>
|
||||
<prj_uid>441299927591d969ff284b7005303758</prj_uid>
|
||||
<pro_uid>684563509591d96a01cbab3088210120</pro_uid>
|
||||
<act_name>Task 1</act_name>
|
||||
<act_type>TASK</act_type>
|
||||
<act_is_for_compensation>0</act_is_for_compensation>
|
||||
<act_start_quantity>1</act_start_quantity>
|
||||
<act_completion_quantity>0</act_completion_quantity>
|
||||
<act_task_type>EMPTY</act_task_type>
|
||||
<act_implementation></act_implementation>
|
||||
<act_instantiate>0</act_instantiate>
|
||||
<act_script_type></act_script_type>
|
||||
<act_script></act_script>
|
||||
<act_loop_type>EMPTY</act_loop_type>
|
||||
<act_test_before>0</act_test_before>
|
||||
<act_loop_maximum>0</act_loop_maximum>
|
||||
<act_loop_condition>0</act_loop_condition>
|
||||
<act_loop_cardinality>0</act_loop_cardinality>
|
||||
<act_loop_behavior>0</act_loop_behavior>
|
||||
<act_is_adhoc>0</act_is_adhoc>
|
||||
<act_is_collapsed>0</act_is_collapsed>
|
||||
<act_completion_condition>0</act_completion_condition>
|
||||
<act_ordering>0</act_ordering>
|
||||
<act_cancel_remaining_instances>1</act_cancel_remaining_instances>
|
||||
<act_protocol>0</act_protocol>
|
||||
<act_method>0</act_method>
|
||||
<act_is_global>0</act_is_global>
|
||||
<act_referer>0</act_referer>
|
||||
<act_default_flow>0</act_default_flow>
|
||||
<act_master_diagram>0</act_master_diagram>
|
||||
<bou_uid>635529260591d96b6cbfcb7051450866</bou_uid>
|
||||
<dia_uid>358612266591d96a014d1e6034604444</dia_uid>
|
||||
<element_uid>382310413591d96b6cb34d7077964801</element_uid>
|
||||
<bou_element>891718728591d96a426dd25018705242</bou_element>
|
||||
<bou_element_type>bpmnActivity</bou_element_type>
|
||||
<bou_x>256</bou_x>
|
||||
<bou_y>79</bou_y>
|
||||
<bou_width>150</bou_width>
|
||||
<bou_height>75</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
</table>
|
||||
<table name="ARTIFACT"/>
|
||||
<table name="BOUND">
|
||||
<record>
|
||||
<bou_uid>214544408591d96f0071200088162965</bou_uid>
|
||||
<prj_uid>441299927591d969ff284b7005303758</prj_uid>
|
||||
<dia_uid>358612266591d96a014d1e6034604444</dia_uid>
|
||||
<element_uid>754852677591d96f0066c53097043776</element_uid>
|
||||
<bou_element>891718728591d96a426dd25018705242</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>100</bou_x>
|
||||
<bou_y>213</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<bou_uid>635529260591d96b6cbfcb7051450866</bou_uid>
|
||||
<prj_uid>441299927591d969ff284b7005303758</prj_uid>
|
||||
<dia_uid>358612266591d96a014d1e6034604444</dia_uid>
|
||||
<element_uid>382310413591d96b6cb34d7077964801</element_uid>
|
||||
<bou_element>891718728591d96a426dd25018705242</bou_element>
|
||||
<bou_element_type>bpmnActivity</bou_element_type>
|
||||
<bou_x>256</bou_x>
|
||||
<bou_y>79</bou_y>
|
||||
<bou_width>150</bou_width>
|
||||
<bou_height>75</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<bou_uid>735358742591d96b70622c8075629514</bou_uid>
|
||||
<prj_uid>441299927591d969ff284b7005303758</prj_uid>
|
||||
<dia_uid>358612266591d96a014d1e6034604444</dia_uid>
|
||||
<element_uid>349681056591d96b7059a07092140602</element_uid>
|
||||
<bou_element>891718728591d96a426dd25018705242</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>100</bou_x>
|
||||
<bou_y>100</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<bou_uid>908599339591d96b70910b0020050417</bou_uid>
|
||||
<prj_uid>441299927591d969ff284b7005303758</prj_uid>
|
||||
<dia_uid>358612266591d96a014d1e6034604444</dia_uid>
|
||||
<element_uid>132598392591d96b7084aa6048071487</element_uid>
|
||||
<bou_element>891718728591d96a426dd25018705242</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>545</bou_x>
|
||||
<bou_y>100</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
</table>
|
||||
<table name="DATA"/>
|
||||
<table name="DIAGRAM">
|
||||
<record>
|
||||
<dia_uid>358612266591d96a014d1e6034604444</dia_uid>
|
||||
<prj_uid>441299927591d969ff284b7005303758</prj_uid>
|
||||
<dia_name>WebEntryEvent</dia_name>
|
||||
<dia_is_closable>0</dia_is_closable>
|
||||
</record>
|
||||
</table>
|
||||
<table name="DOCUMENTATION"/>
|
||||
<table name="EVENT">
|
||||
<record>
|
||||
<evn_uid>754852677591d96f0066c53097043776</evn_uid>
|
||||
<prj_uid>441299927591d969ff284b7005303758</prj_uid>
|
||||
<pro_uid>684563509591d96a01cbab3088210120</pro_uid>
|
||||
<evn_name></evn_name>
|
||||
<evn_type>START</evn_type>
|
||||
<evn_marker>EMPTY</evn_marker>
|
||||
<evn_is_interrupting>1</evn_is_interrupting>
|
||||
<evn_attached_to></evn_attached_to>
|
||||
<evn_cancel_activity>0</evn_cancel_activity>
|
||||
<evn_activity_ref></evn_activity_ref>
|
||||
<evn_wait_for_completion>0</evn_wait_for_completion>
|
||||
<evn_error_name></evn_error_name>
|
||||
<evn_error_code></evn_error_code>
|
||||
<evn_escalation_name></evn_escalation_name>
|
||||
<evn_escalation_code></evn_escalation_code>
|
||||
<evn_condition></evn_condition>
|
||||
<evn_message>LEAD</evn_message>
|
||||
<evn_operation_name></evn_operation_name>
|
||||
<evn_operation_implementation_ref></evn_operation_implementation_ref>
|
||||
<evn_time_date></evn_time_date>
|
||||
<evn_time_cycle></evn_time_cycle>
|
||||
<evn_time_duration></evn_time_duration>
|
||||
<evn_behavior>CATCH</evn_behavior>
|
||||
<bou_uid>214544408591d96f0071200088162965</bou_uid>
|
||||
<dia_uid>358612266591d96a014d1e6034604444</dia_uid>
|
||||
<element_uid>754852677591d96f0066c53097043776</element_uid>
|
||||
<bou_element>891718728591d96a426dd25018705242</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>100</bou_x>
|
||||
<bou_y>213</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<evn_uid>349681056591d96b7059a07092140602</evn_uid>
|
||||
<prj_uid>441299927591d969ff284b7005303758</prj_uid>
|
||||
<pro_uid>684563509591d96a01cbab3088210120</pro_uid>
|
||||
<evn_name>first</evn_name>
|
||||
<evn_type>START</evn_type>
|
||||
<evn_marker>EMPTY</evn_marker>
|
||||
<evn_is_interrupting>1</evn_is_interrupting>
|
||||
<evn_attached_to></evn_attached_to>
|
||||
<evn_cancel_activity>0</evn_cancel_activity>
|
||||
<evn_activity_ref></evn_activity_ref>
|
||||
<evn_wait_for_completion>0</evn_wait_for_completion>
|
||||
<evn_error_name></evn_error_name>
|
||||
<evn_error_code></evn_error_code>
|
||||
<evn_escalation_name></evn_escalation_name>
|
||||
<evn_escalation_code></evn_escalation_code>
|
||||
<evn_condition></evn_condition>
|
||||
<evn_message>LEAD</evn_message>
|
||||
<evn_operation_name></evn_operation_name>
|
||||
<evn_operation_implementation_ref></evn_operation_implementation_ref>
|
||||
<evn_time_date></evn_time_date>
|
||||
<evn_time_cycle></evn_time_cycle>
|
||||
<evn_time_duration></evn_time_duration>
|
||||
<evn_behavior>CATCH</evn_behavior>
|
||||
<bou_uid>735358742591d96b70622c8075629514</bou_uid>
|
||||
<dia_uid>358612266591d96a014d1e6034604444</dia_uid>
|
||||
<element_uid>349681056591d96b7059a07092140602</element_uid>
|
||||
<bou_element>891718728591d96a426dd25018705242</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>100</bou_x>
|
||||
<bou_y>100</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<evn_uid>132598392591d96b7084aa6048071487</evn_uid>
|
||||
<prj_uid>441299927591d969ff284b7005303758</prj_uid>
|
||||
<pro_uid>684563509591d96a01cbab3088210120</pro_uid>
|
||||
<evn_name></evn_name>
|
||||
<evn_type>END</evn_type>
|
||||
<evn_marker>EMPTY</evn_marker>
|
||||
<evn_is_interrupting>1</evn_is_interrupting>
|
||||
<evn_attached_to></evn_attached_to>
|
||||
<evn_cancel_activity>0</evn_cancel_activity>
|
||||
<evn_activity_ref></evn_activity_ref>
|
||||
<evn_wait_for_completion>0</evn_wait_for_completion>
|
||||
<evn_error_name></evn_error_name>
|
||||
<evn_error_code></evn_error_code>
|
||||
<evn_escalation_name></evn_escalation_name>
|
||||
<evn_escalation_code></evn_escalation_code>
|
||||
<evn_condition></evn_condition>
|
||||
<evn_message></evn_message>
|
||||
<evn_operation_name></evn_operation_name>
|
||||
<evn_operation_implementation_ref></evn_operation_implementation_ref>
|
||||
<evn_time_date></evn_time_date>
|
||||
<evn_time_cycle></evn_time_cycle>
|
||||
<evn_time_duration></evn_time_duration>
|
||||
<evn_behavior>THROW</evn_behavior>
|
||||
<bou_uid>908599339591d96b70910b0020050417</bou_uid>
|
||||
<dia_uid>358612266591d96a014d1e6034604444</dia_uid>
|
||||
<element_uid>132598392591d96b7084aa6048071487</element_uid>
|
||||
<bou_element>891718728591d96a426dd25018705242</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>545</bou_x>
|
||||
<bou_y>100</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
</table>
|
||||
<table name="EXTENSION"/>
|
||||
<table name="FLOW">
|
||||
<record>
|
||||
<flo_uid>714921265591d96f01e21a0012216876</flo_uid>
|
||||
<prj_uid>441299927591d969ff284b7005303758</prj_uid>
|
||||
<dia_uid>358612266591d96a014d1e6034604444</dia_uid>
|
||||
<flo_type>SEQUENCE</flo_type>
|
||||
<flo_name> </flo_name>
|
||||
<flo_element_origin>754852677591d96f0066c53097043776</flo_element_origin>
|
||||
<flo_element_origin_type>bpmnEvent</flo_element_origin_type>
|
||||
<flo_element_origin_port>0</flo_element_origin_port>
|
||||
<flo_element_dest>382310413591d96b6cb34d7077964801</flo_element_dest>
|
||||
<flo_element_dest_type>bpmnActivity</flo_element_dest_type>
|
||||
<flo_element_dest_port>0</flo_element_dest_port>
|
||||
<flo_is_inmediate>1</flo_is_inmediate>
|
||||
<flo_condition></flo_condition>
|
||||
<flo_x1>133</flo_x1>
|
||||
<flo_y1>230</flo_y1>
|
||||
<flo_x2>332</flo_x2>
|
||||
<flo_y2>154</flo_y2>
|
||||
<flo_state><![CDATA[[{"x":133,"y":230},{"x":332,"y":230},{"x":332,"y":154}]]]></flo_state>
|
||||
<flo_position>1</flo_position>
|
||||
</record>
|
||||
<record>
|
||||
<flo_uid>755827041591d96b7215314058494878</flo_uid>
|
||||
<prj_uid>441299927591d969ff284b7005303758</prj_uid>
|
||||
<dia_uid>358612266591d96a014d1e6034604444</dia_uid>
|
||||
<flo_type>SEQUENCE</flo_type>
|
||||
<flo_name> </flo_name>
|
||||
<flo_element_origin>349681056591d96b7059a07092140602</flo_element_origin>
|
||||
<flo_element_origin_type>bpmnEvent</flo_element_origin_type>
|
||||
<flo_element_origin_port>0</flo_element_origin_port>
|
||||
<flo_element_dest>382310413591d96b6cb34d7077964801</flo_element_dest>
|
||||
<flo_element_dest_type>bpmnActivity</flo_element_dest_type>
|
||||
<flo_element_dest_port>0</flo_element_dest_port>
|
||||
<flo_is_inmediate>1</flo_is_inmediate>
|
||||
<flo_condition></flo_condition>
|
||||
<flo_x1>133</flo_x1>
|
||||
<flo_y1>117</flo_y1>
|
||||
<flo_x2>256</flo_x2>
|
||||
<flo_y2>117</flo_y2>
|
||||
<flo_state><![CDATA[[{"x":133,"y":117},{"x":256,"y":117}]]]></flo_state>
|
||||
<flo_position>1</flo_position>
|
||||
</record>
|
||||
<record>
|
||||
<flo_uid>957678631591d96b7217c76024693278</flo_uid>
|
||||
<prj_uid>441299927591d969ff284b7005303758</prj_uid>
|
||||
<dia_uid>358612266591d96a014d1e6034604444</dia_uid>
|
||||
<flo_type>SEQUENCE</flo_type>
|
||||
<flo_name> </flo_name>
|
||||
<flo_element_origin>382310413591d96b6cb34d7077964801</flo_element_origin>
|
||||
<flo_element_origin_type>bpmnActivity</flo_element_origin_type>
|
||||
<flo_element_origin_port>0</flo_element_origin_port>
|
||||
<flo_element_dest>132598392591d96b7084aa6048071487</flo_element_dest>
|
||||
<flo_element_dest_type>bpmnEvent</flo_element_dest_type>
|
||||
<flo_element_dest_port>0</flo_element_dest_port>
|
||||
<flo_is_inmediate>1</flo_is_inmediate>
|
||||
<flo_condition></flo_condition>
|
||||
<flo_x1>407</flo_x1>
|
||||
<flo_y1>117</flo_y1>
|
||||
<flo_x2>545</flo_x2>
|
||||
<flo_y2>117</flo_y2>
|
||||
<flo_state><![CDATA[[{"x":407,"y":117},{"x":545,"y":117}]]]></flo_state>
|
||||
<flo_position>1</flo_position>
|
||||
</record>
|
||||
</table>
|
||||
<table name="GATEWAY"/>
|
||||
<table name="LANE"/>
|
||||
<table name="LANESET"/>
|
||||
<table name="PARTICIPANT"/>
|
||||
<table name="PROCESS">
|
||||
<record>
|
||||
<pro_uid>684563509591d96a01cbab3088210120</pro_uid>
|
||||
<prj_uid>441299927591d969ff284b7005303758</prj_uid>
|
||||
<dia_uid>358612266591d96a014d1e6034604444</dia_uid>
|
||||
<pro_name>WebEntryEvent</pro_name>
|
||||
<pro_type>NONE</pro_type>
|
||||
<pro_is_executable>0</pro_is_executable>
|
||||
<pro_is_closed>0</pro_is_closed>
|
||||
<pro_is_subprocess>0</pro_is_subprocess>
|
||||
</record>
|
||||
</table>
|
||||
<table name="PROJECT">
|
||||
<record>
|
||||
<prj_uid>441299927591d969ff284b7005303758</prj_uid>
|
||||
<prj_name>WebEntryEvent</prj_name>
|
||||
<prj_description></prj_description>
|
||||
<prj_target_namespace></prj_target_namespace>
|
||||
<prj_expresion_language></prj_expresion_language>
|
||||
<prj_type_language></prj_type_language>
|
||||
<prj_exporter></prj_exporter>
|
||||
<prj_exporter_version></prj_exporter_version>
|
||||
<prj_create_date><![CDATA[2017-05-18 12:42:08]]></prj_create_date>
|
||||
<prj_update_date><![CDATA[2017-05-18 12:43:27]]></prj_update_date>
|
||||
<prj_author>00000000000000000000000000000001</prj_author>
|
||||
<prj_author_version></prj_author_version>
|
||||
<prj_original_source></prj_original_source>
|
||||
</record>
|
||||
</table>
|
||||
</definition>
|
||||
<definition class="workflow">
|
||||
<table name="process">
|
||||
<record>
|
||||
<pro_uid>441299927591d969ff284b7005303758</pro_uid>
|
||||
<pro_title>WebEntryEvent</pro_title>
|
||||
<pro_description></pro_description>
|
||||
<pro_parent>441299927591d969ff284b7005303758</pro_parent>
|
||||
<pro_time>1</pro_time>
|
||||
<pro_timeunit>DAYS</pro_timeunit>
|
||||
<pro_status>ACTIVE</pro_status>
|
||||
<pro_type_day></pro_type_day>
|
||||
<pro_type>NORMAL</pro_type>
|
||||
<pro_assignment>FALSE</pro_assignment>
|
||||
<pro_show_map>0</pro_show_map>
|
||||
<pro_show_message>0</pro_show_message>
|
||||
<pro_subprocess>0</pro_subprocess>
|
||||
<pro_tri_create></pro_tri_create>
|
||||
<pro_tri_open></pro_tri_open>
|
||||
<pro_tri_deleted></pro_tri_deleted>
|
||||
<pro_tri_canceled></pro_tri_canceled>
|
||||
<pro_tri_paused></pro_tri_paused>
|
||||
<pro_tri_reassigned></pro_tri_reassigned>
|
||||
<pro_tri_unpaused></pro_tri_unpaused>
|
||||
<pro_type_process>PUBLIC</pro_type_process>
|
||||
<pro_show_delegate>0</pro_show_delegate>
|
||||
<pro_show_dynaform>0</pro_show_dynaform>
|
||||
<pro_category></pro_category>
|
||||
<pro_sub_category></pro_sub_category>
|
||||
<pro_industry>0</pro_industry>
|
||||
<pro_update_date><![CDATA[2017-05-18 12:43:27]]></pro_update_date>
|
||||
<pro_create_date><![CDATA[2017-05-18 12:42:08]]></pro_create_date>
|
||||
<pro_create_user>00000000000000000000000000000001</pro_create_user>
|
||||
<pro_height>5000</pro_height>
|
||||
<pro_width>10000</pro_width>
|
||||
<pro_title_x>0</pro_title_x>
|
||||
<pro_title_y>0</pro_title_y>
|
||||
<pro_debug>0</pro_debug>
|
||||
<pro_dynaforms></pro_dynaforms>
|
||||
<pro_derivation_screen_tpl></pro_derivation_screen_tpl>
|
||||
<pro_cost>0</pro_cost>
|
||||
<pro_unit_cost></pro_unit_cost>
|
||||
<pro_itee>1</pro_itee>
|
||||
<pro_action_done><![CDATA[a:1:{i:0;s:41:"GATEWAYTOGATEWAY_DELETE_CORRUPTED_RECORDS";}]]></pro_action_done>
|
||||
<pro_category_label>No Category</pro_category_label>
|
||||
<pro_bpmn>1</pro_bpmn>
|
||||
</record>
|
||||
</table>
|
||||
<table name="tasks">
|
||||
<record>
|
||||
<pro_uid>441299927591d969ff284b7005303758</pro_uid>
|
||||
<tas_uid>382310413591d96b6cb34d7077964801</tas_uid>
|
||||
<tas_title>Task 1</tas_title>
|
||||
<tas_description></tas_description>
|
||||
<tas_def_title></tas_def_title>
|
||||
<tas_def_subject_message></tas_def_subject_message>
|
||||
<tas_def_proc_code></tas_def_proc_code>
|
||||
<tas_def_message></tas_def_message>
|
||||
<tas_def_description></tas_def_description>
|
||||
<tas_type>NORMAL</tas_type>
|
||||
<tas_duration>1</tas_duration>
|
||||
<tas_delay_type></tas_delay_type>
|
||||
<tas_temporizer>0</tas_temporizer>
|
||||
<tas_type_day></tas_type_day>
|
||||
<tas_timeunit>DAYS</tas_timeunit>
|
||||
<tas_alert>FALSE</tas_alert>
|
||||
<tas_priority_variable></tas_priority_variable>
|
||||
<tas_assign_type>BALANCED</tas_assign_type>
|
||||
<tas_assign_variable><![CDATA[@@SYS_NEXT_USER_TO_BE_ASSIGNED]]></tas_assign_variable>
|
||||
<tas_group_variable></tas_group_variable>
|
||||
<tas_mi_instance_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCE]]></tas_mi_instance_variable>
|
||||
<tas_mi_complete_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCES_COMPLETE]]></tas_mi_complete_variable>
|
||||
<tas_assign_location>FALSE</tas_assign_location>
|
||||
<tas_assign_location_adhoc>FALSE</tas_assign_location_adhoc>
|
||||
<tas_transfer_fly>FALSE</tas_transfer_fly>
|
||||
<tas_last_assigned>0</tas_last_assigned>
|
||||
<tas_user>0</tas_user>
|
||||
<tas_can_upload>FALSE</tas_can_upload>
|
||||
<tas_view_upload>FALSE</tas_view_upload>
|
||||
<tas_view_additional_documentation>FALSE</tas_view_additional_documentation>
|
||||
<tas_can_cancel>FALSE</tas_can_cancel>
|
||||
<tas_owner_app>FALSE</tas_owner_app>
|
||||
<stg_uid></stg_uid>
|
||||
<tas_can_pause>FALSE</tas_can_pause>
|
||||
<tas_can_send_message>TRUE</tas_can_send_message>
|
||||
<tas_can_delete_docs>FALSE</tas_can_delete_docs>
|
||||
<tas_self_service>FALSE</tas_self_service>
|
||||
<tas_start>TRUE</tas_start>
|
||||
<tas_to_last_user>FALSE</tas_to_last_user>
|
||||
<tas_send_last_email>FALSE</tas_send_last_email>
|
||||
<tas_derivation>NORMAL</tas_derivation>
|
||||
<tas_posx>256</tas_posx>
|
||||
<tas_posy>79</tas_posy>
|
||||
<tas_width>110</tas_width>
|
||||
<tas_height>60</tas_height>
|
||||
<tas_color></tas_color>
|
||||
<tas_evn_uid></tas_evn_uid>
|
||||
<tas_boundary></tas_boundary>
|
||||
<tas_derivation_screen_tpl></tas_derivation_screen_tpl>
|
||||
<tas_selfservice_timeout>0</tas_selfservice_timeout>
|
||||
<tas_selfservice_time>0</tas_selfservice_time>
|
||||
<tas_selfservice_time_unit></tas_selfservice_time_unit>
|
||||
<tas_selfservice_trigger_uid></tas_selfservice_trigger_uid>
|
||||
<tas_selfservice_execution>EVERY_TIME</tas_selfservice_execution>
|
||||
<tas_not_email_from_format>0</tas_not_email_from_format>
|
||||
<tas_offline>FALSE</tas_offline>
|
||||
<tas_email_server_uid></tas_email_server_uid>
|
||||
<tas_auto_root>FALSE</tas_auto_root>
|
||||
<tas_receive_server_uid></tas_receive_server_uid>
|
||||
<tas_receive_last_email>FALSE</tas_receive_last_email>
|
||||
<tas_receive_email_from_format>0</tas_receive_email_from_format>
|
||||
<tas_receive_message_type>text</tas_receive_message_type>
|
||||
<tas_receive_message_template>alert_message.html</tas_receive_message_template>
|
||||
<tas_receive_subject_message></tas_receive_subject_message>
|
||||
<tas_receive_message></tas_receive_message>
|
||||
<tas_average></tas_average>
|
||||
<tas_sdv></tas_sdv>
|
||||
</record>
|
||||
<record>
|
||||
<pro_uid>441299927591d969ff284b7005303758</pro_uid>
|
||||
<tas_uid>wee-54929591d96cebdc838076843684</tas_uid>
|
||||
<tas_title>WEBENTRYEVENT</tas_title>
|
||||
<tas_description></tas_description>
|
||||
<tas_def_title></tas_def_title>
|
||||
<tas_def_subject_message></tas_def_subject_message>
|
||||
<tas_def_proc_code></tas_def_proc_code>
|
||||
<tas_def_message></tas_def_message>
|
||||
<tas_def_description></tas_def_description>
|
||||
<tas_type>WEBENTRYEVENT</tas_type>
|
||||
<tas_duration>1</tas_duration>
|
||||
<tas_delay_type></tas_delay_type>
|
||||
<tas_temporizer>0</tas_temporizer>
|
||||
<tas_type_day></tas_type_day>
|
||||
<tas_timeunit>DAYS</tas_timeunit>
|
||||
<tas_alert>FALSE</tas_alert>
|
||||
<tas_priority_variable></tas_priority_variable>
|
||||
<tas_assign_type>BALANCED</tas_assign_type>
|
||||
<tas_assign_variable><![CDATA[@@SYS_NEXT_USER_TO_BE_ASSIGNED]]></tas_assign_variable>
|
||||
<tas_group_variable></tas_group_variable>
|
||||
<tas_mi_instance_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCE]]></tas_mi_instance_variable>
|
||||
<tas_mi_complete_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCES_COMPLETE]]></tas_mi_complete_variable>
|
||||
<tas_assign_location>FALSE</tas_assign_location>
|
||||
<tas_assign_location_adhoc>FALSE</tas_assign_location_adhoc>
|
||||
<tas_transfer_fly>FALSE</tas_transfer_fly>
|
||||
<tas_last_assigned>0</tas_last_assigned>
|
||||
<tas_user>0</tas_user>
|
||||
<tas_can_upload>FALSE</tas_can_upload>
|
||||
<tas_view_upload>FALSE</tas_view_upload>
|
||||
<tas_view_additional_documentation>FALSE</tas_view_additional_documentation>
|
||||
<tas_can_cancel>FALSE</tas_can_cancel>
|
||||
<tas_owner_app>FALSE</tas_owner_app>
|
||||
<stg_uid></stg_uid>
|
||||
<tas_can_pause>FALSE</tas_can_pause>
|
||||
<tas_can_send_message>TRUE</tas_can_send_message>
|
||||
<tas_can_delete_docs>FALSE</tas_can_delete_docs>
|
||||
<tas_self_service>FALSE</tas_self_service>
|
||||
<tas_start>TRUE</tas_start>
|
||||
<tas_to_last_user>FALSE</tas_to_last_user>
|
||||
<tas_send_last_email>FALSE</tas_send_last_email>
|
||||
<tas_derivation>NORMAL</tas_derivation>
|
||||
<tas_posx>100</tas_posx>
|
||||
<tas_posy>100</tas_posy>
|
||||
<tas_width>110</tas_width>
|
||||
<tas_height>60</tas_height>
|
||||
<tas_color></tas_color>
|
||||
<tas_evn_uid></tas_evn_uid>
|
||||
<tas_boundary></tas_boundary>
|
||||
<tas_derivation_screen_tpl></tas_derivation_screen_tpl>
|
||||
<tas_selfservice_timeout>0</tas_selfservice_timeout>
|
||||
<tas_selfservice_time>0</tas_selfservice_time>
|
||||
<tas_selfservice_time_unit></tas_selfservice_time_unit>
|
||||
<tas_selfservice_trigger_uid></tas_selfservice_trigger_uid>
|
||||
<tas_selfservice_execution>EVERY_TIME</tas_selfservice_execution>
|
||||
<tas_not_email_from_format>0</tas_not_email_from_format>
|
||||
<tas_offline>FALSE</tas_offline>
|
||||
<tas_email_server_uid></tas_email_server_uid>
|
||||
<tas_auto_root>FALSE</tas_auto_root>
|
||||
<tas_receive_server_uid></tas_receive_server_uid>
|
||||
<tas_receive_last_email>FALSE</tas_receive_last_email>
|
||||
<tas_receive_email_from_format>0</tas_receive_email_from_format>
|
||||
<tas_receive_message_type>text</tas_receive_message_type>
|
||||
<tas_receive_message_template>alert_message.html</tas_receive_message_template>
|
||||
<tas_receive_subject_message></tas_receive_subject_message>
|
||||
<tas_receive_message></tas_receive_message>
|
||||
<tas_average></tas_average>
|
||||
<tas_sdv></tas_sdv>
|
||||
</record>
|
||||
<record>
|
||||
<pro_uid>441299927591d969ff284b7005303758</pro_uid>
|
||||
<tas_uid>wee-64523591d96fc408bb5096940569</tas_uid>
|
||||
<tas_title>WEBENTRYEVENT</tas_title>
|
||||
<tas_description></tas_description>
|
||||
<tas_def_title></tas_def_title>
|
||||
<tas_def_subject_message></tas_def_subject_message>
|
||||
<tas_def_proc_code></tas_def_proc_code>
|
||||
<tas_def_message></tas_def_message>
|
||||
<tas_def_description></tas_def_description>
|
||||
<tas_type>WEBENTRYEVENT</tas_type>
|
||||
<tas_duration>1</tas_duration>
|
||||
<tas_delay_type></tas_delay_type>
|
||||
<tas_temporizer>0</tas_temporizer>
|
||||
<tas_type_day></tas_type_day>
|
||||
<tas_timeunit>DAYS</tas_timeunit>
|
||||
<tas_alert>FALSE</tas_alert>
|
||||
<tas_priority_variable></tas_priority_variable>
|
||||
<tas_assign_type>BALANCED</tas_assign_type>
|
||||
<tas_assign_variable><![CDATA[@@SYS_NEXT_USER_TO_BE_ASSIGNED]]></tas_assign_variable>
|
||||
<tas_group_variable></tas_group_variable>
|
||||
<tas_mi_instance_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCE]]></tas_mi_instance_variable>
|
||||
<tas_mi_complete_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCES_COMPLETE]]></tas_mi_complete_variable>
|
||||
<tas_assign_location>FALSE</tas_assign_location>
|
||||
<tas_assign_location_adhoc>FALSE</tas_assign_location_adhoc>
|
||||
<tas_transfer_fly>FALSE</tas_transfer_fly>
|
||||
<tas_last_assigned>0</tas_last_assigned>
|
||||
<tas_user>0</tas_user>
|
||||
<tas_can_upload>FALSE</tas_can_upload>
|
||||
<tas_view_upload>FALSE</tas_view_upload>
|
||||
<tas_view_additional_documentation>FALSE</tas_view_additional_documentation>
|
||||
<tas_can_cancel>FALSE</tas_can_cancel>
|
||||
<tas_owner_app>FALSE</tas_owner_app>
|
||||
<stg_uid></stg_uid>
|
||||
<tas_can_pause>FALSE</tas_can_pause>
|
||||
<tas_can_send_message>TRUE</tas_can_send_message>
|
||||
<tas_can_delete_docs>FALSE</tas_can_delete_docs>
|
||||
<tas_self_service>FALSE</tas_self_service>
|
||||
<tas_start>TRUE</tas_start>
|
||||
<tas_to_last_user>FALSE</tas_to_last_user>
|
||||
<tas_send_last_email>FALSE</tas_send_last_email>
|
||||
<tas_derivation>NORMAL</tas_derivation>
|
||||
<tas_posx>100</tas_posx>
|
||||
<tas_posy>213</tas_posy>
|
||||
<tas_width>110</tas_width>
|
||||
<tas_height>60</tas_height>
|
||||
<tas_color></tas_color>
|
||||
<tas_evn_uid></tas_evn_uid>
|
||||
<tas_boundary></tas_boundary>
|
||||
<tas_derivation_screen_tpl></tas_derivation_screen_tpl>
|
||||
<tas_selfservice_timeout>0</tas_selfservice_timeout>
|
||||
<tas_selfservice_time>0</tas_selfservice_time>
|
||||
<tas_selfservice_time_unit></tas_selfservice_time_unit>
|
||||
<tas_selfservice_trigger_uid></tas_selfservice_trigger_uid>
|
||||
<tas_selfservice_execution>EVERY_TIME</tas_selfservice_execution>
|
||||
<tas_not_email_from_format>0</tas_not_email_from_format>
|
||||
<tas_offline>FALSE</tas_offline>
|
||||
<tas_email_server_uid></tas_email_server_uid>
|
||||
<tas_auto_root>FALSE</tas_auto_root>
|
||||
<tas_receive_server_uid></tas_receive_server_uid>
|
||||
<tas_receive_last_email>FALSE</tas_receive_last_email>
|
||||
<tas_receive_email_from_format>0</tas_receive_email_from_format>
|
||||
<tas_receive_message_type>text</tas_receive_message_type>
|
||||
<tas_receive_message_template>alert_message.html</tas_receive_message_template>
|
||||
<tas_receive_subject_message></tas_receive_subject_message>
|
||||
<tas_receive_message></tas_receive_message>
|
||||
<tas_average></tas_average>
|
||||
<tas_sdv></tas_sdv>
|
||||
</record>
|
||||
</table>
|
||||
<table name="routes">
|
||||
<record>
|
||||
<rou_uid>184293535591d96f02bc533028984423</rou_uid>
|
||||
<rou_parent>0</rou_parent>
|
||||
<pro_uid>441299927591d969ff284b7005303758</pro_uid>
|
||||
<tas_uid>382310413591d96b6cb34d7077964801</tas_uid>
|
||||
<rou_next_task>-1</rou_next_task>
|
||||
<rou_case>1</rou_case>
|
||||
<rou_type>SEQUENTIAL</rou_type>
|
||||
<rou_default>0</rou_default>
|
||||
<rou_condition></rou_condition>
|
||||
<rou_to_last_user>FALSE</rou_to_last_user>
|
||||
<rou_optional>FALSE</rou_optional>
|
||||
<rou_send_email>TRUE</rou_send_email>
|
||||
<rou_sourceanchor>1</rou_sourceanchor>
|
||||
<rou_targetanchor>0</rou_targetanchor>
|
||||
<rou_to_port>1</rou_to_port>
|
||||
<rou_from_port>2</rou_from_port>
|
||||
<rou_evn_uid></rou_evn_uid>
|
||||
<gat_uid></gat_uid>
|
||||
</record>
|
||||
<record>
|
||||
<rou_uid>674628874591d96fc547a04006969081</rou_uid>
|
||||
<rou_parent>0</rou_parent>
|
||||
<pro_uid>441299927591d969ff284b7005303758</pro_uid>
|
||||
<tas_uid>wee-64523591d96fc408bb5096940569</tas_uid>
|
||||
<rou_next_task>382310413591d96b6cb34d7077964801</rou_next_task>
|
||||
<rou_case>1</rou_case>
|
||||
<rou_type>SEQUENTIAL</rou_type>
|
||||
<rou_default>0</rou_default>
|
||||
<rou_condition></rou_condition>
|
||||
<rou_to_last_user>FALSE</rou_to_last_user>
|
||||
<rou_optional>FALSE</rou_optional>
|
||||
<rou_send_email>TRUE</rou_send_email>
|
||||
<rou_sourceanchor>1</rou_sourceanchor>
|
||||
<rou_targetanchor>0</rou_targetanchor>
|
||||
<rou_to_port>1</rou_to_port>
|
||||
<rou_from_port>2</rou_from_port>
|
||||
<rou_evn_uid></rou_evn_uid>
|
||||
<gat_uid></gat_uid>
|
||||
</record>
|
||||
<record>
|
||||
<rou_uid>777329623591d96f04965b8071665220</rou_uid>
|
||||
<rou_parent>0</rou_parent>
|
||||
<pro_uid>441299927591d969ff284b7005303758</pro_uid>
|
||||
<tas_uid>wee-54929591d96cebdc838076843684</tas_uid>
|
||||
<rou_next_task>382310413591d96b6cb34d7077964801</rou_next_task>
|
||||
<rou_case>1</rou_case>
|
||||
<rou_type>SEQUENTIAL</rou_type>
|
||||
<rou_default>0</rou_default>
|
||||
<rou_condition></rou_condition>
|
||||
<rou_to_last_user>FALSE</rou_to_last_user>
|
||||
<rou_optional>FALSE</rou_optional>
|
||||
<rou_send_email>TRUE</rou_send_email>
|
||||
<rou_sourceanchor>1</rou_sourceanchor>
|
||||
<rou_targetanchor>0</rou_targetanchor>
|
||||
<rou_to_port>1</rou_to_port>
|
||||
<rou_from_port>2</rou_from_port>
|
||||
<rou_evn_uid></rou_evn_uid>
|
||||
<gat_uid></gat_uid>
|
||||
</record>
|
||||
</table>
|
||||
<table name="lanes"/>
|
||||
<table name="gateways"/>
|
||||
<table name="inputs"/>
|
||||
<table name="outputs"/>
|
||||
<table name="dynaforms">
|
||||
<record>
|
||||
<dyn_uid>361249164591d96e6edcb81084086222</dyn_uid>
|
||||
<dyn_title>Form2</dyn_title>
|
||||
<dyn_description></dyn_description>
|
||||
<pro_uid>441299927591d969ff284b7005303758</pro_uid>
|
||||
<dyn_type>xmlform</dyn_type>
|
||||
<dyn_filename><![CDATA[441299927591d969ff284b7005303758/361249164591d96e6edcb81084086222]]></dyn_filename>
|
||||
<dyn_content><![CDATA[{"name":"Form2","description":"","items":[{"type":"form","variable":"","var_uid":"","dataType":"","id":"361249164591d96e6edcb81084086222","name":"Form2","description":"","mode":"edit","script":"","language":"en","externalLibs":"","printable":false,"items":[],"variables":[]}]}]]></dyn_content>
|
||||
<dyn_label></dyn_label>
|
||||
<dyn_version>2</dyn_version>
|
||||
<dyn_update_date><![CDATA[2017-05-18 12:43:18]]></dyn_update_date>
|
||||
</record>
|
||||
<record>
|
||||
<dyn_uid>839383145591d96c1331811037017265</dyn_uid>
|
||||
<dyn_title>Form1</dyn_title>
|
||||
<dyn_description></dyn_description>
|
||||
<pro_uid>441299927591d969ff284b7005303758</pro_uid>
|
||||
<dyn_type>xmlform</dyn_type>
|
||||
<dyn_filename><![CDATA[441299927591d969ff284b7005303758/839383145591d96c1331811037017265]]></dyn_filename>
|
||||
<dyn_content><![CDATA[{"name":"Form1","description":"","items":[{"type":"form","variable":"","var_uid":"","dataType":"","id":"839383145591d96c1331811037017265","name":"Form1","description":"","mode":"edit","script":"","language":"en","externalLibs":"","printable":false,"items":[],"variables":[]}]}]]></dyn_content>
|
||||
<dyn_label></dyn_label>
|
||||
<dyn_version>2</dyn_version>
|
||||
<dyn_update_date><![CDATA[2017-05-18 12:42:41]]></dyn_update_date>
|
||||
</record>
|
||||
</table>
|
||||
<table name="steps">
|
||||
<record>
|
||||
<step_uid>184891718591d96fc460179075100311</step_uid>
|
||||
<pro_uid>441299927591d969ff284b7005303758</pro_uid>
|
||||
<tas_uid>wee-64523591d96fc408bb5096940569</tas_uid>
|
||||
<step_type_obj>DYNAFORM</step_type_obj>
|
||||
<step_uid_obj>361249164591d96e6edcb81084086222</step_uid_obj>
|
||||
<step_condition></step_condition>
|
||||
<step_position>1</step_position>
|
||||
<step_mode>EDIT</step_mode>
|
||||
</record>
|
||||
<record>
|
||||
<step_uid>593687534591d96ceca0ba3047943309</step_uid>
|
||||
<pro_uid>441299927591d969ff284b7005303758</pro_uid>
|
||||
<tas_uid>wee-54929591d96cebdc838076843684</tas_uid>
|
||||
<step_type_obj>DYNAFORM</step_type_obj>
|
||||
<step_uid_obj>839383145591d96c1331811037017265</step_uid_obj>
|
||||
<step_condition></step_condition>
|
||||
<step_position>1</step_position>
|
||||
<step_mode>EDIT</step_mode>
|
||||
</record>
|
||||
</table>
|
||||
<table name="triggers"/>
|
||||
<table name="taskusers"/>
|
||||
<table name="groupwfs"/>
|
||||
<table name="steptriggers"/>
|
||||
<table name="dbconnections"/>
|
||||
<table name="reportTables"/>
|
||||
<table name="reportTablesVars"/>
|
||||
<table name="stepSupervisor"/>
|
||||
<table name="objectPermissions"/>
|
||||
<table name="subProcess"/>
|
||||
<table name="caseTracker"/>
|
||||
<table name="caseTrackerObject"/>
|
||||
<table name="stage"/>
|
||||
<table name="fieldCondition"/>
|
||||
<table name="event"/>
|
||||
<table name="caseScheduler"/>
|
||||
<table name="processCategory"/>
|
||||
<table name="taskExtraProperties"/>
|
||||
<table name="processUser"/>
|
||||
<table name="processVariables"/>
|
||||
<table name="webEntry"/>
|
||||
<table name="webEntryEvent">
|
||||
<record>
|
||||
<wee_uid>738419055591d96cf2b41c2097553491</wee_uid>
|
||||
<prj_uid>441299927591d969ff284b7005303758</prj_uid>
|
||||
<evn_uid>349681056591d96b7059a07092140602</evn_uid>
|
||||
<act_uid>382310413591d96b6cb34d7077964801</act_uid>
|
||||
<dyn_uid>839383145591d96c1331811037017265</dyn_uid>
|
||||
<usr_uid>00000000000000000000000000000001</usr_uid>
|
||||
<wee_title>349681056591d96b7059a07092140602</wee_title>
|
||||
<wee_description></wee_description>
|
||||
<wee_status>ENABLED</wee_status>
|
||||
<wee_we_uid>601692046591d96cf02f3c6044834198</wee_we_uid>
|
||||
<wee_we_tas_uid>wee-54929591d96cebdc838076843684</wee_we_tas_uid>
|
||||
<wee_we_url>349681056591d96b7059a07092140602.php</wee_we_url>
|
||||
</record>
|
||||
<record>
|
||||
<wee_uid>994230525591d96fc6eb5c3089474099</wee_uid>
|
||||
<prj_uid>441299927591d969ff284b7005303758</prj_uid>
|
||||
<evn_uid>754852677591d96f0066c53097043776</evn_uid>
|
||||
<act_uid>382310413591d96b6cb34d7077964801</act_uid>
|
||||
<dyn_uid>361249164591d96e6edcb81084086222</dyn_uid>
|
||||
<usr_uid>00000000000000000000000000000001</usr_uid>
|
||||
<wee_title>754852677591d96f0066c53097043776</wee_title>
|
||||
<wee_description></wee_description>
|
||||
<wee_status>ENABLED</wee_status>
|
||||
<wee_we_uid>628282652591d96fc61ddc3005225961</wee_we_uid>
|
||||
<wee_we_tas_uid>wee-64523591d96fc408bb5096940569</wee_we_tas_uid>
|
||||
<wee_we_url>754852677591d96f0066c53097043776.php</wee_we_url>
|
||||
</record>
|
||||
</table>
|
||||
<table name="messageType"/>
|
||||
<table name="messageTypeVariable"/>
|
||||
<table name="messageEventDefinition"/>
|
||||
<table name="scriptTask"/>
|
||||
<table name="timerEvent"/>
|
||||
<table name="emailEvent"/>
|
||||
<table name="filesManager"/>
|
||||
<table name="abeConfiguration"/>
|
||||
<table name="elementTask"/>
|
||||
</definition>
|
||||
<workflow-files>
|
||||
<file target="dynaforms">
|
||||
<file_name>Form2</file_name>
|
||||
<file_path><![CDATA[441299927591d969ff284b7005303758/361249164591d96e6edcb81084086222.xml]]></file_path>
|
||||
<file_content><![CDATA[PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPGR5bmFGb3JtIHR5cGU9InhtbGZvcm0iIG5hbWU9IjQ0MTI5OTkyNzU5MWQ5NjlmZjI4NGI3MDA1MzAzNzU4LzM2MTI0OTE2NDU5MWQ5NmU2ZWRjYjgxMDg0MDg2MjIyIiB3aWR0aD0iNTAwIiBlbmFibGV0ZW1wbGF0ZT0iMCIgbW9kZT0iIiBuZXh0c3RlcHNhdmU9InByb21wdCI+CjwvZHluYUZvcm0+]]></file_content>
|
||||
</file>
|
||||
<file target="dynaforms">
|
||||
<file_name>Form1</file_name>
|
||||
<file_path><![CDATA[441299927591d969ff284b7005303758/839383145591d96c1331811037017265.xml]]></file_path>
|
||||
<file_content><![CDATA[PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPGR5bmFGb3JtIHR5cGU9InhtbGZvcm0iIG5hbWU9IjQ0MTI5OTkyNzU5MWQ5NjlmZjI4NGI3MDA1MzAzNzU4LzgzOTM4MzE0NTU5MWQ5NmMxMzMxODExMDM3MDE3MjY1IiB3aWR0aD0iNTAwIiBlbmFibGV0ZW1wbGF0ZT0iMCIgbW9kZT0iIiBuZXh0c3RlcHNhdmU9InByb21wdCI+CjwvZHluYUZvcm0+]]></file_content>
|
||||
</file>
|
||||
<file target="public">
|
||||
<file_name>349681056591d96b7059a07092140602Info.php</file_name>
|
||||
<file_path><![CDATA[441299927591d969ff284b7005303758/349681056591d96b7059a07092140602Info.php]]></file_path>
|
||||
<file_content><![CDATA[PD9waHAKCiRHX1BVQkxJU0ggPSBuZXcgUHVibGlzaGVyKCk7CiRzaG93ID0gImxvZ2luL3Nob3dNZXNzYWdlIjsKJG1lc3NhZ2UgPSAiIjsKaWYgKGlzc2V0KCRfU0VTU0lPTlsiX193ZWJFbnRyeVN1Y2Nlc3NfXyJdKSkgewogICAgJHNob3cgPSAibG9naW4vc2hvd0luZm8iOwogICAgJG1lc3NhZ2UgPSAkX1NFU1NJT05bIl9fd2ViRW50cnlTdWNjZXNzX18iXTsKfSBlbHNlIHsKICAgICRzaG93ID0gImxvZ2luL3Nob3dNZXNzYWdlIjsKICAgICRtZXNzYWdlID0gJF9TRVNTSU9OWyJfX3dlYkVudHJ5RXJyb3JfXyJdOwp9CiRHX1BVQkxJU0gtPkFkZENvbnRlbnQoInhtbGZvcm0iLCAieG1sZm9ybSIsICRzaG93LCAiIiwgJG1lc3NhZ2UpOwpHOjpSZW5kZXJQYWdlKCJwdWJsaXNoIiwgImJsYW5rIik7Cgo=]]></file_content>
|
||||
</file>
|
||||
<file target="public">
|
||||
<file_name>754852677591d96f0066c53097043776Info.php</file_name>
|
||||
<file_path><![CDATA[441299927591d969ff284b7005303758/754852677591d96f0066c53097043776Info.php]]></file_path>
|
||||
<file_content><![CDATA[PD9waHAKCiRHX1BVQkxJU0ggPSBuZXcgUHVibGlzaGVyKCk7CiRzaG93ID0gImxvZ2luL3Nob3dNZXNzYWdlIjsKJG1lc3NhZ2UgPSAiIjsKaWYgKGlzc2V0KCRfU0VTU0lPTlsiX193ZWJFbnRyeVN1Y2Nlc3NfXyJdKSkgewogICAgJHNob3cgPSAibG9naW4vc2hvd0luZm8iOwogICAgJG1lc3NhZ2UgPSAkX1NFU1NJT05bIl9fd2ViRW50cnlTdWNjZXNzX18iXTsKfSBlbHNlIHsKICAgICRzaG93ID0gImxvZ2luL3Nob3dNZXNzYWdlIjsKICAgICRtZXNzYWdlID0gJF9TRVNTSU9OWyJfX3dlYkVudHJ5RXJyb3JfXyJdOwp9CiRHX1BVQkxJU0gtPkFkZENvbnRlbnQoInhtbGZvcm0iLCAieG1sZm9ybSIsICRzaG93LCAiIiwgJG1lc3NhZ2UpOwpHOjpSZW5kZXJQYWdlKCJwdWJsaXNoIiwgImJsYW5rIik7Cgo=]]></file_content>
|
||||
</file>
|
||||
</workflow-files>
|
||||
</ProcessMaker-Project>
|
||||
@@ -1,667 +0,0 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<ProcessMaker-Project version="3.0">
|
||||
<metadata>
|
||||
<meta key="vendor_version"><![CDATA[(Branch feature/HOR-3207)]]></meta>
|
||||
<meta key="vendor_version_code">Michelangelo</meta>
|
||||
<meta key="export_timestamp">1495125086</meta>
|
||||
<meta key="export_datetime"><![CDATA[2017-05-18T16:31:26+00:00]]></meta>
|
||||
<meta key="export_server_addr"><![CDATA[127.0.0.1:8080]]></meta>
|
||||
<meta key="export_server_os">Darwin</meta>
|
||||
<meta key="export_server_php_version">50621</meta>
|
||||
<meta key="export_version">2</meta>
|
||||
<meta key="workspace">hor3207a</meta>
|
||||
<meta key="name">WebEntryEvent2</meta>
|
||||
<meta key="uid">764314601591da882ee7360035898228</meta>
|
||||
</metadata>
|
||||
<definition class="BPMN">
|
||||
<table name="ACTIVITY">
|
||||
<record>
|
||||
<act_uid>699674969591da8ad2c8e29094085586</act_uid>
|
||||
<prj_uid>764314601591da882ee7360035898228</prj_uid>
|
||||
<pro_uid>827725863591da88311f126098111677</pro_uid>
|
||||
<act_name>Task 1</act_name>
|
||||
<act_type>TASK</act_type>
|
||||
<act_is_for_compensation>0</act_is_for_compensation>
|
||||
<act_start_quantity>1</act_start_quantity>
|
||||
<act_completion_quantity>0</act_completion_quantity>
|
||||
<act_task_type>EMPTY</act_task_type>
|
||||
<act_implementation></act_implementation>
|
||||
<act_instantiate>0</act_instantiate>
|
||||
<act_script_type></act_script_type>
|
||||
<act_script></act_script>
|
||||
<act_loop_type>EMPTY</act_loop_type>
|
||||
<act_test_before>0</act_test_before>
|
||||
<act_loop_maximum>0</act_loop_maximum>
|
||||
<act_loop_condition>0</act_loop_condition>
|
||||
<act_loop_cardinality>0</act_loop_cardinality>
|
||||
<act_loop_behavior>0</act_loop_behavior>
|
||||
<act_is_adhoc>0</act_is_adhoc>
|
||||
<act_is_collapsed>0</act_is_collapsed>
|
||||
<act_completion_condition>0</act_completion_condition>
|
||||
<act_ordering>0</act_ordering>
|
||||
<act_cancel_remaining_instances>0</act_cancel_remaining_instances>
|
||||
<act_protocol>0</act_protocol>
|
||||
<act_method>0</act_method>
|
||||
<act_is_global>0</act_is_global>
|
||||
<act_referer>0</act_referer>
|
||||
<act_default_flow>0</act_default_flow>
|
||||
<act_master_diagram>0</act_master_diagram>
|
||||
<bou_uid>796773032591da8ad2d78f9070801311</bou_uid>
|
||||
<dia_uid>976761549591da883096875051042456</dia_uid>
|
||||
<element_uid>699674969591da8ad2c8e29094085586</element_uid>
|
||||
<bou_element>592748205591dcc43e17925091079095</bou_element>
|
||||
<bou_element_type>bpmnActivity</bou_element_type>
|
||||
<bou_x>359</bou_x>
|
||||
<bou_y>74</bou_y>
|
||||
<bou_width>150</bou_width>
|
||||
<bou_height>75</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
</table>
|
||||
<table name="ARTIFACT"/>
|
||||
<table name="BOUND">
|
||||
<record>
|
||||
<bou_uid>644078661591da8ad49b168076298122</bou_uid>
|
||||
<prj_uid>764314601591da882ee7360035898228</prj_uid>
|
||||
<dia_uid>976761549591da883096875051042456</dia_uid>
|
||||
<element_uid>629345707591da8ad4948a3022146882</element_uid>
|
||||
<bou_element>592748205591dcc43e17925091079095</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>606</bou_x>
|
||||
<bou_y>95</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<bou_uid>720886708591dcc59beb096016129290</bou_uid>
|
||||
<prj_uid>764314601591da882ee7360035898228</prj_uid>
|
||||
<dia_uid>976761549591da883096875051042456</dia_uid>
|
||||
<element_uid>757752922591dcc59bdaed3079376019</element_uid>
|
||||
<bou_element>592748205591dcc43e17925091079095</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>240</bou_x>
|
||||
<bou_y>187</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<bou_uid>784735656591da8ad4749e5074175364</bou_uid>
|
||||
<prj_uid>764314601591da882ee7360035898228</prj_uid>
|
||||
<dia_uid>976761549591da883096875051042456</dia_uid>
|
||||
<element_uid>103520741591da8ad46aa47032601056</element_uid>
|
||||
<bou_element>592748205591dcc43e17925091079095</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>240</bou_x>
|
||||
<bou_y>95</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<bou_uid>796773032591da8ad2d78f9070801311</bou_uid>
|
||||
<prj_uid>764314601591da882ee7360035898228</prj_uid>
|
||||
<dia_uid>976761549591da883096875051042456</dia_uid>
|
||||
<element_uid>699674969591da8ad2c8e29094085586</element_uid>
|
||||
<bou_element>592748205591dcc43e17925091079095</bou_element>
|
||||
<bou_element_type>bpmnActivity</bou_element_type>
|
||||
<bou_x>359</bou_x>
|
||||
<bou_y>74</bou_y>
|
||||
<bou_width>150</bou_width>
|
||||
<bou_height>75</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
</table>
|
||||
<table name="DATA"/>
|
||||
<table name="DIAGRAM">
|
||||
<record>
|
||||
<dia_uid>976761549591da883096875051042456</dia_uid>
|
||||
<prj_uid>764314601591da882ee7360035898228</prj_uid>
|
||||
<dia_name>WebEntryEvent2</dia_name>
|
||||
<dia_is_closable>0</dia_is_closable>
|
||||
</record>
|
||||
</table>
|
||||
<table name="DOCUMENTATION"/>
|
||||
<table name="EVENT">
|
||||
<record>
|
||||
<evn_uid>629345707591da8ad4948a3022146882</evn_uid>
|
||||
<prj_uid>764314601591da882ee7360035898228</prj_uid>
|
||||
<pro_uid>827725863591da88311f126098111677</pro_uid>
|
||||
<evn_name></evn_name>
|
||||
<evn_type>END</evn_type>
|
||||
<evn_marker>EMPTY</evn_marker>
|
||||
<evn_is_interrupting>1</evn_is_interrupting>
|
||||
<evn_attached_to></evn_attached_to>
|
||||
<evn_cancel_activity>0</evn_cancel_activity>
|
||||
<evn_activity_ref></evn_activity_ref>
|
||||
<evn_wait_for_completion>0</evn_wait_for_completion>
|
||||
<evn_error_name></evn_error_name>
|
||||
<evn_error_code></evn_error_code>
|
||||
<evn_escalation_name></evn_escalation_name>
|
||||
<evn_escalation_code></evn_escalation_code>
|
||||
<evn_condition></evn_condition>
|
||||
<evn_message></evn_message>
|
||||
<evn_operation_name></evn_operation_name>
|
||||
<evn_operation_implementation_ref></evn_operation_implementation_ref>
|
||||
<evn_time_date></evn_time_date>
|
||||
<evn_time_cycle></evn_time_cycle>
|
||||
<evn_time_duration></evn_time_duration>
|
||||
<evn_behavior>THROW</evn_behavior>
|
||||
<bou_uid>644078661591da8ad49b168076298122</bou_uid>
|
||||
<dia_uid>976761549591da883096875051042456</dia_uid>
|
||||
<element_uid>629345707591da8ad4948a3022146882</element_uid>
|
||||
<bou_element>592748205591dcc43e17925091079095</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>606</bou_x>
|
||||
<bou_y>95</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<evn_uid>757752922591dcc59bdaed3079376019</evn_uid>
|
||||
<prj_uid>764314601591da882ee7360035898228</prj_uid>
|
||||
<pro_uid>827725863591da88311f126098111677</pro_uid>
|
||||
<evn_name>simple start</evn_name>
|
||||
<evn_type>START</evn_type>
|
||||
<evn_marker>EMPTY</evn_marker>
|
||||
<evn_is_interrupting>1</evn_is_interrupting>
|
||||
<evn_attached_to></evn_attached_to>
|
||||
<evn_cancel_activity>0</evn_cancel_activity>
|
||||
<evn_activity_ref></evn_activity_ref>
|
||||
<evn_wait_for_completion>0</evn_wait_for_completion>
|
||||
<evn_error_name></evn_error_name>
|
||||
<evn_error_code></evn_error_code>
|
||||
<evn_escalation_name></evn_escalation_name>
|
||||
<evn_escalation_code></evn_escalation_code>
|
||||
<evn_condition></evn_condition>
|
||||
<evn_message>LEAD</evn_message>
|
||||
<evn_operation_name></evn_operation_name>
|
||||
<evn_operation_implementation_ref></evn_operation_implementation_ref>
|
||||
<evn_time_date></evn_time_date>
|
||||
<evn_time_cycle></evn_time_cycle>
|
||||
<evn_time_duration></evn_time_duration>
|
||||
<evn_behavior>CATCH</evn_behavior>
|
||||
<bou_uid>720886708591dcc59beb096016129290</bou_uid>
|
||||
<dia_uid>976761549591da883096875051042456</dia_uid>
|
||||
<element_uid>757752922591dcc59bdaed3079376019</element_uid>
|
||||
<bou_element>592748205591dcc43e17925091079095</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>240</bou_x>
|
||||
<bou_y>187</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
<record>
|
||||
<evn_uid>103520741591da8ad46aa47032601056</evn_uid>
|
||||
<prj_uid>764314601591da882ee7360035898228</prj_uid>
|
||||
<pro_uid>827725863591da88311f126098111677</pro_uid>
|
||||
<evn_name></evn_name>
|
||||
<evn_type>START</evn_type>
|
||||
<evn_marker>EMPTY</evn_marker>
|
||||
<evn_is_interrupting>1</evn_is_interrupting>
|
||||
<evn_attached_to></evn_attached_to>
|
||||
<evn_cancel_activity>0</evn_cancel_activity>
|
||||
<evn_activity_ref></evn_activity_ref>
|
||||
<evn_wait_for_completion>0</evn_wait_for_completion>
|
||||
<evn_error_name></evn_error_name>
|
||||
<evn_error_code></evn_error_code>
|
||||
<evn_escalation_name></evn_escalation_name>
|
||||
<evn_escalation_code></evn_escalation_code>
|
||||
<evn_condition></evn_condition>
|
||||
<evn_message>LEAD</evn_message>
|
||||
<evn_operation_name></evn_operation_name>
|
||||
<evn_operation_implementation_ref></evn_operation_implementation_ref>
|
||||
<evn_time_date></evn_time_date>
|
||||
<evn_time_cycle></evn_time_cycle>
|
||||
<evn_time_duration></evn_time_duration>
|
||||
<evn_behavior>CATCH</evn_behavior>
|
||||
<bou_uid>784735656591da8ad4749e5074175364</bou_uid>
|
||||
<dia_uid>976761549591da883096875051042456</dia_uid>
|
||||
<element_uid>103520741591da8ad46aa47032601056</element_uid>
|
||||
<bou_element>592748205591dcc43e17925091079095</bou_element>
|
||||
<bou_element_type>bpmnEvent</bou_element_type>
|
||||
<bou_x>240</bou_x>
|
||||
<bou_y>95</bou_y>
|
||||
<bou_width>33</bou_width>
|
||||
<bou_height>33</bou_height>
|
||||
<bou_rel_position>0</bou_rel_position>
|
||||
<bou_size_identical>0</bou_size_identical>
|
||||
<bou_container>bpmnDiagram</bou_container>
|
||||
</record>
|
||||
</table>
|
||||
<table name="EXTENSION"/>
|
||||
<table name="FLOW">
|
||||
<record>
|
||||
<flo_uid>544425218591da8ad5424e9036223137</flo_uid>
|
||||
<prj_uid>764314601591da882ee7360035898228</prj_uid>
|
||||
<dia_uid>976761549591da883096875051042456</dia_uid>
|
||||
<flo_type>SEQUENCE</flo_type>
|
||||
<flo_name> </flo_name>
|
||||
<flo_element_origin>103520741591da8ad46aa47032601056</flo_element_origin>
|
||||
<flo_element_origin_type>bpmnEvent</flo_element_origin_type>
|
||||
<flo_element_origin_port>0</flo_element_origin_port>
|
||||
<flo_element_dest>699674969591da8ad2c8e29094085586</flo_element_dest>
|
||||
<flo_element_dest_type>bpmnActivity</flo_element_dest_type>
|
||||
<flo_element_dest_port>0</flo_element_dest_port>
|
||||
<flo_is_inmediate>1</flo_is_inmediate>
|
||||
<flo_condition></flo_condition>
|
||||
<flo_x1>273</flo_x1>
|
||||
<flo_y1>112</flo_y1>
|
||||
<flo_x2>359</flo_x2>
|
||||
<flo_y2>112</flo_y2>
|
||||
<flo_state><![CDATA[[{"x":273,"y":112},{"x":359,"y":112}]]]></flo_state>
|
||||
<flo_position>1</flo_position>
|
||||
</record>
|
||||
<record>
|
||||
<flo_uid>664834305591da8ad5445c1002013300</flo_uid>
|
||||
<prj_uid>764314601591da882ee7360035898228</prj_uid>
|
||||
<dia_uid>976761549591da883096875051042456</dia_uid>
|
||||
<flo_type>SEQUENCE</flo_type>
|
||||
<flo_name> </flo_name>
|
||||
<flo_element_origin>699674969591da8ad2c8e29094085586</flo_element_origin>
|
||||
<flo_element_origin_type>bpmnActivity</flo_element_origin_type>
|
||||
<flo_element_origin_port>0</flo_element_origin_port>
|
||||
<flo_element_dest>629345707591da8ad4948a3022146882</flo_element_dest>
|
||||
<flo_element_dest_type>bpmnEvent</flo_element_dest_type>
|
||||
<flo_element_dest_port>0</flo_element_dest_port>
|
||||
<flo_is_inmediate>1</flo_is_inmediate>
|
||||
<flo_condition></flo_condition>
|
||||
<flo_x1>510</flo_x1>
|
||||
<flo_y1>112</flo_y1>
|
||||
<flo_x2>606</flo_x2>
|
||||
<flo_y2>112</flo_y2>
|
||||
<flo_state><![CDATA[[{"x":510,"y":112},{"x":606,"y":112}]]]></flo_state>
|
||||
<flo_position>1</flo_position>
|
||||
</record>
|
||||
<record>
|
||||
<flo_uid>732645293591dcc59c42f67065123627</flo_uid>
|
||||
<prj_uid>764314601591da882ee7360035898228</prj_uid>
|
||||
<dia_uid>976761549591da883096875051042456</dia_uid>
|
||||
<flo_type>SEQUENCE</flo_type>
|
||||
<flo_name> </flo_name>
|
||||
<flo_element_origin>757752922591dcc59bdaed3079376019</flo_element_origin>
|
||||
<flo_element_origin_type>bpmnEvent</flo_element_origin_type>
|
||||
<flo_element_origin_port>0</flo_element_origin_port>
|
||||
<flo_element_dest>699674969591da8ad2c8e29094085586</flo_element_dest>
|
||||
<flo_element_dest_type>bpmnActivity</flo_element_dest_type>
|
||||
<flo_element_dest_port>0</flo_element_dest_port>
|
||||
<flo_is_inmediate>1</flo_is_inmediate>
|
||||
<flo_condition></flo_condition>
|
||||
<flo_x1>273</flo_x1>
|
||||
<flo_y1>204</flo_y1>
|
||||
<flo_x2>435</flo_x2>
|
||||
<flo_y2>149</flo_y2>
|
||||
<flo_state><![CDATA[[{"x":273,"y":204},{"x":435,"y":204},{"x":435,"y":149}]]]></flo_state>
|
||||
<flo_position>1</flo_position>
|
||||
</record>
|
||||
</table>
|
||||
<table name="GATEWAY"/>
|
||||
<table name="LANE"/>
|
||||
<table name="LANESET"/>
|
||||
<table name="PARTICIPANT"/>
|
||||
<table name="PROCESS">
|
||||
<record>
|
||||
<pro_uid>827725863591da88311f126098111677</pro_uid>
|
||||
<prj_uid>764314601591da882ee7360035898228</prj_uid>
|
||||
<dia_uid>976761549591da883096875051042456</dia_uid>
|
||||
<pro_name>WebEntryEvent2</pro_name>
|
||||
<pro_type>NONE</pro_type>
|
||||
<pro_is_executable>0</pro_is_executable>
|
||||
<pro_is_closed>0</pro_is_closed>
|
||||
<pro_is_subprocess>0</pro_is_subprocess>
|
||||
</record>
|
||||
</table>
|
||||
<table name="PROJECT">
|
||||
<record>
|
||||
<prj_uid>764314601591da882ee7360035898228</prj_uid>
|
||||
<prj_name>WebEntryEvent2</prj_name>
|
||||
<prj_description></prj_description>
|
||||
<prj_target_namespace></prj_target_namespace>
|
||||
<prj_expresion_language></prj_expresion_language>
|
||||
<prj_type_language></prj_type_language>
|
||||
<prj_exporter></prj_exporter>
|
||||
<prj_exporter_version></prj_exporter_version>
|
||||
<prj_create_date><![CDATA[2017-05-18 13:58:27]]></prj_create_date>
|
||||
<prj_update_date><![CDATA[2017-05-18 16:31:21]]></prj_update_date>
|
||||
<prj_author>00000000000000000000000000000001</prj_author>
|
||||
<prj_author_version></prj_author_version>
|
||||
<prj_original_source></prj_original_source>
|
||||
</record>
|
||||
</table>
|
||||
</definition>
|
||||
<definition class="workflow">
|
||||
<table name="process">
|
||||
<record>
|
||||
<pro_uid>764314601591da882ee7360035898228</pro_uid>
|
||||
<pro_title>WebEntryEvent2</pro_title>
|
||||
<pro_description></pro_description>
|
||||
<pro_parent>764314601591da882ee7360035898228</pro_parent>
|
||||
<pro_time>1</pro_time>
|
||||
<pro_timeunit>DAYS</pro_timeunit>
|
||||
<pro_status>ACTIVE</pro_status>
|
||||
<pro_type_day></pro_type_day>
|
||||
<pro_type>NORMAL</pro_type>
|
||||
<pro_assignment>FALSE</pro_assignment>
|
||||
<pro_show_map>0</pro_show_map>
|
||||
<pro_show_message>0</pro_show_message>
|
||||
<pro_subprocess>0</pro_subprocess>
|
||||
<pro_tri_create></pro_tri_create>
|
||||
<pro_tri_open></pro_tri_open>
|
||||
<pro_tri_deleted></pro_tri_deleted>
|
||||
<pro_tri_canceled></pro_tri_canceled>
|
||||
<pro_tri_paused></pro_tri_paused>
|
||||
<pro_tri_reassigned></pro_tri_reassigned>
|
||||
<pro_tri_unpaused></pro_tri_unpaused>
|
||||
<pro_type_process>PUBLIC</pro_type_process>
|
||||
<pro_show_delegate>0</pro_show_delegate>
|
||||
<pro_show_dynaform>0</pro_show_dynaform>
|
||||
<pro_category></pro_category>
|
||||
<pro_sub_category></pro_sub_category>
|
||||
<pro_industry>0</pro_industry>
|
||||
<pro_update_date><![CDATA[2017-05-18 16:31:21]]></pro_update_date>
|
||||
<pro_create_date><![CDATA[2017-05-18 13:58:26]]></pro_create_date>
|
||||
<pro_create_user>00000000000000000000000000000001</pro_create_user>
|
||||
<pro_height>5000</pro_height>
|
||||
<pro_width>10000</pro_width>
|
||||
<pro_title_x>0</pro_title_x>
|
||||
<pro_title_y>0</pro_title_y>
|
||||
<pro_debug>0</pro_debug>
|
||||
<pro_dynaforms></pro_dynaforms>
|
||||
<pro_derivation_screen_tpl></pro_derivation_screen_tpl>
|
||||
<pro_cost>0</pro_cost>
|
||||
<pro_unit_cost></pro_unit_cost>
|
||||
<pro_itee>1</pro_itee>
|
||||
<pro_action_done><![CDATA[a:1:{i:0;s:41:"GATEWAYTOGATEWAY_DELETE_CORRUPTED_RECORDS";}]]></pro_action_done>
|
||||
<pro_category_label>No Category</pro_category_label>
|
||||
<pro_bpmn>1</pro_bpmn>
|
||||
</record>
|
||||
</table>
|
||||
<table name="tasks">
|
||||
<record>
|
||||
<pro_uid>764314601591da882ee7360035898228</pro_uid>
|
||||
<tas_uid>699674969591da8ad2c8e29094085586</tas_uid>
|
||||
<tas_title>Task 1</tas_title>
|
||||
<tas_description></tas_description>
|
||||
<tas_def_title></tas_def_title>
|
||||
<tas_def_subject_message></tas_def_subject_message>
|
||||
<tas_def_proc_code></tas_def_proc_code>
|
||||
<tas_def_message></tas_def_message>
|
||||
<tas_def_description></tas_def_description>
|
||||
<tas_type>NORMAL</tas_type>
|
||||
<tas_duration>1</tas_duration>
|
||||
<tas_delay_type></tas_delay_type>
|
||||
<tas_temporizer>0</tas_temporizer>
|
||||
<tas_type_day></tas_type_day>
|
||||
<tas_timeunit>DAYS</tas_timeunit>
|
||||
<tas_alert>FALSE</tas_alert>
|
||||
<tas_priority_variable></tas_priority_variable>
|
||||
<tas_assign_type>BALANCED</tas_assign_type>
|
||||
<tas_assign_variable><![CDATA[@@SYS_NEXT_USER_TO_BE_ASSIGNED]]></tas_assign_variable>
|
||||
<tas_group_variable></tas_group_variable>
|
||||
<tas_mi_instance_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCE]]></tas_mi_instance_variable>
|
||||
<tas_mi_complete_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCES_COMPLETE]]></tas_mi_complete_variable>
|
||||
<tas_assign_location>FALSE</tas_assign_location>
|
||||
<tas_assign_location_adhoc>FALSE</tas_assign_location_adhoc>
|
||||
<tas_transfer_fly>FALSE</tas_transfer_fly>
|
||||
<tas_last_assigned>0</tas_last_assigned>
|
||||
<tas_user>0</tas_user>
|
||||
<tas_can_upload>FALSE</tas_can_upload>
|
||||
<tas_view_upload>FALSE</tas_view_upload>
|
||||
<tas_view_additional_documentation>FALSE</tas_view_additional_documentation>
|
||||
<tas_can_cancel>FALSE</tas_can_cancel>
|
||||
<tas_owner_app>FALSE</tas_owner_app>
|
||||
<stg_uid></stg_uid>
|
||||
<tas_can_pause>FALSE</tas_can_pause>
|
||||
<tas_can_send_message>TRUE</tas_can_send_message>
|
||||
<tas_can_delete_docs>FALSE</tas_can_delete_docs>
|
||||
<tas_self_service>FALSE</tas_self_service>
|
||||
<tas_start>TRUE</tas_start>
|
||||
<tas_to_last_user>FALSE</tas_to_last_user>
|
||||
<tas_send_last_email>FALSE</tas_send_last_email>
|
||||
<tas_derivation>NORMAL</tas_derivation>
|
||||
<tas_posx>359</tas_posx>
|
||||
<tas_posy>74</tas_posy>
|
||||
<tas_width>110</tas_width>
|
||||
<tas_height>60</tas_height>
|
||||
<tas_color></tas_color>
|
||||
<tas_evn_uid></tas_evn_uid>
|
||||
<tas_boundary></tas_boundary>
|
||||
<tas_derivation_screen_tpl></tas_derivation_screen_tpl>
|
||||
<tas_selfservice_timeout>0</tas_selfservice_timeout>
|
||||
<tas_selfservice_time>0</tas_selfservice_time>
|
||||
<tas_selfservice_time_unit></tas_selfservice_time_unit>
|
||||
<tas_selfservice_trigger_uid></tas_selfservice_trigger_uid>
|
||||
<tas_selfservice_execution>EVERY_TIME</tas_selfservice_execution>
|
||||
<tas_not_email_from_format>0</tas_not_email_from_format>
|
||||
<tas_offline>FALSE</tas_offline>
|
||||
<tas_email_server_uid></tas_email_server_uid>
|
||||
<tas_auto_root>FALSE</tas_auto_root>
|
||||
<tas_receive_server_uid></tas_receive_server_uid>
|
||||
<tas_receive_last_email>FALSE</tas_receive_last_email>
|
||||
<tas_receive_email_from_format>0</tas_receive_email_from_format>
|
||||
<tas_receive_message_type>text</tas_receive_message_type>
|
||||
<tas_receive_message_template>alert_message.html</tas_receive_message_template>
|
||||
<tas_receive_subject_message></tas_receive_subject_message>
|
||||
<tas_receive_message></tas_receive_message>
|
||||
<tas_average></tas_average>
|
||||
<tas_sdv></tas_sdv>
|
||||
</record>
|
||||
<record>
|
||||
<pro_uid>764314601591da882ee7360035898228</pro_uid>
|
||||
<tas_uid>wee-96854591da8b6eda526061044026</tas_uid>
|
||||
<tas_title>WEBENTRYEVENT</tas_title>
|
||||
<tas_description></tas_description>
|
||||
<tas_def_title></tas_def_title>
|
||||
<tas_def_subject_message></tas_def_subject_message>
|
||||
<tas_def_proc_code></tas_def_proc_code>
|
||||
<tas_def_message></tas_def_message>
|
||||
<tas_def_description></tas_def_description>
|
||||
<tas_type>WEBENTRYEVENT</tas_type>
|
||||
<tas_duration>1</tas_duration>
|
||||
<tas_delay_type></tas_delay_type>
|
||||
<tas_temporizer>0</tas_temporizer>
|
||||
<tas_type_day></tas_type_day>
|
||||
<tas_timeunit>DAYS</tas_timeunit>
|
||||
<tas_alert>FALSE</tas_alert>
|
||||
<tas_priority_variable></tas_priority_variable>
|
||||
<tas_assign_type>BALANCED</tas_assign_type>
|
||||
<tas_assign_variable><![CDATA[@@SYS_NEXT_USER_TO_BE_ASSIGNED]]></tas_assign_variable>
|
||||
<tas_group_variable></tas_group_variable>
|
||||
<tas_mi_instance_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCE]]></tas_mi_instance_variable>
|
||||
<tas_mi_complete_variable><![CDATA[@@SYS_VAR_TOTAL_INSTANCES_COMPLETE]]></tas_mi_complete_variable>
|
||||
<tas_assign_location>FALSE</tas_assign_location>
|
||||
<tas_assign_location_adhoc>FALSE</tas_assign_location_adhoc>
|
||||
<tas_transfer_fly>FALSE</tas_transfer_fly>
|
||||
<tas_last_assigned>0</tas_last_assigned>
|
||||
<tas_user>0</tas_user>
|
||||
<tas_can_upload>FALSE</tas_can_upload>
|
||||
<tas_view_upload>FALSE</tas_view_upload>
|
||||
<tas_view_additional_documentation>FALSE</tas_view_additional_documentation>
|
||||
<tas_can_cancel>FALSE</tas_can_cancel>
|
||||
<tas_owner_app>FALSE</tas_owner_app>
|
||||
<stg_uid></stg_uid>
|
||||
<tas_can_pause>FALSE</tas_can_pause>
|
||||
<tas_can_send_message>TRUE</tas_can_send_message>
|
||||
<tas_can_delete_docs>FALSE</tas_can_delete_docs>
|
||||
<tas_self_service>FALSE</tas_self_service>
|
||||
<tas_start>TRUE</tas_start>
|
||||
<tas_to_last_user>FALSE</tas_to_last_user>
|
||||
<tas_send_last_email>FALSE</tas_send_last_email>
|
||||
<tas_derivation>NORMAL</tas_derivation>
|
||||
<tas_posx>240</tas_posx>
|
||||
<tas_posy>95</tas_posy>
|
||||
<tas_width>110</tas_width>
|
||||
<tas_height>60</tas_height>
|
||||
<tas_color></tas_color>
|
||||
<tas_evn_uid></tas_evn_uid>
|
||||
<tas_boundary></tas_boundary>
|
||||
<tas_derivation_screen_tpl></tas_derivation_screen_tpl>
|
||||
<tas_selfservice_timeout>0</tas_selfservice_timeout>
|
||||
<tas_selfservice_time>0</tas_selfservice_time>
|
||||
<tas_selfservice_time_unit></tas_selfservice_time_unit>
|
||||
<tas_selfservice_trigger_uid></tas_selfservice_trigger_uid>
|
||||
<tas_selfservice_execution>EVERY_TIME</tas_selfservice_execution>
|
||||
<tas_not_email_from_format>0</tas_not_email_from_format>
|
||||
<tas_offline>FALSE</tas_offline>
|
||||
<tas_email_server_uid></tas_email_server_uid>
|
||||
<tas_auto_root>FALSE</tas_auto_root>
|
||||
<tas_receive_server_uid></tas_receive_server_uid>
|
||||
<tas_receive_last_email>FALSE</tas_receive_last_email>
|
||||
<tas_receive_email_from_format>0</tas_receive_email_from_format>
|
||||
<tas_receive_message_type>text</tas_receive_message_type>
|
||||
<tas_receive_message_template>alert_message.html</tas_receive_message_template>
|
||||
<tas_receive_subject_message></tas_receive_subject_message>
|
||||
<tas_receive_message></tas_receive_message>
|
||||
<tas_average></tas_average>
|
||||
<tas_sdv></tas_sdv>
|
||||
</record>
|
||||
</table>
|
||||
<table name="routes">
|
||||
<record>
|
||||
<rou_uid>140127072591dcc59f37b55051754850</rou_uid>
|
||||
<rou_parent>0</rou_parent>
|
||||
<pro_uid>764314601591da882ee7360035898228</pro_uid>
|
||||
<tas_uid>wee-96854591da8b6eda526061044026</tas_uid>
|
||||
<rou_next_task>699674969591da8ad2c8e29094085586</rou_next_task>
|
||||
<rou_case>1</rou_case>
|
||||
<rou_type>SEQUENTIAL</rou_type>
|
||||
<rou_default>0</rou_default>
|
||||
<rou_condition></rou_condition>
|
||||
<rou_to_last_user>FALSE</rou_to_last_user>
|
||||
<rou_optional>FALSE</rou_optional>
|
||||
<rou_send_email>TRUE</rou_send_email>
|
||||
<rou_sourceanchor>1</rou_sourceanchor>
|
||||
<rou_targetanchor>0</rou_targetanchor>
|
||||
<rou_to_port>1</rou_to_port>
|
||||
<rou_from_port>2</rou_from_port>
|
||||
<rou_evn_uid></rou_evn_uid>
|
||||
<gat_uid></gat_uid>
|
||||
</record>
|
||||
<record>
|
||||
<rou_uid>326526437591dcc59d531b0071922316</rou_uid>
|
||||
<rou_parent>0</rou_parent>
|
||||
<pro_uid>764314601591da882ee7360035898228</pro_uid>
|
||||
<tas_uid>699674969591da8ad2c8e29094085586</tas_uid>
|
||||
<rou_next_task>-1</rou_next_task>
|
||||
<rou_case>1</rou_case>
|
||||
<rou_type>SEQUENTIAL</rou_type>
|
||||
<rou_default>0</rou_default>
|
||||
<rou_condition></rou_condition>
|
||||
<rou_to_last_user>FALSE</rou_to_last_user>
|
||||
<rou_optional>FALSE</rou_optional>
|
||||
<rou_send_email>TRUE</rou_send_email>
|
||||
<rou_sourceanchor>1</rou_sourceanchor>
|
||||
<rou_targetanchor>0</rou_targetanchor>
|
||||
<rou_to_port>1</rou_to_port>
|
||||
<rou_from_port>2</rou_from_port>
|
||||
<rou_evn_uid></rou_evn_uid>
|
||||
<gat_uid></gat_uid>
|
||||
</record>
|
||||
</table>
|
||||
<table name="lanes"/>
|
||||
<table name="gateways"/>
|
||||
<table name="inputs"/>
|
||||
<table name="outputs"/>
|
||||
<table name="dynaforms">
|
||||
<record>
|
||||
<dyn_uid>877826579591da8a5465c72072288515</dyn_uid>
|
||||
<dyn_title>Form1</dyn_title>
|
||||
<dyn_description></dyn_description>
|
||||
<pro_uid>764314601591da882ee7360035898228</pro_uid>
|
||||
<dyn_type>xmlform</dyn_type>
|
||||
<dyn_filename><![CDATA[764314601591da882ee7360035898228/877826579591da8a5465c72072288515]]></dyn_filename>
|
||||
<dyn_content><![CDATA[{"name":"Form1","description":"","items":[{"type":"form","variable":"","var_uid":"","dataType":"","id":"877826579591da8a5465c72072288515","name":"Form1","description":"","mode":"edit","script":"","language":"en","externalLibs":"","printable":false,"items":[],"variables":[]}]}]]></dyn_content>
|
||||
<dyn_label></dyn_label>
|
||||
<dyn_version>2</dyn_version>
|
||||
<dyn_update_date><![CDATA[2017-05-18 13:59:01]]></dyn_update_date>
|
||||
</record>
|
||||
</table>
|
||||
<table name="steps">
|
||||
<record>
|
||||
<step_uid>529105626591da8b7076636070339785</step_uid>
|
||||
<pro_uid>764314601591da882ee7360035898228</pro_uid>
|
||||
<tas_uid>wee-96854591da8b6eda526061044026</tas_uid>
|
||||
<step_type_obj>DYNAFORM</step_type_obj>
|
||||
<step_uid_obj>877826579591da8a5465c72072288515</step_uid_obj>
|
||||
<step_condition></step_condition>
|
||||
<step_position>1</step_position>
|
||||
<step_mode>EDIT</step_mode>
|
||||
</record>
|
||||
</table>
|
||||
<table name="triggers"/>
|
||||
<table name="taskusers"/>
|
||||
<table name="groupwfs"/>
|
||||
<table name="steptriggers"/>
|
||||
<table name="dbconnections"/>
|
||||
<table name="reportTables"/>
|
||||
<table name="reportTablesVars"/>
|
||||
<table name="stepSupervisor"/>
|
||||
<table name="objectPermissions"/>
|
||||
<table name="subProcess"/>
|
||||
<table name="caseTracker"/>
|
||||
<table name="caseTrackerObject"/>
|
||||
<table name="stage"/>
|
||||
<table name="fieldCondition"/>
|
||||
<table name="event"/>
|
||||
<table name="caseScheduler"/>
|
||||
<table name="processCategory"/>
|
||||
<table name="taskExtraProperties"/>
|
||||
<table name="processUser"/>
|
||||
<table name="processVariables"/>
|
||||
<table name="webEntry"/>
|
||||
<table name="webEntryEvent">
|
||||
<record>
|
||||
<wee_uid>193368522591da8b76111f9092017469</wee_uid>
|
||||
<prj_uid>764314601591da882ee7360035898228</prj_uid>
|
||||
<evn_uid>103520741591da8ad46aa47032601056</evn_uid>
|
||||
<act_uid>699674969591da8ad2c8e29094085586</act_uid>
|
||||
<dyn_uid>877826579591da8a5465c72072288515</dyn_uid>
|
||||
<usr_uid>00000000000000000000000000000001</usr_uid>
|
||||
<wee_title>103520741591da8ad46aa47032601056</wee_title>
|
||||
<wee_description></wee_description>
|
||||
<wee_status>ENABLED</wee_status>
|
||||
<wee_we_uid>178183036591da8b7340ba1059701145</wee_we_uid>
|
||||
<wee_we_tas_uid>wee-96854591da8b6eda526061044026</wee_we_tas_uid>
|
||||
<wee_we_url>103520741591da8ad46aa47032601056.php</wee_we_url>
|
||||
</record>
|
||||
</table>
|
||||
<table name="messageType"/>
|
||||
<table name="messageTypeVariable"/>
|
||||
<table name="messageEventDefinition"/>
|
||||
<table name="scriptTask"/>
|
||||
<table name="timerEvent"/>
|
||||
<table name="emailEvent"/>
|
||||
<table name="filesManager"/>
|
||||
<table name="abeConfiguration"/>
|
||||
<table name="elementTask"/>
|
||||
</definition>
|
||||
<workflow-files>
|
||||
<file target="dynaforms">
|
||||
<file_name>Form1</file_name>
|
||||
<file_path><![CDATA[764314601591da882ee7360035898228/877826579591da8a5465c72072288515.xml]]></file_path>
|
||||
<file_content><![CDATA[PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0iVVRGLTgiPz4KPGR5bmFGb3JtIHR5cGU9InhtbGZvcm0iIG5hbWU9Ijc2NDMxNDYwMTU5MWRhODgyZWU3MzYwMDM1ODk4MjI4Lzg3NzgyNjU3OTU5MWRhOGE1NDY1YzcyMDcyMjg4NTE1IiB3aWR0aD0iNTAwIiBlbmFibGV0ZW1wbGF0ZT0iMCIgbW9kZT0iIiBuZXh0c3RlcHNhdmU9InByb21wdCI+CjwvZHluYUZvcm0+]]></file_content>
|
||||
</file>
|
||||
<file target="public">
|
||||
<file_name>103520741591da8ad46aa47032601056Info.php</file_name>
|
||||
<file_path><![CDATA[764314601591da882ee7360035898228/103520741591da8ad46aa47032601056Info.php]]></file_path>
|
||||
<file_content><![CDATA[PD9waHAKCiRHX1BVQkxJU0ggPSBuZXcgUHVibGlzaGVyKCk7CiRzaG93ID0gImxvZ2luL3Nob3dNZXNzYWdlIjsKJG1lc3NhZ2UgPSAiIjsKaWYgKGlzc2V0KCRfU0VTU0lPTlsiX193ZWJFbnRyeVN1Y2Nlc3NfXyJdKSkgewogICAgJHNob3cgPSAibG9naW4vc2hvd0luZm8iOwogICAgJG1lc3NhZ2UgPSAkX1NFU1NJT05bIl9fd2ViRW50cnlTdWNjZXNzX18iXTsKfSBlbHNlIHsKICAgICRzaG93ID0gImxvZ2luL3Nob3dNZXNzYWdlIjsKICAgICRtZXNzYWdlID0gJF9TRVNTSU9OWyJfX3dlYkVudHJ5RXJyb3JfXyJdOwp9CiRHX1BVQkxJU0gtPkFkZENvbnRlbnQoInhtbGZvcm0iLCAieG1sZm9ybSIsICRzaG93LCAiIiwgJG1lc3NhZ2UpOwpHOjpSZW5kZXJQYWdlKCJwdWJsaXNoIiwgImJsYW5rIik7Cgo=]]></file_content>
|
||||
</file>
|
||||
</workflow-files>
|
||||
</ProcessMaker-Project>
|
||||
File diff suppressed because it is too large
Load Diff
@@ -8,7 +8,9 @@ use Google_Client;
|
||||
use Google_Service_Gmail_Message;
|
||||
use Illuminate\Foundation\Testing\DatabaseTransactions;
|
||||
use PHPMailerOAuth;
|
||||
use ProcessMaker\Core\System;
|
||||
use ProcessMaker\GmailOAuth\GmailOAuth;
|
||||
use ProcessMaker\Model\User;
|
||||
use RBAC;
|
||||
use Tests\TestCase;
|
||||
|
||||
@@ -140,14 +142,23 @@ class GmailOAuthTest extends TestCase
|
||||
*/
|
||||
public function it_should_create_email_server()
|
||||
{
|
||||
$this->markTestIncomplete("It required valid workspace");
|
||||
global $RBAC;
|
||||
$user = User::where('USR_ID', '=', 1)->get()->first();
|
||||
$_SESSION['USER_LOGGED'] = $user['USR_UID'];
|
||||
$RBAC = RBAC::getSingleton(PATH_DATA, session_id());
|
||||
$RBAC->initRBAC();
|
||||
$RBAC->loadUserRolePermission('PROCESSMAKER', $_SESSION['USER_LOGGED']);
|
||||
|
||||
$faker = $this->faker;
|
||||
$clientId = $faker->uuid;
|
||||
$clientSecret = $faker->uuid;
|
||||
$refreshToken = $faker->uuid;
|
||||
|
||||
$gmailOAuth = new GmailOAuth();
|
||||
$gmailOAuth->setEmailEngine("GMAILAPI");
|
||||
$gmailOAuth->setClientID($faker->uuid);
|
||||
$gmailOAuth->setClientSecret($faker->uuid);
|
||||
$gmailOAuth->setRefreshToken($faker->uuid);
|
||||
$gmailOAuth->setClientID($clientId);
|
||||
$gmailOAuth->setClientSecret($clientSecret);
|
||||
$gmailOAuth->setRefreshToken($refreshToken);
|
||||
$gmailOAuth->setFromAccount($faker->email);
|
||||
$gmailOAuth->setSenderEmail(1);
|
||||
$gmailOAuth->setSenderName($faker->word);
|
||||
@@ -155,8 +166,11 @@ class GmailOAuthTest extends TestCase
|
||||
$gmailOAuth->setMailTo($faker->email);
|
||||
$gmailOAuth->setSetDefaultConfiguration(0);
|
||||
|
||||
$this->expectException(Exception::class);
|
||||
$result = $gmailOAuth->saveEmailServer();
|
||||
|
||||
$this->assertEquals($clientId, $result['OAUTH_CLIENT_ID']);
|
||||
$this->assertEquals($clientSecret, $result['OAUTH_CLIENT_SECRET']);
|
||||
$this->assertEquals($refreshToken, $result['OAUTH_REFRESH_TOKEN']);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -166,7 +180,6 @@ class GmailOAuthTest extends TestCase
|
||||
*/
|
||||
public function it_should_udpate_email_server()
|
||||
{
|
||||
$this->markTestIncomplete("It required valid workspace");
|
||||
$faker = $this->faker;
|
||||
|
||||
$gmailOAuth = new GmailOAuth();
|
||||
@@ -330,4 +343,22 @@ class GmailOAuthTest extends TestCase
|
||||
}
|
||||
$this->assertTrue(true);
|
||||
}
|
||||
|
||||
/**
|
||||
* It tests that the message body contains the link to the image
|
||||
*
|
||||
* @test
|
||||
* @covers \ProcessMaker\GmailOAuth\GmailOAuth::getMessageBody()
|
||||
*/
|
||||
public function it_should_tests_the_get_message_body_method()
|
||||
{
|
||||
// Create the GmailOAuth object
|
||||
$gmailOauth = new GmailOAuth();
|
||||
|
||||
// Call the getMessageBody method
|
||||
$res = $gmailOauth->getMessageBody();
|
||||
|
||||
// Assert the result contains the server protocol and host
|
||||
$this->assertRegExp("#" . System::getServerProtocol() . System::getServerHost() . "#", $res);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,79 +2,31 @@
|
||||
|
||||
namespace Tests\unit\workflow\engine\src\ProcessMaker\Importer;
|
||||
|
||||
use G;
|
||||
use Carbon\Carbon;
|
||||
use Exception;
|
||||
use G;
|
||||
use Illuminate\Support\Facades\Cache;
|
||||
use PmLicenseManager;
|
||||
use ProcessMaker\Importer\XmlImporter;
|
||||
use ProcessMaker\Model\Groupwf;
|
||||
use ProcessMaker\Model\User;
|
||||
use ProcessMaker\Importer\XmlImporter;
|
||||
use Tests\TestCase;
|
||||
|
||||
class XmlImporterTest extends TestCase
|
||||
{
|
||||
private $user;
|
||||
|
||||
/**
|
||||
* Set up unit tests.
|
||||
*/
|
||||
public function setUp()
|
||||
{
|
||||
/**
|
||||
* To perform the test this requires a valid installation and its respective license.
|
||||
*
|
||||
* In the file "workflow/engine/classes/WorkspaceTools.php",
|
||||
* these lines need the db.php file.
|
||||
*
|
||||
* public function __construct($workspaceName)
|
||||
* {
|
||||
* $this->name = $workspaceName;
|
||||
* $this->path = PATH_DB . $this->name;
|
||||
* $this->dbPath = $this->path . '/db.php';
|
||||
* if ($this->workspaceExists()) {
|
||||
* $this->getDBInfo();
|
||||
* }
|
||||
* $this->setListContentMigrateTable();
|
||||
* }
|
||||
*
|
||||
*
|
||||
* In the file "workflow/engine/src/ProcessMaker/BusinessModel/Migrator/GranularImporter.php",
|
||||
* these lines need a valid license.
|
||||
*
|
||||
* public function import($objectList)
|
||||
* {
|
||||
* try {
|
||||
* if (\PMLicensedFeatures::getSingleton()->verifyfeature
|
||||
* ("jXsSi94bkRUcVZyRStNVExlTXhEclVadGRRcG9xbjNvTWVFQUF3cklKQVBiVT0=")
|
||||
* ) {
|
||||
* $objectList = $this->reorderImportOrder($objectList);
|
||||
* foreach ($objectList as $data) {
|
||||
* $objClass = $this->factory->create($data['name']);
|
||||
* if (is_object($objClass)) {
|
||||
* $dataImport = $data['data'][$data['name']];
|
||||
* $replace = ($data['value'] == 'replace') ? true : false;
|
||||
* $objClass->beforeImport($dataImport);
|
||||
* $migratorData = $objClass->import($dataImport, $replace);
|
||||
* $objClass->afterImport($dataImport);
|
||||
* }
|
||||
* }
|
||||
* } else {
|
||||
* $exception = new ImportException();
|
||||
* $exception->setNameException(\G::LoadTranslation('ID_NO_LICENSE_SELECTIVEIMPORTEXPORT_ENABLED'));
|
||||
* throw($exception);
|
||||
* }
|
||||
*
|
||||
* } catch (\Exception $e) {
|
||||
* if (get_class($e) === 'ProcessMaker\BusinessModel\Migrator\ImportException') {
|
||||
* throw $e;
|
||||
* } else {
|
||||
* $exception = new ImportException('Please review your current process definition
|
||||
* for missing elements, it\'s recommended that a new process should be exported
|
||||
* with all the elements.');
|
||||
* throw $exception;
|
||||
* }
|
||||
* }
|
||||
* }
|
||||
*/
|
||||
$this->markTestIncomplete("To perform the test this requires a valid installation and its respective license.");
|
||||
parent::setUp();
|
||||
$this->user = factory(User::class)->create();
|
||||
Groupwf::truncate();
|
||||
|
||||
$cached = ["jXsSi94bkRUcVZyRStNVExlTXhEclVadGRRcG9xbjNvTWVFQUF3cklKQVBiVT0=" => 1];
|
||||
Cache::put(PmLicenseManager::CACHE_KEY . '.' . config("system.workspace"), $cached, Carbon::now()->addDay(1));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -5,6 +5,7 @@ namespace Tests\unit\workflow\engine\src\ProcessMaker\Model;
|
||||
use Illuminate\Foundation\Testing\DatabaseTransactions;
|
||||
use ProcessMaker\Model\Application;
|
||||
use ProcessMaker\Model\Process;
|
||||
use ProcessMaker\Model\User;
|
||||
use Tests\TestCase;
|
||||
|
||||
/**
|
||||
@@ -16,10 +17,43 @@ class ApplicationTest extends TestCase
|
||||
{
|
||||
use DatabaseTransactions;
|
||||
|
||||
/**
|
||||
* Test belongs to APP_CUR_USER
|
||||
*
|
||||
* @covers \ProcessMaker\Model\Application::currentUser()
|
||||
* @test
|
||||
*/
|
||||
public function it_has_a_current_user()
|
||||
{
|
||||
$application = factory(Application::class)->create([
|
||||
'APP_CUR_USER' => function () {
|
||||
return factory(User::class)->create()->USR_UID;
|
||||
}
|
||||
]);
|
||||
$this->assertInstanceOf(User::class, $application->currentUser);
|
||||
}
|
||||
|
||||
/**
|
||||
* Test belongs to APP_INIT_USER
|
||||
*
|
||||
* @covers \ProcessMaker\Model\Application::creatorUser()
|
||||
* @test
|
||||
*/
|
||||
public function it_has_a_init_user()
|
||||
{
|
||||
$application = factory(Application::class)->create([
|
||||
'APP_INIT_USER' => function () {
|
||||
return factory(User::class)->create()->USR_UID;
|
||||
}
|
||||
]);
|
||||
$this->assertInstanceOf(User::class, $application->creatoruser);
|
||||
}
|
||||
|
||||
/**
|
||||
* This checks if return the columns used
|
||||
*
|
||||
* @covers \ProcessMaker\Model\Application::getByProUid()
|
||||
* @covers \ProcessMaker\Model\Application::scopeProUid()
|
||||
* @test
|
||||
*/
|
||||
public function it_return_cases_by_process()
|
||||
@@ -36,6 +70,7 @@ class ApplicationTest extends TestCase
|
||||
* This checks if return the columns used
|
||||
*
|
||||
* @covers \ProcessMaker\Model\Application::getCase()
|
||||
* @covers \ProcessMaker\Model\Application::scopeAppUid()
|
||||
* @test
|
||||
*/
|
||||
public function it_return_case_information()
|
||||
@@ -45,4 +80,34 @@ class ApplicationTest extends TestCase
|
||||
$this->assertArrayHasKey('APP_STATUS', $result);
|
||||
$this->assertArrayHasKey('APP_INIT_USER', $result);
|
||||
}
|
||||
|
||||
/**
|
||||
* This checks if the columns was updated correctly
|
||||
*
|
||||
* @covers \ProcessMaker\Model\Application::updateColumns()
|
||||
* @test
|
||||
*/
|
||||
public function it_update_columns()
|
||||
{
|
||||
// No column will be updated
|
||||
$application = factory(Application::class)->create();
|
||||
$result = Application::updateColumns($application->APP_UID, []);
|
||||
$this->isEmpty($result);
|
||||
|
||||
// Tried to update APP_ROUTING_DATA
|
||||
$application = factory(Application::class)->create();
|
||||
$result = Application::updateColumns($application->APP_UID, ['APP_ROUTING_DATA' => '']);
|
||||
$this->assertArrayHasKey('APP_ROUTING_DATA', $result);
|
||||
|
||||
// We can not update with a empty user
|
||||
$application = factory(Application::class)->create();
|
||||
$result = Application::updateColumns($application->APP_UID, ['APP_CUR_USER' => '']);
|
||||
$this->assertArrayNotHasKey('APP_CUR_USER', $result);
|
||||
|
||||
// Tried to update APP_CUR_USER
|
||||
$application = factory(Application::class)->create();
|
||||
$result = Application::updateColumns($application->APP_UID, ['APP_CUR_USER' => '00000000000000000000000000000001']);
|
||||
$this->assertArrayHasKey('APP_CUR_USER', $result);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1,11 +1,6 @@
|
||||
<?php
|
||||
namespace Tests\unit\workflow\src\ProcessMaker\Model;
|
||||
|
||||
use ProcessMaker\Model\AppAssignSelfServiceValue;
|
||||
use ProcessMaker\Model\AppAssignSelfServiceValueGroup;
|
||||
use ProcessMaker\Model\Application;
|
||||
use ProcessMaker\Model\GroupUser;
|
||||
use ProcessMaker\Model\Groupwf;
|
||||
use ProcessMaker\Model\ListUnassigned;
|
||||
use ProcessMaker\Model\Process;
|
||||
use ProcessMaker\Model\ProcessCategory;
|
||||
@@ -14,686 +9,172 @@ use ProcessMaker\Model\TaskUser;
|
||||
use ProcessMaker\Model\User;
|
||||
use Tests\TestCase;
|
||||
|
||||
/**
|
||||
* Class ListUnassignedTest
|
||||
*
|
||||
* @coversDefaultClass \ProcessMaker\Model\ListUnassigned
|
||||
*/
|
||||
class ListUnassignedTest extends TestCase
|
||||
{
|
||||
/**
|
||||
* This is using instead of DatabaseTransactions
|
||||
* @todo DatabaseTransactions is having conflicts with propel
|
||||
*/
|
||||
protected function setUp()
|
||||
{
|
||||
$this->markTestIncomplete();//@todo: Please correct this unit test
|
||||
}
|
||||
|
||||
/**
|
||||
* This checks the counters is working properly in self-service user assigned
|
||||
* @covers ListUnassigned::doCount
|
||||
* @test
|
||||
*/
|
||||
public function it_should_count_cases_by_user_with_self_service_user_assigned()
|
||||
{
|
||||
//Create process
|
||||
$process = factory(Process::class)->create();
|
||||
//Create user
|
||||
$user = factory(User::class)->create();
|
||||
//Create a task self service
|
||||
$task = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE',
|
||||
'TAS_GROUP_VARIABLE' => '',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
//Assign a user in the task
|
||||
factory(TaskUser::class)->create([
|
||||
'TAS_UID' => $task->TAS_UID,
|
||||
'USR_UID' => $user->USR_UID,
|
||||
'TU_RELATION' => 1, //Related to the user
|
||||
'TU_TYPE' => 1
|
||||
]);
|
||||
//Create the register in list unassigned
|
||||
factory(ListUnassigned::class, 25)->create([
|
||||
'TAS_ID' => $task->TAS_ID
|
||||
]);
|
||||
//Review the count self-service
|
||||
$result = ListUnassigned::countSelfService($user->USR_UID);
|
||||
$this->assertEquals(25, $result);
|
||||
}
|
||||
|
||||
/**
|
||||
* This checks the counters is working properly in self-service-value-based when the variable has a value related with the USR_UID
|
||||
* When the value assigned in the variable @@ARRAY_OF_USERS = [USR_UID]
|
||||
* @covers ListUnassigned::doCount
|
||||
* @test
|
||||
*/
|
||||
public function it_should_count_cases_by_user_with_self_service_value_based_usr_uid()
|
||||
{
|
||||
//Create process
|
||||
$process = factory(Process::class)->create();
|
||||
//Create a case
|
||||
$application = factory(Application::class)->create();
|
||||
//Create user
|
||||
$user = factory(User::class)->create();
|
||||
//Create a task self service value based
|
||||
$task = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE',
|
||||
'TAS_GROUP_VARIABLE' => '@@ARRAY_OF_USERS',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
//Create the relation for the value assigned in the TAS_GROUP_VARIABLE
|
||||
$appSelfValue = factory(AppAssignSelfServiceValue::class)->create([
|
||||
'APP_NUMBER' => $application->APP_NUMBER,
|
||||
'DEL_INDEX' => 2,
|
||||
'TAS_ID' => $task->TAS_ID
|
||||
]);
|
||||
factory(AppAssignSelfServiceValueGroup::class)->create([
|
||||
'ID' => $appSelfValue->ID,
|
||||
'GRP_UID' => $user->USR_UID,
|
||||
'ASSIGNEE_ID' => $user->USR_ID, //The usrId or grpId
|
||||
'ASSIGNEE_TYPE' => 1 //Related to the user=1 related to the group=2
|
||||
]);
|
||||
//Create the register in list unassigned
|
||||
factory(ListUnassigned::class, 25)->create([
|
||||
'APP_NUMBER' => $application->APP_NUMBER,
|
||||
'DEL_INDEX' => $appSelfValue->DEL_INDEX,
|
||||
'TAS_ID' => $task->TAS_ID,
|
||||
]);
|
||||
//Review the count self-service
|
||||
$result = ListUnassigned::countSelfService($user->USR_UID);
|
||||
$this->assertEquals(25, $result);
|
||||
}
|
||||
|
||||
/**
|
||||
* This checks the counters is working properly in self-service and self-service value based
|
||||
* @covers ListUnassigned::doCount
|
||||
* @test
|
||||
*/
|
||||
public function it_should_count_cases_by_user_with_self_service_mixed_with_self_service_value_based()
|
||||
{
|
||||
//Create process
|
||||
$process = factory(Process::class)->create();
|
||||
//Create a case
|
||||
$application = factory(Application::class)->create();
|
||||
//Create user
|
||||
$user = factory(User::class)->create();
|
||||
//Create a task self service
|
||||
$task = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE',
|
||||
'TAS_GROUP_VARIABLE' => '',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
//Assign a user in the task
|
||||
factory(TaskUser::class)->create([
|
||||
'TAS_UID' => $task->TAS_UID,
|
||||
'USR_UID' => $user->USR_UID,
|
||||
'TU_RELATION' => 1, //Related to the user
|
||||
'TU_TYPE' => 1
|
||||
]);
|
||||
//Create the register in self service
|
||||
factory(ListUnassigned::class, 15)->create([
|
||||
'TAS_ID' => $task->TAS_ID
|
||||
]);
|
||||
//Create a task self service value based
|
||||
$task1 = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE',
|
||||
'TAS_GROUP_VARIABLE' => '@@ARRAY_OF_USERS',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
//Create the relation for the value assigned in the TAS_GROUP_VARIABLE
|
||||
$appSelfValue = factory(AppAssignSelfServiceValue::class)->create([
|
||||
'APP_NUMBER' => $application->APP_NUMBER,
|
||||
'DEL_INDEX' => 2,
|
||||
'TAS_ID' => $task1->TAS_ID
|
||||
]);
|
||||
factory(AppAssignSelfServiceValueGroup::class)->create([
|
||||
'ID' => $appSelfValue->ID,
|
||||
'GRP_UID' => $user->USR_UID,
|
||||
'ASSIGNEE_ID' => $user->USR_ID, //The usrId or grpId
|
||||
'ASSIGNEE_TYPE' => 1 //Related to the user=1 related to the group=2
|
||||
]);
|
||||
//Create the register in self service value based
|
||||
factory(ListUnassigned::class, 15)->create([
|
||||
'APP_NUMBER' => $application->APP_NUMBER,
|
||||
'DEL_INDEX' => $appSelfValue->DEL_INDEX,
|
||||
'TAS_ID' => $task->TAS_ID,
|
||||
]);
|
||||
//Review the count self-service
|
||||
$result = ListUnassigned::countSelfService($user->USR_UID);
|
||||
$this->assertEquals(30, $result);
|
||||
}
|
||||
|
||||
/**
|
||||
* This checks the counters is working properly in self-service group assigned
|
||||
* @covers ListUnassigned::doCount
|
||||
* @test
|
||||
*/
|
||||
public function it_should_count_cases_by_user_with_self_service_group_assigned()
|
||||
{
|
||||
//Create process
|
||||
$process = factory(Process::class)->create();
|
||||
//Create group
|
||||
$group = factory(Groupwf::class)->create();
|
||||
//Create user
|
||||
$user = factory(User::class)->create();
|
||||
//Assign a user in the group
|
||||
factory(GroupUser::class)->create([
|
||||
'GRP_UID' => $group->GRP_UID,
|
||||
'GRP_ID' => $group->GRP_ID,
|
||||
'USR_UID' => $user->USR_UID
|
||||
]);
|
||||
//Create a task self service
|
||||
$task = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE',
|
||||
'TAS_GROUP_VARIABLE' => '',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
//Assign a user in the task
|
||||
factory(TaskUser::class)->create([
|
||||
'TAS_UID' => $task->TAS_UID,
|
||||
'USR_UID' => $user->USR_UID,
|
||||
'TU_RELATION' => 2, //Related to the group
|
||||
'TU_TYPE' => 1
|
||||
]);
|
||||
//Create the register in list unassigned
|
||||
factory(ListUnassigned::class, 25)->create([
|
||||
'TAS_ID' => $task->TAS_ID
|
||||
]);
|
||||
//Review the count self-service
|
||||
$result = ListUnassigned::countSelfService($user->USR_UID);
|
||||
$this->assertEquals(25, $result);
|
||||
}
|
||||
|
||||
/**
|
||||
* This checks the counters is working properly in self-service-value-based when the variable has a value related with the GRP_UID
|
||||
* When the value assigned in the variable @@ARRAY_OF_USERS = [GRP_UID]
|
||||
* @covers ListUnassigned::doCount
|
||||
* @test
|
||||
*/
|
||||
public function it_should_count_cases_by_user_with_self_service_value_based_grp_uid()
|
||||
{
|
||||
//Create process
|
||||
$process = factory(Process::class)->create();
|
||||
//Create a task self service value based
|
||||
$task = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE',
|
||||
'TAS_GROUP_VARIABLE' => '@@ARRAY_OF_USERS',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
//Create a case
|
||||
$application = factory(Application::class)->create();
|
||||
//Create group
|
||||
$group = factory(Groupwf::class)->create();
|
||||
//Create user
|
||||
$user = factory(User::class)->create([
|
||||
'USR_USERNAME' => 'gary',
|
||||
'USR_LASTNAME' => 'Gary',
|
||||
'USR_FIRSTNAME' => 'Bailey',
|
||||
]);
|
||||
//Assign a user in the group
|
||||
factory(GroupUser::class)->create([
|
||||
'GRP_UID' => $group->GRP_UID,
|
||||
'GRP_ID' => $group->GRP_ID,
|
||||
'USR_UID' => $user->USR_UID,
|
||||
]);
|
||||
//Create the relation for the value assigned in the TAS_GROUP_VARIABLE
|
||||
$appSelfValue = factory(AppAssignSelfServiceValue::class)->create([
|
||||
'APP_NUMBER' => $application->APP_NUMBER,
|
||||
'APP_UID' => $application->APP_UID,
|
||||
'DEL_INDEX' => 2,
|
||||
'TAS_ID' => $task->TAS_ID
|
||||
]);
|
||||
factory(AppAssignSelfServiceValueGroup::class)->create([
|
||||
'ID' => $appSelfValue->ID,
|
||||
'GRP_UID' => $group->GRP_UID,
|
||||
'ASSIGNEE_ID' => $group->GRP_ID, //The usrId or grpId
|
||||
'ASSIGNEE_TYPE' => 2 //Related to the user=1 related to the group=2
|
||||
]);
|
||||
//Create the register in list unassigned
|
||||
factory(ListUnassigned::class, 25)->create([
|
||||
'APP_NUMBER' => $application->APP_NUMBER,
|
||||
'DEL_INDEX' => 2,
|
||||
'TAS_ID' => $task->TAS_ID,
|
||||
]);
|
||||
//Review the count self-service
|
||||
$result = ListUnassigned::countSelfService($user->USR_UID);
|
||||
$this->assertEquals(25, $result);
|
||||
}
|
||||
|
||||
/**
|
||||
* This checks the counters is working properly in self-service user and group assigned in parallel task
|
||||
* @covers ListUnassigned::doCount
|
||||
* @test
|
||||
*/
|
||||
public function it_should_count_cases_by_user_with_self_service_user_and_group_assigned_parallel_task()
|
||||
{
|
||||
//Create process
|
||||
$process = factory(Process::class)->create();
|
||||
//Create group
|
||||
$group = factory(Groupwf::class)->create();
|
||||
//Create user
|
||||
$user = factory(User::class)->create();
|
||||
//Assign a user in the group
|
||||
factory(GroupUser::class)->create([
|
||||
'GRP_UID' => $group->GRP_UID,
|
||||
'GRP_ID' => $group->GRP_ID,
|
||||
'USR_UID' => $user->USR_UID
|
||||
]);
|
||||
//Create a task self service
|
||||
$task1 = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE',
|
||||
'TAS_GROUP_VARIABLE' => '',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
//Assign a user in the task1
|
||||
factory(TaskUser::class)->create([
|
||||
'TAS_UID' => $task1->TAS_UID,
|
||||
'USR_UID' => $user->USR_UID,
|
||||
'TU_RELATION' => 1, //Related to the user
|
||||
'TU_TYPE' => 1
|
||||
]);
|
||||
//Create a task self service
|
||||
$task2 = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE',
|
||||
'TAS_GROUP_VARIABLE' => '',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
//Assign a user in the task2
|
||||
factory(TaskUser::class)->create([
|
||||
'TAS_UID' => $task2->TAS_UID,
|
||||
'USR_UID' => $user->USR_UID,
|
||||
'TU_RELATION' => 1, //Related to the user
|
||||
'TU_TYPE' => 1
|
||||
]);
|
||||
//Create a task self service
|
||||
$task3 = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE',
|
||||
'TAS_GROUP_VARIABLE' => '',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
//Assign a user in the task
|
||||
factory(TaskUser::class)->create([
|
||||
'TAS_UID' => $task3->TAS_UID,
|
||||
'USR_UID' => $group->GRP_UID,
|
||||
'TU_RELATION' => 2, //Related to the group
|
||||
'TU_TYPE' => 1
|
||||
]);
|
||||
//Create a task self service
|
||||
$task4 = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE',
|
||||
'TAS_GROUP_VARIABLE' => '',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
//Assign a user in the task
|
||||
factory(TaskUser::class)->create([
|
||||
'TAS_UID' => $task4->TAS_UID,
|
||||
'USR_UID' => $group->GRP_UID,
|
||||
'TU_RELATION' => 2, //Related to the group
|
||||
'TU_TYPE' => 1
|
||||
]);
|
||||
//Create the register in list unassigned related to the task1
|
||||
factory(ListUnassigned::class, 10)->create([
|
||||
'TAS_ID' => $task1->TAS_ID
|
||||
]);
|
||||
//Create the register in list unassigned related to the task2
|
||||
factory(ListUnassigned::class, 10)->create([
|
||||
'TAS_ID' => $task2->TAS_ID
|
||||
]);
|
||||
//Create the register in list unassigned related to the task3
|
||||
factory(ListUnassigned::class, 10)->create([
|
||||
'TAS_ID' => $task3->TAS_ID
|
||||
]);
|
||||
//Create the register in list unassigned related to the task4
|
||||
factory(ListUnassigned::class, 10)->create([
|
||||
'TAS_ID' => $task4->TAS_ID
|
||||
]);
|
||||
//Review the count self-service
|
||||
$result = ListUnassigned::countSelfService($user->USR_UID);
|
||||
$this->assertEquals(40, $result);
|
||||
}
|
||||
|
||||
/**
|
||||
* This checks the counters is working properly in self-service-value-based with GRP_UID and USR_UID in parallel task
|
||||
* When the value assigned in the variable @@ARRAY_OF_USERS = [GRP_UID, USR_UID]
|
||||
* @covers ListUnassigned::doCount
|
||||
* @test
|
||||
*/
|
||||
public function it_should_count_cases_by_user_with_self_service_value_based_usr_uid_and_grp_uid()
|
||||
{
|
||||
//Create process
|
||||
$process = factory(Process::class)->create();
|
||||
//Create a case
|
||||
$application = factory(Application::class)->create();
|
||||
//Create user
|
||||
$user = factory(User::class)->create();
|
||||
//Create a task1 self service value based
|
||||
$task1 = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE',
|
||||
'TAS_GROUP_VARIABLE' => '@@ARRAY_OF_USERS',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
//Create the relation for the value assigned in the TAS_GROUP_VARIABLE
|
||||
$appSelfValue = factory(AppAssignSelfServiceValue::class)->create([
|
||||
'APP_NUMBER' => $application->APP_NUMBER,
|
||||
'TAS_ID' => $task1->TAS_ID
|
||||
]);
|
||||
factory(AppAssignSelfServiceValueGroup::class)->create([
|
||||
'ID' => $appSelfValue->ID,
|
||||
'GRP_UID' => $user->USR_UID,
|
||||
'ASSIGNEE_ID' => $user->USR_ID, //The usrId or grpId
|
||||
'ASSIGNEE_TYPE' => 1 //Related to the user=1 related to the group=2
|
||||
]);
|
||||
//Create the register in list unassigned
|
||||
factory(ListUnassigned::class, 15)->create([
|
||||
'APP_NUMBER' => $application->APP_NUMBER,
|
||||
'DEL_INDEX' => $appSelfValue->DEL_INDEX,
|
||||
'TAS_ID' => $task1->TAS_ID,
|
||||
]);
|
||||
//Create a task2 self service value based
|
||||
$task2 = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE',
|
||||
'TAS_GROUP_VARIABLE' => '@@ARRAY_OF_USERS',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
//Create the relation for the value assigned in the TAS_GROUP_VARIABLE
|
||||
$appSelfValue = factory(AppAssignSelfServiceValue::class)->create([
|
||||
'APP_NUMBER' => $application->APP_NUMBER,
|
||||
'TAS_ID' => $task2->TAS_ID
|
||||
]);
|
||||
factory(AppAssignSelfServiceValueGroup::class)->create([
|
||||
'ID' => $appSelfValue->ID,
|
||||
'GRP_UID' => $user->USR_UID,
|
||||
'ASSIGNEE_ID' => $user->USR_ID, //The usrId or grpId
|
||||
'ASSIGNEE_TYPE' => 1 //Related to the user=1 related to the group=2
|
||||
]);
|
||||
//Create the register in list unassigned
|
||||
factory(ListUnassigned::class, 15)->create([
|
||||
'APP_NUMBER' => $application->APP_NUMBER,
|
||||
'DEL_INDEX' => $appSelfValue->DEL_INDEX,
|
||||
'TAS_ID' => $task2->TAS_ID,
|
||||
]);
|
||||
//Review the count self-service
|
||||
$result = ListUnassigned::countSelfService($user->USR_UID);
|
||||
$this->assertEquals(30, $result);
|
||||
}
|
||||
|
||||
/**
|
||||
* This checks to make sure pagination is working properly
|
||||
*
|
||||
* @covers ListUnassigned::loadList
|
||||
* @test
|
||||
*/
|
||||
public function it_should_return_pages_of_data()
|
||||
{
|
||||
//Create process
|
||||
$process = factory(Process::class)->create();
|
||||
//Create user
|
||||
$user = factory(User::class)->create();
|
||||
//Create a task self service
|
||||
$task = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE',
|
||||
'TAS_GROUP_VARIABLE' => '',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
//Assign a user in the task
|
||||
for ($x = 1; $x <= 5; $x++) {
|
||||
$list = factory(ListUnassigned::class)->states('foreign_keys')->create();
|
||||
factory(TaskUser::class)->create([
|
||||
'TAS_UID' => $task->TAS_UID,
|
||||
'TAS_UID' => $list->TAS_UID,
|
||||
'USR_UID' => $user->USR_UID,
|
||||
'TU_RELATION' => 1, //Related to the user
|
||||
'TU_TYPE' => 1
|
||||
]);
|
||||
//Create the register in list unassigned
|
||||
factory(ListUnassigned::class, 51)->create([
|
||||
'TAS_ID' => $task->TAS_ID
|
||||
]);
|
||||
}
|
||||
|
||||
// Define the filters
|
||||
$filters = ['start' => 0, 'limit' => 25];
|
||||
$filters = ['start' => 0, 'limit' => 2];
|
||||
// Get data first page
|
||||
$result = ListUnassigned::loadList($user->USR_UID, $filters);
|
||||
$this->assertCount(25, $result);
|
||||
$this->assertCount(2, $result);
|
||||
// Get data second page
|
||||
$filters = ['start' => 25, 'limit' => 25];
|
||||
$filters = ['start' => 2, 'limit' => 2];
|
||||
$result = ListUnassigned::loadList($user->USR_UID, $filters);
|
||||
$this->assertCount(25, $result);
|
||||
$this->assertCount(2, $result);
|
||||
// Get data third page
|
||||
$filters = ['start' => 50, 'limit' => 25];
|
||||
$filters = ['start' => 4, 'limit' => 2];
|
||||
$result = ListUnassigned::loadList($user->USR_UID, $filters);
|
||||
$this->assertCount(1, $result);
|
||||
}
|
||||
|
||||
/**
|
||||
* This ensures ordering ascending and descending works by case number APP_NUMBER
|
||||
*
|
||||
* @covers ListUnassigned::loadList
|
||||
* @test
|
||||
*/
|
||||
public function it_should_sort_by_case_number()
|
||||
{
|
||||
//Create process
|
||||
$process = factory(Process::class)->create();
|
||||
//Create user
|
||||
$user = factory(User::class)->create();
|
||||
//Create a task self service
|
||||
$task = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE',
|
||||
'TAS_GROUP_VARIABLE' => '',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
//Assign a user in the task
|
||||
for ($x = 1; $x <= 5; $x++) {
|
||||
$list = factory(ListUnassigned::class)->states('foreign_keys')->create();
|
||||
factory(TaskUser::class)->create([
|
||||
'TAS_UID' => $task->TAS_UID,
|
||||
'TAS_UID' => $list->TAS_UID,
|
||||
'USR_UID' => $user->USR_UID,
|
||||
'TU_RELATION' => 1, //Related to the user
|
||||
'TU_TYPE' => 1
|
||||
]);
|
||||
//Create a case
|
||||
$application = factory(Application::class)->create([
|
||||
'APP_NUMBER' => 3000
|
||||
]);
|
||||
//Create the register in list unassigned
|
||||
factory(ListUnassigned::class)->create([
|
||||
'TAS_ID' => $task->TAS_ID,
|
||||
'APP_NUMBER' => $application->APP_NUMBER
|
||||
]);
|
||||
//Create a case
|
||||
$application = factory(Application::class)->create([
|
||||
'APP_NUMBER' => 2000
|
||||
]);
|
||||
//Create the register in list unassigned
|
||||
factory(ListUnassigned::class)->create([
|
||||
'TAS_ID' => $task->TAS_ID,
|
||||
'APP_NUMBER' => $application->APP_NUMBER
|
||||
]);
|
||||
}
|
||||
//Define the filters
|
||||
$filters = ['sort' => 'APP_NUMBER', 'dir' => 'ASC'];
|
||||
//Get data
|
||||
$result = ListUnassigned::loadList($user->USR_UID, $filters);
|
||||
$this->assertCount(2, $result);
|
||||
//Get the minor case number first
|
||||
$this->assertEquals(2000, $result[0]['APP_NUMBER']);
|
||||
//Get the major case number second
|
||||
$this->assertEquals(3000, $result[1]['APP_NUMBER']);
|
||||
$this->assertGreaterThan($result[0]['APP_NUMBER'], $result[1]['APP_NUMBER']);
|
||||
|
||||
//Define the filters
|
||||
$filters = ['sort' => 'APP_NUMBER', 'dir' => 'DESC'];
|
||||
//Get data
|
||||
$result = ListUnassigned::loadList($user->USR_UID, $filters);
|
||||
$this->assertCount(2, $result);
|
||||
//Get the major case number first
|
||||
$this->assertEquals(3000, $result[0]['APP_NUMBER']);
|
||||
//Get the minor case number second
|
||||
$this->assertEquals(2000, $result[1]['APP_NUMBER']);
|
||||
$this->assertGreaterThan($result[1]['APP_NUMBER'], $result[0]['APP_NUMBER']);
|
||||
}
|
||||
|
||||
/**
|
||||
* This ensures ordering ascending and descending works by case number APP_TITLE
|
||||
*
|
||||
* @covers ListUnassigned::loadList
|
||||
* @test
|
||||
*/
|
||||
public function it_should_sort_by_case_title()
|
||||
{
|
||||
//Create process
|
||||
$process = factory(Process::class)->create();
|
||||
//Create user
|
||||
$user = factory(User::class)->create();
|
||||
//Create a task self service
|
||||
$task = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE',
|
||||
'TAS_GROUP_VARIABLE' => '',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
//Assign a user in the task
|
||||
for ($x = 1; $x <= 5; $x++) {
|
||||
$list = factory(ListUnassigned::class)->states('foreign_keys')->create();
|
||||
factory(TaskUser::class)->create([
|
||||
'TAS_UID' => $task->TAS_UID,
|
||||
'TAS_UID' => $list->TAS_UID,
|
||||
'USR_UID' => $user->USR_UID,
|
||||
'TU_RELATION' => 1, //Related to the user
|
||||
'TU_TYPE' => 1
|
||||
]);
|
||||
//Create a case
|
||||
$application = factory(Application::class)->create([
|
||||
'APP_NUMBER' => 3001
|
||||
]);
|
||||
//Create the register in list unassigned
|
||||
factory(ListUnassigned::class)->create([
|
||||
'TAS_ID' => $task->TAS_ID,
|
||||
'APP_NUMBER' => $application->APP_NUMBER,
|
||||
'APP_TITLE' => 'Request nro ' . $application->APP_NUMBER,
|
||||
]);
|
||||
//Create a case
|
||||
$application = factory(Application::class)->create([
|
||||
'APP_NUMBER' => 2001
|
||||
]);
|
||||
//Create the register in list unassigned
|
||||
factory(ListUnassigned::class)->create([
|
||||
'TAS_ID' => $task->TAS_ID,
|
||||
'APP_NUMBER' => $application->APP_NUMBER,
|
||||
'APP_TITLE' => 'Request nro ' . $application->APP_NUMBER,
|
||||
]);
|
||||
}
|
||||
//Define the filters
|
||||
$filters = ['sort' => 'APP_TITLE', 'dir' => 'ASC'];
|
||||
//Get data
|
||||
$result = ListUnassigned::loadList($user->USR_UID, $filters);
|
||||
$this->assertCount(2, $result);
|
||||
//Get the minor case title first
|
||||
$this->assertEquals('Request nro 2001', $result[0]['APP_TITLE']);
|
||||
//Get the major case title second
|
||||
$this->assertEquals('Request nro 3001', $result[1]['APP_TITLE']);
|
||||
$this->assertGreaterThan($result[0]['APP_TITLE'], $result[1]['APP_TITLE']);
|
||||
|
||||
//Define the filters
|
||||
$filters = ['sort' => 'APP_TITLE', 'dir' => 'DESC'];
|
||||
//Get data
|
||||
$result = ListUnassigned::loadList($user->USR_UID, $filters);
|
||||
$this->assertCount(2, $result);
|
||||
//Get the major case title first
|
||||
$this->assertEquals('Request nro 3001', $result[0]['APP_TITLE']);
|
||||
//Get the minor case title second
|
||||
$this->assertEquals('Request nro 2001', $result[1]['APP_TITLE']);
|
||||
$this->assertGreaterThan($result[1]['APP_TITLE'], $result[0]['APP_TITLE']);
|
||||
}
|
||||
|
||||
/**
|
||||
* This ensures ordering ascending and descending works by case number APP_PRO_TITLE
|
||||
*
|
||||
* @covers ListUnassigned::loadList
|
||||
* @test
|
||||
*/
|
||||
public function it_should_sort_by_process()
|
||||
{
|
||||
//Create user
|
||||
$user = factory(User::class)->create();
|
||||
//Create process
|
||||
$process = factory(Process::class)->create();
|
||||
//Create a task self service
|
||||
$task = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE',
|
||||
'TAS_GROUP_VARIABLE' => '',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
//Assign a user in the task
|
||||
for ($x = 1; $x <= 5; $x++) {
|
||||
$list = factory(ListUnassigned::class)->states('foreign_keys')->create();
|
||||
factory(TaskUser::class)->create([
|
||||
'TAS_UID' => $task->TAS_UID,
|
||||
'TAS_UID' => $list->TAS_UID,
|
||||
'USR_UID' => $user->USR_UID,
|
||||
'TU_RELATION' => 1, //Related to the user
|
||||
'TU_TYPE' => 1
|
||||
]);
|
||||
//Create the register in list unassigned
|
||||
factory(ListUnassigned::class)->create([
|
||||
'TAS_ID' => $task->TAS_ID,
|
||||
'APP_PRO_TITLE' => 'Egypt Supplier Payment Proposal',
|
||||
]);
|
||||
|
||||
//Create the register in list unassigned
|
||||
factory(ListUnassigned::class)->create([
|
||||
'TAS_ID' => $task->TAS_ID,
|
||||
'APP_PRO_TITLE' => 'Russia Supplier Payment Proposal',
|
||||
]);
|
||||
}
|
||||
//Define the filters
|
||||
$filters = ['sort' => 'APP_PRO_TITLE', 'dir' => 'ASC'];
|
||||
//Get data
|
||||
$result = ListUnassigned::loadList($user->USR_UID, $filters);
|
||||
$this->assertCount(2, $result);
|
||||
//Get the minor process name first
|
||||
$this->assertEquals('Egypt Supplier Payment Proposal', $result[0]['APP_PRO_TITLE']);
|
||||
//Get the major process name second
|
||||
$this->assertEquals('Russia Supplier Payment Proposal', $result[1]['APP_PRO_TITLE']);
|
||||
$this->assertGreaterThan($result[0]['APP_PRO_TITLE'], $result[1]['APP_PRO_TITLE']);
|
||||
//Define the filters
|
||||
$filters = ['sort' => 'APP_PRO_TITLE', 'dir' => 'DESC'];
|
||||
//Get data
|
||||
$result = ListUnassigned::loadList($user->USR_UID, $filters);
|
||||
$this->assertCount(2, $result);
|
||||
//Get the major process name first
|
||||
$this->assertEquals('Russia Supplier Payment Proposal', $result[0]['APP_PRO_TITLE']);
|
||||
//Get the minor process name second
|
||||
$this->assertEquals('Egypt Supplier Payment Proposal', $result[1]['APP_PRO_TITLE']);
|
||||
$this->assertGreaterThan($result[1]['APP_PRO_TITLE'], $result[0]['APP_PRO_TITLE']);
|
||||
}
|
||||
|
||||
/**
|
||||
* This ensures ordering ascending and descending works by case number APP_TAS_TITLE
|
||||
*
|
||||
* @covers ListUnassigned::loadList
|
||||
* @test
|
||||
*/
|
||||
public function it_should_sort_by_task()
|
||||
{
|
||||
//Create user
|
||||
$user = factory(User::class)->create();
|
||||
//Create process
|
||||
$process = factory(Process::class)->create();
|
||||
//Create a task self service
|
||||
$task = factory(Task::class)->create([
|
||||
'TAS_ASSIGN_TYPE' => 'SELF_SERVICE',
|
||||
'TAS_GROUP_VARIABLE' => '',
|
||||
'PRO_UID' => $process->PRO_UID
|
||||
]);
|
||||
//Assign a user in the task
|
||||
for ($x = 1; $x <= 5; $x++) {
|
||||
$list = factory(ListUnassigned::class)->states('foreign_keys')->create();
|
||||
factory(TaskUser::class)->create([
|
||||
'TAS_UID' => $task->TAS_UID,
|
||||
'TAS_UID' => $list->TAS_UID,
|
||||
'USR_UID' => $user->USR_UID,
|
||||
'TU_RELATION' => 1, //Related to the user
|
||||
'TU_TYPE' => 1
|
||||
]);
|
||||
//Create the register in list unassigned
|
||||
factory(ListUnassigned::class)->create([
|
||||
'TAS_ID' => $task->TAS_ID,
|
||||
'APP_TAS_TITLE' => 'Initiate Request',
|
||||
]);
|
||||
//Create the register in list unassigned
|
||||
factory(ListUnassigned::class)->create([
|
||||
'TAS_ID' => $task->TAS_ID,
|
||||
'APP_TAS_TITLE' => 'Waiting for AP Manager Validation',
|
||||
]);
|
||||
}
|
||||
//Define the filters
|
||||
$filters = ['sort' => 'APP_TAS_TITLE', 'dir' => 'ASC'];
|
||||
//Get data
|
||||
$result = ListUnassigned::loadList($user->USR_UID, $filters);
|
||||
$this->assertCount(2, $result);
|
||||
//Get the minor task name first
|
||||
$this->assertEquals('Initiate Request', $result[0]['APP_TAS_TITLE']);
|
||||
//Get the major task name second
|
||||
$this->assertEquals('Waiting for AP Manager Validation', $result[1]['APP_TAS_TITLE']);
|
||||
$this->assertGreaterThan($result[0]['APP_TAS_TITLE'], $result[1]['APP_TAS_TITLE']);
|
||||
//Define the filters
|
||||
$filters = ['sort' => 'APP_TAS_TITLE', 'dir' => 'DESC'];
|
||||
//Get data
|
||||
$result = ListUnassigned::loadList($user->USR_UID, $filters);
|
||||
$this->assertCount(2, $result);
|
||||
//Get the major task name first
|
||||
$this->assertEquals('Waiting for AP Manager Validation', $result[0]['APP_TAS_TITLE']);
|
||||
//Get the minor task namesecond
|
||||
$this->assertEquals('Initiate Request', $result[1]['APP_TAS_TITLE']);
|
||||
$this->assertGreaterThan($result[1]['APP_TAS_TITLE'], $result[0]['APP_TAS_TITLE']);
|
||||
}
|
||||
|
||||
/**
|
||||
* This checks to make sure filter by category is working properly
|
||||
*
|
||||
* @covers ListUnassigned::loadList
|
||||
* @test
|
||||
*/
|
||||
@@ -752,6 +233,7 @@ class ListUnassignedTest extends TestCase
|
||||
|
||||
/**
|
||||
* This checks to make sure filter by category is working properly
|
||||
*
|
||||
* @covers ListUnassigned::loadList
|
||||
* @test
|
||||
*/
|
||||
|
||||
@@ -34,8 +34,6 @@ class LightTest extends TestCase
|
||||
*/
|
||||
protected function setUp()
|
||||
{
|
||||
$this->markTestIncomplete();//@todo: we need to correct this before the epic PMC-857 because this test use Unassigned cases
|
||||
|
||||
parent::setUp();
|
||||
$this->workspace = env("DB_DATABASE", "test");
|
||||
$this->clientId = config("oauthClients.pm.clientId");
|
||||
|
||||
@@ -15,24 +15,6 @@ class ProjectTest extends TestCase
|
||||
|
||||
public function setUp()
|
||||
{
|
||||
/**
|
||||
* To perform the test this requires a valid installation and its respective license.
|
||||
*
|
||||
* In the file "workflow/engine/classes/WorkspaceTools.php",
|
||||
* these lines need the db.php file.
|
||||
*
|
||||
* public function __construct($workspaceName)
|
||||
* {
|
||||
* $this->name = $workspaceName;
|
||||
* $this->path = PATH_DB . $this->name;
|
||||
* $this->dbPath = $this->path . '/db.php';
|
||||
* if ($this->workspaceExists()) {
|
||||
* $this->getDBInfo();
|
||||
* }
|
||||
* $this->setListContentMigrateTable();
|
||||
* }
|
||||
*/
|
||||
$this->markTestIncomplete("To perform the test this requires a valid installation and its respective license.");
|
||||
parent::setUp();
|
||||
$this->user = factory(User::class)->create();
|
||||
}
|
||||
@@ -45,7 +27,7 @@ class ProjectTest extends TestCase
|
||||
*/
|
||||
public function it_should_set_the_process_owner_with_invalid_value()
|
||||
{
|
||||
$filename = PATH_TRUNK . "/tests/resources/p1normal-1.pmx";
|
||||
$filename = PATH_TRUNK . "/tests/resources/p1normal-2.pmx";
|
||||
$importer = new XmlImporter();
|
||||
$importer->setData("usr_uid", $this->user->USR_UID);
|
||||
$importer->setSourceFile($filename);
|
||||
|
||||
@@ -2288,127 +2288,134 @@ class Cases
|
||||
* Get the next step
|
||||
*
|
||||
* @name getNextStep
|
||||
* @param string $sProUid
|
||||
* @param string $sAppUid
|
||||
* @param integer $iDelIndex
|
||||
* @param integer $iPosition
|
||||
* @param string $proUid
|
||||
* @param string $appUid
|
||||
* @param integer $delIndex
|
||||
* @param integer $position
|
||||
* @return array
|
||||
*/
|
||||
public function getNextStep($sProUid = '', $sAppUid = '', $iDelIndex = 0, $iPosition = 0)
|
||||
public function getNextStep($proUid = '', $appUid = '', $delIndex = 0, $position = 0)
|
||||
{
|
||||
$oPMScript = new PMScript();
|
||||
$oApplication = new Application();
|
||||
$aFields = $oApplication->Load($sAppUid);
|
||||
if (!is_array($aFields['APP_DATA'])) {
|
||||
$aFields['APP_DATA'] = G::array_merges(G::getSystemConstants(), unserialize($aFields['APP_DATA']));
|
||||
$pmScript = new PMScript();
|
||||
$application = new Application();
|
||||
$fields = $application->Load($appUid);
|
||||
$data = Cases::unserializeData($fields['APP_DATA']);
|
||||
unset($data['USER_LOGGED']);
|
||||
unset($data['USR_USERNAME']);
|
||||
|
||||
if (!is_array($fields['APP_DATA'])) {
|
||||
$fields['APP_DATA'] = G::array_merges(G::getSystemConstants(), $data);
|
||||
}
|
||||
$oPMScript->setFields($aFields['APP_DATA']);
|
||||
|
||||
$pmScript->setFields($fields['APP_DATA']);
|
||||
|
||||
try {
|
||||
//get the current Delegation, and TaskUID
|
||||
$c = new Criteria('workflow');
|
||||
$c->add(AppDelegationPeer::PRO_UID, $sProUid);
|
||||
$c->add(AppDelegationPeer::APP_UID, $sAppUid);
|
||||
$c->add(AppDelegationPeer::DEL_INDEX, $iDelIndex);
|
||||
$aRow = AppDelegationPeer::doSelect($c);
|
||||
$c->add(AppDelegationPeer::PRO_UID, $proUid);
|
||||
$c->add(AppDelegationPeer::APP_UID, $appUid);
|
||||
$c->add(AppDelegationPeer::DEL_INDEX, $delIndex);
|
||||
$rows = AppDelegationPeer::doSelect($c);
|
||||
|
||||
if (!isset($aRow[0])) {
|
||||
if (!isset($rows[0])) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$sTaskUid = $aRow[0]->getTasUid();
|
||||
$taskUid = $rows[0]->getTasUid();
|
||||
|
||||
//get max step for this task
|
||||
$c = new Criteria();
|
||||
$c->clearSelectColumns();
|
||||
$c->addSelectColumn('MAX(' . StepPeer::STEP_POSITION . ')');
|
||||
$c->add(StepPeer::PRO_UID, $sProUid);
|
||||
$c->add(StepPeer::TAS_UID, $sTaskUid);
|
||||
$c->add(StepPeer::PRO_UID, $proUid);
|
||||
$c->add(StepPeer::TAS_UID, $taskUid);
|
||||
$rs = StepPeer::doSelectRS($c);
|
||||
$rs->next();
|
||||
$row = $rs->getRow();
|
||||
$iLastStep = intval($row[0]);
|
||||
if ($iPosition != 10000 && $iPosition > $iLastStep) {
|
||||
throw (new Exception(G::LoadTranslation('ID_STEP_DOES_NOT_EXIST', array(G::LoadTranslation('ID_POSITION'), $iPosition))));
|
||||
$lastStep = intval($row[0]);
|
||||
if ($position != 10000 && $position > $lastStep) {
|
||||
throw (new Exception(G::LoadTranslation('ID_STEP_DOES_NOT_EXIST',
|
||||
[G::LoadTranslation('ID_POSITION'), $position])));
|
||||
}
|
||||
$iPosition += 1;
|
||||
$aNextStep = null;
|
||||
if ($iPosition <= $iLastStep) {
|
||||
while ($iPosition <= $iLastStep) {
|
||||
$bAccessStep = false;
|
||||
$position += 1;
|
||||
$nextStep = null;
|
||||
if ($position <= $lastStep) {
|
||||
while ($position <= $lastStep) {
|
||||
$accessStep = false;
|
||||
//step
|
||||
$oStep = new Step;
|
||||
$oStep = $oStep->loadByProcessTaskPosition($sProUid, $sTaskUid, $iPosition);
|
||||
if ($oStep) {
|
||||
if (trim($oStep->getStepCondition()) !== '') {
|
||||
$oPMScript->setScript($oStep->getStepCondition());
|
||||
$oPMScript->setExecutedOn(PMScript::CONDITION);
|
||||
$bAccessStep = $oPMScript->evaluate();
|
||||
$step = new Step;
|
||||
$step = $step->loadByProcessTaskPosition($proUid, $taskUid, $position);
|
||||
if ($step) {
|
||||
if (trim($step->getStepCondition()) !== '') {
|
||||
$pmScript->setScript($step->getStepCondition());
|
||||
$pmScript->setExecutedOn(PMScript::CONDITION);
|
||||
$accessStep = $pmScript->evaluate();
|
||||
} else {
|
||||
$bAccessStep = true;
|
||||
$accessStep = true;
|
||||
}
|
||||
if ($bAccessStep) {
|
||||
switch ($oStep->getStepTypeObj()) {
|
||||
if ($accessStep) {
|
||||
switch ($step->getStepTypeObj()) {
|
||||
case 'DYNAFORM':
|
||||
$sAction = 'EDIT';
|
||||
$action = 'EDIT';
|
||||
break;
|
||||
case 'OUTPUT_DOCUMENT':
|
||||
$sAction = 'GENERATE';
|
||||
$action = 'GENERATE';
|
||||
break;
|
||||
case 'INPUT_DOCUMENT':
|
||||
$sAction = 'ATTACH';
|
||||
$action = 'ATTACH';
|
||||
break;
|
||||
case 'EXTERNAL':
|
||||
$sAction = 'EDIT';
|
||||
$action = 'EDIT';
|
||||
break;
|
||||
case 'MESSAGE':
|
||||
$sAction = '';
|
||||
$action = '';
|
||||
break;
|
||||
}
|
||||
if (array_key_exists('gmail', $_SESSION) || (array_key_exists('gmail', $_GET) && $_GET['gmail'] == 1)) {
|
||||
$aNextStep = array(
|
||||
'TYPE' => $oStep->getStepTypeObj(),
|
||||
'UID' => $oStep->getStepUidObj(),
|
||||
'POSITION' => $oStep->getStepPosition(),
|
||||
'PAGE' => 'cases_Step?TYPE=' . $oStep->getStepTypeObj() . '&UID=' .
|
||||
$oStep->getStepUidObj() . '&POSITION=' . $oStep->getStepPosition() .
|
||||
'&ACTION=' . $sAction .
|
||||
if (array_key_exists('gmail', $_SESSION) || (array_key_exists('gmail',
|
||||
$_GET) && $_GET['gmail'] == 1)) {
|
||||
$nextStep = [
|
||||
'TYPE' => $step->getStepTypeObj(),
|
||||
'UID' => $step->getStepUidObj(),
|
||||
'POSITION' => $step->getStepPosition(),
|
||||
'PAGE' => 'cases_Step?TYPE=' . $step->getStepTypeObj() . '&UID=' .
|
||||
$step->getStepUidObj() . '&POSITION=' . $step->getStepPosition() .
|
||||
'&ACTION=' . $action .
|
||||
'&gmail=1'
|
||||
);
|
||||
];
|
||||
} else {
|
||||
$aNextStep = array(
|
||||
'TYPE' => $oStep->getStepTypeObj(),
|
||||
'UID' => $oStep->getStepUidObj(),
|
||||
'POSITION' => $oStep->getStepPosition(),
|
||||
'PAGE' => 'cases_Step?TYPE=' . $oStep->getStepTypeObj() . '&UID=' .
|
||||
$oStep->getStepUidObj() . '&POSITION=' . $oStep->getStepPosition() .
|
||||
'&ACTION=' . $sAction
|
||||
);
|
||||
$nextStep = [
|
||||
'TYPE' => $step->getStepTypeObj(),
|
||||
'UID' => $step->getStepUidObj(),
|
||||
'POSITION' => $step->getStepPosition(),
|
||||
'PAGE' => 'cases_Step?TYPE=' . $step->getStepTypeObj() . '&UID=' .
|
||||
$step->getStepUidObj() . '&POSITION=' . $step->getStepPosition() .
|
||||
'&ACTION=' . $action
|
||||
];
|
||||
}
|
||||
$iPosition = $iLastStep;
|
||||
$position = $lastStep;
|
||||
}
|
||||
}
|
||||
$iPosition += 1;
|
||||
$position += 1;
|
||||
}
|
||||
}
|
||||
if (!$aNextStep) {
|
||||
if (!$nextStep) {
|
||||
if (array_key_exists('gmail', $_SESSION) || (array_key_exists('gmail', $_GET) && $_GET['gmail'] == 1)) {
|
||||
$aNextStep = array(
|
||||
$nextStep = [
|
||||
'TYPE' => 'DERIVATION',
|
||||
'UID' => -1,
|
||||
'POSITION' => ($iLastStep + 1),
|
||||
'POSITION' => ($lastStep + 1),
|
||||
'PAGE' => 'cases_Step?TYPE=ASSIGN_TASK&UID=-1&POSITION=10000&ACTION=ASSIGN&gmail=1'
|
||||
);
|
||||
];
|
||||
} else {
|
||||
$aNextStep = array(
|
||||
$nextStep = [
|
||||
'TYPE' => 'DERIVATION',
|
||||
'UID' => -1,
|
||||
'POSITION' => ($iLastStep + 1),
|
||||
'POSITION' => ($lastStep + 1),
|
||||
'PAGE' => 'cases_Step?TYPE=ASSIGN_TASK&UID=-1&POSITION=10000&ACTION=ASSIGN'
|
||||
);
|
||||
];
|
||||
}
|
||||
}
|
||||
return $aNextStep;
|
||||
return $nextStep;
|
||||
} catch (exception $e) {
|
||||
throw ($e);
|
||||
}
|
||||
@@ -4402,6 +4409,7 @@ class Cases
|
||||
|
||||
$dataList = array_merge($caseFields, $dataList);
|
||||
$listCanceled = new ListCanceled();
|
||||
// This action requires interaction with IndicatorsCalculator class
|
||||
$listCanceled->create($dataList);
|
||||
/*----------------------------------********---------------------------------*/
|
||||
}
|
||||
|
||||
@@ -1,20 +1,27 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* Route case
|
||||
*/
|
||||
|
||||
use ProcessMaker\Model\Application as ModelApplication;
|
||||
|
||||
class Derivation
|
||||
{
|
||||
var $case;
|
||||
protected $appCurrentUser;
|
||||
protected $arraySiblings;
|
||||
protected $aSP;
|
||||
protected $context;
|
||||
protected $flagControl;
|
||||
protected $flagControlMulInstance;
|
||||
protected $sys;
|
||||
protected $context;
|
||||
protected $flagUpdateList;
|
||||
protected $iNewDelIndex;
|
||||
protected $regexpTaskTypeToInclude;
|
||||
protected $removeList;
|
||||
protected $sys;
|
||||
public $node;
|
||||
public $userLogged = null;
|
||||
protected $flagUpdateList;
|
||||
protected $removeList;
|
||||
protected $aSP;
|
||||
protected $iNewDelIndex;
|
||||
protected $arraySiblings;
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
@@ -888,7 +895,10 @@ class Derivation
|
||||
$aContext['appUid'] = $currentDelegation['APP_UID'];
|
||||
$aContext['delIndex'] = $currentDelegation['DEL_INDEX'];
|
||||
|
||||
// Remove the fields that will update with the thread creation
|
||||
unset($appFields['APP_ROUTING_DATA']);
|
||||
$this->appCurrentUser = $appFields['APP_CUR_USER'];
|
||||
unset($appFields['APP_CUR_USER']);
|
||||
|
||||
//We close the current derivation, then we'll try to derivate to each defined route
|
||||
$this->case->CloseCurrentDelegation( $currentDelegation['APP_UID'], $currentDelegation['DEL_INDEX'] );
|
||||
@@ -1237,6 +1247,7 @@ class Derivation
|
||||
$nextDel['DEL_PRIORITY'] = 3;
|
||||
}
|
||||
|
||||
$newDelegationUser = '';
|
||||
switch ($nextDel['TAS_ASSIGN_TYPE']) {
|
||||
case 'CANCEL_MI':
|
||||
case 'STATIC_MI':
|
||||
@@ -1266,12 +1277,14 @@ class Derivation
|
||||
$row = $criteriaMultiR->getRow();
|
||||
$delPrevious = $row['DEL_PREVIOUS'];
|
||||
}
|
||||
// Get the user that will create the new case
|
||||
$newDelegationUser = $this->verifyCurrentUserInTask($nextDel, $aSP);
|
||||
// Create new delegation
|
||||
$iNewDelIndex = $this->case->newAppDelegation(
|
||||
$appFields['PRO_UID'],
|
||||
$currentDelegation['APP_UID'],
|
||||
$nextDel['TAS_UID'],
|
||||
$this->verifyCurrentUserInTask($nextDel, $aSP),
|
||||
$newDelegationUser,
|
||||
$currentDelegation['DEL_INDEX'],
|
||||
$nextDel['DEL_PRIORITY'],
|
||||
$delType,
|
||||
@@ -1297,8 +1310,13 @@ class Derivation
|
||||
}
|
||||
}
|
||||
|
||||
$application = new Application();
|
||||
$result = $application->update(['APP_UID' => $currentDelegation['APP_UID'], 'APP_ROUTING_DATA' => serialize($arrayRoutingData)]);
|
||||
/** Update the table application */
|
||||
$applicationFields = [
|
||||
'APP_ROUTING_DATA' => $arrayRoutingData,
|
||||
'APP_CUR_USER' => $newDelegationUser
|
||||
];
|
||||
$colUpdated = ModelApplication::updateColumns($currentDelegation['APP_UID'], $applicationFields);
|
||||
$appFields['APP_CUR_USER'] = !empty($colUpdated['APP_CUR_USER']) ? $colUpdated['APP_CUR_USER'] : $this->appCurrentUser;
|
||||
|
||||
// We updated the information relate to APP_THREAD
|
||||
$iAppThreadIndex = $appFields['DEL_THREAD'];
|
||||
|
||||
@@ -766,32 +766,32 @@ class IndicatorsCalculator
|
||||
return $returnVal;
|
||||
}
|
||||
|
||||
public function suggestedTimeForTask($taskId)
|
||||
/**
|
||||
* Get some calculations related to the specific task
|
||||
* Returns population standard deviation of the expression from timeByTask/totalCase
|
||||
* Return the average from timeByTask/totalCase
|
||||
*
|
||||
* @param string $tasUid
|
||||
*
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
public function suggestedTimeForTask($tasUid)
|
||||
{
|
||||
$qryParams = array();
|
||||
$qryParams[':taskId'] = $taskId;
|
||||
$sqlString = 'select
|
||||
ROUND(AVG(TOTAL_TIME_BY_TASK/TOTAL_CASES_OUT), 2) as average,
|
||||
ROUND(STDDEV(TOTAL_TIME_BY_TASK/TOTAL_CASES_OUT), 2) as sdv
|
||||
from USR_REPORTING where TAS_UID = :taskId';
|
||||
$retval = $this->pdoExecutor($sqlString, $qryParams);
|
||||
return $retval[0];
|
||||
}
|
||||
try {
|
||||
$criteria = new Criteria('workflow');
|
||||
$criteria->addSelectColumn(UsrReportingPeer::TOTAL_CASES_OUT);
|
||||
$criteria->addAsColumn('average', 'ROUND(AVG(TOTAL_TIME_BY_TASK/TOTAL_CASES_OUT), 2)');
|
||||
$criteria->addAsColumn('sdv', 'ROUND(STDDEV(TOTAL_TIME_BY_TASK/TOTAL_CASES_OUT), 2)');
|
||||
$criteria->add(UsrReportingPeer::TAS_UID, $tasUid);
|
||||
$dataset = UsrReportingPeer::doSelectRS($criteria);
|
||||
$dataset->setFetchmode(ResultSet::FETCHMODE_ASSOC);
|
||||
$dataset->next();
|
||||
$result = $dataset->getRow();
|
||||
|
||||
|
||||
/* For debug only:
|
||||
* public function interpolateQuery($query, $params) {
|
||||
$keys = array();
|
||||
# build a regular expression for each parameter
|
||||
foreach ($params as $key => $value) {
|
||||
echo "<br>key", $key, " -- value", $value;
|
||||
if (is_string($key)) {
|
||||
$keys[] = '/:'.$key.'/';
|
||||
} else {
|
||||
$keys[] = '/[?]/';
|
||||
return $result;
|
||||
} catch (Exception $error) {
|
||||
throw $error;
|
||||
}
|
||||
}
|
||||
$query = preg_replace($keys, $params, $query, 1, $count);
|
||||
return $query;
|
||||
}*/
|
||||
}
|
||||
|
||||
@@ -111,6 +111,16 @@ class SpoolRun
|
||||
return $this->spoolId;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the fileData property
|
||||
*
|
||||
* @param array $fileData
|
||||
*/
|
||||
public function setFileData($fileData)
|
||||
{
|
||||
$this->fileData = $fileData;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the fileData property
|
||||
*
|
||||
@@ -674,42 +684,6 @@ class SpoolRun
|
||||
$this->updateSpoolError($error->getMessage());
|
||||
}
|
||||
break;
|
||||
case 'OPENMAIL':
|
||||
$pack = new package($this->fileData);
|
||||
$header = $pack->returnHeader();
|
||||
$body = $pack->returnBody();
|
||||
$send = new smtp();
|
||||
$send->setServer($this->config['MESS_SERVER']);
|
||||
$send->setPort($this->config['MESS_PORT']);
|
||||
$send->setUsername($this->config['MESS_ACCOUNT']);
|
||||
|
||||
$passwd = $this->config['MESS_PASSWORD'];
|
||||
$passwdDec = G::decrypt($passwd, 'EMAILENCRYPT');
|
||||
$auxPass = explode('hash:', $passwdDec);
|
||||
|
||||
if (count($auxPass) > 1) {
|
||||
if (count($auxPass) == 2) {
|
||||
$passwd = $auxPass[1];
|
||||
} else {
|
||||
array_shift($auxPass);
|
||||
$passwd = implode('', $auxPass);
|
||||
}
|
||||
}
|
||||
|
||||
$this->config['MESS_PASSWORD'] = $passwd;
|
||||
$send->setPassword($this->config['MESS_PASSWORD']);
|
||||
$send->setReturnPath($this->fileData['from_email']);
|
||||
$send->setHeaders($header);
|
||||
$send->setBody($body);
|
||||
$send->setEnvelopeTo($this->fileData['envelope_to']);
|
||||
if ($send->sendMessage()) {
|
||||
$this->error = '';
|
||||
$this->status = 'sent';
|
||||
} else {
|
||||
$this->error = implode(', ', $send->returnErrors());
|
||||
$this->status = 'failed';
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1007,10 +1007,21 @@ class WsBase
|
||||
|
||||
$result = "";
|
||||
if ($gmail != 1) {
|
||||
$closure = function() use ($setup, $messageArray, $gmail, $to) {
|
||||
// Create always the record in APP_MESSAGE table
|
||||
$spool = new SpoolRun();
|
||||
$spool->setConfig($setup);
|
||||
$spool->create($messageArray);
|
||||
|
||||
// Get the data of the record created
|
||||
$fileData = $spool->getFileData();
|
||||
$fileData['spoolId'] = $spool->getSpoolId();
|
||||
|
||||
// Create the closure and send the required data
|
||||
$closure = function() use ($setup, $fileData, $gmail, $to) {
|
||||
$spool = new SpoolRun();
|
||||
$spool->setConfig($setup);
|
||||
$spool->setSpoolId($fileData['spoolId']);
|
||||
$spool->setFileData($fileData);
|
||||
$spool->sendMail();
|
||||
return $spool;
|
||||
};
|
||||
|
||||
@@ -350,14 +350,9 @@ function executeQuery ($SqlStatement, $DBConnectionUID = 'workflow', $aParameter
|
||||
} catch (SQLException $sqle) {
|
||||
//Logger
|
||||
$aContext['action'] = 'execute-query';
|
||||
$aContext['exception'] = (array)$sqle;
|
||||
$aContext['SQLExceptionMessage'] = $sqle->getMessage();
|
||||
\Bootstrap::registerMonolog('sqlExecution', 400, 'Sql Execution', $aContext, $sysSys, 'processmaker.log');
|
||||
|
||||
if (isset($sqle->xdebug_message)) {
|
||||
error_log(print_r($sqle->xdebug_message, true));
|
||||
} else {
|
||||
error_log(print_r($sqle, true));
|
||||
}
|
||||
$con->rollback();
|
||||
throw $sqle;
|
||||
}
|
||||
|
||||
@@ -152,6 +152,7 @@ class AppDelay extends BaseAppDelay
|
||||
|
||||
/**
|
||||
* Build the row for the appDelay to be inserted
|
||||
* This function check the instance of RBAC
|
||||
*
|
||||
* @param string $proUid
|
||||
* @param integer $proId
|
||||
|
||||
@@ -111,6 +111,7 @@ class ListCanceled extends BaseListCanceled implements ListInterface
|
||||
}
|
||||
if (!empty($data['TAS_UID'])) {
|
||||
$t = new Task();
|
||||
// The load task gets some calculations related to the Indicators
|
||||
$data['TAS_ID'] = $t->load($data['TAS_UID'])['TAS_ID'];
|
||||
}
|
||||
$con = Propel::getConnection(ListCanceledPeer::DATABASE_NAME);
|
||||
|
||||
@@ -487,32 +487,38 @@ class Task extends BaseTask
|
||||
return $row;
|
||||
}
|
||||
|
||||
public function load($TasUid)
|
||||
/**
|
||||
* Load the properties related to the task
|
||||
*
|
||||
* @param string $tasUid
|
||||
*
|
||||
* @return array
|
||||
* @throws Exception
|
||||
*/
|
||||
public function load($tasUid)
|
||||
{
|
||||
try {
|
||||
$oRow = TaskPeer::retrieveByPK($TasUid);
|
||||
$rows = TaskPeer::retrieveByPK($tasUid);
|
||||
|
||||
if (!is_null($oRow)) {
|
||||
$aFields = $oRow->toArray(BasePeer::TYPE_FIELDNAME);
|
||||
|
||||
$this->fromArray($aFields, BasePeer::TYPE_FIELDNAME); //Populating an object from of the array
|
||||
if (!is_null($rows)) {
|
||||
$fields = $rows->toArray(BasePeer::TYPE_FIELDNAME);
|
||||
$this->fromArray($fields, BasePeer::TYPE_FIELDNAME); //Populating an object from of the array
|
||||
//Populating attributes
|
||||
$this->setNew(false);
|
||||
|
||||
/*----------------------------------********---------------------------------*/
|
||||
$indicator = new IndicatorsCalculator();
|
||||
$data = $indicator->suggestedTimeForTask($TasUid);
|
||||
$aFields["TAS_AVERAGE"] = $data['average'];
|
||||
$aFields["TAS_SDV"] = $data['sdv'];
|
||||
$data = $indicator->suggestedTimeForTask($tasUid);
|
||||
$fields["TAS_AVERAGE"] = $data['average'];
|
||||
$fields["TAS_SDV"] = $data['sdv'];
|
||||
/*----------------------------------********---------------------------------*/
|
||||
|
||||
///////
|
||||
return $aFields;
|
||||
return $fields;
|
||||
} else {
|
||||
throw (new Exception("The row '" . $TasUid . "' in table TASK doesn't exist!"));
|
||||
throw new Exception("The row '" . $tasUid . "' in table TASK doesn't exist!");
|
||||
}
|
||||
} catch (Exception $oError) {
|
||||
throw ($oError);
|
||||
} catch (Exception $error) {
|
||||
throw $error;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -15119,6 +15119,12 @@ msgstr "Error"
|
||||
msgid "Monthly"
|
||||
msgstr "Monthly"
|
||||
|
||||
# TRANSLATION
|
||||
# LABEL/ID_MAFE_90589c47f06eb971d548591f23c285af
|
||||
#: LABEL/ID_MAFE_90589c47f06eb971d548591f23c285af
|
||||
msgid "Custom"
|
||||
msgstr "Custom"
|
||||
|
||||
# TRANSLATION
|
||||
# LABEL/ID_MAFE_9060587edeb01a63e3d3edc959678d1e
|
||||
#: LABEL/ID_MAFE_9060587edeb01a63e3d3edc959678d1e
|
||||
@@ -18059,12 +18065,6 @@ msgstr "There are problems updating the Timer Event, please try again."
|
||||
msgid "Group or User"
|
||||
msgstr "Group or User"
|
||||
|
||||
# TRANSLATION
|
||||
# LABEL/ID_MAFE_f4b5974fd11406f8410fa7e8502a26a3
|
||||
#: LABEL/ID_MAFE_f4b5974fd11406f8410fa7e8502a26a3
|
||||
msgid "Granular"
|
||||
msgstr "Granular"
|
||||
|
||||
# TRANSLATION
|
||||
# LABEL/ID_MAFE_f4ee0932c0b3cdb0af6d4407fc915b28
|
||||
#: LABEL/ID_MAFE_f4ee0932c0b3cdb0af6d4407fc915b28
|
||||
|
||||
@@ -59371,6 +59371,7 @@ INSERT INTO TRANSLATION (TRN_CATEGORY,TRN_ID,TRN_LANG,TRN_VALUE,TRN_UPDATE_DATE
|
||||
( 'LABEL','ID_MAFE_8ff922bbcd8ad41cdfc48d3c5163b2ab','en','Calendar', NOW()) ,
|
||||
( 'LABEL','ID_MAFE_902b0d55fddef6f8d651fe1035b7d4bd','en','Error', NOW()) ,
|
||||
( 'LABEL','ID_MAFE_9030e39f00132d583da4122532e509e9','en','Monthly', NOW()) ,
|
||||
( 'LABEL','ID_MAFE_90589c47f06eb971d548591f23c285af','en','Custom', NOW()) ,
|
||||
( 'LABEL','ID_MAFE_9060587edeb01a63e3d3edc959678d1e','en','Before', NOW()) ,
|
||||
( 'LABEL','ID_MAFE_9119da1dd85e63663fb91ce63de56b09','en','Start Event: The process always begins with a start event.', NOW()) ,
|
||||
( 'LABEL','ID_MAFE_912ce77b9eb2aa7567125d574283747c','en','Assignment Rules saved successfully', NOW()) ,
|
||||
@@ -59871,7 +59872,6 @@ INSERT INTO TRANSLATION (TRN_CATEGORY,TRN_ID,TRN_LANG,TRN_VALUE,TRN_UPDATE_DATE
|
||||
( 'LABEL','ID_MAFE_f4636507ca93332f92f92fb219a43b02','en','Database Connection', NOW()) ,
|
||||
( 'LABEL','ID_MAFE_f49b52022300199128ed01380edda751','en','There are problems updating the Timer Event, please try again.', NOW()) ,
|
||||
( 'LABEL','ID_MAFE_f4ae7ce97eda9edfe1541b3fdea115b6','en','Group or User', NOW()) ,
|
||||
( 'LABEL','ID_MAFE_f4b5974fd11406f8410fa7e8502a26a3','en','Granular', NOW()) ,
|
||||
( 'LABEL','ID_MAFE_f4ee0932c0b3cdb0af6d4407fc915b28','en','The variable Name already exists.', NOW()) ,
|
||||
( 'LABEL','ID_MAFE_f4f33214dfca4a6aa8a15fff06c43ff5','en','One date/time', NOW()) ,
|
||||
( 'LABEL','ID_MAFE_f4f70727dc34561dfde1a3c529b6205c','en','Settings', NOW()) ,
|
||||
|
||||
@@ -190,6 +190,7 @@ class JobsManager
|
||||
$callback($environment);
|
||||
} catch (Exception $e) {
|
||||
Log::error($e->getMessage() . ": " . $e->getTraceAsString());
|
||||
throw $e;
|
||||
}
|
||||
});
|
||||
$instance->delay($this->delay);
|
||||
|
||||
@@ -350,7 +350,7 @@ class GmailOAuth
|
||||
{
|
||||
$templateTower = new TemplatePower(PATH_TPL . "admin" . PATH_SEP . "email.tpl");
|
||||
$templateTower->prepare();
|
||||
$templateTower->assign("server", System::getServerHostname());
|
||||
$templateTower->assign("server", System::getServerProtocol() . System::getServerHost());
|
||||
$templateTower->assign("date", date("H:i:s"));
|
||||
$templateTower->assign("ver", System::getVersion());
|
||||
$templateTower->assign("engine", G::LoadTranslation("ID_MESS_ENGINE_TYPE_4"));
|
||||
|
||||
11
workflow/engine/src/ProcessMaker/Model/AppDelay.php
Normal file
11
workflow/engine/src/ProcessMaker/Model/AppDelay.php
Normal file
@@ -0,0 +1,11 @@
|
||||
<?php
|
||||
|
||||
namespace ProcessMaker\Model;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class AppDelay extends Model
|
||||
{
|
||||
protected $table = 'APP_DELAY';
|
||||
public $timestamps = false;
|
||||
}
|
||||
@@ -16,20 +16,22 @@ class Application extends Model
|
||||
return $this->hasMany(Delegation::class, 'APP_UID', 'APP_UID');
|
||||
}
|
||||
|
||||
public function parent()
|
||||
{
|
||||
return $this->hasOne(Application::class, 'APP_PARENT', 'APP_UID');
|
||||
}
|
||||
|
||||
public function currentUser()
|
||||
{
|
||||
return $this->hasOne(User::class, 'APP_CUR_USER', 'USR_UID');
|
||||
return $this->belongsTo(User::class, 'APP_CUR_USER', 'USR_UID');
|
||||
}
|
||||
|
||||
public function creatorUser()
|
||||
{
|
||||
return $this->belongsTo(User::class, 'APP_INIT_USER', 'USR_UID');
|
||||
}
|
||||
|
||||
/**
|
||||
* Scope for query to get the application by APP_UID.
|
||||
*
|
||||
* @param \Illuminate\Database\Eloquent\Builder $query
|
||||
* @param string $appUid
|
||||
*
|
||||
* @return \Illuminate\Database\Eloquent\Builder
|
||||
*/
|
||||
public function scopeAppUid($query, $appUid)
|
||||
@@ -85,4 +87,26 @@ class Application extends Model
|
||||
|
||||
return $firstElement;
|
||||
}
|
||||
|
||||
/**
|
||||
* Update properties
|
||||
*
|
||||
* @param string $appUid
|
||||
* @param array $fields
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public static function updateColumns($appUid, $fields)
|
||||
{
|
||||
$properties = [];
|
||||
$properties['APP_ROUTING_DATA'] = !empty($fields['APP_ROUTING_DATA']) ? serialize($fields['APP_ROUTING_DATA']) : serialize([]);
|
||||
|
||||
// This column will to update only when the thread is related to the user
|
||||
if (!empty($fields['APP_CUR_USER'])) {
|
||||
$properties['APP_CUR_USER'] = $fields['APP_CUR_USER'];
|
||||
}
|
||||
Application::query()->appUid($appUid)->update($properties);
|
||||
|
||||
return $properties;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -110,43 +110,6 @@ class ListUnassigned extends Model
|
||||
return $result;
|
||||
}
|
||||
|
||||
/**
|
||||
* Count the self-services cases by user
|
||||
*
|
||||
* @param string $usrUid
|
||||
*
|
||||
* @return integer
|
||||
*/
|
||||
public static function countSelfService($usrUid)
|
||||
{
|
||||
//Get the task self services related to the user
|
||||
$taskSelfService = TaskUser::getSelfServicePerUser($usrUid);
|
||||
//Get the task self services value based related to the user
|
||||
$selfServiceValueBased = AppAssignSelfServiceValue::getSelfServiceCasesByEvaluatePerUser($usrUid);
|
||||
|
||||
//Start the query for get the cases related to the user
|
||||
$query = ListUnassigned::query()->select('APP_NUMBER');
|
||||
|
||||
//Get the cases unassigned
|
||||
if (!empty($selfServiceValueBased)) {
|
||||
$query->where(function ($query) use ($selfServiceValueBased, $taskSelfService) {
|
||||
//Get the cases related to the task self service
|
||||
$query->tasksIn($taskSelfService);
|
||||
foreach ($selfServiceValueBased as $case) {
|
||||
//Get the cases related to the task self service value based
|
||||
$query->orWhere(function ($query) use ($case) {
|
||||
$query->case($case['APP_NUMBER'])->index($case['DEL_INDEX'])->task($case['TAS_ID']);
|
||||
});
|
||||
}
|
||||
});
|
||||
} else {
|
||||
//Get the cases related to the task self service
|
||||
$query->tasksIn($taskSelfService);
|
||||
}
|
||||
|
||||
return $query->count();
|
||||
}
|
||||
|
||||
/**
|
||||
* Search data
|
||||
*
|
||||
|
||||
@@ -12,6 +12,7 @@ class ProcessVariables extends Model
|
||||
public $timestamps = false;
|
||||
//primary key
|
||||
protected $primaryKey = 'VAR_UID';
|
||||
public $incrementing = false;
|
||||
|
||||
/**
|
||||
* Scope a query to filter an specific process
|
||||
|
||||
11
workflow/engine/src/ProcessMaker/Model/Step.php
Normal file
11
workflow/engine/src/ProcessMaker/Model/Step.php
Normal file
@@ -0,0 +1,11 @@
|
||||
<?php
|
||||
|
||||
namespace ProcessMaker\Model;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class Step extends Model
|
||||
{
|
||||
protected $table = "STEP";
|
||||
public $timestamps = false;
|
||||
}
|
||||
13
workflow/engine/src/ProcessMaker/Model/UserReporting.php
Normal file
13
workflow/engine/src/ProcessMaker/Model/UserReporting.php
Normal file
@@ -0,0 +1,13 @@
|
||||
<?php
|
||||
|
||||
|
||||
namespace ProcessMaker\Model;
|
||||
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
|
||||
class UserReporting extends Model
|
||||
{
|
||||
protected $table = "USR_REPORTING";
|
||||
public $timestamps = false;
|
||||
}
|
||||
@@ -1189,8 +1189,6 @@ var gridbb = new Ext.PagingToolbar({
|
||||
|
||||
var grid;
|
||||
var getGrid = function( data, element) {
|
||||
// var grid = Ext.getCmp('gridpanel');
|
||||
|
||||
grid = new Ext.grid.GridPanel({
|
||||
store: datastore,
|
||||
cm: cm,
|
||||
@@ -1375,18 +1373,14 @@ var cm = new Ext.grid.ColumnModel([
|
||||
//By default columns are sortable
|
||||
cm.defaultSortable = true;
|
||||
|
||||
function handleRowClick(sm, rowIndex) {//alert(rowIndex);
|
||||
//console.log("Row Clicked: ", rowIndex);
|
||||
function handleRowClick(sm, rowIndex) {
|
||||
var selections = sm.getSelections();
|
||||
tb = ext_itemgrid.getTopToolbar();
|
||||
if (selections.length > 1) {
|
||||
//tb.items.get('tb_delete').enable();
|
||||
tb.items.get('tb_delete')[permitodelete==1 ? 'enable': 'disable']();
|
||||
tb.items.get('tb_rename').disable();
|
||||
tb.items.get('tb_download').hide();
|
||||
//tb.items.get('tb_download').disable();
|
||||
} else if (selections.length == 1) {
|
||||
//tb.items.get('tb_delete')[selections[0].get('is_deletable') ? 'enable': 'disable']();
|
||||
tb.items.get('tb_delete')[permitodelete==1 ? 'enable': 'disable']();
|
||||
tb.items.get('tb_rename')[selections[0].get('is_deletable') ? 'disable': 'disable']();
|
||||
tb.items.get('tb_download')[selections[0].get('is_readable')
|
||||
@@ -1888,34 +1882,20 @@ var documentsTab = {
|
||||
}
|
||||
},
|
||||
{
|
||||
// region : "center",
|
||||
// layout:'fit',
|
||||
// items : [ {
|
||||
region : "center",
|
||||
// xtype : "tabpanel",
|
||||
layout:'fit',
|
||||
id : "mainpanel",
|
||||
// autoHeight : true,
|
||||
// enableTabScroll : true,
|
||||
// activeTab : 0,
|
||||
// hideTabStripItem:0,
|
||||
items : [ {
|
||||
xtype : "editorgrid",
|
||||
layout:'fit',
|
||||
region : "center",
|
||||
// title : "Documents",
|
||||
// autoHeight : true,
|
||||
// autoScroll : true,
|
||||
// collapsible : false,
|
||||
// closeOnTab : true,
|
||||
id : "gridpanel",
|
||||
ds : datastore,
|
||||
cm : cm,
|
||||
tbar : gridtb,
|
||||
bbar : gridbb,
|
||||
ddGroup : 'TreeDD',
|
||||
enableDragDrop: true,
|
||||
//plugins: expander,
|
||||
enableDragDrop: false,
|
||||
plugins: rowExpander,
|
||||
selModel : new Ext.grid.RowSelectionModel({
|
||||
listeners : {
|
||||
|
||||
@@ -310,6 +310,8 @@ emailServer.application = {
|
||||
Ext.getCmp("txtIncomingServer").allowBlank = true;
|
||||
Ext.getCmp("txtIncomingPort").allowBlank = true;
|
||||
Ext.getCmp("txtAccountFrom").allowBlank = false;
|
||||
Ext.getCmp("textClientId").allowBlank = true;
|
||||
Ext.getCmp("textClientSecret").allowBlank = true;
|
||||
} else if (cboEmailEngine === "IMAP") {
|
||||
/*----------------------------------********---------------------------------*/
|
||||
Ext.getCmp("txtServer").setVisible(true);
|
||||
@@ -338,6 +340,8 @@ emailServer.application = {
|
||||
Ext.getCmp("txtIncomingServer").allowBlank = false;
|
||||
Ext.getCmp("txtIncomingPort").allowBlank = false;
|
||||
Ext.getCmp("txtAccountFrom").allowBlank = false;
|
||||
Ext.getCmp("textClientId").allowBlank = true;
|
||||
Ext.getCmp("textClientSecret").allowBlank = true;
|
||||
/*----------------------------------********---------------------------------*/
|
||||
} else if (cboEmailEngine === "GMAILAPI") {
|
||||
Ext.getCmp("txtServer").setVisible(false);
|
||||
@@ -362,6 +366,8 @@ emailServer.application = {
|
||||
Ext.getCmp("txtIncomingPort").allowBlank = true;
|
||||
Ext.getCmp("txtAccountFrom").allowBlank = false;
|
||||
Ext.getCmp("txtPassword").allowBlank = true;
|
||||
Ext.getCmp("textClientId").allowBlank = false;
|
||||
Ext.getCmp("textClientSecret").allowBlank = false;
|
||||
} else {
|
||||
//MAIL
|
||||
Ext.getCmp("txtServer").setVisible(false);
|
||||
@@ -383,6 +389,8 @@ emailServer.application = {
|
||||
Ext.getCmp("txtIncomingPort").allowBlank = true;
|
||||
Ext.getCmp("txtAccountFrom").allowBlank = true;
|
||||
Ext.getCmp("txtPassword").allowBlank = true;
|
||||
Ext.getCmp("textClientId").allowBlank = true;
|
||||
Ext.getCmp("textClientSecret").allowBlank = true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -798,12 +806,14 @@ emailServer.application = {
|
||||
var textClientId = new Ext.form.TextField({
|
||||
id: "textClientId",
|
||||
name: "textClientId",
|
||||
fieldLabel: _("ID_CLIENT_ID")
|
||||
fieldLabel: _("ID_CLIENT_ID"),
|
||||
allowBlank: false
|
||||
});
|
||||
var textClientSecret = new Ext.form.TextField({
|
||||
id: "textClientSecret",
|
||||
name: "textClientSecret",
|
||||
fieldLabel: _("ID_CLIENT_SECRET")
|
||||
fieldLabel: _("ID_CLIENT_SECRET"),
|
||||
allowBlank: false
|
||||
});
|
||||
var buttonContinue = new Ext.Action({
|
||||
id: 'buttonContinue',
|
||||
|
||||
Reference in New Issue
Block a user