@@ -88,6 +88,7 @@ class Code
private function upCode($info, $card)
{
+ $card = trim($card);
if (!$card) {
return;
}
@@ -245,7 +245,9 @@ class Info
$where = 'status = 1 and state = 1';
- if ($type) {
+ if ($type == 1) {
+ $where .= ' and type in (1,2)';
+ } elseif ($type) {
$where .= ' and type = ' . $type;