Ignore:
Timestamp:
Nov 18, 2014 5:13:28 PM (11 years ago)
Author:
namnd
Message:
 
File:
1 edited

Legend:

Unmodified
Added
Removed
  • TabularUnified pro-violet-viettel/sourcecode/application/modules/frontend/models/user_model.php

    r556 r559  
    365365                        $user ['updated_time'] = date ( 'Y-m-d H:i:s' );
    366366                        $this->updateUser ( $us_id, $user );
    367                         $sms = "Qui vi da nap thanh cong " . $amount . " VND vao tai khoan " . $username . " tren soanbaigiang.smas.vn";
     367                        $sms = "Qui vi da nap thanh cong " . $amount . " VNĐ vao tai khoan " . $username . " tren soanbaigiang.smas.vn";
    368368                        $status = 1;
    369369                } else {
     
    445445                $paidlog ['paidType'] = $paidType;
    446446                $paidlog ['amount'] = $amount;
     447                $paidlog['source'] = "";
     448                if ($paidType == 1)
     449                {
     450                        $paidlog['source'] = $sentNumber;
     451                       
     452                }else
     453                {
     454                        $paidlog['source'] = "Thẻ cào";
     455                }
    447456                $paidlog ['paidTime'] = $paidTime;
    448457                $this->db->query ( 'UNLOCK TABLES' );
    449                 $sql = 'INSERT INTO tblpaidlog(us_id, paid_type, amount, paid_time) VALUES (?,?,?,?)';
     458                $sql = 'INSERT INTO tblpaidlog(us_id, paid_type, amount, source, paid_time) VALUES (?,?,?,?,?)';
    450459                $query = $this->db->query ( $sql, $paidlog );
    451460        }
     
    469478                $query = $this->db->query ($sql, $cardlog);
    470479        }
     480       
     481        public function getPaidlog($us_id)
     482        {
     483                $this->db->query ( 'UNLOCK TABLES' );
     484                $sql = 'SELECT * FROM tblpaidlog where us_id = ?';
     485                $query = $this->db->query ( $sql, array (
     486                                $us_id
     487                ) );
     488                $row = $query->result_array();
     489                return $row;
     490        }
    471491}
Note: See TracChangeset for help on using the changeset viewer.