I have spent the last week reinstalling ERPAL platform multiple times, using the latest dev version, on different servers.

The most persisting error that makes the platform ununsable is thrown when I try to create a Sales Process, either directly or by creating it in an another form like an Email or Meeting. It shows:

Warning: Creating default object from empty value in date_item_update_entity_id() (line 174 of /home/erpal/public_html/profiles/erpal_platform/modules/contrib/date_item/includes/date_item.api.inc).
EntityMalformedException: Missing bundle property on entity of type date_item. in entity_extract_ids() (line 7907 of /home/erpal/public_html/includes/common.inc).


The strange thing is that if I test the platform with https://simplytest.me/project/erpal_platform then this error does not occur. (It does however show other errors that I will post in another issue)

How I install ERPAL is nothing fancy, just the way all distributions are installed: upload of the source code, create and empty database, go to the domain url and follow the installation instructions. I do set the timezone to Curacao and the currency to Netherlands Antillean Guilder. Thats it..nothing extra.

I urge the developers of this platform to *please* assist with this bug, which I'm quite sure is a bug hidden away in the platform code somewhere.

Only local images are allowed.

CommentFileSizeAuthor
#3 date_item.jpg17.34 KBYuri
salesprocess-error.png17.79 KBYuri
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Yuri created an issue. See original summary.

Yuri’s picture

And I'm not the only one having this issue: see https://www.drupal.org/node/2532928

Yuri’s picture

Issue summary: View changes
FileSize
17.34 KB

Yuri’s picture

Yuri’s picture

Eureka! The first indication what caused this: after 2 more test installations with various configurations, I found out that after deleting one or more sales processes, this causes this issue error to appear each time a new sales process is created.
Clearing the caches does not resolve this.

Some similar issues in other projects point to the possibility of orphaned entities in the database that are left after the deletion.

AndrewsizZ’s picture

Hey Yuri,
I think I found issue, created patch https://www.drupal.org/node/2811239#comment-11690805
Could you cehck if it works for you?

Yuri’s picture

Thank you AndrewsizZ, that patch works for saving a sales process.
However....
A new error appears when an activity is saved that contains a newsly created sales process:

EntityMetadataWrapperException: Invalid data value given. Be sure it matches the required data type and format. Value at crm_core_activity(): . in EntityDrupalWrapper->set() (line 756 of /home/erpal/public_html/profiles/erpal_platform/modules/contrib/entity/includes/entity.wrapper.inc).

To reproduce:
Create an activity, fill in required fields, use the 'create sales process link in the actifity form to create and save a sales process.
The sales process is saved without error and visible in its field in the activity form.
Save the activity.
Error appears mentioned above.

  • AndrewsizZ committed 2106e10 on 7.x-3.x
    Issue #2810549 by Yuri, AndrewsizZ: Missing bundle property on entity of...
AndrewsizZ’s picture

Status: Active » Fixed

Hey Yuri,
If inital issue fixed I will close current issue. For new error please create new issue.
Thanks

Yuri’s picture

Related issue created here: https://www.drupal.org/node/2811689

Yuri’s picture

Other new related issue here: https://www.drupal.org/node/2811785

Yuri’s picture

Status: Fixed » Needs review
ChoY’s picture

I cannot reproduce this error - and I am not sure if a patch is needed here
Yuri: How do you configure the date field in date item types? Default should be site's time zone