Test Setup Failed
Pull Request — master (#190)
by
unknown
12:55 queued 03:21
created
lib/org/openpsa/projects/project.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -231,7 +231,7 @@
 block discarded – undo
231 231
             $new_status = $this->_find_status($this->_status_map[$this->status_type], $status_types);
232 232
         }
233 233
 
234
-        if (   !is_null($new_status)
234
+        if (!is_null($new_status)
235 235
             && $this->status != $new_status) {
236 236
             $this->status = $new_status;
237 237
             $update_required = true;
Please login to merge, or discard this patch.
lib/org/openpsa/projects/status.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -68,7 +68,7 @@
 block discarded – undo
68 68
             $status_changer_label = $this->l10n->get('system');
69 69
             $target_person_label = $this->l10n->get('system');
70 70
 
71
-            if (    $status_change->metadata->creator
71
+            if ($status_change->metadata->creator
72 72
                  && $status_change->metadata->creator != $fallback_creator->guid) {
73 73
                 $status_changer = org_openpsa_widgets_contact::get($status_change->metadata->creator);
74 74
                 $status_changer_label = $status_changer->show_inline();
Please login to merge, or discard this patch.
lib/org/openpsa/mypage/handler/workingon.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -152,7 +152,7 @@
 block discarded – undo
152 152
         // Set the "now working on" status
153 153
         $workingon = new org_openpsa_mypage_workingon();
154 154
         if (!$workingon->set($_POST['task'])) {
155
-            midcom::get()->uimessages->add($this->_l10n->get('org.openpsa.mypage'),  'Failed to set "working on" parameter to "' . $_POST['task'] . '", reason ' . midcom_connection::get_error_string(), 'error');
155
+            midcom::get()->uimessages->add($this->_l10n->get('org.openpsa.mypage'), 'Failed to set "working on" parameter to "' . $_POST['task'] . '", reason ' . midcom_connection::get_error_string(), 'error');
156 156
         }
157 157
 
158 158
         return new midcom_response_relocate($relocate . "workingon/");
Please login to merge, or discard this patch.
lib/org/openpsa/sales/salesproject/deliverable.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
     {
55 55
         $this->calculate_price(false);
56 56
 
57
-        if (   $this->orgOpenpsaObtype == org_openpsa_products_product_dba::DELIVERY_SUBSCRIPTION
57
+        if ($this->orgOpenpsaObtype == org_openpsa_products_product_dba::DELIVERY_SUBSCRIPTION
58 58
             && $this->continuous == true) {
59 59
             $this->end = 0;
60 60
         } elseif ($this->end < $this->start) {
@@ -140,7 +140,7 @@  discard block
 block discarded – undo
140 140
         $calculator->run($this);
141 141
         $cost = $calculator->get_cost();
142 142
         $price = $calculator->get_price();
143
-        if (   $price != $this->price
143
+        if ($price != $this->price
144 144
             || $cost != $this->cost) {
145 145
             $this->price = $price;
146 146
             $this->cost = $cost;
@@ -187,7 +187,7 @@  discard block
 block discarded – undo
187 187
         $units = $agreement_hours['invoiceable'];
188 188
         $uninvoiceableUnits = $agreement_hours['reported'] - ($agreement_hours['invoiceable'] + $agreement_hours['invoiced']);
189 189
 
190
-        if (   $units != $this->units
190
+        if ($units != $this->units
191 191
             || $uninvoiceableUnits != $this->uninvoiceableUnits) {
192 192
             debug_add("agreement values have changed, setting units to " . $units . ", uninvoiceable: " . $uninvoiceableUnits);
193 193
             $this->units = $units;
@@ -242,7 +242,7 @@  discard block
 block discarded – undo
242 242
 
243 243
     public function invoice()
244 244
     {
245
-        if (   $this->state >= self::STATE_INVOICED
245
+        if ($this->state >= self::STATE_INVOICED
246 246
             || $this->orgOpenpsaObtype == org_openpsa_products_product_dba::DELIVERY_SUBSCRIPTION) {
247 247
             return false;
248 248
         }
Please login to merge, or discard this patch.
lib/org/openpsa/sales/handler/deliverable/admin.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -54,7 +54,7 @@  discard block
 block discarded – undo
54 54
         $this->_load_schemadb();
55 55
         $this->_modify_schema();
56 56
         $controller = midcom_helper_datamanager2_controller::create('simple');
57
-        $controller->schemadb =& $this->_schemadb;
57
+        $controller->schemadb = & $this->_schemadb;
58 58
         $controller->set_storage($this->_deliverable, $this->_schema);
59 59
         if (!$controller->initialize()) {
60 60
             throw new midcom_error("Failed to initialize a DM2 controller instance for deliverable {$this->_deliverable->id}.");
@@ -67,7 +67,7 @@  discard block
 block discarded – undo
67 67
      */
68 68
     private function _modify_schema()
69 69
     {
70
-        $fields =& $this->_schemadb['subscription']->fields;
70
+        $fields = & $this->_schemadb['subscription']->fields;
71 71
 
72 72
         $mc = new org_openpsa_relatedto_collector($this->_deliverable->guid, 'midcom_services_at_entry_dba');
73 73
         $mc->add_object_order('start', 'ASC');
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
         $at_entries = $mc->get_related_objects();
76 76
 
77 77
         if (sizeof($at_entries) != 1) {
78
-            if (   (   $this->_deliverable->continuous
78
+            if (($this->_deliverable->continuous
79 79
                     || $this->_deliverable->end > time())
80 80
                 && $this->_deliverable->state == org_openpsa_sales_salesproject_deliverable_dba::STATE_STARTED) {
81 81
                 $fields['next_cycle']['hidden'] = false;
@@ -128,7 +128,7 @@  discard block
 block discarded – undo
128 128
         if (!empty($formdata['at_entry']->value)) {
129 129
             $entry = new midcom_services_at_entry_dba((int) $formdata['at_entry']->value);
130 130
         }
131
-        if (   isset($formdata['next_cycle'])
131
+        if (isset($formdata['next_cycle'])
132 132
             && !$formdata['next_cycle']->is_empty()) {
133 133
             $next_cycle = (int) $formdata['next_cycle']->value->format('U');
134 134
         }
Please login to merge, or discard this patch.
lib/org/openpsa/sales/handler/deliverable/view.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -77,7 +77,7 @@
 block discarded – undo
77 77
         $this->_load_schema();
78 78
 
79 79
         $this->_request_data['controller'] = midcom_helper_datamanager2_controller::create('ajax');
80
-        $this->_request_data['controller']->schemadb =& $this->_request_data['schemadb_salesproject_deliverable'];
80
+        $this->_request_data['controller']->schemadb = & $this->_request_data['schemadb_salesproject_deliverable'];
81 81
         $this->_request_data['controller']->set_storage($this->_deliverable);
82 82
         $this->_request_data['controller']->process_ajax();
83 83
 
Please login to merge, or discard this patch.
lib/org/openpsa/sales/handler/edit.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -55,7 +55,7 @@  discard block
 block discarded – undo
55 55
     {
56 56
         $this->_load_schemadb();
57 57
         $this->_controller = midcom_helper_datamanager2_controller::create('simple');
58
-        $this->_controller->schemadb =& $this->_schemadb;
58
+        $this->_controller->schemadb = & $this->_schemadb;
59 59
         $this->_controller->set_storage($this->_salesproject, $this->_schema);
60 60
         if (!$this->_controller->initialize()) {
61 61
             throw new midcom_error("Failed to initialize a DM2 controller instance for salesproject {$this->_salesproject->id}.");
@@ -71,9 +71,9 @@  discard block
 block discarded – undo
71 71
         $this->_load_defaults($args);
72 72
 
73 73
         $this->_controller = midcom_helper_datamanager2_controller::create('create');
74
-        $this->_controller->schemadb =& $this->_schemadb;
74
+        $this->_controller->schemadb = & $this->_schemadb;
75 75
         $this->_controller->schemaname = $this->_schema;
76
-        $this->_controller->callback_object =& $this;
76
+        $this->_controller->callback_object = & $this;
77 77
         $this->_controller->defaults = $this->_defaults;
78 78
         if (!$this->_controller->initialize()) {
79 79
             throw new midcom_error("Failed to initialize a DM2 create controller.");
@@ -84,7 +84,7 @@  discard block
 block discarded – undo
84 84
     {
85 85
         $schemadb = midcom_helper_datamanager2_schema::load_database($this->_config->get('schemadb_salesproject'));
86 86
         if ($this->_salesproject) {
87
-            $fields =& $schemadb['default']->fields;
87
+            $fields = & $schemadb['default']->fields;
88 88
             $fields['customer']['type_config']['options'] = org_openpsa_helpers_list::task_groups($this->_salesproject);
89 89
         }
90 90
         $this->_schemadb = $schemadb;
@@ -96,7 +96,7 @@  discard block
 block discarded – undo
96 96
         $this->_defaults['owner'] = midcom_connection::get_user();
97 97
 
98 98
         if (!empty($args[0])) {
99
-            $fields =& $this->_schemadb['default']->fields;
99
+            $fields = & $this->_schemadb['default']->fields;
100 100
             try {
101 101
                 $customer = new org_openpsa_contacts_group_dba($args[0]);
102 102
                 $fields['customer']['type_config']['options'] = array(0 => '', $customer->id => $customer->official);
Please login to merge, or discard this patch.
lib/org/openpsa/sales/midcom/interfaces.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -53,7 +53,7 @@  discard block
 block discarded – undo
53 53
      */
54 54
     private function _find_suspects_event(midcom_core_dbaobject $object, $defaults, array &$links_array)
55 55
     {
56
-        if (   !is_array($object->participants)
56
+        if (!is_array($object->participants)
57 57
             || count($object->participants) < 2) {
58 58
             //We have invalid list or less than two participants, abort
59 59
             return;
@@ -144,7 +144,7 @@  discard block
 block discarded – undo
144 144
      */
145 145
     public function new_subscription_cycle(array $args, midcom_baseclasses_components_cron_handler $handler)
146 146
     {
147
-        if (   !isset($args['deliverable'])
147
+        if (!isset($args['deliverable'])
148 148
             || !isset($args['cycle'])) {
149 149
             $handler->print_error('deliverable GUID or cycle number not set, aborting');
150 150
             return false;
Please login to merge, or discard this patch.
lib/org/openpsa/sales/salesproject.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -90,7 +90,7 @@  discard block
 block discarded – undo
90 90
             }
91 91
         }
92 92
         $profit = $value - $cost;
93
-        if (   $this->value != $value
93
+        if ($this->value != $value
94 94
             || $this->profit != $profit) {
95 95
             $this->value = $value;
96 96
             $this->profit = $value - $cost;
@@ -220,12 +220,12 @@  discard block
 block discarded – undo
220 220
 
221 221
     public function _on_updating()
222 222
     {
223
-        if (   $this->state != self::STATE_ACTIVE
223
+        if ($this->state != self::STATE_ACTIVE
224 224
             && !$this->end) {
225 225
             //Not active anymore and end not set, set it to now
226 226
             $this->end = time();
227 227
         }
228
-        if (   $this->end
228
+        if ($this->end
229 229
             && $this->state == self::STATE_ACTIVE) {
230 230
             //Returned to active state, clear the end marker.
231 231
             $this->end = 0;
Please login to merge, or discard this patch.