|
@@ -1343,50 +1343,27 @@ class ChapterController extends BaseController
|
|
|
return 899;
|
|
|
}
|
|
|
} else {
|
|
|
- //$fee = ceil($chapter->size/100);
|
|
|
- //$channel_fee = BookService::getChapterPrice()
|
|
|
+
|
|
|
$channel_fee = BookService::getChapterPrice($this->distribution_channel_id);
|
|
|
if ($channel_fee) {
|
|
|
$price_rate = $channel_fee / 100;
|
|
|
} else {
|
|
|
- //$price_rate = 0.012;
|
|
|
$price_rate = env('DEFAULT_CHAPTER_PRICE', 0.015);
|
|
|
}
|
|
|
- //Log::info($price_rate);
|
|
|
- $fee = ceil($chapter->size * $price_rate);
|
|
|
- /*if($this->isRaisePrice()){
|
|
|
- $fee = round($chapter->size * 0.018);
|
|
|
- }*/
|
|
|
- }
|
|
|
- /*//首个计费章节书币价格以35书币为基准,低于35提升至35,原价高于35书币,维持原价
|
|
|
- if (isset($chapter->sequence) && isset($book_info->vip_seq)) {
|
|
|
- if ($chapter->sequence == $book_info->vip_seq) {
|
|
|
- if ($fee < 35) {
|
|
|
- $fee = 35;
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
- //$template_10_site = redisEnv('TEMPLATE_10_SITE','');
|
|
|
- list($template_10_site,$template_10_no_abtest_site) = redisEnvMulti('TEMPLATE_10_SITE','TEMPLATE_10_NO_AB_TEST_SITE');
|
|
|
- $start_time = env('TEMPLATE_COMPARE_START_TIME', 0);
|
|
|
- if($start_time && $template_10_site && in_array($this->distribution_channel_id,explode(',',$template_10_site))){
|
|
|
- if($this->uid %2 == 0 && strtotime($this->user->created_at) > $start_time){
|
|
|
- if($fee <37) $fee = 37;
|
|
|
- if($fee >45) $fee = 45;
|
|
|
+ //判断是否为测试
|
|
|
+ if($this->distribution_channel_id == 4326 && $book_info->bid == 6450)
|
|
|
+ {
|
|
|
+ $price_rate = 0.04;
|
|
|
+ $fee = ceil($chapter->size * $price_rate);
|
|
|
+ if($fee >189) $fee = 189;
|
|
|
+ }else{
|
|
|
+ $fee = ceil($chapter->size * $price_rate);
|
|
|
+ if($fee >60) $fee = 60;
|
|
|
}
|
|
|
- }
|
|
|
-
|
|
|
- if($template_10_no_abtest_site &&
|
|
|
- in_array($this->distribution_channel_id,explode(',',$template_10_no_abtest_site)) &&
|
|
|
- ($info = DataAnalysisSelectUserService::getByUidAndType($this->uid, 'TEMPLATE_COMPAREV10_2')) &&
|
|
|
- $info->attach
|
|
|
- ){
|
|
|
if($fee <37) $fee = 37;
|
|
|
- if($fee >45) $fee = 45;
|
|
|
- }*/
|
|
|
- if($fee <37) $fee = 37;
|
|
|
- if($fee >60) $fee = 60;
|
|
|
- return $fee;
|
|
|
+
|
|
|
+ return $fee;
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
//降低付费用户书币价值
|