Skip to content

Commit

Permalink
shop update
Browse files Browse the repository at this point in the history
  • Loading branch information
skeeks-semenov committed Feb 20, 2024
1 parent 11c1b0d commit 3e7aca8
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions src/ImportCsvShopContentHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
use yii\widgets\ActiveForm;

/**
* @property ShopStore $shopStore
* @property ShopStore $shopStore
*
* @author Semenov Alexander <[email protected]>
*/
Expand Down Expand Up @@ -138,11 +138,9 @@ public function renderConfigForm(ActiveForm $form)
}

echo $form->field($this, 'content_id')->listBox(
ArrayHelper::merge(['' => ' - '], CmsContent::getDataForSelect(true, function (ActiveQuery $activeQuery) {
$activeQuery->andWhere([
'id' => \yii\helpers\ArrayHelper::map(\skeeks\cms\shop\models\ShopContent::find()->all(), 'content_id', 'content_id'),
]);
})), [
ArrayHelper::merge(['' => ' - '], [
\Yii::$app->shop->contentProducts->id => \Yii::$app->shop->contentProducts->name
]), [
'size' => 1,
'data-form-reload' => 'true',
]);
Expand Down Expand Up @@ -422,7 +420,6 @@ public function import($number, $row)
}



if ($this->is_save_source_data) {
$data = $this->getRowDataWithHeaders($row);
$shopProductIsUpdate = true;
Expand Down Expand Up @@ -478,7 +475,6 @@ public function import($number, $row)
unset($element);



return $result;
}

Expand Down

0 comments on commit 3e7aca8

Please sign in to comment.