| Total Complexity | 5 |
| Total Lines | 28 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 5 | class Number implements \Validate\Contracts\Validate |
||
| 6 | { |
||
| 7 | |||
| 8 | /** |
||
| 9 | * Remove Virgulas do Numeral e Add . |
||
| 10 | */ |
||
| 11 | public static function toDatabase(string $number) |
||
| 12 | { |
||
| 13 | if(strpos($number, ',') > 0) { |
||
| 14 | $number = str_replace('.', '', $number); |
||
| 15 | $number = str_replace(',', '.', $number); |
||
| 16 | } |
||
| 17 | return $number; |
||
| 18 | } |
||
| 19 | |||
| 20 | public static function toUser($number) |
||
| 23 | } |
||
| 24 | |||
| 25 | public static function validate($number) |
||
| 26 | { |
||
| 27 | return true; |
||
| 28 | } |
||
| 29 | |||
| 30 | public static function isSame(string $to, string $from) |
||
| 33 | } |
||
| 34 | |||
| 35 | } |
||
| 36 |