getTextField example


        return [
            'properties' => [
                'id' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'number' => array_merge($this->textMapping->getKeywordField()['copy_to' => 'swag_all']),
                'categoryIds' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'variantId' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'taxId' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'articleId' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'kind' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'name' => array_merge(
                    $this->textMapping->getTextField(),
                    [
                        'fields' => [
                            'raw' => $this->textMapping->getKeywordField(),
                        ],
                        'copy_to' => 'swag_all',
                    ]
                ),
                'inStock' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'ean' => $this->textMapping->getKeywordField(),
                'supplierNumber' => $this->textMapping->getKeywordField(),
                'additionalText' => $this->textMapping->getTextField(),
                

        $analyzers = $this->shopAnalyzer->get($shop);

        $fields = [
            'raw' => $this->textMapping->getKeywordField(),
        ];

        foreach ($analyzers as $analyzer) {
            $key = $analyzer . '_analyzer';

            $fields[$key] = array_merge(
                $this->textMapping->getTextField(),
                ['analyzer' => $analyzer]
            );
        }

        return array_merge(
            $this->textMapping->getTextField(),
            ['fields' => $fields]
        );
    }
}

        return [
            'properties' => [
                'id' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'number' => $this->getTextFieldWithRawData(),
                'invoiceAmount' => TypeMappingInterface::MAPPING_DOUBLE_FIELD,
                'invoiceShipping' => TypeMappingInterface::MAPPING_DOUBLE_FIELD,
                'orderTime' => TypeMappingInterface::MAPPING_DATE_AND_DATE_TIME_FIELD,
                'status' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'cleared' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'customerId' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'supplierId' => $this->textMapping->getTextField(),
                'billingCountryId' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'shippingCountryId' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'groupKey' => $this->textMapping->getKeywordField(),
                'email' => $this->getTextFieldWithRawData(),
                'orderDocuments' => $this->getTextFieldWithRawData(),
                'transactionId' => $this->textMapping->getKeywordField(),
                'firstname' => $this->getTextFieldWithRawData(),
                'lastname' => $this->getTextFieldWithRawData(),
                'paymentId' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'paymentName' => $this->textMapping->getTextField(),
                'dispatchId' => TypeMappingInterface::MAPPING_LONG_FIELD,
                

            '_source' => [
                'includes' => ['id', 'mainVariantId', 'variantId', 'number'],
            ],
            'properties' => [
                // Identifiers                 'id' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'mainVariantId' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'variantId' => TypeMappingInterface::MAPPING_LONG_FIELD,

                // Number fields                 'number' => array_merge($this->textMapping->getTextField()['analyzer' => 'standard', 'fields' => ['raw' => $this->textMapping->getKeywordField()]]),
                'ean' => $this->textMapping->getKeywordField(),
                'manufacturerNumber' => $this->fieldMapping->getLanguageField($shop),

                // Language fields                 'name' => $this->fieldMapping->getLanguageField($shop),
                'shortDescription' => $this->fieldMapping->getLanguageField($shop),
                'longDescription' => $this->fieldMapping->getLanguageField($shop),
                'additional' => $this->fieldMapping->getLanguageField($shop),
                'keywords' => $this->fieldMapping->getLanguageField($shop),
                'metaTitle' => $this->fieldMapping->getLanguageField($shop),

                
'company' => $this->getTextFieldWithRawData(),
                'department' => $this->getTextFieldWithRawData(),
                'street' => $this->getTextFieldWithRawData(),
                'zipcode' => $this->getTextFieldWithRawData(),
                'city' => $this->getTextFieldWithRawData(),
                'phone' => $this->getTextFieldWithRawData(),
                'countryId' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'countryName' => $this->textMapping->getKeywordField(),
                'customerGroupId' => TypeMappingInterface::MAPPING_LONG_FIELD,
                'customerGroupName' => $this->textMapping->getKeywordField(),

                'swag_all' => $this->textMapping->getTextField(),
            ],
        ];
    }

    /** * {@inheritdoc} */
    public function getDomainName()
    {
        return 'customer';
    }

    
Home | Imprint | This part of the site doesn't use cookies.