protected function _printSummaryRows() { $oldFields = $this->fields; $this->fields = array(); foreach ($oldFields as $k => $v) { $this->fields[$k] = $v; if ($k == 'categoryid') { $this->fields['congregationids'] = array('label' => 'Congregations'); } if ($k == 'alt_title') { $this->fields['tags'] = array(); } } parent::_printSummaryRows(); unset($this->fields['congregationids']); unset($this->fields['tags']); }
function _printSummaryRows() { parent::_printSummaryRows(); include_once 'include/size_detector.class.php'; if (SizeDetector::isNarrow()) { ?> <tr class="divider-before"> <td colspan="2" id="family-members-container"> <h4> Members:</h4> <?php } else { ?> <tr class="divider-before"> <th>Members</th> <td id="family-members-container"> <?php } $persons = $this->getMemberData(); $show_actions = !empty($this->id); // hide actions if this is a "draft" family if (isset($this->_tmp['show_member_callback'])) { call_user_func($this->_tmp['show_member_callback'], $persons); } else { if (empty($this->_tmp['abbreviate_member_list'])) { ?> <div style="float: left" id="member-details-container"> <?php // full blown version $special_fields = array('congregation'); if (!empty($this->_tmp['member_list_special_fields'])) { $special_fields = $this->_tmp['member_list_special_fields']; } include 'templates/person_list.template.php'; ?> </div> <?php if ($GLOBALS['system']->featureEnabled('PHOTOS') && $this->id) { ?> <div style="float: left; " id="family-photos-container"> <?php foreach ($persons as $personid => $details) { ?> <a href="?view=persons&personid=<?php echo (int) $personid; ?> "><img title="<?php echo ents($details['first_name'] . ' ' . $details['last_name']); ?> " src="?call=person_photo&personid=<?php echo (int) $personid; ?> " /></a> <?php } ?> </div> <?php } } else { // abbreviated version $GLOBALS['system']->includeDBClass('person'); $dummy_person = new Person(); ?> <table> <?php foreach ($persons as $id => $person) { $dummy_person->populate($id, $person); $tr_class = $person['status'] == 'archived' ? ' class="archived"' : ''; ?> <tr<?php echo $tr_class; ?> > <td class="nowrap"><a href="?view=persons&personid=<?php echo $id; ?> "><?php echo ents($dummy_person->toString()); ?> </a></td> <td><?php $dummy_person->printFieldValue('gender'); ?> </td> <td><?php $dummy_person->printFieldValue('age_bracket'); ?> </td> </tr> <?php } ?> </table> <?php } } ?> </td> </tr> <?php }