Author: david
Date: Thu Dec 3 10:52:05 2009
New Revision: 4051
Log:
move editSuccess.php to editIsdfSuccess.php
Added:
trunk/apps/qubit/modules/function/templates/editIsdfSuccess.php
- copied unchanged from r4050,
trunk/apps/qubit/modules/function/templates/editSuccess.php
Deleted:
trunk/apps/qubit/modules/function/templates/editSuccess.php
Modified:
trunk/apps/qubit/modules/function/actions/editAction.class.php
trunk/apps/qubit/modules/function/config/security.yml
trunk/apps/qubit/modules/function/config/view.yml
Modified: trunk/apps/qubit/modules/function/actions/editAction.class.php
==============================================================================
--- trunk/apps/qubit/modules/function/actions/editAction.class.php Thu Dec
3 10:48:52 2009 (r4050)
+++ trunk/apps/qubit/modules/function/actions/editAction.class.php Thu Dec
3 10:52:05 2009 (r4051)
@@ -366,6 +366,8 @@
$this->redirect(array('module' => 'function', 'action' => 'show', 'id'
=> $this->func->id));
}
}
+
+ $this->setTemplate('editIsdf');
}
public function updateEventRelations()
Modified: trunk/apps/qubit/modules/function/config/security.yml
==============================================================================
--- trunk/apps/qubit/modules/function/config/security.yml Thu Dec 3
10:48:52 2009 (r4050)
+++ trunk/apps/qubit/modules/function/config/security.yml Thu Dec 3
10:52:05 2009 (r4051)
@@ -2,11 +2,7 @@
is_secure: on
credentials: [[ contributor, editor, administrator ]]
-edit:
- is_secure: on
- credentials: [[ contributor, editor, administrator, translator ]]
-
-editIsaar:
+editIsdf:
is_secure: on
credentials: [[ contributor, editor, administrator, translator ]]
Modified: trunk/apps/qubit/modules/function/config/view.yml
==============================================================================
--- trunk/apps/qubit/modules/function/config/view.yml Thu Dec 3 10:48:52
2009 (r4050)
+++ trunk/apps/qubit/modules/function/config/view.yml Thu Dec 3 10:52:05
2009 (r4051)
@@ -5,7 +5,7 @@
MainMenu: []
SearchBox: []
-editSuccess:
+editIsdfSuccess:
stylesheets:
/vendor/yui/autocomplete/assets/skins/sam/autocomplete: { position: first }
javascripts:
Copied: trunk/apps/qubit/modules/function/templates/editIsdfSuccess.php (from
r4050, trunk/apps/qubit/modules/function/templates/editSuccess.php)
==============================================================================
--- /dev/null 00:00:00 1970 (empty, because file is newly added)
+++ trunk/apps/qubit/modules/function/templates/editIsdfSuccess.php Thu Dec
3 10:52:05 2009 (r4051, copy of r4050,
trunk/apps/qubit/modules/function/templates/editSuccess.php)
@@ -0,0 +1,205 @@
+<?php use_helper('Javascript') ?>
+
+<?php // write functionRelationDialog yui dialog object to DOM via javascript
+// echo include_partial('functionRelationDialog'); ?>
+
+<div class="pageTitle">
+<?php if (isset($sf_request->id)): ?>
+<?php echo __('edit function') ?>
+<?php else: ?>
+<?php echo __('create function') ?>
+<?php endif; ?>
+</div>
+
+<?php if (isset($sf_request->id)): ?>
+<form method="POST" action="<?php echo url_for(array('module' => 'function',
'action' => 'edit', 'id' => $sf_request->id)) ?>" id="editForm">
+<?php else: ?>
+<form method="POST" action="<?php echo url_for(array('module' => 'function',
'action' => 'create')) ?>" id="editForm">
+<?php endif; ?>
+
+ <?php echo $form->renderHiddenFields() ?>
+
+ <div class="formHeader">
+ <?php echo render_title($func) ?>
+ </div>
+
+ <?php if ($form->hasGlobalErrors()): ?>
+ <div class="error">
+ <ul>
+ <?php foreach($form->getGlobalErrors() as $error): ?>
+ <li><?php echo $error ?></li>
+ <?php endforeach; ?>
+ </ul>
+ </div>
+ <?php endif; ?>
+
+ <fieldset class="collapsible" id="identityArea">
+ <legend><?php echo __('identity area'); ?></legend>
+
+ <?php echo $form->type->renderRow() ?>
+
+ <?php echo $form->authorizedFormOfName->label('authorized form(s) of
name')->renderRow() ?>
+
+ <?php echo $form->parallelName->label('parallel form(s) of
name')->renderRow() ?>
+
+ <?php echo $form->otherName->label('other form(s) of name')->renderRow() ?>
+
+ <?php echo $form->classification->renderRow() ?>
+ </fieldset>
+
+ <fieldset class="collapsible collapsed" id="descriptionArea">
+ <legend><?php echo __('context area'); ?></legend>
+
+ <?php echo $form->dates->renderRow() ?>
+
+ <?php echo $form->description->renderRow(array('class' => 'resizable')) ?>
+
+ <?php echo $form->history->renderRow(array('class' => 'resizable')) ?>
+
+ <?php echo $form->legislation->renderRow(array('class' => 'resizable')) ?>
+ </fieldset>
+
+ <fieldset class="collapsible collapsed" id="relationshipsArea">
+ <legend><?php echo __('relationships area'); ?></legend>
+
+ <div class="form-item">
+ <table class="inline" id="relatedEntities">
+ <caption><?php echo __('Related corporate bodies, archival materials
and other resources'); ?></caption>
+ <tr>
+ <th style="width: 25%"><?php echo __('name'); ?></th>
+ <th style="width: 15%"><?php echo __('type'); ?></th>
+ <th style="width: 20%"><?php echo __('dates'); ?></th>
+ <th style="width: 30%"><?php echo __('description'); ?></th>
+ <th style="width: 10%; text-align: center"><?php echo
image_tag('delete', array('align' => 'top', 'class' => 'deleteIcon')) ?></th>
+ </tr>
+ <?php if (0 < count($funcRelations)): ?>
+ <?php foreach ($funcRelations as $funcRelation): ?>
+ <tr id="<?php echo 'functionRelation_'.$funcRelation->getId() ?>"
class="<?php echo 'related_obj_'.$funcRelation->getId() ?>">
+ <?php if ($funcRelation->getObjectId() == $func->getId()): ?>
+ <td><?php echo
$funcRelation->getSubject()->getAuthorizedFormOfName() ?></td>
+ <?php else: ?>
+ <td><?php echo $funcRelation->getObject()->getAuthorizedFormOfName()
?></td>
+ <?php endif; ?>
+ <td><?php echo $funcRelation->getType() ?></td>
+ <td>
+ <?php if (0 < strlen($dateDisplay =
$funcRelation->getNoteByTypeId(QubitTerm::RELATION_NOTE_DATE_DISPLAY_ID)) || 0
< count($dateArray = $funcRelation->getDates())): ?>
+ <?php if (0 < strlen($dateDisplay)): ?>
+ <?php echo $dateDisplay ?>
+ <?php elseif (2 == count($dateArray)): ?>
+ <?php echo __('%1% - %2%', array('%1%' =>
collapse_date($dateArray['start']), '%2%' => collapse_date($dateArray['end'])))
?>
+ <?php else: ?>
+ <?php echo collapse_date(array_shift($dateArray)) ?>
+ <?php endif; ?>
+ <?php endif; ?>
+ </td>
+ <td><?php echo
$funcRelation->getNoteByTypeId(QubitTerm::RELATION_NOTE_DESCRIPTION_ID) ?></td>
+ <td style="text-align: center;">
+ <input type="checkbox" name="deleteRelations[<?php echo
$funcRelation->getId() ?>]" value="delete" class="multiDelete" />
+ </td>
+ </tr>
+ <?php endforeach; ?>
+ <?php endif; ?>
+ </table>
+ </div>
+
+ <!-- * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * -->
+ <!-- NOTE: The functionRelationDialog.js script cuts this *entire*
-->
+ <!-- "functionRelation" table and pastes it in a YUI dialog object.
-->
+ <!-- * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * -->
+ <table class="inline" id="functionRelation">
+ <caption><?php echo __('new relationship') ?></caption>
+ <tbody>
+ <tr>
+ <th style="width: 66%" colspan="3">
+ <label for="editActorRelation_functionName"
class="required_field"><?php echo __('Name of related entity') ?></label>
+ </th>
+ <th style="width: 34%">
+ <label for="editActorRelation_categoryId"><?php echo __('Category of
relationship') ?></label>
+ </th>
+ </tr>
+ <tr>
+ <td colspan="3" style="width: 66%">
+ <?php // include_partial('functionNameAutoComplete',
array('function' => $func))?>
+ </td>
+ <td style="width: 34%">
+ <?php echo select_tag('editActorRelation[categoryId]',
objects_for_select($funcRelationCategories, 'getId', 'getName')) ?>
+ </td>
+ </tr>
+ <tr>
+ <th colspan="4">
+ <label for="editActorRelation_description"><?php echo
__('Description of relationship') ?></label>
+ </th>
+ </tr>
+ <tr>
+ <td colspan="4" style="width: 100%">
+ <?php echo textarea_tag('editActorRelation[description]', '',
array('class' => 'resizable', 'style' => '30x3')) ?>
+ </td>
+ </tr>
+ <tr>
+ <th style="width: 25%">
+ <label for="editActorRelation_startDate"><?php echo
__('date&dagger') ?></label>
+ </th>
+ <th style="width: 25%">
+ <label for="editActorRelation_endDate"><?php echo __('end
date†') ?></label>
+ </th>
+ <th colspan="2" style="width: 50%">
+ <label for="editActorRelation_dateDisplay"><?php echo __('date
display') ?></label>
+ </th>
+ </tr>
+ <tr>
+ <td style="width: 25%">
+ <?php echo input_tag('editActorRelation[startDate]') ?>
+ </td>
+ <td style="width: 25%">
+ <?php echo input_tag('editActorRelation[endDate]') ?>
+ </td>
+ <td colspan="2" style="width: 50%">
+ <?php echo input_tag('editActorRelation[dateDisplay]') ?>
+ </td>
+ </tr>
+ <tr>
+ <td colspan="4">
+ <?php echo __('%1% - required field', array('%1%' => '*'))?><br />
+ <?php echo __('%1% - dates must be specified in ISO-8601 format
(YYYY-MM-DD)', array('%1%' => '†'))?>
+ </td>
+ </tr>
+ </tbody>
+ </table>
+ </fieldset>
+
+ <fieldset class="collapsible collapsed" id="controlArea">
+ <legend><?php echo __('control area'); ?></legend>
+
+ <?php echo $form->descriptionIdentifier->label('function description
identifier')->renderRow() ?>
+
+ <?php echo $form->institutionIdentifier->label('institution
identifiers')->renderRow() ?>
+
+ <?php echo $form->rules->label('Rules and/or conventions
used')->renderRow(array('class' => 'resizable')) ?>
+
+ <?php echo $form->descriptionStatus->label('status')->renderRow() ?>
+
+ <?php echo $form->descriptionDetail->label('level of detail')->renderRow()
?>
+
+ <?php echo $form->revisionHistory->label('dates of creation, revision or
deletion')->renderRow(array('class' => 'resizable')) ?>
+
+ <?php echo $form->language->label('language(s)')->renderRow(array('class'
=> 'form-autocomplete')) ?>
+
+ <?php echo $form->script->label('script(s)')->renderRow(array('class' =>
'form-autocomplete')) ?>
+
+ <?php echo $form->sources->renderRow(array('class' => 'resizable')) ?>
+
+ <?php echo $form->maintenanceNotes->renderRow(array('class' =>
'resizable')) ?>
+
+ </fieldset>
+
+ <ul class="actions">
+ <?php if (isset($sf_request->id)): ?>
+ <li><?php echo link_to(__('Cancel'), array('module' => 'function',
'action' => 'show', 'id' => $func->id)) ?></li>
+ <li><?php echo submit_tag(__('Save')) ?></li>
+ <?php else: ?>
+ <li><?php echo link_to(__('Cancel'), array('module' => 'function',
'action' => 'list')) ?></li>
+ <li><?php echo submit_tag(__('Create')) ?></li>
+ <?php endif; ?>
+ </ul>
+
+</form>
\ No newline at end of file
--
You received this message because you are subscribed to the Google Groups
"Qubit Toolkit Commits" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/qubit-commits?hl=en.