Correction by code style
This commit is contained in:
Ivan Chaplygin 2023-09-01 16:16:57 +03:00
parent 0cbd954071
commit a2623cba56
2 changed files with 5 additions and 4 deletions

View file

@ -259,7 +259,7 @@ class RetailcrmIcml
if (
empty($feature['id_feature'])
|| empty($feature['name'])
|| $feature['value'] === null
|| null === $feature['value']
) {
continue;
}
@ -272,7 +272,7 @@ class RetailcrmIcml
$this->writer->startElement('param');
$this->writer->writeAttribute('code', 'feature_' . $feature['id_feature'] . '_' . $numberCode);
$this->writer->writeAttribute('name' , $feature['name']);
$this->writer->writeAttribute('name', $feature['name']);
$this->writer->text($feature['value']);
$this->writer->endElement();

View file

@ -139,7 +139,8 @@ class RetailcrmCatalogTest extends RetailcrmTestCase
$this->assertNotFalse($xml);
}
private function getFeaturesData() {
private function getFeaturesData()
{
return [
[
'id_feature' => 1,
@ -165,7 +166,7 @@ class RetailcrmCatalogTest extends RetailcrmTestCase
'id_feature' => 2,
'name' => 'test',
'value' => 'value2',
]
],
];
}
}