modmore / Commerce_DigitalProduct

Digital product module for Modmore's Commerce.
5 stars 1 forks source link

Bundle product with digital-products won't show in invoice #13

Open hurby opened 11 months ago

hurby commented 11 months ago

A single download product wil be inside the invoice

Scherm­afbeelding 2023-10-05 om 13 12 59

A bundle containing digital products wil not.

Scherm­afbeelding 2023-10-05 om 13 13 57
hurby commented 11 months ago

It has something to do with the amout of digital products inside the bundle, a bundle of 59 digital products will not show in the invoice a bundle with 4 products will. Strange since the bundle is the only product needing to be in the invoice

this i find in the error log

INSERT INTO modx_commerce_order_address (id, class_key, properties, order, type, user_address, fullname, firstname, lastname, company, address1, address2, address3, zip, city, state, country, phone, mobile, email, notes, address) VALUES (1249, 'comOrderAddress', 'a:1:{s:16:\"vat_registration\";s:0:\"\";}', 1420, 'billing', 14, 'dewa', '', '', '', 'dew', '', '', '23', '32', '32', 'NL', '', '', 'ew@dew.nl', '', 0) Array ( [0] => 23000 [1] => 1062 [2] => Duplicate entry '1249' for key 'PRIMARY' )

[2023-10-05 11:27:41] (ERROR @ /www/core/xpdo/om/xpdoobject.class.php : 1452) Error 23000 executing statement: INSERT INTO modx_commerce_order_address (id, class_key, properties, order, type, user_address, fullname, firstname, lastname, company, address1, address2, address3, zip, city, state, country, phone, mobile, email, notes, address) VALUES (1250, 'comOrderAddress', 'a:0:{}', 1420, 'shipping', 13, 'dewa', '', '', '', 'dew', '', '', '23', '32', '32', 'NL', '', '', 'ew@dew.nl', '', 0) Array ( [0] => 23000 [1] => 1062 [2] => Duplicate entry '1250' for key 'PRIMARY' )

muzzwood commented 11 months ago

I don't think that error is related, though that's also interesting. Is that being logged during the address step of checkout? I've only tested with a few products so far, but will look into it.

hurby commented 11 months ago

The bundle contains 59 files. I know it is a lot of files Mayby there's something going wrong with the order object to pdf. Mail is much bigger to generate but fine. It is pure the invoice.

hurby commented 11 months ago

From address step onwards till payment, the last two lines are the thing i think

[2023-10-05 11:49:42] (ERROR @ /www/core/xpdo/om/xpdoobject.class.php : 1452) Error 23000 executing statement: INSERT INTO modx_commerce_order_address (id, class_key, properties, order, type, user_address, fullname, firstname, lastname, company, address1, address2, address3, zip, city, state, country, phone, mobile, email, notes, address) VALUES (1261, 'comOrderAddress', 'a:1:{s:16:\"vat_registration\";s:0:\"\";}', 1423, 'billing', 14, 'dewa', '', '', '', 'dew', '', '', '23', '32', '32', 'NL', '', '', 'ew@dew.nl', '', 0) Array ( [0] => 23000 [1] => 1062 [2] => Duplicate entry '1261' for key 'PRIMARY' )

[2023-10-05 11:49:42] (ERROR @ /www/core/xpdo/om/xpdoobject.class.php : 1452) Error 23000 executing statement: INSERT INTO modx_commerce_order_address (id, class_key, properties, order, type, user_address, fullname, firstname, lastname, company, address1, address2, address3, zip, city, state, country, phone, mobile, email, notes, address) VALUES (1262, 'comOrderAddress', 'a:0:{}', 1423, 'shipping', 80, 'herbert', '', '', '', 'Plein Eendragt 25b', '', '', '3111 AS', 'Schiedam', '', 'BE', '0626142194', '', 'hurby@hurby.nl', '', 0) Array ( [0] => 23000 [1] => 1062 [2] => Duplicate entry '1262' for key 'PRIMARY' )

[2023-10-05 11:49:43] (ERROR @ /www/core/cache/includes/elements/modplugin/25.include.cache.php : 5) PHP warning: Undefined property: modX::$hpCount [2023-10-05 11:50:18] (ERROR @ /www/core/cache/includes/elements/modplugin/25.include.cache.php : 5) PHP warning: Undefined property: modX::$hpCount [2023-10-05 11:50:28] (ERROR @ /www/core/cache/includes/elements/modplugin/25.include.cache.php : 5) PHP warning: Undefined property: modX::$hpCount [2023-10-05 11:50:28] (ERROR @ /www/core/xpdo/om/xpdoobject.class.php : 811) comOrderAddress: Attempt to set NOT NULL field order to NULL [2023-10-05 11:50:28] (ERROR @ /www/core/xpdo/om/xpdoobject.class.php : 811) comOrderAddress: Attempt to set NOT NULL field order to NULL

hurby commented 11 months ago

i,ve setup a testing environment with three products 1 single digi product , 1 bundels with 4 digi products , one bundle with 59 digi products. the last one is the only one failing in invoice. The invoice doesn't need to contain the bundles content. Something there is off