<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace ModStart\Core\Type; use Illuminate\Support\Str; use ModStart\Core\Input\Request; use ModStart\Core\Input\Response; use ModStart\Core\Util\ConstantUtil; use ModStart\Core\Util\SerializeUtil; class TypeUtil { public static function dumpJsFile($ChIGR) { goto FXCCg; nS0rJ: $BWI89 = array(); goto Zyqm1; Uq1eY: foreach ($ChIGR as $E1HRj) { $E7qsE[class_basename($E1HRj)] = TypeUtil::dump($E1HRj); } goto nS0rJ; hJEH8: foreach ($E7qsE as $f0dxO => $Ese1E) { $BWI89[] = "export const {$f0dxO} = " . SerializeUtil::jsonEncodePretty($Ese1E) . ';'; } goto feKU8; Zyqm1: $BWI89[] = '// This file is created by ' . Request::currentPageUrl() . '
'; goto hJEH8; FXCCg: $E7qsE = array(); goto Uq1eY; feKU8: return Response::raw(join('
', $BWI89), array('Content-Type' => 'text/plain')); goto gc3Bm; gc3Bm: } public static function name($nYSke, $HDpl6) { goto FAXXd; PNiz0: foreach ($CEqzM as $pztz4 => $Q0rz2) { if ($pztz4 == $HDpl6) { return $Q0rz2; } } goto DanKM; DanKM: return null; goto eJiTp; FAXXd: $CEqzM = $nYSke::getList(); goto PNiz0; eJiTp: } public static function filter($nYSke, $c6Fiz) { goto FEhBj; oxMYM: return $XYn5i; goto D1Eg2; TuIJb: foreach ($CEqzM as $pztz4 => $Q0rz2) { if (in_array($pztz4, $c6Fiz)) { $XYn5i[$pztz4] = $Q0rz2; } } goto oxMYM; D1zvo: $XYn5i = array(); goto TuIJb; FEhBj: $CEqzM = $nYSke::getList(); goto D1zvo; D1Eg2: } public static function dump($ottBC) { goto e3P02; TMKxr: foreach ($UtHxd as $VFU9l => $HDpl6) { goto iBNBP; iBNBP: $c6Fiz[$VFU9l]['key'] = $VFU9l; goto JYQno; GORCz: $c6Fiz[$VFU9l]['name'] = isset($PGfuX[$HDpl6]) ? $PGfuX[$HDpl6] : null; goto MnlgO; JYQno: $c6Fiz[$VFU9l]['value'] = $HDpl6; goto GORCz; MnlgO: } goto hUnYH; IU6Ji: $PGfuX = $ottBC::getList(); goto TMKxr; e3P02: $UtHxd = ConstantUtil::dump($ottBC); goto IU6Ji; hUnYH: return $c6Fiz; goto t3Ax1; t3Ax1: } public static function colorGuessMap($hS5RD) { goto Vu2Z3; flPqS: $PiPL6 = array('fail' => 'danger', 'error' => 'danger', 'wait_verify' => 'danger', 'wait_pay' => 'warning', 'danger' => 'warning', 'running' => 'warning', 'refund' => 'warning', 'success' => 'success', 'verified' => 'success', 'pass' => 'success', 'reject' => 'danger', 'wait' => 'muted', 'canceled' => 'muted', 'disabled' => 'muted', 'completed' => 'success', 'finish' => 'success', 'converting' => 'warning', 'sending' => 'warning', 'ignore' => 'muted', 'expired' => 'muted', 'info' => 'primary', 'unread' => 'danger', 'read' => 'muted', 'processed' => 'success', 'verifying' => 'warning', 'online' => 'success', 'payed' => 'success', 'wait_process' => 'warning', 'deleted' => 'muted', 'invalid' => 'warning', 'valid' => 'success'); goto kz6Ar; W4RMS: return $PGfuX; goto WXdqv; up0ui: $rx74c[$hS5RD] = $PGfuX; goto W4RMS; CCvVq: $PGfuX = array(); goto flPqS; kz6Ar: foreach (ConstantUtil::dump($hS5RD) as $pztz4 => $Q0rz2) { $pztz4 = strtolower($pztz4); foreach ($PiPL6 as $h0Bet => $j7KvK) { if (Str::contains($pztz4, $h0Bet)) { $PGfuX[$Q0rz2] = $j7KvK; break; } } } goto up0ui; Vu2Z3: static $rx74c = array(); goto DqKSb; DqKSb: if (isset($rx74c[$hS5RD])) { return $rx74c[$hS5RD]; } goto CCvVq; WXdqv: } }