Author: sevein
Date: Thu Aug 18 15:31:05 2011
New Revision: 9535
Log:
Reorganizing contact information dialog
Modified:
trunk/apps/qubit/modules/contactinformation/actions/relatedContactInformationComponent.class.php
trunk/apps/qubit/modules/contactinformation/templates/_relatedContactInformation.php
Modified:
trunk/apps/qubit/modules/contactinformation/actions/relatedContactInformationComponent.class.php
==============================================================================
---
trunk/apps/qubit/modules/contactinformation/actions/relatedContactInformationComponent.class.php
Thu Aug 18 15:09:57 2011 (r9534)
+++
trunk/apps/qubit/modules/contactinformation/actions/relatedContactInformationComponent.class.php
Thu Aug 18 15:31:05 2011 (r9535)
@@ -28,6 +28,8 @@
'countryCode',
'email',
'fax',
+ 'latitude',
+ 'longitude',
'note',
'region',
'postalCode',
@@ -52,16 +54,9 @@
break;
- case 'city':
- case 'contactPerson':
- case 'contactType':
- case 'email':
- case 'fax':
- case 'postalCode':
- case 'region':
- case 'telephone':
- case 'website':
- $this->form->setValidator($name, new sfValidatorString);
+ case 'latitude':
+ case 'longitude':
+ $this->form->setValidator($name, new sfValidatorNumber);
$this->form->setWidget($name, new sfWidgetFormInput);
break;
@@ -72,6 +67,12 @@
$this->form->setWidget($name, new sfWidgetFormTextArea(array(),
array('rows' => 2)));
break;
+
+ default:
+ $this->form->setValidator($name, new sfValidatorString);
+ $this->form->setWidget($name, new sfWidgetFormInput);
+
+ break;
}
}
Modified:
trunk/apps/qubit/modules/contactinformation/templates/_relatedContactInformation.php
==============================================================================
---
trunk/apps/qubit/modules/contactinformation/templates/_relatedContactInformation.php
Thu Aug 18 15:09:57 2011 (r9534)
+++
trunk/apps/qubit/modules/contactinformation/templates/_relatedContactInformation.php
Thu Aug 18 15:31:05 2011 (r9535)
@@ -100,41 +100,52 @@
<ul class="yui-nav">
- <li class="selected"><a
href="#contactInformationRelationTab1"><em>Details</em></a></li>
- <li><a href="#contactInformationRelationTab2"><em>Contact</em></a></li>
+ <li class="selected"><a
href="#contactInformationRelation_Tab1"><em><?php echo __('Main')
?></em></a></li>
+ <li><a href="#contactInformationRelation_Tab2"><em><?php echo
__('Physical location') ?></em></a></li>
+ <li><a href="#contactInformationRelation_Tab3"><em><?php echo
__('Other details') ?></em></a></li>
</ul>
<div class="yui-content">
- <div id="contactInformationRelationTab1">
+ <div id="contactInformationRelation_Tab1">
- <?php echo $form->streetAddress->renderRow() ?>
+ <?php // TODO jquery error echo $form->primaryContact->renderRow() ?>
+
+ <?php echo $form->telephone->renderRow() ?>
+
+ <?php echo $form->fax->renderRow() ?>
+
+ <?php echo $form->email->renderRow() ?>
+
+ <?php echo $form->website
+ ->label(__('URL'))
+ ->renderRow() ?>
<?php echo $form->city->renderRow() ?>
+ </div>
+
+ <div id="contactInformationRelation_Tab2">
+
+ <?php echo $form->streetAddress->renderRow() ?>
+
<?php echo $form->region->renderRow() ?>
<?php echo $form->countryCode->renderRow() ?>
<?php echo $form->postalCode->renderRow() ?>
- <?php echo $form->telephone->renderRow() ?>
+ <?php echo $form->latitude->renderRow() ?>
- <?php echo $form->fax->renderRow() ?>
+ <?php echo $form->longitude->renderRow() ?>
</div>
- <div id="contactInformationRelationTab2">
-
- <?php echo $form->email->renderRow() ?>
-
- <?php echo $form->website->renderRow() ?>
+ <div id="contactInformationRelation_Tab3">
<?php echo $form->contactPerson->renderRow() ?>
- <?php // TODO jquery error echo $form->primaryContact->renderRow() ?>
-
<?php echo $form->contactType->renderRow() ?>
<?php echo $form->note->renderRow() ?>
--
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.