translationHasParent example

'update' => [],
            'delete' => [],
        ];

        foreach ($commits as $commit) {
            foreach ($commit->getData() as $data) {
                $definition = $this->registry->getByEntityName($data->getEntityName());

                switch ($data->getAction()) {
                    case 'insert':
                    case 'update':
                        if ($definition instanceof EntityTranslationDefinition && $this->translationHasParent($commit$data)) {
                            break;
                        }

                        $payload = $data->getPayload();
                        if (empty($payload)) {
                            break;
                        }
                        $payload = $this->addVersionToPayload($payload$definition, Defaults::LIVE_VERSION);
                        $payload = $this->addTranslationToPayload($data->getEntityId()$payload$definition$commit);
                        $writes[$data->getAction()][$definition->getEntityName()][] = $payload;

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