44
55/**
66 * Class AppSettingsForm
7+ *
8+ * @property array adminFriendlyEmail
9+ * @property array systemFriendlyEmail
10+ *
711 * @package justcoded\yii2\settings\forms
812 */
913class AppSettingsForm extends SettingsForm
@@ -27,14 +31,14 @@ class AppSettingsForm extends SettingsForm
2731 *
2832 * @var string
2933 */
30- public $ senderEmail ;
34+ public $ systemEmail ;
3135
3236 /**
3337 * Name, which will be set in 'from' mail column
3438 *
3539 * @var string
3640 */
37- public $ senderName ;
41+ public $ systemName ;
3842
3943 /**
4044 * In minuts
@@ -56,9 +60,9 @@ class AppSettingsForm extends SettingsForm
5660 public function rules ()
5761 {
5862 return [
59- [['adminEmail ' , 'adminName ' , 'senderName ' , 'senderEmail ' ], 'string ' ],
60- [['adminEmail ' , 'senderEmail ' ], 'email ' ],
61- [['passwordResetToken ' , 'rememberMeExpiration ' , 'senderEmail ' , 'adminEmail ' ], 'required ' ],
63+ [['adminEmail ' , 'adminName ' , 'systemEmail ' , 'systemName ' ], 'string ' ],
64+ [['adminEmail ' , 'systemEmail ' ], 'email ' ],
65+ [['passwordResetToken ' , 'rememberMeExpiration ' , 'systemEmail ' , 'adminEmail ' ], 'required ' ],
6266 [['passwordResetToken ' , 'rememberMeExpiration ' ], 'integer ' ],
6367 ];
6468 }
@@ -71,8 +75,8 @@ public function attributeLabels()
7175 return [
7276 'adminEmail ' => 'Admin email ' ,
7377 'adminName ' => 'Admin name ' ,
74- 'senderEmail ' => 'Sender email ' ,
75- 'senderName ' => 'Sender name ' ,
78+ 'systemEmail ' => 'System email ' ,
79+ 'systemName ' => 'System email name ' ,
7680 'passwordResetToken ' => 'Password reset token ' ,
7781 'rememberMeExpiration ' => 'Remember me expiration ' ,
7882 ];
@@ -99,8 +103,8 @@ public function getAdminFriendlyEmail()
99103 /**
100104 * @return array
101105 */
102- public function getSenderFriendlyEmail ()
106+ public function getSystemFriendlyEmail ()
103107 {
104- return [$ this ->senderEmail => $ this ->senderName ];
108+ return [$ this ->systemEmail => $ this ->systemName ];
105109 }
106110}
0 commit comments