| @@ 114-118 (lines=5) @@ | ||
| 111 | protected function sanitizeDescription($string) |
|
| 112 | { |
|
| 113 | $description = parent::sanitizeDescription($string); |
|
| 114 | if (strpos($description, '/REMI/USTD//') !== false |
|
| 115 | && preg_match('#/REMI/USTD//(.*?)/#s', $description, $results) && !empty($results[1]) |
|
| 116 | ) { |
|
| 117 | return $results[1]; |
|
| 118 | } |
|
| 119 | if (strpos($description, '/REMI/STRD/CUR/') !== false |
|
| 120 | && preg_match('#/REMI/STRD/CUR/(.*?)/#s', $description, $results) && !empty($results[1]) |
|
| 121 | ) { |
|
| @@ 119-123 (lines=5) @@ | ||
| 116 | ) { |
|
| 117 | return $results[1]; |
|
| 118 | } |
|
| 119 | if (strpos($description, '/REMI/STRD/CUR/') !== false |
|
| 120 | && preg_match('#/REMI/STRD/CUR/(.*?)/#s', $description, $results) && !empty($results[1]) |
|
| 121 | ) { |
|
| 122 | return $results[1]; |
|
| 123 | } |
|
| 124 | ||
| 125 | return $description; |
|
| 126 | } |
|
| @@ 122-126 (lines=5) @@ | ||
| 119 | $description = parent::parseTransactionDescription(); |
|
| 120 | ||
| 121 | // SEPA MT940 Structured |
|
| 122 | if (strpos($description, '/REMI/') !== false |
|
| 123 | && preg_match('#/REMI/(.*)[/:]?#', $description, $results) && !empty($results[1]) |
|
| 124 | ) { |
|
| 125 | return $results[1]; |
|
| 126 | } |
|
| 127 | ||
| 128 | $accountIsInDescription = strpos($description, 'REK:'); |
|
| 129 | if ($accountIsInDescription !== false) { |
|
| @@ 132-136 (lines=5) @@ | ||
| 129 | protected function sanitizeDescription($string) |
|
| 130 | { |
|
| 131 | $description = parent::sanitizeDescription($string); |
|
| 132 | if (strpos($description, '/REMI/') !== false |
|
| 133 | && preg_match('#/REMI/(.*?)(/((PURP|ISDT|CSID|RTRN)/)|$)#s', $description, $results) && !empty($results[1]) |
|
| 134 | ) { |
|
| 135 | return $results[1]; |
|
| 136 | } |
|
| 137 | if (strpos($description, '/EREF/') !== false |
|
| 138 | && preg_match('#/EREF/(.*?)/(ORDP)/#s', $description, $results) && !empty($results[1]) |
|
| 139 | ) { |
|
| @@ 137-141 (lines=5) @@ | ||
| 134 | ) { |
|
| 135 | return $results[1]; |
|
| 136 | } |
|
| 137 | if (strpos($description, '/EREF/') !== false |
|
| 138 | && preg_match('#/EREF/(.*?)/(ORDP)/#s', $description, $results) && !empty($results[1]) |
|
| 139 | ) { |
|
| 140 | return $results[1]; |
|
| 141 | } |
|
| 142 | ||
| 143 | if (strpos($description, '/PREF/') !== false |
|
| 144 | && preg_match('#/PREF/(.*)/?#s', $description, $results) && !empty($results[1]) |
|
| @@ 143-147 (lines=5) @@ | ||
| 140 | return $results[1]; |
|
| 141 | } |
|
| 142 | ||
| 143 | if (strpos($description, '/PREF/') !== false |
|
| 144 | && preg_match('#/PREF/(.*)/?#s', $description, $results) && !empty($results[1]) |
|
| 145 | ) { |
|
| 146 | return $results[1]; |
|
| 147 | } |
|
| 148 | ||
| 149 | return $description; |
|
| 150 | } |
|