You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
<?php
|
|
|
|
|
|
|
|
class messagecenter_model extends CI_Model {
|
|
|
|
function __construct() {
|
|
|
|
parent::__construct();
|
|
|
|
$this->INFO = $this->load->database('INFO', TRUE);
|
|
|
|
$this->HT = $this->load->database('HT', TRUE);
|
|
|
|
}
|
|
|
|
|
|
|
|
public function get_tp_list($from_time,$to_time){
|
|
|
|
$sql = 'select * from trippest_sms_log where TPSL_callbackTime > ? and TPSL_callbackTime < ? and TPSL_sendState = 1';
|
|
|
|
$query = $this->INFO->query($sql,array($from_time,$to_time));
|
|
|
|
return $query->result();
|
|
|
|
}
|
|
|
|
|
|
|
|
public function get_cht_list($from_time,$to_time){
|
|
|
|
$sql = 'select * from [syn123].InfoManager.dbo.train_sms_verification where created_on > ? and created_on < ?';
|
|
|
|
$query = $this->INFO->query($sql,array($from_time,$to_time));
|
|
|
|
return $query->result();
|
|
|
|
}
|
|
|
|
|
|
|
|
public function getOrderInfo($order){
|
|
|
|
$sql = "select GUT_FirstName,GUT_LastName,COLD_StartDate from BIZ_ConfirmLineInfo INNER JOIN BIZ_ConfirmLineDetail on coli_sn = COLD_COLI_SN INNER JOIN BIZ_GUEST on COLI_GUT_SN = GUT_SN where COLI_ID = ?";
|
|
|
|
$query = $this->HT->query($sql,array($order));
|
|
|
|
return $query->row();
|
|
|
|
}
|
|
|
|
|
|
|
|
public function updateColiMemo($order,$message){
|
|
|
|
$sql = 'update BIZ_ConfirmLineInfo set COLI_Memo = ? where coli_id = ?';
|
|
|
|
$query = $this->HT->query($sql,array($message,$order));
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|