function render() { $this->view->headLink()->appendStylesheet('/css/express-table/style.css'); $formGroups = $this->_config->getFormGroups(); // print_r($formGroups); ?> <div style="text-align: center; width: 100%; padding-left: 20px" align="center" > <table class="statistics " style="width: 90%"> <?php $index = 0; foreach ($formGroups as $groups) { ?> <tr><th style="height: 5px"><?php echo $groups['label']; ?> </th></tr> <tr><td> <table class="hor-minimalist-b" style="width: 95%"> <?php foreach ($this->_config->getFormGroupElements(null, $index) as $elementid) { $prop = $this->_config->getPropByName($elementid); ?> <tr> <td style="text-align: left; width: 20%; max-width: 200px;text-transform: capitalize;font-weight: bold;;" ><?php echo $this->view->translate($prop->label); ?> </td> <td style="width: 10px"> : </td> <td style="text-align: left;" ><?php echo $this->_model->{$elementid}; ?> </td> </tr> <?php } ?> </table> </td></tr> <?php $index += 1; } ?> </table></div> <?php }
function render() { $this->view->headLink()->appendStylesheet('/css/express-table/style.css'); $formGroups = $this->_config->getFormGroups($this->_uiName); // print_r($formGroups); ?> <style > dt{ display:none; } </style> <form id='<?php echo $this->_form_id; ?> ' method="post" class='form-horizontal' role="form" action="<?php echo $this->view->url(); ?> " > <?php $index = 0; foreach ($formGroups as $groups) { ?> <fieldset> <h5><?php echo $groups['label']; ?> </h5> <?php foreach ($this->_config->getFormGroupElements($this->_uiName, $index) as $elementid) { $prop = $this->_config->getPropByName($elementid); $element = $this->getFormElement($elementid, $prop); $isRequired = true; if ($element instanceof Zend_Form_Element) { $isRequired = $element->isRequired(); } if (!$prop->isAllowEdit) { continue; } $style = ""; if ($prop->input == 'hidden') { $style = 'display: none;'; } ?> <div class="form-group"> <label for="<?php echo $elementid; ?> " class="col-sm-2 control-label"> <?php echo $this->view->translate($prop->label); ?> <?php if ($isRequired and $prop->modification == 'changeable') { echo "<span style='color: red;'>*<span>"; } ?> </label> <div class="col-sm-10"> <?php if (true == $this->_form->isEditForm()) { if ('readonly' == $prop->modification) { $value = $element->getValue(); echo $this->_config->fieldTranform($elementid, $value); echo "<input id='{$elementid}' name='{$elementid}' type='hidden' value='{$value}'>"; } else { echo $element; } } else { echo $element; } ?> </div> </div> <?php } ?> </fieldset> <?php $index += 1; } ?> </form> <?php $this->view->jQuery()->onLoadCaptureStart(); ?> $('form#<?php echo $this->_form_id; ?> ').find('dt').remove(); $('#SaveButton').unbind().bind('click',function(){ $('form#<?php echo $this->_form_id; ?> ').submit(); }); <?php $this->view->jQuery()->onLoadCaptureEnd(); ?> <?php }
function render() { $this->view->headLink()->appendStylesheet('/css/express-table/style.css'); $sections = $this->_modelInfoConfig->getSections(); // print_r($formGroups); ?> <div style="text-align: center; width: 100%; padding-left: 20px" align="center" > <table class="statistics " style="width: 90%"> <?php $index = 0; foreach ($sections as $section) { ?> <tr id="<?php echo $section['id']; ?> "><th style="height: 5px"><?php echo $section['label']; ?> </th></tr> <tr><td> <table class="hor-minimalist-b" style="width: 95%"> <tr> <?php $line = 0; $col = 0; foreach ($section['items'] as $item) { $line++; $col += 1; if ($item->type == 'field') { $elementid = $item->id; $prop = $this->_config->getPropByName($elementid); ?> <td style="text-align: left; width: 20%; max-width: 200px;text-transform: capitalize;font-weight: bold;;" ><?php echo $this->view->translate($prop->label); ?> </td> <td style="width: 10px"> : </td> <td style="text-align: left;" ><?php echo $this->_model->{$elementid}; ?> </td> <?php if ($line % 2 == 0) { echo "</tr><tr>"; $col = 0; } ?> <?php } elseif ($item->type == 'viewHelper') { ?> <tr> <td colspan="6"> <?php echo $this->view->{$item->id}($this->_model); ?> </td> </tr> <?php $col = 0; } ?> <?php } ?> <?php if ($col == 1) { echo "<td> </td><td> </td><td> </td></tr>"; $endline = true; } ?> </table> </td></tr> <?php $index += 1; } ?> </table></div> <?php }