@@ -54,7 +54,7 @@ discard block |
||
54 | 54 | { |
55 | 55 | $node = $nap->get_node($node_id); |
56 | 56 | |
57 | - if ( !array_key_exists($node[MIDCOM_NAV_COMPONENT], $this->_request_data['components']) |
|
57 | + if (!array_key_exists($node[MIDCOM_NAV_COMPONENT], $this->_request_data['components']) |
|
58 | 58 | && $node[MIDCOM_NAV_COMPONENT] != 'midcom.helper.search') { |
59 | 59 | $l10n = $this->_i18n->get_l10n($node[MIDCOM_NAV_COMPONENT]); |
60 | 60 | $this->_request_data['components'][$node[MIDCOM_NAV_COMPONENT]] = $l10n->get($node[MIDCOM_NAV_COMPONENT]); |
@@ -107,7 +107,7 @@ discard block |
||
107 | 107 | } |
108 | 108 | $this->prepare_formdata($_REQUEST['type']); |
109 | 109 | |
110 | - if ( count(explode(' ', $data['query'])) == 1 |
|
110 | + if (count(explode(' ', $data['query'])) == 1 |
|
111 | 111 | && strpos($data['query'], '*') === false |
112 | 112 | && $this->_config->get('single_term_auto_wildcard')) { |
113 | 113 | //If there is only one search term append * to the query if auto_wildcard is enabled |
@@ -181,12 +181,12 @@ discard block |
||
181 | 181 | $this->_request_data['last_document_number'] = $last_document_id + 1; |
182 | 182 | $this->_request_data['shown_documents'] = $last_document_id - $first_document_id + 1; |
183 | 183 | $this->_request_data['results_per_page'] = $results_per_page; |
184 | - $this->_request_data['all_results'] =& $result; |
|
184 | + $this->_request_data['all_results'] = & $result; |
|
185 | 185 | $this->_request_data['result'] = array_slice($result, $first_document_id, $results_per_page); |
186 | 186 | |
187 | 187 | // Register GUIDs for cache engine |
188 | 188 | foreach ($this->_request_data['result'] as $doc) { |
189 | - if ( !isset($doc->source) |
|
189 | + if (!isset($doc->source) |
|
190 | 190 | || !mgd_is_guid($doc->source)) { |
191 | 191 | // Non-Midgard results don't need to go through cache registration |
192 | 192 | continue; |
@@ -27,14 +27,14 @@ |
||
27 | 27 | |
28 | 28 | $changes = true; |
29 | 29 | |
30 | - echo "<dt>". $data['handler']->translate($attribute) ."</dt>\n"; |
|
30 | + echo "<dt>" . $data['handler']->translate($attribute) . "</dt>\n"; |
|
31 | 31 | echo " <dd>\n"; |
32 | 32 | echo $values['diff']; |
33 | 33 | echo " </dd>\n"; |
34 | 34 | } |
35 | 35 | |
36 | 36 | if (!$changes) { |
37 | - echo "<dt>". $data['l10n']->get('no changes in content') ."</dt>\n"; |
|
37 | + echo "<dt>" . $data['l10n']->get('no changes in content') . "</dt>\n"; |
|
38 | 38 | } |
39 | 39 | ?> |
40 | 40 | </dl> |
41 | 41 | \ No newline at end of file |
@@ -1,7 +1,7 @@ discard block |
||
1 | 1 | <?php |
2 | 2 | $diff = $data['diff']; |
3 | 3 | $latest = $data['latest_revision']; |
4 | -$comment= $data['comment']; |
|
4 | +$comment = $data['comment']; |
|
5 | 5 | ?> |
6 | 6 | <div class="rcs_navigation"> |
7 | 7 | <?php |
@@ -14,7 +14,7 @@ discard block |
||
14 | 14 | <?php |
15 | 15 | $changes = false; |
16 | 16 | foreach ($diff as $attribute => $values) { |
17 | - if ( !array_key_exists('diff', $values) |
|
17 | + if (!array_key_exists('diff', $values) |
|
18 | 18 | || !midcom_services_rcs::is_field_showable($attribute) |
19 | 19 | || is_array($values['diff'])) { |
20 | 20 | continue; |
@@ -28,7 +28,7 @@ discard block |
||
28 | 28 | } |
29 | 29 | |
30 | 30 | if (!$changes) { |
31 | - echo "<dt>". $data['l10n']->get('no changes in content') ."</dt>\n"; |
|
31 | + echo "<dt>" . $data['l10n']->get('no changes in content') . "</dt>\n"; |
|
32 | 32 | } |
33 | 33 | ?> |
34 | 34 | </dl> |
35 | 35 | \ No newline at end of file |
@@ -23,7 +23,7 @@ |
||
23 | 23 | <th><?php echo $data['l10n']->get('type'); ?></th> |
24 | 24 | <?php |
25 | 25 | } ?> |
26 | -<?php if ( array_key_exists('invoiceable_filter', $query_data)) { |
|
26 | +<?php if (array_key_exists('invoiceable_filter', $query_data)) { |
|
27 | 27 | ?> |
28 | 28 | <th><?php echo midcom::get()->i18n->get_string('invoiceable', 'org.openpsa.projects'); ?></th> |
29 | 29 | <?php |
@@ -40,7 +40,7 @@ |
||
40 | 40 | $at_entries = $mc->get_related_objects(); |
41 | 41 | |
42 | 42 | if (empty($at_entries)) { |
43 | - if ( ( $this->_deliverable->continuous |
|
43 | + if (($this->_deliverable->continuous |
|
44 | 44 | || $this->_deliverable->end > time()) |
45 | 45 | && $this->_deliverable->state == org_openpsa_sales_salesproject_deliverable_dba::STATE_STARTED) { |
46 | 46 | $schema->get_field('next_cycle')['hidden'] = false; |
@@ -43,7 +43,7 @@ discard block |
||
43 | 43 | |
44 | 44 | public function __construct($identifier = null) |
45 | 45 | { |
46 | - if ( midcom::get()->config->get('person_class') != 'midgard_person' |
|
46 | + if (midcom::get()->config->get('person_class') != 'midgard_person' |
|
47 | 47 | && midcom::get()->config->get('person_class') != 'openpsa_person') { |
48 | 48 | $this->__mgdschema_class_name__ = midcom::get()->config->get('person_class'); |
49 | 49 | } |
@@ -52,7 +52,7 @@ discard block |
||
52 | 52 | |
53 | 53 | public function __set($name, $value) |
54 | 54 | { |
55 | - if ( $name == 'homepage' |
|
55 | + if ($name == 'homepage' |
|
56 | 56 | && !empty($value) |
57 | 57 | && $value != $this->homepage) { |
58 | 58 | $this->_register_prober = true; |
@@ -278,7 +278,7 @@ discard block |
||
278 | 278 | } |
279 | 279 | |
280 | 280 | // Override requested root object properties |
281 | - if ( !empty($this->target->guid) |
|
281 | + if (!empty($this->target->guid) |
|
282 | 282 | && $target->guid === $this->target->guid) { |
283 | 283 | foreach ($this->root_object_values as $name => $value) { |
284 | 284 | $target->$name = $value; |
@@ -320,7 +320,7 @@ discard block |
||
320 | 320 | return false; |
321 | 321 | } |
322 | 322 | |
323 | - if ( !$this->_copy_data('parameters', $source, $target) |
|
323 | + if (!$this->_copy_data('parameters', $source, $target) |
|
324 | 324 | || !$this->_copy_data('metadata', $source, $target) |
325 | 325 | || !$this->_copy_data('attachments', $source, $target) |
326 | 326 | || !$this->_copy_data('privileges', $source, $target)) { |
@@ -342,7 +342,7 @@ discard block |
||
342 | 342 | { |
343 | 343 | if ($this->$type) { |
344 | 344 | $method = 'copy_' . $type; |
345 | - if ( !$this->$method($source, $target) |
|
345 | + if (!$this->$method($source, $target) |
|
346 | 346 | && $this->halt_on_errors) { |
347 | 347 | $this->errors[] = $this->_l10n->get('failed to copy ' . $type); |
348 | 348 | return false; |
@@ -88,7 +88,7 @@ |
||
88 | 88 | ]) |
89 | 89 | ->setRequired('object') |
90 | 90 | ->setAllowedTypes('object', midcom_core_dbaobject::class) |
91 | - ->setNormalizer('label', function ($options, $value) { |
|
91 | + ->setNormalizer('label', function($options, $value) { |
|
92 | 92 | if ($value === null) { |
93 | 93 | return midcom_helper_reflector::get_object_title($options['object']); |
94 | 94 | } |
@@ -36,7 +36,7 @@ |
||
36 | 36 | } |
37 | 37 | $result = []; |
38 | 38 | |
39 | - if ( !empty($array['file']) |
|
39 | + if (!empty($array['file']) |
|
40 | 40 | || !empty($array['identifier']) && substr($array['identifier'], 0, 8) === 'tmpfile-') { |
41 | 41 | $result['file'] = parent::reverseTransform($array); |
42 | 42 | } elseif (!empty($array['objects'])) { |