|
@@ -2379,10 +2379,9 @@ class WelcomeController extends BaseController
|
|
|
|
|
|
private function monthOrderInfo($openid)
|
|
private function monthOrderInfo($openid)
|
|
{
|
|
{
|
|
- return '';
|
|
|
|
$property = $this->property;
|
|
$property = $this->property;
|
|
if (!$property) return '';
|
|
if (!$property) return '';
|
|
- $month_info = UserMonthService::getOrderAndSignStatusByUid($this->uid);
|
|
|
|
|
|
+ /*$month_info = UserMonthService::getOrderAndSignStatusByUid($this->uid);
|
|
if($month_info){
|
|
if($month_info){
|
|
return [
|
|
return [
|
|
'price' => '30元',
|
|
'price' => '30元',
|
|
@@ -2391,93 +2390,38 @@ class WelcomeController extends BaseController
|
|
'focus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/month_order_check.png',
|
|
'focus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/month_order_check.png',
|
|
'unfocus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/month_order_1.png'
|
|
'unfocus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/month_order_1.png'
|
|
];
|
|
];
|
|
- /*if(in_array('MONTH',$month_info)){
|
|
|
|
- return [
|
|
|
|
- 'price' => '30元',
|
|
|
|
- 'text' => '30元包月 全站万本精彩小说免费看',
|
|
|
|
- 'link' => generateMonthOrderUrl($this->uid),
|
|
|
|
- 'focus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/month_order_check.png',
|
|
|
|
- 'unfocus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/month_order_1.png'
|
|
|
|
- ];
|
|
|
|
- }
|
|
|
|
- if(in_array('WEEK',$month_info)){
|
|
|
|
- return [
|
|
|
|
- 'price' => '7元',
|
|
|
|
- 'text' => '7元包周 全站万本精彩小说免费看',
|
|
|
|
- 'link' => generateMonthOrderUrlV2($this->uid, env('MONTH_WEEK_ORDER_PLAN_ID'), _getIp()),
|
|
|
|
- 'focus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/week-order-2.png',
|
|
|
|
- 'unfocus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/week-order-1.png'
|
|
|
|
- ];
|
|
|
|
- }*/
|
|
|
|
- }
|
|
|
|
|
|
+ }*/
|
|
if (in_array($this->distribution_channel_id, explode(',', redisEnv('OPEN_ORDER_INNER_SITES')))) {
|
|
if (in_array($this->distribution_channel_id, explode(',', redisEnv('OPEN_ORDER_INNER_SITES')))) {
|
|
- $info = DataAnalysisSelectUserService::getByUidAndType($this->uid, 'MONTH_V2');
|
|
|
|
|
|
+ $info = DataAnalysisSelectUserService::getByUidAndType($this->uid, 'MONTH_V3');
|
|
if ($info) {
|
|
if ($info) {
|
|
- if ($info->attach == 'show' || $info->attach == 'week-show') {
|
|
|
|
|
|
+ if ($info->attach == 'show') {
|
|
return [
|
|
return [
|
|
- 'price' => '30元',
|
|
|
|
- 'text' => '30元包月 全站万本精彩小说免费看',
|
|
|
|
- 'link' => generateMonthOrderUrl($this->uid),
|
|
|
|
|
|
+ 'price' => '98元',
|
|
|
|
+ 'text' => '98元包季 全站万本精彩小说免费看',
|
|
|
|
+ 'link' => \App\Modules\User\Services\UserMonthService::monthOrderLink($this->uid,env('MONTH_QUARTER_ORDER_PLAN_ID')),
|
|
'focus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/month_order_check.png',
|
|
'focus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/month_order_check.png',
|
|
'unfocus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/month_order_1.png'
|
|
'unfocus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/month_order_1.png'
|
|
];
|
|
];
|
|
}
|
|
}
|
|
- /*if ($info->attach == 'week-show') {
|
|
|
|
- return [
|
|
|
|
- 'price' => '7元',
|
|
|
|
- 'text' => '7元包周 全站万本精彩小说免费看',
|
|
|
|
- 'link' => generateMonthOrderUrlV2($this->uid, env('MONTH_WEEK_ORDER_PLAN_ID'), _getIp()),
|
|
|
|
- 'focus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/week-order-2.png',
|
|
|
|
- 'unfocus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/week-order-1.png'
|
|
|
|
- ];
|
|
|
|
- }*/
|
|
|
|
return '';
|
|
return '';
|
|
}
|
|
}
|
|
}
|
|
}
|
|
if (in_array($this->distribution_channel_id, explode(',', redisEnv('OPEN_ORDER_INNER_SITES')))
|
|
if (in_array($this->distribution_channel_id, explode(',', redisEnv('OPEN_ORDER_INNER_SITES')))
|
|
&& in_array($property, ['none', 'low', 'medium'])
|
|
&& in_array($property, ['none', 'low', 'medium'])
|
|
) {
|
|
) {
|
|
- if (!UserMonthService::isSignMonth($openid)) {
|
|
|
|
- $start_time = redisEnv('MONTH_TEMPLATE_COMPARE_START_TIME', 0);
|
|
|
|
- if (!$start_time || (strtotime($this->user->created_at) < $start_time)) {
|
|
|
|
- if ($property == 'nonenone') {
|
|
|
|
- return [
|
|
|
|
- 'price' => '7元',
|
|
|
|
- 'text' => '7元包周 全站万本精彩小说免费看',
|
|
|
|
- 'link' => generateMonthOrderUrlV2($this->uid, env('MONTH_WEEK_ORDER_PLAN_ID'), _getIp()),
|
|
|
|
- 'focus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/week-order-2.png',
|
|
|
|
- 'unfocus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/week-order-1.png'
|
|
|
|
- ];
|
|
|
|
- } else {
|
|
|
|
- return [
|
|
|
|
- 'price' => '30元',
|
|
|
|
- 'text' => '30元包月 全站万本精彩小说免费看',
|
|
|
|
- 'link' => generateMonthOrderUrl($this->uid),
|
|
|
|
- 'focus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/month_order_check.png',
|
|
|
|
- 'unfocus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/month_order_1.png'
|
|
|
|
- ];
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
- $attach = $this->uid % 2 == 0 ? 'show' : 'hide';
|
|
|
|
- if ($attach == 'hide') return '';
|
|
|
|
- if ($property == 'nonenone') {
|
|
|
|
- return [
|
|
|
|
- 'price' => '7元',
|
|
|
|
- 'text' => '7元包周 全站万本精彩小说免费看',
|
|
|
|
- 'link' => generateMonthOrderUrlV2($this->uid, env('MONTH_WEEK_ORDER_PLAN_ID'), _getIp()),
|
|
|
|
- 'focus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/week-order-2.png',
|
|
|
|
- 'unfocus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/week-order-1.png'
|
|
|
|
- ];
|
|
|
|
- } else {
|
|
|
|
- return [
|
|
|
|
- 'price' => '30元',
|
|
|
|
- 'text' => '30元包月 全站万本精彩小说免费看',
|
|
|
|
- 'link' => generateMonthOrderUrl($this->uid),
|
|
|
|
- 'focus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/month_order_check.png',
|
|
|
|
- 'unfocus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/month_order_1.png'
|
|
|
|
- ];
|
|
|
|
- }
|
|
|
|
- }
|
|
|
|
|
|
+ $start_time = redisEnv('MONTH_TEMPLATE_COMPARE_START_TIME', 0);
|
|
|
|
+ if(!$start_time || (strtotime($this->user->created_at) < $start_time )) return '';
|
|
|
|
+
|
|
|
|
+ $attach = $this->uid % 2 == 0 ? 'show' : 'hide';
|
|
|
|
+ if ($attach == 'hide') return '';
|
|
|
|
+ return [
|
|
|
|
+ 'price' => '98元',
|
|
|
|
+ 'text' => '98元包季 全站万本精彩小说免费看',
|
|
|
|
+ 'link' => \App\Modules\User\Services\UserMonthService::monthOrderLink($this->uid,env('MONTH_QUARTER_ORDER_PLAN_ID')),
|
|
|
|
+ 'focus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/month_order_check.png',
|
|
|
|
+ 'unfocus_img'=>'https://cdn-novel.iycdm.com/h5/monthpay/month_order_1.png'
|
|
|
|
+ ];
|
|
|
|
+
|
|
}
|
|
}
|
|
return '';
|
|
return '';
|
|
}
|
|
}
|