opencart-module/catalog/model/extension/retailcrm/api.php

12 lines
338 B
PHP
Raw Normal View History

<?php
class ModelExtensionRetailcrmApi extends Model
{
public function login($username, $key)
{
$query = $this->db->query("SELECT * FROM `" . DB_PREFIX . "api` WHERE `username` = '" . $this->db->escape($username) . "' AND `key` = '" . $this->db->escape($key) . "' AND status = '1'");
return $query->row;
}
}