Drupal 7.16
Ubercart 7.x-3.2

I tried to add pay-per-node as a feature to a product in Ubercart.

When on node/[NID]/edit/features/paypernode/add, I get the following message as an error:

Notice: Undefined variable: return in paypernode_get_types() (line 617 of sites/all/modules/paypernode/paypernode.module).

Additionally, there is no selection field under "Node type", only the text:

" Node type *
Node type the user will be allowed to create."

Trying to save the feature returns the error:

"Node type field is required."

This only seems to happen when no content types are selected. Looking at the code, it seems that it is supposed to show all of them in that case, but instead, it doesn't show any.

Comments

maurizio.ganovelli’s picture

Assigned: Unassigned » maurizio.ganovelli

Seems like no content type is allowed in your paypernode system. Before you can successfully add a ppn product feature you must select which content types are allowed to be created upon checkout. You can define this setting from Pay per node >> Allowed content types (admin/settings/paypernode/allowed).
Let me know if this helps!

maurizio.ganovelli’s picture

Category: bug » support
Status: Active » Fixed

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

Anonymous’s picture

Issue summary: View changes

Adding some additional information about the cause.