亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? class.rateengine.php

?? asterisk用 的voip記費軟件
?? PHP
?? 第 1 頁 / 共 3 頁
字號:
						" WHERE $CLAUSE_DATE AND id_cc_card = '".$A2B->id_card."' AND id_cc_package_offer = '$id_cc_package_offer' ";								$pack_result = $A2B -> instance_table -> SQLExec ($A2B -> DBHandle, $QUERY);												if (is_array($pack_result) && count($pack_result)>0){					$freetimetocall_used = $pack_result[0][0];				}else{					$freetimetocall_used = 0;				}								$A2B -> write_log ('line:'.__LINE__." - PACK USED TIME : $QUERY ; RESULT -> $freetimetocall_used");				if ($this -> debug_st) echo ('line:'.__LINE__." - PACK USED TIME : $QUERY ; RESULT -> $freetimetocall_used");								$this -> freetimetocall_left[$K] = $freetimetocall - $freetimetocall_used;				if ($this -> freetimetocall_left[$K] < 0) $this -> freetimetocall_left[$K] = 0;							}		}		if ($this -> debug_st) print_r($this -> freetimetocall_left);		// ****************  END PACKAGE PARAMETERS ****************  				$credit -= $connectcharge;		$credit -= $disconnectcharge;		//$credit -= ($initblock/60)*$rateinitial;				$this -> ratecard_obj[$K]['timeout']=0;				// CHECK IF THE USER IS ALLOW TO CALL WITH ITS CREDIT AMOUNT		if ($credit < $A2B->agiconfig['min_credit_2call']){			return "ERROR CT1";  //NO ENOUGH CREDIT TO CALL THIS NUMBER		}				// if ($rateinitial==0) return "ERROR RATEINITIAL($rateinitial)";		$TIMEOUT = 0;				if ($rateinitial<=0){			$this -> ratecard_obj[$K]['timeout']= $A2B->agiconfig['maxtime_tocall_negatif_free_route']; // 90 min			if ($this -> debug_st) print_r($this -> ratecard_obj[$K]);			return $TIMEOUT;		}						// 2 KIND OF CALCULATION : PROGRESSIVE RATE & FLAT RATE		// IF FLAT RATE 		if (empty($chargea) || $chargea==0 || empty($timechargea) || $timechargea==0 ){						$num_min = $credit/$rateinitial;						if ($this -> debug_st) echo "num_min:$num_min ($credit/$rateinitial)\n";						$num_sec = intval($num_min * 60);			if ($this -> debug_st) echo "num_sec:$num_sec \n";						if ($billingblock > 0) {				$mod_sec = $num_sec % $billingblock; 					$num_sec=$num_sec-$mod_sec;			}						$TIMEOUT = $num_sec;				// IF PROGRESSIVE RATE 		}else{			if ($this -> debug_st) echo "CYCLE A	TIMEOUT:$TIMEOUT\n";			// CYCLE A			$credit -= $stepchargea;						//if ($credit<=0) return "ERROR CT2";		//NO ENOUGH CREDIT TO CALL THIS NUMBER			if ($credit<=0){				if ($this -> freetimetocall_left[$K] > 0){					$this -> ratecard_obj[$K]['timeout'] = $this -> freetimetocall_left[$K];					if ($this -> debug_st) print_r($this -> ratecard_obj[$K]);					return $this -> freetimetocall_left[$K];				}else{					return "ERROR CT2";		//NO ENOUGH CREDIT TO CALL THIS NUMBER				}							}			if (!($chargea>0)) return "ERROR CHARGEA($chargea)";			$num_min = $credit/$chargea;			if ($this -> debug_st) echo "			CYCLEA num_min:$num_min ($credit/$chargea)\n";						$num_sec = intval($num_min * 60);			if ($this -> debug_st) echo "			CYCLEA num_sec:$num_sec \n";			if ($billingblocka > 0) {				$mod_sec = $num_sec % $billingblocka;				$num_sec=$num_sec-$mod_sec;			}									if (($num_sec>$timechargea) && !(empty($chargeb) || $chargeb==0 || empty($timechargeb) || $timechargeb==0) ){				$TIMEOUT += $timechargea;				$credit -= ($chargea/60) * $timechargea;				if ($this -> debug_st) echo "		CYCLE B		TIMEOUT:$TIMEOUT\n";				// CYCLE B				$credit -= $stepchargeb;				if ($credit<=0){					$this -> ratecard_obj[$K]['timeout'] = $TIMEOUT + $this -> freetimetocall_left[$K];					return $TIMEOUT + $this -> freetimetocall_left[$K];		//NO ENOUGH CREDIT TO GO TO THE CYCLE B				}								if (!($chargeb>0)) return "ERROR CHARGEB($chargeb)";				$num_min = $credit/$chargeb;				if ($this -> debug_st) echo "			CYCLEB num_min:$num_min ($credit/$chargeb)\n";							$num_sec = intval($num_min * 60);				if ($this -> debug_st) echo "			CYCLEB num_sec:$num_sec \n";				if ($billingblockb > 0) {					$mod_sec = $num_sec % $billingblockb;					$num_sec=$num_sec-$mod_sec;				} 				if (($num_sec>$timechargeb) && !(empty($chargec) || $chargec==0 || empty($timechargec) || $timechargec==0) )				{					$TIMEOUT += $timechargeb;					$credit -= ($chargeb/60) * $timechargeb;											if ($this -> debug_st) echo "				CYCLE C		TIMEOUT:$TIMEOUT\n";					// CYCLE C					$credit -= $stepchargec;					if ($credit<=0){						$this -> ratecard_obj[$K]['timeout'] = $TIMEOUT + $this -> freetimetocall_left[$K];						return $TIMEOUT + $this -> freetimetocall_left[$K];		//NO ENOUGH CREDIT TO GO TO THE CYCLE C					}										if (!($chargec>0)) return "ERROR CHARGEC($chargec)";					$num_min = $credit/$chargec;					if ($this -> debug_st) echo "			CYCLEC num_min:$num_min ($credit/$chargec)\n";								$num_sec = intval($num_min * 60);					if ($this -> debug_st) echo "			CYCLEC num_sec:$num_sec \n";					if ($billingblockc > 0) {						$mod_sec = $num_sec % $billingblockc;						$num_sec=$num_sec-$mod_sec; 					}																		if (($num_sec>$timechargec)){						if ($this -> debug_st) echo "		OUT CYCLE C		TIMEOUT:$TIMEOUT\n";						$TIMEOUT += $timechargec;						$credit -= ($chargec/60) * $timechargec;														// IF CYCLE C IS FINISH USE THE RATEINITIAL														$num_min = $credit/$rateinitial;						if ($this -> debug_st) echo "			OUT CYCLEC num_min:$num_min ($credit/$rateinitial)\n";									$num_sec = intval($num_min * 60);						if ($this -> debug_st) echo "			OUT CYCLEC num_sec:$num_sec \n";						if ($billingblock > 0) {							$mod_sec = $num_sec % $billingblock;							$num_sec=$num_sec-$mod_sec;						}						$TIMEOUT += $num_sec;														// THIS IS THE END												}else{						$TIMEOUT += $num_sec;					}														}else{											if (($num_sec>$timechargeb)){						$TIMEOUT += $timechargeb;						if ($this -> debug_st) echo "		OUT CYCLE B		TIMEOUT:$TIMEOUT\n";						$credit -= ($chargeb/60) * $timechargeb;													// IF CYCLE B IS FINISH USE THE RATEINITIAL						$num_min = $credit/$rateinitial;						if ($this -> debug_st) echo "			OUT CYCLEB num_min:$num_min ($credit/$rateinitial)\n";									$num_sec = intval($num_min * 60);						if ($this -> debug_st) echo "			OUT CYCLEB num_sec:$num_sec \n";						if ($billingblock > 0) {							$mod_sec = $num_sec % $billingblock;							$num_sec=$num_sec-$mod_sec; 						}														$TIMEOUT += $num_sec;															// THIS IS THE END											}else{						$TIMEOUT += $num_sec;					}											}						}else{								if (($num_sec>$timechargea)){									$TIMEOUT += $timechargea;					if ($this -> debug_st) echo "		OUT CYCLE A		TIMEOUT:$TIMEOUT\n";					$credit -= ($chargea/60) * $timechargea;										// IF CYCLE A IS FINISH USE THE RATEINITIAL					$num_min = $credit/$rateinitial;					if ($this -> debug_st) echo "			OUT CYCLEA num_min:$num_min ($credit/$rateinitial)\n";								$num_sec = intval($num_min * 60);					if ($this -> debug_st) echo "			OUT CYCLEA num_sec:$num_sec \n";;					if ($billingblock > 0) {						$mod_sec = $num_sec % $billingblock;						$num_sec=$num_sec-$mod_sec; 					}										$TIMEOUT += $num_sec;													// THIS IS THE END								}else{					$TIMEOUT += $num_sec;				}						}				}		$this -> ratecard_obj[$K]['timeout']=$TIMEOUT + $this -> freetimetocall_left[$K];		if ($this -> debug_st) print_r($this -> ratecard_obj[$K]);		RETURN $TIMEOUT + $this -> freetimetocall_left[$K];	}	/*		RATE ENGINE - CALCUL COST OF THE CALL		* CALCUL THE CREDIT COSUMED BY THE CALL	*/	function rate_engine_calculcost (&$A2B, $callduration, $K=0, $freetimetocall_used){			$K = $this->usedratecard;		$buyrate = round(abs($this -> ratecard_obj[$K][9]),4);		$buyrateinitblock = $this -> ratecard_obj[$K][10];		$buyrateincrement = $this -> ratecard_obj[$K][11];				$rateinitial = round(abs($this -> ratecard_obj[$K][12]),4);		$initblock = $this -> ratecard_obj[$K][13];		$billingblock = $this -> ratecard_obj[$K][14];			$connectcharge = round(abs($this -> ratecard_obj[$K][15]),4);		$disconnectcharge = round(abs($this -> ratecard_obj[$K][16]),4);			$stepchargea = $this -> ratecard_obj[$K][17]; 		$chargea = round(abs($this -> ratecard_obj[$K][18]),4);		$timechargea = $this -> ratecard_obj[$K][19];		$billingblocka = $this -> ratecard_obj[$K][20];			$stepchargeb = $this -> ratecard_obj[$K][21];		$chargeb = round(abs($this -> ratecard_obj[$K][22]),4);		$timechargeb = $this -> ratecard_obj[$K][23];		$billingblockb = $this -> ratecard_obj[$K][24];			$stepchargec = $this -> ratecard_obj[$K][25];		$chargec = round(abs($this -> ratecard_obj[$K][26]),4);			$timechargec = $this -> ratecard_obj[$K][27];		$billingblockc = $this -> ratecard_obj[$K][28];				if (!is_numeric($freetimetocall_used)) $freetimetocall_used=0;				if ($this -> debug_st)  echo "CALLDURATION: $callduration - freetimetocall_used=$freetimetocall_used\n\n";		$A2B -> debug( WRITELOG, $agi, __FILE__, __LINE__, "[CC_RATE_ENGINE_CALCULCOST: K=$K - CALLDURATION:$callduration - freetimetocall_used=$freetimetocall_used]");				$cost =0;		$cost -= $connectcharge;		$cost -= $disconnectcharge;				// CALCULATION BUYRATE COST		$buyratecallduration = $callduration;				$buyratecost =0;		if ($buyratecallduration<$buyrateinitblock) $buyratecallduration=$buyrateinitblock;		if ($buyrateincrement > 0) {				$mod_sec = $buyratecallduration % $buyrateincrement;			if ($mod_sec>0) $buyratecallduration += ($buyrateincrement - $mod_sec);		}				$buyratecost -= ($buyratecallduration/60) * $buyrate;		if ($this -> debug_st)  echo "1. cost: $cost\n buyratecost:$buyratecost\n";				$callduration = $callduration - $freetimetocall_used;				// 2 KIND OF CALCULATION : PROGRESSIVE RATE & FLAT RATE		// IF FLAT RATE 		if (empty($chargea) || $chargea==0 || empty($timechargea) || $timechargea==0 ){					if ($callduration<$initblock) $callduration=$initblock;						if ($billingblock > 0) {					$mod_sec = $callduration % $billingblock;  				if ($mod_sec>0) $callduration += ($billingblock - $mod_sec);			}						$cost -= ($callduration/60) * $rateinitial;				if ($this -> debug_st)  echo "1.a cost: $cost\n";			$A2B -> debug( WRITELOG, $agi, __FILE__, __LINE__, "[TEMP - CC_RATE_ENGINE_CALCULCOST: 1. COST: $cost]:[ ($callduration/60) * $rateinitial ]");				// IF PROGRESSIVE RATE 		}else{			if ($this -> debug_st) echo "CYCLE A	COST:$cost\n";			// CYCLE A			$cost -= $stepchargea;			if ($this -> debug_st)  echo "1.A cost: $cost\n\n";						if ($callduration>$timechargea){ $duration_report = $callduration-$timechargea; $callduration=$timechargea; }						if ($billingblocka > 0) {					$mod_sec = $callduration % $billingblocka;  				if ($mod_sec>0) $callduration += ($billingblocka - $mod_sec);			}			$cost -= ($callduration/60) * $chargea;						if (($duration_report>0) && !(empty($chargeb) || $chargeb==0 || empty($timechargeb) || $timechargeb==0) )			{				$callduration=$duration_report;				$duration_report=0;												// CYCLE B				$cost -= $stepchargeb;				if ($this -> debug_st)  echo "1.B cost: $cost\n\n";									if ($callduration>$timechargeb){ 					$duration_report = $callduration-$timechargeb; 					$callduration=$timechargeb;				}									if ($billingblockb > 0) {						$mod_sec = $callduration % $billingblockb;  					if ($mod_sec>0) $callduration += ($billingblockb - $mod_sec);				}				$cost -= ($callduration/60) * $chargeb; // change chargea -> chargeb thanks to Abbas :D									if (($duration_report>0) && !(empty($chargec) || $chargec==0 || empty($timechargec) || $timechargec==0) )				{											$callduration=$duration_report;					$duration_report=0;																	// CYCLE C					$cost -= $stepchargec;					if ($this -> debug_st)  echo "1.C cost: $cost\n\n";												if ($callduration>$timechargec){ 						$duration_report = $callduration-$timechargec; 						$callduration=$timechargec; 					}												if ($billingblockc > 0) {							$mod_sec = $callduration % $billingblockc;  						if ($mod_sec>0) $callduration += ($billingblockc - $mod_sec);					}					$cost -= ($callduration/60) * $chargec;											}			}						if ($duration_report>0){							if ($duration_report<$initblock) $duration_report=$initblock;						if ($billingblock > 0) {						$mod_sec = $duration_report % $billingblock;  					if ($mod_sec>0) $duration_report += ($billingblock - $mod_sec);				}								$cost -= ($duration_report/60) * $rateinitial;								$A2B -> debug( WRITELOG, $agi, __FILE__, __LINE__, "[TEMP - CC_RATE_ENGINE_CALCULCOST: 2. DURATION_REPORT:$duration_report - COST: $cost]");			}					}		$cost = round($cost,4);		if ($this -> debug_st)  echo "FINAL COST: $cost\n\n";		$A2B -> debug( WRITELOG, $agi, __FILE__, __LINE__, "[CC_RATE_ENGINE_CALCULCOST: K=$K - BUYCOST: $buyratecost - SELLING COST: $cost]");		$this -> lastcost = $cost;		$this -> lastbuycost = $buyratecost;	}    /* 		SORT_ASC : Tri en ordre ascendant      	SORT_DESC : Tri en ordre descendant	*/	function array_csort() 	{  		$args = func_get_args();		$marray = array_shift($args);		$i=0;		$msortline = "return(array_multisort(";		foreach ($args as $arg) {			$i++;			if (is_string($arg)) {				foreach ($marray as $row) {					$sortarr[$i][] = $row[$arg];				}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日韩成人dvd| 6080yy午夜一二三区久久| 97国产一区二区| 在线观看av一区二区| 欧美日韩一区小说| 亚洲精品在线观看视频| 欧美国产日韩精品免费观看| 亚洲精品国产视频| 蜜臂av日日欢夜夜爽一区| 国产一区二区三区综合| 一本大道久久精品懂色aⅴ| 欧美丰满美乳xxx高潮www| 久久亚洲免费视频| 亚洲激情图片一区| 精品中文av资源站在线观看| 97久久超碰精品国产| 欧美日韩高清一区二区不卡| 国产午夜精品理论片a级大结局| 亚洲激情中文1区| 精东粉嫩av免费一区二区三区| 成人成人成人在线视频| 欧美丰满美乳xxx高潮www| 欧美国产乱子伦| 午夜欧美电影在线观看| 国产福利91精品| 韩国av一区二区| 欧美性xxxxxxxx| 亚洲一区二区三区三| 欧美日韩另类国产亚洲欧美一级| 午夜精彩视频在线观看不卡| 欧美乱熟臀69xxxxxx| 国产精品国产自产拍高清av王其| 精彩视频一区二区| 久久久久国产一区二区三区四区| 国产精品欧美经典| 免费欧美在线视频| 欧美在线观看视频在线| 国产日韩精品一区二区三区| 视频一区中文字幕国产| 91蜜桃网址入口| 亚洲精品一区二区精华| 亚洲午夜久久久久| 成人免费不卡视频| 精品人在线二区三区| 亚洲第一久久影院| 一本色道久久综合亚洲91| 久久这里都是精品| 日韩黄色片在线观看| 色国产综合视频| 欧美国产日韩一二三区| 日韩av电影免费观看高清完整版在线观看| 成人黄色免费短视频| 91精品国产一区二区三区| 一区二区三区免费在线观看| 国产久卡久卡久卡久卡视频精品| 欧美一区永久视频免费观看| 中文字幕亚洲区| 91网上在线视频| 久久久久国产精品厨房| 蜜臀久久久99精品久久久久久| 91丨九色丨黑人外教| 欧美成人午夜电影| 图片区小说区区亚洲影院| 国产一区二区剧情av在线| 欧美成人三级在线| 午夜成人免费视频| 欧美区在线观看| 亚洲免费av网站| 成人开心网精品视频| 日韩女优电影在线观看| 天天射综合影视| a在线欧美一区| 国产精品高潮呻吟| 日韩成人av影视| 欧美一区二视频| 亚洲国产综合91精品麻豆| 一本大道久久a久久综合婷婷| 亚洲国产精品精华液2区45| 国产一区二区免费视频| 日韩欧美一级二级三级| 另类小说图片综合网| 91精品国产手机| 视频在线在亚洲| 欧美日韩色综合| 日韩精彩视频在线观看| 欧美性受xxxx| 日韩中文字幕麻豆| 欧美日韩国产影片| 丝袜美腿亚洲综合| 欧美日韩高清一区二区三区| 亚洲一级不卡视频| 欧美日韩一本到| 日韩国产欧美在线播放| 欧美剧在线免费观看网站 | 91精品国产一区二区三区蜜臀| 视频一区二区欧美| 欧美日韩一区在线观看| 日韩 欧美一区二区三区| 欧美巨大另类极品videosbest | 亚洲午夜电影在线| 色综合天天综合网天天狠天天| 又紧又大又爽精品一区二区| 在线观看网站黄不卡| 亚洲男人的天堂一区二区| 色哟哟国产精品免费观看| 久久久精品日韩欧美| 成人精品视频网站| 一色桃子久久精品亚洲| 欧美性一区二区| 肉丝袜脚交视频一区二区| 2021国产精品久久精品| 国产成人8x视频一区二区| 亚洲人成亚洲人成在线观看图片| 色婷婷综合中文久久一本| 日韩一区精品视频| 日韩一区二区三区高清免费看看| 国产一区二区日韩精品| 国产精品二三区| 欧美精品精品一区| 国产乱码精品1区2区3区| 亚洲老司机在线| 7777精品伊人久久久大香线蕉的 | 天涯成人国产亚洲精品一区av| 欧美videos大乳护士334| 国产91对白在线观看九色| 亚洲图片欧美色图| 日韩欧美一二三| 色综合久久久久综合| 日日嗨av一区二区三区四区| 亚洲国产高清在线| 欧美三级三级三级爽爽爽| 国产伦精品一区二区三区在线观看| 国产精品色婷婷| 欧美一区二区网站| 成人性色生活片免费看爆迷你毛片| 亚洲成人第一页| 国产亚洲福利社区一区| 欧美日韩一区二区在线视频| 国产真实乱对白精彩久久| 夜夜爽夜夜爽精品视频| 日韩手机在线导航| 一本一道久久a久久精品| 日韩电影在线免费| 亚洲男人的天堂一区二区| 欧美成va人片在线观看| 欧美自拍偷拍一区| 国产综合色在线视频区| 亚洲激情欧美激情| 久久人人97超碰com| 欧美最新大片在线看| 成人手机在线视频| 天堂久久久久va久久久久| 亚洲视频香蕉人妖| 精品国产免费视频| 在线播放中文字幕一区| www.亚洲人| 国产大陆a不卡| 日本欧美一区二区在线观看| 一区二区三国产精华液| 欧美www视频| 日韩三级视频在线看| 成人视屏免费看| 国产福利视频一区二区三区| 亚洲高清免费观看 | 视频一区二区中文字幕| 亚洲欧美在线aaa| 91精品麻豆日日躁夜夜躁| 色悠久久久久综合欧美99| 国产一区二区精品久久| 精品一区精品二区高清| 亚洲免费在线播放| 18成人在线观看| 欧美日韩免费高清一区色橹橹| 91天堂素人约啪| 国产毛片精品国产一区二区三区| 日韩国产成人精品| 亚洲同性gay激情无套| 久久久久久久久久看片| 91精品一区二区三区久久久久久| 欧美中文字幕一二三区视频| 97超碰欧美中文字幕| 风间由美性色一区二区三区| 国内精品国产成人国产三级粉色| 99热99精品| 国产电影精品久久禁18| 国产不卡在线一区| 久久狠狠亚洲综合| 精品一二线国产| 日韩中文字幕一区二区三区| 亚洲国产精品天堂| 五月婷婷久久丁香| 午夜精品福利在线| 美日韩一区二区三区| 日韩av二区在线播放| 国内外成人在线| 国产一级精品在线| 国产成人免费xxxxxxxx| 国产aⅴ精品一区二区三区色成熟| 狠狠色综合日日| 免费美女久久99|