Closed (fixed)
Project:
Content Construction Kit (CCK)
Version:
5.x-1.x-dev
Component:
General
Priority:
Normal
Category:
Feature request
Assigned:
Reporter:
Created:
6 Feb 2007 at 19:29 UTC
Updated:
25 Mar 2008 at 16:21 UTC
I needed a CCK pollfield for a couple of projects I'm working on so I have created a pollfield module. It has all the functionality of the core poll module but as a CCK field so you can add one or more pollfields to any content type. I have it working in both 4.7 and 5.x.
My question is whether I should create a separate project for this or should it be in the core CCK package? I only ask because the poll module is a core module, otherwise I would just make a project for it. It makes no difference to me one way or the other, just trying to get a feel for the best way to go.
Comments
Comment #1
fagoAs the poll module is even in drupal core, I would include it with CCK.
On the long road I personally would prefer to have the poll field even in drupal core instead of the poll content type.
Comment #2
moshe weitzman commentedI could go either way on this. U just want to subscribe to the issue. I need this module (for drupal5) within a week or two. Go Karen!
Comment #3
moshe weitzman commentedI should add that i just need regular old poll features . No need for Views and such. All I need is to add a textfield to a poll with a long question but the core poll node type is locked and can't be extended.
Comment #4
yched commentedI have to admit mixed feelings at the idea of another field module in cck core.
The way I (only personally...) see it, polls are not really a 'basic' datatype. They're in drupal core, but rather on their way out it seems, because 'advanced poll' module and votingAPI-based solutions seem more promising.
There was the idea of a 'voting api' field some time ago. If / when it comes, won't it makethe "core" pollfield obsolete as well ?
On the other hand, it seems that your pollfield will have some specific stuff regarding Views integration ? That might provide a good example of default behaviour override - no core module currently make use of CONTENT_CALLBACK_CUSTOM - if it could override the default 'view' bahaviour, it would be even better ? :-)
Comment #5
karens commentedI decided to just go ahead and make a project for it. It can always be pulled back into the core package later if anyone wants to. The project is at http://drupal.org/project/pollfield. You can add one or more pollfields to any content type, and all the poll values are Views-enabled so you can create a Views view of questions and responses.
It obviously needs testing, but seems to generally be working right. There is both a 4.7 and a 5.x version.
And, yes, it does use a lot of the custom handlers so it is a good example of that -- custom view, custom default value, and custom Views tables (I need to get back to that issue and post the patch for the content module side of that, but it works even without a patch since it will just overwrite the tables that the content module creates.)
Comment #6
catchMarking as fixed :)
Comment #7
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.