Changeset 695 for pro-violet-viettel/sourcecode/application
- Timestamp:
- Jan 15, 2015 12:08:25 PM (10 years ago)
- Location:
- pro-violet-viettel/sourcecode/application
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
pro-violet-viettel/sourcecode/application/config/config.php
r682 r695 381 381 | 382 382 */ 383 384 $config['bccs_service_url'] = 'http://192.168.176.210:8684/BCCSGateway/BCCSGateway?wsdl'; 383 385 $config['mt_service_url'] = 'http://192.168.181.186:7777/sentmt/fromcp.asmx'; 384 386 $config['charging_service_url'] = 'http://10.60.32.154:8101/ChargingService.asmx'; … … 395 397 $config['charging_password'] = 'sbg123#@!'; 396 398 399 $config['bccs_username'] = '62ecbe4b1c0f7807'; 400 $config['bccs_password'] = '2996360cfaf294374687ccba21e07165'; 401 397 402 $config['topup_lock_path'] = '/var/tmp/'; 398 403 $config['topup_lock_max_reach'] = 3; … … 409 414 $config['6'] = 70000; 410 415 $config['12'] = 130000; 411 $config['api_url'] = 'http://api.violet.vn/';412 416 413 417 /* End of file config.php */ -
pro-violet-viettel/sourcecode/application/config/database.php
r682 r695 49 49 $active_record = TRUE; 50 50 51 $db['default']['hostname'] = 'mysql:host=127.0.0.1';51 /*$db['default']['hostname'] = 'mysql:host=127.0.0.1'; 52 52 $db['default']['username'] = 'root';//sbg 53 53 $db['default']['password'] = 'Quyenhue@123';//sbg~~!!@@123 … … 63 63 $db['default']['swap_pre'] = ''; 64 64 $db['default']['autoinit'] = TRUE; 65 $db['default']['stricton'] = FALSE; 65 $db['default']['stricton'] = FALSE;*/ 66 66 67 67 68 /*$db['default']['hostname'] = '127.0.0.1';68 $db['default']['hostname'] = 'mysql:host=127.0.0.1'; 69 69 $db['default']['username'] = 'sbg';//sbg 70 70 $db['default']['password'] = 'sbg~~!!@@123';//sbg~~!!@@123 71 71 $db['default']['database'] = 'sbg'; 72 $db['default']['dbdriver'] = ' mysqli';72 $db['default']['dbdriver'] = 'pdo'; 73 73 $db['default']['dbprefix'] = ''; 74 74 $db['default']['pconnect'] = TRUE; … … 80 80 $db['default']['swap_pre'] = ''; 81 81 $db['default']['autoinit'] = TRUE; 82 $db['default']['stricton'] = FALSE; */82 $db['default']['stricton'] = FALSE; 83 83 84 84 -
pro-violet-viettel/sourcecode/application/language/message/messages_lang.php
r669 r695 61 61 $lang['_SBG_MO_USER_REGISTER_DUPLICATE_MSG'] = 'So dien thoai cua Ban da dang ky tai khoan DV Soan bai giang Online truoc do. Vui long long truy cap http://soanbaigiang.smas.vn de su dung DV hoac LH 01662860000 (cuoc goi di dong) de biet them chi tiet'; 62 62 63 $lang['_SBG_MO_USER_PHONENUM_CHANGE_DUPLICATE_MSG'] = 'So dien thoai :sentNumber: da dang ky DV Soan bai giang Online. Vui long soan HD SBGgui 8062 (500d/tin) hoac LH 01662860000 de biet them chi tiet';63 $lang['_SBG_MO_USER_PHONENUM_CHANGE_DUPLICATE_MSG'] = 'So dien thoai :sentNumber: da dang ky DV Soan bai giang Online. Vui long soan SBG HD gui 8062 (500d/tin) hoac LH 01662860000 de biet them chi tiet'; 64 64 $lang['_SBG_MO_USER_PHONENUM_CHANGE_INCORRECT_PASSWORD_MSG'] = 'Mat khau cua ban khong dung. Vui long kiem tra lai hoac LH 01662860000 de biet them chi tiet'; 65 65 … … 67 67 $lang['_SBG_MO_USER_OLD_PHONENUM_CHANGE_SUCCESS_MSG'] = 'Ban da doi thanh cong so dien thoai tai DV Soan bai giang Online sang so dien thoai :sentNumber:. Vui long LH 01662860000 de biet them chi tiet'; 68 68 69 $lang['_SBG_MO_USER_PHONENUM_NOT_REGISTER_MSG'] = 'So thue bao :username: chua dang ky DV Soan bai giang Online. De dang ky, soan SBG DK gui 8062 (500d/tin). Chi tiet soan HD SBGgui 8062 (500d/tin) hoac LH 01662860000 (cuoc goi di dong).';69 $lang['_SBG_MO_USER_PHONENUM_NOT_REGISTER_MSG'] = 'So thue bao :username: chua dang ky DV Soan bai giang Online. De dang ky, soan SBG DK gui 8062 (500d/tin). Chi tiet soan SBG HD gui 8062 (500d/tin) hoac LH 01662860000 (cuoc goi di dong).'; 70 70 $lang['_SBG_MO_USER_PASSWORD_RECOVERY_MSG'] = 'Mat khau cua Ban la :pass:. Moi Ban truy cap soanbaigiang.smas.vn de su dung DV. Chi tiet LH 01662860000 (cuoc goi di dong).'; 71 71 $lang['_SBG_MO_USER_PASSWORD_CHANGE_SUCCESS_MSG'] = 'Ban da doi thanh cong mat khau tren SBG Online. Mat khau moi cua ban la :password:. Tran trong.'; … … 78 78 $lang['_SBG_MO_PAY_TO_ACCOUNT_FOR_MSG'] = 'Ban da duoc nap :amount:d vao tai khoan cua DV Soan bai giang Online tu so dien thoai :sentNumber:. Chi tiet LH 01662860000 (cuoc goi di dong).'; 79 79 $lang['_SBG_MO_PAY_TO_ACCOUNT_FOR_OTHER_SUCCESS_MSG'] = ' Ban da nap thanh cong :amount:d vao tai khoan :username: cua DV Soan bai giang Online. Chi tiet LH 01662860000 (cuoc goi di dong).'; 80 $lang['_SBG_MO_ACCOUNT_NOT_FOUND_MSG'] = 'So thue bao :username: chua dang ky DV Soan bai giang Online. De dang ky, soan SBG DK gui 8062 (500d/tin). Chi tiet soan HD SBGgui 8062 (500d/tin) hoac LH 01662860000 (cuoc goi di dong).';80 $lang['_SBG_MO_ACCOUNT_NOT_FOUND_MSG'] = 'So thue bao :username: chua dang ky DV Soan bai giang Online. De dang ky, soan SBG DK gui 8062 (500d/tin). Chi tiet soan SBG HD gui 8062 (500d/tin) hoac LH 01662860000 (cuoc goi di dong).'; 81 81 $lang['_SBG_MO_CHARGING_FAIL_NOT_ENOUGH_MSG'] = 'Tai khoan cua ban khong du de thuc hien nap :amount: vao tai khoan cua DV Soan bai giang Online. Chi tiet LH 01662860000 (cuoc goi di dong).:amount: '; 82 82 $lang['_SBG_MO_CHARGING_FAIL_NOT_ENOUGH_FOR_MSG'] = 'Tai khoan cua Ban khong du de thuc hien nap :amount: vao tai khoan :username: cua DV Soan bai giang Online. Chi tiet LH 01662860000 (cuoc goi di dong).'; -
pro-violet-viettel/sourcecode/application/modules/frontend/models/user_model.php
r690 r695 100 100 $aryPatterns = array ('/:trialdays:/', '/:username:/', '/:password:/'); 101 101 $trialdays = $this->config->item('trial_period'); 102 $sms = preg_replace($aryPatterns, array($trialdays, $username, $password), lang('_SBG_MO_USER_REGISTER_SUCCESS_MSG')); 102 $trialdays = strlen($trialdays) < 2 ? '0'. $trialdays : $trialdays; 103 $sms = preg_replace($aryPatterns, array($trialdays. ' ngay', $username, $password), lang('_SBG_MO_USER_REGISTER_SUCCESS_MSG')); 103 104 $status = 1; 104 105 $aryPatterns = array('/:collaborator:/'); … … 410 411 411 412 public function updateUser($us_id, $data) { 412 $this->db->query ( 'UNLOCK TABLES' );413 //$this->db->query ( 'UNLOCK TABLES' ); 413 414 $this->db->where ( 'us_id', $us_id ); 414 $this->db->update ( 'tbluser', $data );415 return $this->db->update ( 'tbluser', $data ); 415 416 } 416 417 … … 458 459 $paidlog = array (); 459 460 $paidlog ['us_id'] = isset ( $user ['us_id'] ) ? $user ['us_id'] : NULL; 460 $paidlog ['paid Type'] = $paidType;461 $paidlog ['paid_type'] = $paidType; 461 462 $paidlog ['amount'] = $amount; 462 463 $paidlog['source'] = ""; … … 464 465 { 465 466 $paidlog['source'] = $sentNumber; 466 467 }else467 } 468 elseif ($paidType == 2) 468 469 { 469 $paidlog['source'] = null; 470 } 471 $paidlog ['paidTime'] = $paidTime; 472 $this->db->query ( 'UNLOCK TABLES' ); 470 $paidlog['source'] = 'Thẻ cào'; 471 } 472 else 473 { 474 $paidlog['source'] = ''; 475 } 476 $paidlog ['paid_time'] = $paidTime; 473 477 $sql = 'INSERT INTO tblpaidlog(us_id, paid_type, amount, source, paid_time) VALUES (?,?,?,?,?)'; 474 $query = $this->db->query ( $sql, $paidlog ); 475 } 476 477 public function insertCardlog($username, $pinCode, $serialNum, $cardValue, $receiveTime) 478 479 return $this->db->query ( $sql, $paidlog ); 480 } 481 482 public function insertCardlog($username, $us_id, $status, $pinCode, $serialNum, $cardValue, $receiveTime) 478 483 { 479 484 try { … … 484 489 $cardlog = array(); 485 490 $cardlog['sender'] = $username; 486 $cardlog['us_id'] = isset ( $user ['us_id'] ) ? $user ['us_id'] : NULL; 491 $cardlog['us_id'] = $us_id; 492 $cardlog['status'] = $status; 487 493 $cardlog['pin_code'] = $pinCode; 488 494 $cardlog['serial_num'] = $serialNum; -
pro-violet-viettel/sourcecode/application/modules/frontend/views/user_profile.php
r690 r695 78 78 79 79 <div class="col-sm-8"> 80 <input type="text" name="fullname" value="<?php echo @$fullname; ?>" placeholder="HỠvà tên" id="form-field-first" class="col-xs-12 col-sm-10" <?php if ( $p_id) echo 'disabled'; ?>>80 <input type="text" name="fullname" value="<?php echo @$fullname; ?>" placeholder="HỠvà tên" id="form-field-first" class="col-xs-12 col-sm-10" <?php if (isset($p_id)) echo 'disabled'; ?>> 81 81 82 82 </div> -
pro-violet-viettel/sourcecode/application/modules/services/controllers/recharge.php
r636 r695 41 41 $chargErrMsg = lang('_SBG_CHARGING_FROM_CARD_FAIL_MSG'); 42 42 $errMsg = ''; 43 43 $cardValue = 0; 44 44 if ($isLocked == 0) { 45 45 $aryParams = array( … … 50 50 51 51 $aryResult = array(); 52 //$aryResult['TransactionAmount'] = 10000; 52 53 $chargCard = $this->services_model->cardPaidProcess($aryParams, $aryResult); 53 54 //$chargCard = _SBG_CARD_PAY_SUCCESS; 55 $status = $chargCard; 54 56 $paidType = 2; 55 57 $amount = $aryResult['TransactionAmount']; 58 $cardValue = $amount; 56 59 $paidTime = date('Y-m-d H:i:s'); 57 60 $user['acc_balanced'] = $user['acc_balanced'] + $amount; 58 61 $user['updated_time'] = date('Y-m-d H:i:s'); 59 if ($amount>0){ 60 $this->objUserModel->updateUser($userID, $user); 62 if ($amount > 0){ 63 $updateData = array('acc_balanced' => $user['acc_balanced'], 'updated_time' => $user['updated_time'] ); 64 $updated = $this->objUserModel->updateUser($userID, $updateData); 61 65 } 62 66 … … 74 78 else { 75 79 $isLocked = createLockFile($lockFilePreFix, $maxReach, $timeToUnlock, $lockFilePath, FALSE); 76 $errMsg = $isLocked == 1 ? $chargErrMsg .'<br />'.$lockedMsg : $chargErrMsg; 80 $errMsg = $isLocked == 1 ? $chargErrMsg .'<br />'.$lockedMsg : $chargErrMsg; 81 $status = 0; 77 82 } 78 83 }else if ($isLocked == 1) { 79 84 $errMsg = $lockedMsg; 80 85 $result['success'] = _SBG_CARD_PAY_FAIL; 86 $status = -1; 81 87 } 88 89 $this->objUserModel->insertCardlog($user['cellphone'],$userID, $status, $pinCard, $cardSerial, $cardValue, $user['updated_time']); 82 90 91 $result['us_id'] = $userID; 92 $result['UPDATED_DATA'] = $user; 83 93 $result['errMsg'] = $errMsg; 84 94 echo json_encode($result); -
pro-violet-viettel/sourcecode/application/modules/services/controllers/sendmessage.php
r689 r695 215 215 { 216 216 error_reporting(E_ALL); 217 217 218 $this->load->model('Services_model'); 218 219 … … 221 222 // get total page 222 223 $totalpage = 1; 224 223 225 $default = $this->Services_model->getCollaborator(2,1,1); 226 227 $data = mb_convert_encoding($default, 'UTF-8'); 228 224 229 if($default){ 225 $xml = simplexml_load_string($d efault);230 $xml = simplexml_load_string($data); 226 231 $xml->registerXPathNamespace("S", "http://schemas.xmlsoap.org/soap/envelope/"); 227 232 $xml = $xml->xpath('//S:Body')[0]; … … 230 235 } 231 236 232 $result = $this->Services_model->getCollaborator(2,1,$totalpage); 237 var_dump($totalpage); 238 239 /*$result = $this->Services_model->getCollaborator(2,1,$totalpage); 233 240 if ($result){ 234 241 $xml = simplexml_load_string($result); … … 258 265 $logMsg = date('Y-m-d H:i:s') . " Result is null \n"; 259 266 write_file('./log/sync_collaborator.log', $logMsg, FOPEN_WRITE_CREATE); 260 } 267 }*/ 261 268 } 262 269 } 270 271 function fix_latin1_mangled_with_utf8_maybe_hopefully_most_of_the_time($str) 272 { 273 return preg_replace_callback('#[\\xA1-\\xFF](?![\\x80-\\xBF]{2,})#', 'utf8_encode_callback', $str); 274 } 275 276 function utf8_encode_callback($m) 277 { 278 return utf8_encode($m[0]); 279 }
Note: See TracChangeset
for help on using the changeset viewer.