In this case you may add the `Drupal\Core\DependencyInjection\DependencySerializationTrait` to serialize the injected object, and you will have it in the submitForm() method.
class YourForm extends FormBase {
use DependencySerializationTrait;
// The rest of your code.
robertoperuzzo → changed the visibility of the branch 3436938-add-back-support to hidden.
@noemi I did some changes to the README.md, could you patch your merge request with this patch → ? (because I tried to push it but I don't know why I don't have the permissions).
Thank you.
@lussoluca I'm not able to fix the phpstan error
$ php vendor/bin/phpstan analyze $_WEB_ROOT/modules/custom/$CI_PROJECT_NAME $PHPSTAN_CONFIGURATION --no-progress || EXIT_CODE=$?
------ ---------------------------------------------------------------------
Line src/Attribute/EmbeddingModel.php
------ ---------------------------------------------------------------------
32 Drupal\search_api_typesense\Attribute\EmbeddingModel::__construct()
does not call parent constructor from
Drupal\Component\Plugin\Attribute\Plugin.
------ ---------------------------------------------------------------------
[ERROR] Found 1 error
Any advice?
robertoperuzzo → created an issue.
Hi @francesco81rs, sorry for the delay. Could you test the attached patch → ? Thank you.
I applied the patch MR 5633 in a Drupal Commerce project (D10.0.11) and I have some problems running our custom Kernel tests. In particular, when we create a commerce_order sample containing a couple of order_items the test fails with the message "Test was run in the child process and ended unexpectedly".
Debugging with xDebug I get the message "Error: Xdebug has detected a possible infinite loop, and aborted your script with a stack depth of '256' frames".
I think it is related to the double reference between order and order_item:
1. in the order we have the entity reference to the order_items
$fields['order_items'] = BaseFieldDefinition::create('entity_reference')
->setLabel(t('Order items'))
->setDescription(t('The order items.'))
->setCardinality(BaseFieldDefinition::CARDINALITY_UNLIMITED)
->setSetting('target_type', 'commerce_order_item')
->setSetting('handler', 'default')
->setDisplayOptions('form', [
'type' => 'inline_entity_form_complex',
'weight' => 0,
'settings' => [
'override_labels' => TRUE,
'label_singular' => t('order item'),
'label_plural' => t('order items'),
'removed_reference' => 'delete',
],
])
->setDisplayOptions('view', [
'type' => 'commerce_order_item_table',
'weight' => 0,
])
->setDisplayConfigurable('form', TRUE)
->setDisplayConfigurable('view', TRUE);
2. in the order_item we have the entity reference to the order
// The order backreference, populated by Order::postSave().
$fields['order_id'] = BaseFieldDefinition::create('entity_reference')
->setLabel(t('Order'))
->setDescription(t('The parent order.'))
->setSetting('target_type', 'commerce_order')
->setReadOnly(TRUE);
Probably, the recursive walk in the patch
array_walk_recursive($value, function (&$item) {
if (is_bool($item)) {
$item = (int) $item;
}
if (is_numeric($item)) {
$item = (string) $item;
}
});
drives crazy the order creation.
robertoperuzzo → created an issue.
This issue has been fixed with the current version 1.0.x-dev.
It was my fault, I didn't save the processors' index (/admin/config/search/search-api/index/articles/processors) before running the indexing.
The "Server index status" is correct.
The drush command drush sapi-ts
does not exist anymore, but I can't test the index status because the indexing process is stuck at the initialization.
I'm using the demo_umami
profile and these configs:
search_api.index.articles.yml
uuid: 399ff165-efed-4f19-8fa6-92996fcb4bc8
langcode: en
status: true
dependencies:
config:
- search_api.server.typesense_test
module:
- node
- search_api_typesense
- search_api
id: articles
name: Articles
description: ''
read_only: false
field_settings:
title:
label: Title
datasource_id: 'entity:node'
property_path: title
type: typesense_string
dependencies:
module:
- node
datasource_settings:
'entity:node':
bundles:
default: false
selected:
- article
languages:
default: true
selected: { }
processor_settings:
add_url: { }
aggregated_field: { }
custom_value: { }
entity_type: { }
language_with_fallback: { }
rendered_item: { }
typesense_schema:
all_fields: false
tracker_settings:
default:
indexing_order: fifo
options:
cron_limit: 50
index_directly: true
track_changes_in_references: true
server: typesense_test
search_api.server.typesense_test.yml
uuid: b2c1e11d-a383-4c9d-acf8-87ac86d553a9
langcode: en
status: true
dependencies:
module:
- search_api_typesense
id: typesense_test
name: 'Typesense test'
description: ''
backend: search_api_typesense
backend_config:
admin_api_key: ddev
nodes:
-
host: typesense
port: '8108'
protocol: http
retry_interval_seconds: '2'
I temporarily fixed in my project defining my custom plugin class
class AutocompleteFiltersString extends ViewsAutocompleteFiltersString {
/**
* {@inheritdoc}
*/
public function valueForm(&$form, FormStateInterface $form_state): void {
if (
empty(array_filter($this->view->args))
&& isset($this->view->argument['store_id'])
) {
$this->view->args = [(int) $this->view->argument['store_id']->getValue()];
}
parent::valueForm($form, $form_state);
}
}
robertoperuzzo → created an issue.
robertoperuzzo → created an issue.
robertoperuzzo → made their first commit to this issue’s fork.
lussoluca → credited robertoperuzzo → .
robertoperuzzo → made their first commit to this issue’s fork.
@nessunluogo could you test this patch? Thank you.
robertoperuzzo → made their first commit to this issue’s fork.
Thank you so much @urvashi_vora and I like your iubenda-logo-retouch.png
. I was wondering if you could replace the old 'i' with the new one in my comment #3. It would be awesome.
@fadeslayer as the Multidomain Google Analytics → , I think it would be better to create a new module or a sub-module that manage the multi-domain behaviour. As a matter of fact the Domain → is a contrib not a core module, so considering the test and the experience you have with the two modules Domain and Multidomain Google Analytics, you could propose a solution on which we can work together.
@fadeslayer if I have correctly understand there are 2 issue here:
- if I deny consent after allowing cookies, they are not deleted automatically, though
- Iubenda code is embedded in page but GA cookies are set before, as if Iubenda script "comes late"
I think they are two behaviours you should better explain in two separated issue using the "issue template" that propose the following paragraphs
Problem/Motivation
Steps to reproduce
Proposed resolution
Remaining tasks
User interface changes
API changes
Data model changes
Here is the new logo
I found this SVG version that seems to be the latest version; so I propose to use this one.
robertoperuzzo → created an issue.
robertoperuzzo → created an issue.
Found, it's my fault! I didn't see the "Enable Text completion" checkbox in the CKEditor 5 plugin settings.
The "Method Not Allowed (Allow: POST)" works as designed, but I don't understand why the dropdown menu still remains hidden.
robertoperuzzo → created an issue.
Looking into the repo the line 744 seems to be correct.
Probably it is something regarding my Drupal installation. I look deeper.
robertoperuzzo → created an issue.
The MR !5 patch works locally using the @luenemann advice, but it doesn't work in my CI/CD pipeline because we use the standard --prefer-dist
flag in composer install command.
So, how can I fix this MR?
@luenemann I run you composer reinstall command, but the MR !5 still doesn't apply.
greggles → credited robertoperuzzo → .
Patch #11 also needs some work to be compatible with S3 File System → . I'm getting this error
Drupal\entity_print\Asset\AssetRenderer::__construct(): Argument #4 ($file_system) must be of type Drupal\Core\File\FileSystem, Drupal\s3fs\S3fsFileService given, called in /var/www/html/web/core/lib/Drupal/Component/DependencyInjection/Container.php on line 259
robertoperuzzo → created an issue.
I moved this issue to version 4.x because 3.x is no more supported.
I moved this issue to version 4.x because 3.x is no more supported.
I moved this issue to version 4.x because 3.x is no more supported.
I did another patch to use input type="datetime-local"
, if could be useful for someone.
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/datetime...
@tongadall you are right!
Here is the fixing patch.
Patch #4 works in my Drupal 9.5.7 new installation.
Thank you Rob-PS for your request. I will fix it in the next few days accordingly to my availability.
I've changed the status to "Needs work" because this must be in the core. There is this contrib module https://www.drupal.org/project/date_popup → that could help.
I tested the patch
#270
✨
[PP-2] Use form element of type date instead textfield when selecting a date in an exposed filter
Needs work
and I get that in my view (it has two date fields in exposed filters)
So it works, but I don't need the time field in my case. So probably some other work on it is needed.
robertoperuzzo → made their first commit to this issue’s fork.