6 replies [Last post]
Wonder95's picture
Offline
Joined: 02/20/2008
Juice: 283
Was this information Helpful?

One thing that I've seen mentioned in the docs and elsewhere is that if you don't like the way the core Ubercart modules display things, you can use Views to display them if you want. However, this isn't the case with taxonomy terms and the image field for the term added by UC. I had a conversation with merlinofchaos tonight, and realized that I am unable to to a listing of terms and images for the Catalog vocabulary in Views 2. Since the image field is added to the taxonomy term edit form by UC via hook_form_alter, in order for it to be able to be displayed in a view, it first needs to be described to Views. So, my suggestion is to add the views functions to uc_catalog that will make the image field for the taxonomy term available to Views 2.

Thanks.

stephthegeek's picture
Offline
Theminator
Joined: 10/20/2007
Juice: 575
Re: Describe taxonomy image field to Views 2

Gorgeous original Drupal themes (and Ubercart themes!) ~ Psst: more Ubercart themes on our new site

Wonder95's picture
Offline
Joined: 02/20/2008
Juice: 283
Remove hook_form_alter() from UC

But wouldn't I somehow have to disable the hook_form_alter() in Ubercart that adds the image field to the taxonomy term?

stephthegeek's picture
Offline
Theminator
Joined: 10/20/2007
Juice: 575
Re: Remove hook_form_alter() from UC

No, just don't add them through the Ubercart version. Ubercart doesn't use the same UI as Taxonomy Image so they're uploaded from different places.

Gorgeous original Drupal themes (and Ubercart themes!) ~ Psst: more Ubercart themes on our new site

Unarmed's picture
Offline
Joined: 08/07/2009
Juice: 141
Re: Re: Remove hook_form_alter() from UC

Hey what do you mean by "don't add them through the Ubercart version"? Thanks =]

branzer's picture
Offline
Joined: 09/07/2009
Juice: 2
Re: Describe taxonomy image field to Views 2

I am not a developer but I have the same requirement. I want add a view to display a list of taxonomy terms(term names and pictures) within my ubercart catalog. Can anyone give me a direction how to add the views functions to uc_catalog that will make the image field for the taxonomy term available to Views?

sepehr's picture
Offline
Joined: 06/28/2010
Juice: 31
uc_catalog patch

Here is a simple patch to remove uc_catalog's term imagefield in favor of taxonomy_image.module.

AttachmentSize
9993-uc_catalog.module_removed-term-imagefield.patch 1.85 KB