Closed (fixed)
Project:
Feedback
Version:
7.x-2.x-dev
Component:
Code
Priority:
Critical
Category:
Task
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
28 Dec 2008 at 03:17 UTC
Updated:
2 Jan 2014 at 23:45 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
sunI think I agree. (although I intentionally chose to not use nodes for Feedback as this is rather a development module originally)
The question is, however, how do we ensure the following
- The "Feedback" content-type should not be displayed on the node/add page.
- The feedback form should not contain the usual extra fields for menu, comments, author, publishing options, etc.
- If Fivestar/Voting API comes into the game, I guess it should not be displayed on the feedback form, but rather when viewing existing feedback messages.
After further consideration, this issue depends on #293512: Abstract back-end for integration with 3rd party issue trackers, as Feedback should also be able to use Project Issue or CaseTracker as backend.
Comment #2
Flying Drupalist commentedHere's another idea, rather than use messages as a node, have feedback create a node along side a message without using the node creation front end. The webmaster would be able to choose a tokenized title for the node, as well as which field to insert the message itself in. Then a node gets created without ever exposing the user to the form, and there would be no need for a new node type, the webmaster would be able to choose page, story, issue, or case as the case may be. :)
Comment #3
sunok, that's so trivial that I even did not think about it. ;)
Anyway, to achieve this, the back-end needs to be pluggable/swappable. Hence, marking as postponed for now.
Comment #4
Flying Drupalist commentedHi, I wonder what the timeline for this is, because this actually sounds like something I can implement on my own even without a dedicated module. Going back to what you said about using a node form's interface, I can get the form in a block, apply hook form alter on it, and use one of the ajax modules to get ajax submission.
All in all I think I can get pretty close to my ideal setup without using the Feedback module. What are your thoughts on this?
Comment #5
sunYou can uninstall probably 99% of all contributed modules by following this argumentation. Modules are here to standardize and improve certain features, behaviors, and functionalities.
Comment #6
smk-ka commentedWhile I understand that feedback using nodes would allow us to leverage all the fancy things that nodes allow us to do, I am a little concerned about privacy: I surely would not want that
- feedback nodes show up in search results
- allow everyone to read customer feedback by guessing its URL (trying node/1, node/2, etc. until something shows up).
Comment #7
socialnicheguru commentedsince nodes adhere to drupal permissions, you as a system admin would have full control.
We would just have to specify the following permissions:
create feedback
delete all feedback
edit all feedback
delete own feedback
edit own feedback
Comment #8
jitenm commentedI also feel this is a great idea, I would love to replicate User Voice functionality.
I'm available to help, so subscribing.
Comment #9
verta commentedI'm looking for a way for privileged non-admins to view the feedback, possible mark as handled.
Comment #10
greg.harveyIn Drupal 7 you will be able to create a Feedback "entity" and store additional data using the FieldsAPI. Hope you don't mind me bumping the version and massaging the title a little so it speaks Drupal 7's language, but this makes a lot more sense and seems far more worth the effort in Drupal 7 land. =)
Could also tie in nicely with this issue later on: #293512: Abstract back-end for integration with 3rd party issue trackers
Comment #11
greg.harveyI'm going to go ahead and write a Drupal 6 module for this, which will hopefully pave the way for a Drupal 7 port. I know it's back to front, but I'm on the clock of a Drupal 6 client so a Drupal 7 module is out of the question.
So here's the thing. Should this be part of the Feedback module package (e.g. contrib/feedback_node) or should it be a separate project, assuming the changes in #293512: Abstract back-end for integration with 3rd party issue trackers are accepted? If the answer is a separate project, then I can go ahead and create a project page and close this issue. But it might be nice to ship it with Feedback as an example of using the API.
Comment #12
socialnicheguru commentedsubscribing for Drupal 6 implementation of feedback_node.module.
Would it be easier for it to be a submodule for now?
Comment #13
Flying Drupalist commentedWhy entities insteads of node? What's wrong with node? :(
Comment #14
Akela commentedSubscribing
Comment #15
darryn commentedSubscribing
Love the project. Will be working on the node version whilst this is backed into modules.
Comment #16
sunComment #17
sunThis should be the next step, and is required for a D7 release of Feedback.
Comment #18
greg.harvey@sun, some of the Drupal 6 ground work has been done in #293512: Abstract back-end for integration with 3rd party issue trackers but it still needs review. I wouldn't mind pushing this along, but it would be kinda nice to deal with #293512 first, IMHO. Then we can create the 'entities' implementation using the hooks, which would avoid needing to re-work this later, if/when #293512 gets committed. (I'm hoping it will at some point!)
Comment #19
sun@greg.harvey, yeah, I'm aware of your fine patch, and feel terribly sorry for having it languishing around for so long. :-/ However, in light of the built-in entity API of D7, I'd like to focus on a D7 implementation of a feedback entry entity first; in particular, to see how it needs to look like and work in a entity-aware environment. We're definitely going to take your code changes into account, because I think you already spent a good time with figuring out a possible API design. Therefore, your effort and work on the issue is still very valuable.
Also note that the feedback UI/form handling just got entirely revamped for D7 over in #305744: Return validation error (use AJAX framework)
Overall, I'm not sure whether we are going to backport all of these changes to D6. Right now, that sounds rather unlikely to me, as I'm trying to stay away from D6 as much as I can ;) Of course, I can't predict future opportunities, but fundamentally, it makes sense to limit major design changes and new features to the heavily improved version of Drupal core.
Comment #20
greg.harveyNp, I know it's been a crazy hectic time... ;-)
For the record, I have no particular interest in the D6 version any more, in so far as I'm no longer working with the customer who needed it, so happy to devote time to D7 instead.
Comment #21
jody lynnI'm getting started on this and hoping to learn a lot about the entity system in the process.
Comment #22
jody lynnThis patch is pretty close.
I have feedback entries as fieldable; you can add fields and see them displayed on the form. I also added a per-entry view page so that you can see full entries with all their fields.
My current problem is saving the field results. Right now the custom fields are not properly saving what I enter into them.
Comment #23
jody lynnOk, feedback is now a fieldable entity.
Comment #24
hadsie commentedJust tried out the patch from #23 and things seem to be running nicely. Thanks @Jody Lynn!
Comment #25
Anonymous (not verified) commentedBefore applying this patch, messages that were posted by users other than user #1 were showing up in the Feedback box after having been submitted (at least in Firefox). That problem was fixed after applying this patch.
I didn't test actually adding fields to the Feedback entity though.
Comment #26
tim.plunkettThe patch works, and the code looks good. There are a couple whitespace issues I fixed, but no changes, so RTBC.
When adding a bunch of fields, #693880: Alternative UIs/themes seems a little more relevant, since it's easier to run out of room with the default layout.
Comment #27
sunwow, this looks pretty good already! Good job!
However, some remarks:
Not sure whether we really need a theme template?
1) An empty form?
2) @see system_settings_form()?
3) Shouldn't we use dsm() for the message?
This shouldn't be necessary. Instead, feedback_load() needs to return FALSE for non-existing feedback entries. When a named dynamic placeholder (i.e., loader function) in a router path returns FALSE, the menu system automatically throws a 404.
Hmmm... #type 'item' is actually a Form API concept. This particular code doesn't really look nice, but I'd totally agree if you respond that there is no pattern or any helper function for rendering custom entity properties yet. Interesting challenge.
Since we do not have other view modes currently, I guess I'd be ok with removing all of the conditionals (including the trailing colons and  s) and go ahead with that for now.
Might be worth to have a look into Entity module for how it resolves that currently (if it even attempts to).
Stale 'user' here.
Let's move the entity controller class into a separate feedback.controller.inc file
Hm. We don't really support bundles here. AFAIK, Field API assigns a default bundle name if an entity type is fieldable, but doesn't specify any bundles. Might make sense to rely on that here.
Don't think we need "settings" in the title of a menu item/link within the administrative configuration section.
Powered by Dreditor.
Comment #28
jody lynnI went through all the comments above and made changes.
feedback_admin_settings_form as an empty form is necessary because the tabs for 'manage fields'/'manage display' require a form menu callback as their parent. I made the adjustments to it though.
Related, the 'bundles' part of feedback_entity_info is necessary in order to define the admin path where fields can be managed.
I removed all the $entry->content building in feedback_build_content and decided it was just too specific to the full view feedback entry display, so I moved it to the template_preprocess and feedback-entry.tpl.php instead. (And hence kept the feedback-entry template)
Comment #29
jody lynnI committed this. Feedback is now a fieldable entity!