CoolCMS API

ProductImportSettingsFieldsTrait

Job settings fields shared by two forms: `add` (new job, {@see ProductImportAddFormTrait}) and `edit` (change + "validate again", {@see ProductImportSettingsFormTrait}).

Shared on purpose: if the field sets diverged, the admin could not switch in edit what was set in add, and the defaults would diverge too; the defaults are binding (autoCreateProducers=1, autoCreateOptions=0, autoCreateCategories=0).

Used once on the presenter; both form traits only call its methods.

Table of Contents

Methods

addProductImportSettingsFields()  : void
Defaults exactly as binding (`autoCreateProducers=1`, `autoCreateOptions=0`, `autoCreateCategories=0`).
buildProductImportSettings()  : array<string, mixed>

Methods

addProductImportSettingsFields()

Defaults exactly as binding (`autoCreateProducers=1`, `autoCreateOptions=0`, `autoCreateCategories=0`).

private addProductImportSettingsFields(Form $form) : void
Parameters
$form : Form

buildProductImportSettings()

private buildProductImportSettings(ArrayHash $values) : array<string, mixed>
Parameters
$values : ArrayHash
Return values
array<string, mixed> —

settings shape; the single source of truth is the job settings, not <settings> from the file.

On this page

Search results