Пример #1
0
 public function verifyAction()
 {
     $input = $this->_params;
     $verify = new system\library\Verify("", "", "", $input);
     $myobj = \system\library\Database\DB::find_by_sql("SELECT * FROM merchants WHERE number=" . $input['number']);
     if ($myobj) {
         $myobj = new \ArrayObject(array_shift($myobj));
         if ($verify->get($myobj->offsetGet("hashed"), $input)) {
             return "valid";
         } else {
             return "invalid";
         }
     }
 }
Пример #2
0
 public static function getTerminalByName($short_name)
 {
     return DB::find_by_sql("SELECT * FROM " . self::$table . " WHERE short_name='" . $short_name . "'");
 }