<% "$id v." . $obj->get_version %> <% $name %> <% $m->comp('publish_status_span.mc', sorted => $highlight eq 'name' ? 'sorted' : '', asset => $obj) %>
<% $lang->maketext('Category') %>
{category_name} || $classes->{location} || '' %>><% $cat %>
<% $lang->maketext('Site') %>
{site_id} || '' %>><% $site %>
<% $lang->maketext(($class eq 'formatting' ? 'Output Channel' : $disp . ' Type')) %>
{element} || '' %>><% $type || ' ' %>
<% $lang->maketext($date_label) %>
{cover_date} || '' %>><% $date || ' ' %>
<% $lang->maketext('Priority') %>
{priority} || '' %>><% $lang->maketext($priors->{$obj->get_priority}) %>

<% $elink %>

% if ($can_edit && $desk_opts) {
<& '/widgets/profile/select.mc', name => "$widget|next_desk", value => $desk_val, options => $desk_opts, useTable => 0, id => "move$id" &>
% } else {
 
% }
<%once>; my $priors = Bric::Biz::Asset->list_priorities; <%args> $mlabel => 'Move to Desk' $widget => 'desk_asset' $obj $highlight $can_edit $vlabel => 'View' $desk_val $desk_opts $ppage $disp $type $pub => '' $aid $class => 'story' $did $desk_type $user => undef $label => undef $action => undef <%init>; # Get the ID. my $id = $obj->get_id; my $cats = $r->pnotes("desk.cats") || {}; my ($name, $date, $date_label, $cat); my $header_class = 'lightHeader'; my $site_id = $obj->get_site_id; my $site = Bric::Biz::Site->lookup({id => $site_id})->get_name || ' '; my $alias = ''; my $title_class = 'title'; my $idv_class = 'idv'; if ($class eq 'formatting') { $date = $obj->get_deploy_date || ' '; $date_label = 'Deployed Date'; $name = $obj->get_uri; my $cat_id = $obj->get_category_id; if (defined $cat_id) { unless ($cat = $cats->{$cat_id}) { $cat = Bric::Biz::Category->lookup({ id => $cat_id })->get_uri; $cats->{$cat_id} = $cat; $r->pnotes("desk.cats", $cats); } } else { $cat = ' '; } } else { $name = $obj->get_name; $date = $obj->get_cover_date; $date_label = 'Cover Date'; my $co = $vlabel eq 'Edit'; $alias = 'alias' if $obj->get_alias_id; if ($highlight eq 'name') { $title_class .= "sorted"; } elsif ($alias) { $title_class .= $alias; } if ($highlight eq 'id') { $idv_class .= "sorted"; } elsif ($alias) { $idv_class .= $alias; } if ($class eq 'media') { $cat = $cats->{$obj->get_category__id} ||= $obj->get_category_object; $cat = $cat->get_uri if $cat; $name = $m->comp('/widgets/profile/preview_link.mc', type => $class, doc => $obj, title => $name ) if $obj->get_file_name; } else { $cat = $obj->get_primary_category; $cat = $cat->get_uri if $cat; $cat ||= ' '; $name = $m->comp('/widgets/profile/preview_link.mc', type => $class, doc => $obj, title => $name ); } $header_class = 'aliasHeader' if $obj->get_alias_id; } $cat ||= ' '; my $classes = { $highlight => ' class="sorted"' }; my $rowspan = 5; my $link = $ppage . '/' . $aid; my $item_label = 'Trail'; my $item_url = "/workflow/trail/$class/$aid"; if ($desk_type eq 'workflow') { $link .= '?return=' . $did; if ($vlabel eq 'Edit') { $link .= '&checkout=1'; } } else { if ($vlabel eq 'Edit') { $link .= '?checkout=1'; } if ($class eq 'story') { $item_label = 'Clone'; # $item_url = $r->uri . "?$widget|clone_cb=$aid"; $item_url = "/workflow/profile/workspace/clone/$aid"; } } my $elink = $user ? $user : $label ? '$label} : ''; <%doc> ############################################################################### =head1 NAME /widgets/desk/desk_item.html - Desk Item Presentation. =head1 VERSION $LastChangedRevision$ =head1 DATE $LastChangedDate: 2004-05-24 18:17:44 -0700 (Mon, 24 May 2004) $ =head1 DESCRIPTION This element handles the display of individual assets on a desk or workspace.