|
@@ -117,6 +117,26 @@ class UserExtract extends BaseModel
|
|
|
} else if (strtolower($User['user_type']) == 'routine') {
|
|
} else if (strtolower($User['user_type']) == 'routine') {
|
|
|
RoutineTemplate::sendExtractFail($uid, $fail_msg, $extract_number, $User['nickname']);
|
|
RoutineTemplate::sendExtractFail($uid, $fail_msg, $extract_number, $User['nickname']);
|
|
|
}
|
|
}
|
|
|
|
|
+ // 通知提现用户
|
|
|
|
|
+ $openid = WechatUser::where('uid', $uid)->value('openid');
|
|
|
|
|
+ if (!empty($openid)) {
|
|
|
|
|
+ $group = [
|
|
|
|
|
+ 'first' => '提现审核处理通知',
|
|
|
|
|
+ 'remark' => '点击查看订单详情'
|
|
|
|
|
+ ];
|
|
|
|
|
+ $time = date('Y-m-d H:i:s', time());
|
|
|
|
|
+ $group = array_merge($group, [
|
|
|
|
|
+ 'thing3' => $User['nickname'], //客户名称
|
|
|
|
|
+ 'amount6' => $extract_number, //提现金额
|
|
|
|
|
+ 'const15' => '驳回', //审核结果
|
|
|
|
|
+ 'thing4' => $extract_type, //提现分类
|
|
|
|
|
+ 'time8' => $time, //提现时间
|
|
|
|
|
+ ]);
|
|
|
|
|
+
|
|
|
|
|
+ @file_put_contents('quanju.txt', json_encode($group) . "-模版消息4\r\n", 8);
|
|
|
|
|
+ $res = WechatTemplateService::sendTemplate($openid, WechatTemplateService::Extract_SUCCESS, $group);
|
|
|
|
|
+ @file_put_contents('quanju.txt', json_encode($res) . "-模版消息返回4\r\n", 8);
|
|
|
|
|
+ }
|
|
|
return self::edit(compact('fail_time', 'fail_msg', 'status'), $id);
|
|
return self::edit(compact('fail_time', 'fail_msg', 'status'), $id);
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -184,7 +204,30 @@ class UserExtract extends BaseModel
|
|
|
'remark' => '点击查看我的余额明细'
|
|
'remark' => '点击查看我的余额明细'
|
|
|
], Url::buildUrl('/user/cashrecord')->suffix('')->domain(true)->build());
|
|
], Url::buildUrl('/user/cashrecord')->suffix('')->domain(true)->build());
|
|
|
}
|
|
}
|
|
|
|
|
+
|
|
|
|
|
+ // 通知提现用户
|
|
|
|
|
+ $openid = WechatUser::where('uid', $data['uid'])->value('openid');
|
|
|
|
|
+ $nickname = User::where('uid', $data['uid'])->value('nickname');
|
|
|
|
|
+ if (!empty($openid)) {
|
|
|
|
|
+ $group = [
|
|
|
|
|
+ 'first' => '提现审核处理通知',
|
|
|
|
|
+ 'remark' => '点击查看订单详情'
|
|
|
|
|
+ ];
|
|
|
|
|
+ $time = date('Y-m-d H:i:s', time());
|
|
|
|
|
+ $group = array_merge($group, [
|
|
|
|
|
+ 'thing3' => $nickname, //客户名称
|
|
|
|
|
+ 'amount6' => $extractNumber, //提现金额
|
|
|
|
|
+ 'const15' => '通过', //审核结果
|
|
|
|
|
+ 'thing4' => $extract_type, //提现分类
|
|
|
|
|
+ 'time8' => $time, //提现时间
|
|
|
|
|
+ ]);
|
|
|
|
|
+
|
|
|
|
|
+ @file_put_contents('quanju.txt', json_encode($group) . "-模版消息5\r\n", 8);
|
|
|
|
|
+ $res = WechatTemplateService::sendTemplate($openid, WechatTemplateService::Extract_SUCCESS, $group);
|
|
|
|
|
+ @file_put_contents('quanju.txt', json_encode($res) . "-模版消息返回5\r\n", 8);
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
|
|
+
|
|
|
return self::edit(['status' => 1], $id);
|
|
return self::edit(['status' => 1], $id);
|
|
|
}
|
|
}
|
|
|
|
|
|