PluginProbe
Timetics – Appointment Booking Calendar & Scheduling / 1.0.16
Timetics – Appointment Booking Calendar & Scheduling v1.0.16
1.0.61 1.0.60 1.0.59 1.0.58 1.0.57 1.0.56 trunk 1.0.0 1.0.1 1.0.10 1.0.11 1.0.12 1.0.13 1.0.14 1.0.15 1.0.16 1.0.17 1.0.18 1.0.19 1.0.2 1.0.20 1.0.21 1.0.22 1.0.23 1.0.24 All 62 releases
timetics / core / emails / re-invite-staff.php

re-invite-staff.php in Timetics – Appointment Booking Calendar & Scheduling 1.0.16, at core/emails/re-invite-staff.php

72 lines 1.5 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * New event email class
4 *
5 * @package Timetics
6 */
7 namespace Timetics\Core\Emails;
8
9 use Timetics\Core\Staffs\Staff;
10
11 class Re_Invite_Staff extends Email {
12
13 /**
14 * Store staff object
15 *
16 * @var Object
17 */
18 public $staff;
19
20 /**
21 * Re Invite Staff Constructor
22 *
23 * @return void
24 */
25 public function __construct( $staff_id ) {
26 $this->staff = get_user_by( 'id', $staff_id );
27 parent::__construct();
28 }
29
30 /**
31 * Get email recipient
32 *
33 * @return string
34 */
35 public function get_recipient() {
36 return $this->staff->user_email;
37 }
38
39 /**
40 * Get new event email
41 *
42 * @return string
43 */
44 public function get_subject() {
45 return esc_html__('Re Invitation Subject','timetics');
46 }
47
48 /**
49 * Get email title
50 *
51 * @return string
52 */
53 public function get_title() {
54 return esc_html__('Re Invitation Staff','timetics');
55 }
56
57 /**
58 * Get template new event email
59 *
60 * @return string
61 */
62 public function get_template() {
63 $user_login = $this->staff->user_login;
64 $locale = get_user_locale($this->staff);
65 $reset_key = get_password_reset_key($this->staff);
66 $reset_url = site_url( "wp-login.php?action=rp&key={$reset_key}&login={$user_login}&wp_lang={$locale}" );
67
68 $reset_url = apply_filters( 'timetics_staff_password_reset_url', $reset_url, $reset_key, $user_login, $locale );
69 include_once TIMETICS_PLUGIN_DIR . '/templates/emails/new-staff.php';
70 }
71 }
72