{*------------------------------------------------------------------------------- * Dataface Web Application Framework * Copyright (C) 2005-2006 Steve Hannah (shannah@sfu.ca) * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 * of the License, or (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *------------------------------------------------------------------------------- *} {if $ENV.resultSet->found() > 0} {load_record var="record"} {use_macro file="Dataface_Record_Template.html"} {fill_slot name="record_content"} {block name="before_view_tab_content"} {define_slot name="view_tab_content"} {record_view var=rv record=$record} {if !$rv->showLogo} {/if}
{if $rv->showLogo} {if $rv->logos|@count>0} {foreach from=$rv->logos item=logo} {/foreach} {else} {/if} {/if} {block name="before_record_actions"} {define_slot name="record_actions"}
{record_actions record=$record}
{/define_slot} {block name="after_record_actions"} {if $record->_table->relationships()|@count>0} {define_slot name="record_search"} {/define_slot} {/if} {foreach from=$rv->sections item=section} {if $section.class == 'left'} {collapsible_sidebar heading=$section.label see_all=$section.url edit_url=$section.edit_url movable=1 id=$section.name prefix="leftsidebar" oncollapse="DatafaceSections.oncollapse(this)" onexpand="DatafaceSections.onexpand(this)" display=$section.display} {define_slot name="`$section.name`_section_content"} {if $section.content}
{$section.content}
{elseif $section.fields} {foreach from=$section.fields item=field key=fieldname} {if $field.visibility.browse != 'hidden' and $record->htmlValue($field.name)} {/if} {/foreach}
{$field.widget.label}{$record->htmlValue($field.name)}
{elseif $section.records} {glance_list records=$section.records} {/if} {/define_slot} {/collapsible_sidebar} {/if} {/foreach}
{if $rv->showLogo}

{$record->getTitle()}

{$rv->description}
{$rv->status}
{/if} {define_slot name="record_view_main_section"} {if $ENV.prefs.collapse_all_sections_enabled} {/if} {foreach from=$rv->sections item=section} {if $section.class == 'main'} {collapsible_sidebar heading=$section.label edit_url=$section.edit_url movable=1 prefix="mainsidebar" id=$section.name onexpand="DatafaceSections.onexpand(this)" oncollapse="DatafaceSections.oncollapse(this)" display=$section.display} {define_slot name="`$section.name`_section_content"} {if $section.content}
{$section.content}
{elseif $section.fields} {foreach from=$section.fields item=field key=fieldname} {if $field.visibility.browse != 'hidden'} {if $section.record} {assign var="field_value" value=$section.record->htmlValue($field.name)} {else} {assign var="field_value" value=$record->htmlValue($field.name)} {/if} {if $field_value} {/if} {/if} {/foreach}
{if $field.label_link}{/if} {$field.widget.label} {if $field.label_link}{/if} {$field_value}
{elseif $section.records} {glance_list records=$section.records} {/if} {/define_slot} {/collapsible_sidebar} {/if} {/foreach} {/define_slot}
{literal} {/literal}
{/define_slot} {block name="after_view_tab_content"} {/fill_slot} {/use_macro} {else} {use_macro file="Dataface_Main_Template.html"} {fill_slot name="record_content"} {translate id="scripts.GLOBAL.NO_RECORDS_MATCHED_REQUEST"}No records matched your request.{/translate} {/fill_slot} {/use_macro} {/if}