File tree Expand file tree Collapse file tree 2 files changed +10
-6
lines changed
Block/Adminhtml/Catalog/Product/Edit/Tab/Attributes
Test/Unit/Block/Adminhtml/Catalog/Product/Edit/Tab/Attributes Expand file tree Collapse file tree 2 files changed +10
-6
lines changed Original file line number Diff line number Diff line change @@ -111,10 +111,11 @@ public function getOptions()
111
111
public function isDisabledField ()
112
112
{
113
113
return $ this ->_getData ('is_disabled_field ' )
114
- || $ this ->getProduct ()->getId ()
115
- && ($ this ->getAttribute ()->getAttributeCode () === 'price '
116
- || $ this ->getElement ()->getReadonly ()
117
- );
114
+ || ($ this ->getProduct ()->getId ()
115
+ && $ this ->getAttribute ()->getAttributeCode () === 'price '
116
+ )
117
+ || $ this ->getElement ()->getReadonly ();
118
+
118
119
}
119
120
120
121
/**
Original file line number Diff line number Diff line change @@ -40,7 +40,10 @@ public function setUp()
40
40
public function getProduct ()
41
41
{
42
42
$ product = $ this ->getMockBuilder (Product::class)->disableOriginalConstructor ()->getMock ();
43
- $ this ->registry ->expects ($ this ->once ())->method ('registry ' )->with ('product ' )->will (
43
+ $ this ->registry ->expects ($ this ->once ())
44
+ ->method ('registry ' )
45
+ ->with ('product ' )
46
+ ->will (
44
47
$ this ->returnValue ($ product )
45
48
);
46
49
return $ product ;
@@ -70,4 +73,4 @@ public function testGetExtendedElement()
70
73
$ this ->object ->setIsDisabledField (true );
71
74
$ this ->object ->getExtendedElement ($ switchAttributeCode );
72
75
}
73
- }
76
+ }
You can’t perform that action at this time.
0 commit comments