Initial commit

This commit is contained in:
2022-03-25 16:42:41 +01:00
commit 34685838bc
235 changed files with 12766 additions and 0 deletions
@@ -0,0 +1,45 @@
<?php
declare(strict_types=1);
namespace App\Helper\DataNeed;
use App\Logic\Crypto\MainObject;
final class CryptoValues
{
private static array $values = [
"values" => ["Wartość","Values"],
"currency" => ["Currency", "Waluta"],
"date" => ["Data operacji"],
"desc" => ["Rodzaj"]
];
public static function isValue(string $type, string $text) : bool
{
if (!isset(self::$values[$type])) {
return false;
}
$ret = false;
foreach (self::$values[$type] as $value) {
if (strpos($text,$value) !== false) {
$ret = true;
break;
}
}
return $ret;
}
public static function isInOut(MainObject $mainObject) : bool
{
$arr = [
"Wypłata środków","Blokada środków","Wpłata na rachunek"
];
$ret = false;
foreach ($arr as $item) {
if ($mainObject->getDesc() === $item) {
$ret = true;
break;
}
}
return $ret;
}
}