Default setting for any product without class

Project:Product Power Tools
Component:Code
Category:
Priority:normal
Assigned:Unassigned
Status:active
Description
Project: 
Power Tools

It would be nice to be able to setup power tools to any product, not just classes, so we can establish and hide certain fields and complete SKU automatically for any product without a class.

Version: 
Ubercart 2.x-dev
tcindie@drupal.org's picture
Offline
Getting busy with the Ubercode.
Joined: 05/15/2008
Juice: 440
Re: Default setting for any product without class

You can try this version I've attached here.. I think it breaks a few things for regular products that don't belong to a particular class, but at least it should get things heading in the right direction. I don't really have time to delve much deeper into this at the moment, perhaps I will revisit the issue when other projects settle down a bit.

AttachmentSize
powertools.zip 6.98 KB

Follow me on twitter.

Juanzo@drupal.org's picture
Offline
Uber Donor
Joined: 05/05/2008
Juice: 79
Re: Re: Default setting for any product without class
Assigned to:tcindie@drupal.org» Juanzo@drupal.org

Awesome! It does seem to work, somehow. After enabling it, I get the following error multiple times at the Power Tools configuration page:
# user warning: Unknown column 'nid' in 'where clause' query: SELECT enabled FROM uc_power_tools WHERE nid = '4' in /home/totaltec/public_html/sites/all/modules/uc_product_power_tools/uc_product_power_tools_admin.inc on line 70.

Also, instead of listing the default product type, it shows another table with "Unclassed Products" and an enable / disable button, forcing us to enable it to every product created.

I know you are with very little time but thanks for looking at this issue.