Workflow Link in Views

adshill - March 23, 2009 - 00:45
Project:Workflow
Version:6.x-1.1
Component:Code
Category:feature request
Priority:normal
Assigned:Unassigned
Status:active
Description

It would be great if there was a "Workflow Link" option made available in Views - similar to the "Edit Link" and "Delete Link" available in the node options. This would then link through to the Workflow tab of that node, should the user have the relevant permissions.

To go one step further, a link which moved the workflow to the next state would be even more interesting, or even a drop down that allowed you to choose a state to move it to! But the above would suffice... I don't want to be greedy :)

Thanks,

Adam

#1

begona - November 10, 2009 - 13:02

Will there be a way to do this?
Because the structure of the links is very similar, someone knows how to do this???

Thanks in advance!!!

#2

begona - November 10, 2009 - 13:25

Well I made this with custom PHP Field. I used the following code

<?php
return '<a href="http://localhost/PCS_drupal/?q=node/'.$data->nid.'/workflow" > Workflow</a>'
?>

It works very nice!!!!

#3

begona - November 10, 2009 - 14:30

In a more general way the solution is the following

<?php
global $base_url;
return
'<a href="'.$base_url.'/?q=node/'.$data->nid.'/workflow" >Sign Off</a>';
?>

You only have to set the variable $base_url in settings.php

 
 

Drupal is a registered trademark of Dries Buytaert.