<commit_before><?php
namespace Wechat\Event;

class EventEvent {



	/**
	 * 客户发送事件消息处理
	 * 
	 * @param unknown_type $openId
	 * @param unknown_type $event
	 * @param unknown_type $evnetKey
	 * @param unknown_type $ticket
	 */
	public function eventHandle($openId,$event,$evnetKey='',$ticket=''){

			switch ($event){
				//如果是关注事件，拉取客户资料进行存储
				//TODO 此功能为认证帐号才有，这可考虑添加帐号认证判断
				case 'subscribe':
/*					if ($info = get_client_info($openId)){
						$data = $info;
						$data['event_key']=$evnetKey;
						$data['ticket']=$ticket;
					}*/
						$data['openid']=$openId;
						$data['subscribe']='1';
						$data['subscribe_time']=time();
<commit_msg>关注事件判断并拉取客户资料<commit_after><?php
namespace Wechat\Event;

class EventEvent {



	/**
	 * 客户发送事件消息处理
	 * 
	 * @param unknown_type $openId
	 * @param unknown_type $event
	 * @param unknown_type $evnetKey
	 * @param unknown_type $ticket
	 */
	public function eventHandle($openId,$event,$evnetKey='',$ticket=''){

			switch ($event){
				//如果是关注事件，拉取客户资料进行存储
				//TODO 无法获取系统配置，采用自定义配置文件方式配置认证状态
				case 'subscribe':
					if (WEB_ACCOUNT_RZ === '1'){
						$data = get_client_info($openId);
						$data['event_key']=$evnetKey;
						$data['ticket']=$ticket;
					}else{
						$data['openid']=$openId;
						$data['subscribe']='1';
						$data['subscribe_time']=time();
					}
{'fraction_non_alphanumeric': 0.1733232856066315, 'fraction_numerical': 0.002260738507912585, 'mean_word_length': 3.611111111111111, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1877934', 'n_tokens_mistral': 663, 'n_tokens_neox': 572, 'n_words': 77}