/** * Create a new event instance. * * @return void */ public function __construct($topic_uuid, $topics_uid, TopicReply $data) { $notification = new Notification(); $this->count = $notification->countNotification($topics_uid); $this->author = $topics_uid; $this->topic = $topic_uuid; $this->data = $data; }
/** * Create a new event instance. * * @return void * * $flg -> increment or decrement */ public function __construct($notify_user, $topics_uuid, $is_upvote) { $this->user = $notify_user; $notification = new Notification(); $this->count = $notification->countNotification($notify_user); $this->is_upvote = $is_upvote; //Get the most upvote count*/ $tp = new Topic(); $this->upv_cnt = $tp->upvoteTopic($topics_uuid, $is_upvote); $this->topic = $topics_uuid; }
/** * Create a new event instance. * * @return void */ public function __construct($user, $to_follow_uuid) { $notification = new Notification(); $this->count = $notification->countNotification($to_follow_uuid); $this->follow_uuid = $to_follow_uuid; }