tight integration with views module

moshe weitzman - July 28, 2006 - 03:10
Project:Publish
Version:HEAD
Component:Code
Category:feature request
Priority:normal
Assigned:moshe weitzman
Status:active
Description

Let admins specify a View as a channel. This is more flexible than current node listing logic. IMO, we can ditch this logic in curent publish module and just make Views mandatory.

#1

jvandyk - July 28, 2006 - 14:13

I concur.

#2

Boris Mann - July 28, 2006 - 15:32

Great! I thought I said this months ago :P

#3

Boris Mann - July 28, 2006 - 15:32

Lets get this spec'd and funded.

#4

moshe weitzman - August 3, 2006 - 20:04

fyi, looks like bryght is sponsoring me to deliver this. i will use this issue for progress reports. i will probably be doing some subscribe work since the receiving site needs to push these nodes into a corresponding organic group

#5

moshe weitzman - August 3, 2006 - 20:32
Assigned to:Anonymous» moshe weitzman

#6

RobRoy - November 14, 2006 - 01:58

@Moshe, any update on this? I'm interested in helping out.

#7

Morris Singer - May 16, 2007 - 03:12

Since I am upgrading the Publish and Subscribe modules to Drupal 5.x, this is of interest to me. I have a brief spec for what needs to occur for this to happen. As follows:

  1. The publish module should include a .inc file that provides an XML view style plugin. The style plugin will use Drupal's XML functions to turn each node object into an XML element, and it will then use those functions to assemble an entire XML feed.
  2. The publish module should also provide a default page view to use the new XML view style plugin.
  3. Most of the functionality of Publish gets stripped out. What remains is the hook_xmlrpc() hook and its callbacks, which may need to be modified.
  4. A publish administration menu callback would then need to be created to provide a page for administrators to map a channel ID to a view name with an associated list of arguments. The idea here is that one view could be created to handle everything, and the Publish module would then see an XML-RPC request for a specific channel ID, assemble the appropriate arguments and then build the view.

This approach would be perfectly backward compatible with subscribe, I believe.

#8

moshe weitzman - May 16, 2007 - 03:44

that sounds like a nice plan of action. sorry i never got to work on this.

#9

Morris Singer - June 11, 2007 - 22:33

Long awaited, but here at last. Diffed against latest 4.7 version from today. It uses the possibility of a node type filter in an integrated view to determine which node types are published. Conditions are handled by passing arguments to an embedded view -- which does, admittedly, require an API module I had created some time ago, called Views Argument API.

Views are used to generate the channels, and one single view can generate many channels by editing the channel and specifying which arguments to pass to your view. You will have to download and enable the Views Argument API module, and then create a new view. Pay attention to the new Views Argument API fieldset at the bottom of the form to edit your view. Then, edit your channel in admin/build/publish and specify a view, pick out the arguments and the rest is the way it was in 4.7, I think.

AttachmentSize
publish_5.patch 68.41 KB

#10

Morris Singer - June 11, 2007 - 22:33

Long awaited, but here at last. Diffed against latest 4.7 version from today. It uses the possibility of a node type filter in an integrated view to determine which node types are published. Conditions are handled by passing arguments to an embedded view -- which does, admittedly, require an API module I had created some time ago, called Views Argument API.

Views are used to generate the channels, and one single view can generate many channels by editing the channel and specifying which arguments to pass to your view. You will have to download and enable the Views Argument API module, and then create a new view. Pay attention to the new Views Argument API fieldset at the bottom of the form to edit your view. Then, edit your channel in admin/build/publish and specify a view, pick out the arguments and the rest is the way it was in 4.7, I think.

AttachmentSize
publish_5_0.patch 68.41 KB

#11

moshe weitzman - June 12, 2007 - 00:39

hi morrisinger. thanks for following up here. i may not be able to test this, but i do want to call your attention to the efforts at http://drupal.org/node/103171. thats a new views form element which is likely to get into Views project soon. It might deprecate some of your work with Views argument API. not sure.

#12

Morris Singer - June 12, 2007 - 02:14

Moshe,

Thank you for the head's up on that. It looks like it may address a different issue. My API actually just hugely assists in developing administrative forms to pre-select the values of arguments to pass to embedded views. It also defines some basic mechanisms for picking the values to pass to embedded views as arguments (such as the active node's term ID for a specific vocabulary, etc.,) allowing people to develop dynamic views the content of which may change based on what a user is doing or what is going on inside of a module. I do not think the form element you mention will deprecate this, but, if it does, I'll be ready to figure out how to move that into this project if asked.

Thanks for taking a look at this.

-- Morris

#13

Jax - October 2, 2007 - 16:07

The patch applied and the module seems to activate correctly. But after you create a channel and click on "views" I get the following error:

Fatal error: Call to undefined function: views_argument_api_get() in /home/olivier/public_html/d5/sites/all/modules/publish/publish.module on line 323

Other comments:
I don't think the module should declare it's own package.
There is no description of the module.
Is there anyone that is working on a D5 version of the subscibe module (http://drupal.org/project/subscribe)? It also seems to be impossible to get to its issue queue because of some namespace issue with the word "subscribe".

 
 

Drupal is a registered trademark of Dries Buytaert.