File tree Expand file tree Collapse file tree 3 files changed +8
-5
lines changed
app/code/Magento/LoginAsCustomer
view/frontend/web/js/view Expand file tree Collapse file tree 3 files changed +8
-5
lines changed Original file line number Diff line number Diff line change 13
13
14
14
/**
15
15
* Customer data for the logged_as_customer section
16
+ *
17
+ * @SuppressWarnings(PHPMD.CookieAndSessionMisuse)
16
18
*/
17
19
class LoginAsCustomer implements SectionSourceInterface
18
20
{
@@ -41,6 +43,7 @@ public function __construct(
41
43
42
44
/**
43
45
* Retrieve private customer data for the logged_as_customer section
46
+ *
44
47
* @return array
45
48
*/
46
49
public function getSectionData ():array
@@ -50,8 +53,8 @@ public function getSectionData():array
50
53
}
51
54
52
55
return [
53
- 'admin_user_id ' => $ this ->customerSession ->getLoggedAsCustomerAdmindId (),
54
- 'website_name ' => $ this ->storeManager ->getWebsite ()->getName ()
56
+ 'adminUserId ' => $ this ->customerSession ->getLoggedAsCustomerAdmindId (),
57
+ 'websiteName ' => $ this ->storeManager ->getWebsite ()->getName ()
55
58
];
56
59
}
57
60
}
Original file line number Diff line number Diff line change 2
2
"name" : " magento/module-login-as-customer" ,
3
3
"description" : " Allow for admin to enter a customer account" ,
4
4
"require" : {
5
+ "php" : " ~7.1.3||~7.2.0||~7.3.0" ,
5
6
"magento/framework" : " *" ,
6
7
"magento/module-backend" : " *" ,
7
8
"magento/module-checkout" : " *" ,
19
20
" OSL-3.0" ,
20
21
" AFL-3.0"
21
22
],
22
- "version" : " 2.2.1" ,
23
23
"autoload" : {
24
24
"files" : [ " registration.php" ],
25
25
"psr-4" : {
Original file line number Diff line number Diff line change @@ -23,11 +23,11 @@ define([
23
23
24
24
this . customer = customerData . get ( 'customer' ) ;
25
25
this . loginAsCustomer = customerData . get ( 'loggedAsCustomer' ) ;
26
- this . isVisible ( this . loginAsCustomer ( ) . admin_user_id ) ;
26
+ this . isVisible ( this . loginAsCustomer ( ) . adminUserId ) ;
27
27
28
28
this . notificationText = $ . mage . __ ( 'You are connected as <strong>%1</strong> on %2' )
29
29
. replace ( '%1' , this . customer ( ) . fullname )
30
- . replace ( '%2' , this . loginAsCustomer ( ) . website_name ) ;
30
+ . replace ( '%2' , this . loginAsCustomer ( ) . websiteName ) ;
31
31
} ,
32
32
33
33
/** @inheritdoc */
You can’t perform that action at this time.
0 commit comments