I want to add a selector for date during order process in checkout. In which step should the custom field of an order be updated? And how is the custom field update done for order or other entity? I want to add the fields as it is shown in official docs.
$this->customFieldSetRepository->create([
[
'name' => 'swag_example',
'customFields' => [
['name' => 'swag_example_size', 'type' => CustomFieldTypes::INT],
['name' => 'swag_example_color', 'type' => CustomFieldTypes::TEXT]
]
]
], $context);