$t->is(link_to('test', '@homepage', array('absolute' => true)), '<a href="/module/action">test</a>', 'link_to() can take an "absolute" option'); $t->is(link_to('test', '@homepage', array('absolute' => false)), '<a href="module/action">test</a>', 'link_to() can take an "absolute" option'); $t->is(link_to('test', '@homepage', array('query_string' => 'foo=bar')), '<a href="module/action?foo=bar">test</a>', 'link_to() can take a "query_string" option'); $t->is(link_to('test', '@homepage', array('anchor' => 'bar')), '<a href="module/action#bar">test</a>', 'link_to() can take an "anchor" option'); $t->is(link_to('', '@homepage'), '<a href="module/action">module/action</a>', 'link_to() takes the url as the link name if the first argument is empty'); $t->like(link_to('test', '@homepage', array('method' => 'post')), '/==TOKEN==/', 'link_to() includes CSRF token from BaseForm'); // button_to() $t->diag('button_to()'); $t->is(button_to('test', '@homepage'), '<input value="test" type="button" onclick="document.location.href=\'module/action\';" />', 'button_to() returns an HTML "input" tag'); $t->is(button_to('test', '@homepage', array('query_string' => 'foo=bar')), '<input value="test" type="button" onclick="document.location.href=\'module/action?foo=bar\';" />', 'button_to() returns an HTML "input" tag'); $t->is(button_to('test', '@homepage', array('anchor' => 'bar')), '<input value="test" type="button" onclick="document.location.href=\'module/action#bar\';" />', 'button_to() returns an HTML "input" tag'); $t->is(button_to('test', '@homepage', array('popup' => 'true', 'query_string' => 'foo=bar')), '<input value="test" type="button" onclick="var w=window.open(\'module/action?foo=bar\');w.focus();return false;" />', 'button_to() returns an HTML "input" tag'); $t->is(button_to('test', '@homepage', 'popup=true'), '<input value="test" type="button" onclick="var w=window.open(\'module/action\');w.focus();return false;" />', 'button_to() accepts options as string'); $t->is(button_to('test', '@homepage', 'confirm=really?'), '<input value="test" type="button" onclick="if (confirm(\'really?\')) { return document.location.href=\'module/action\';} else return false;" />', 'button_to() works with confirm option'); $t->is(button_to('test', '@homepage', 'popup=true confirm=really?'), '<input value="test" type="button" onclick="if (confirm(\'really?\')) { var w=window.open(\'module/action\');w.focus(); };return false;" />', 'button_to() works with confirm and popup option'); $t->like(button_to('test', '@homepage', array('method' => 'post')), '/==TOKEN==/', 'button_to() includes CSRF token from BaseForm'); class testObject { } try { $o1 = new testObject(); link_to($o1, '@homepage'); $t->fail('link_to() can take an object as its first argument if __toString() method is defined'); } catch (sfException $e) { $t->pass('link_to() can take an object as its first argument if __toString() method is defined'); } class testObjectWithToString { public function __toString() { return 'test';
?> <div class="content"> <?php $id_empresa = isset($filters['id_empresa']) ? $filters['id_empresa'] : null; $c = EmpresaPeer::getCriterioAlcance(); $empresas = EmpresaPeer::doSelect($c); $value = select_empresas('filters[id_empresa]', objects_for_select($empresas, 'getIdEmpresa', '__toString', $id_empresa, array('include_blank' => true)), array('control_name' => 'filters[id_empresa]', 'include_blank' => true)); echo $value ? $value : " "; ?> </div> </div> </fieldset> <ul class="sf_admin_actions"> <li><?php echo button_to(__('reset'), 'tablas/list?filter=filter', 'class=sf_admin_action_reset_filter'); ?> </li> <li><?php echo submit_tag(__('filter'), 'name=filter class=sf_admin_action_filter'); ?> </li> </ul> </form> --> </div>
if ($sf_user->hasCredential('admin') || $sf_user->hasCredential('importer')) { ?> <br /> <?php if (isset($id)) { ?> <?php echo button_to('view', "@railsMap?id=" . $id); ?> <br /> <?php } if (isset($id)) { ?> <?php echo button_to('meta', "@railsMapEditMeta?id=" . $id); ?> <br /> <?php } ?> <input id="netmap_save" type="button" value="save" /><br /> <?php } ?> <div id="netmap_add_entity"> <div id="netmap_add_entity_hide"><a id="netmap_add_entity_hide_link" onclick="$('#netmap_add_entity').css('display', 'none'); return false;">hide</a></div> <?php include_partial('global/section', array('title' => 'Add Entity')); ?>
<ul class="sf_admin_actions"> <li><?php echo button_to(__('create'), 'informes/create', array('class' => 'sf_admin_action_create')); ?> </li> </ul>
<?php // auto-generated by sfPropelAdmin // date: 2008/03/26 17:56:58 ?> <ul class="sf_admin_actions"> <?php if ($sf_user->hasCredential(array(0 => array(0 => 'administrator', 1 => 'vocabularymaintainer', 2 => 'vocabularyadmin')))) { ?> <li><?php $concept = $sf_user->getAttribute('concept', '', sfUser::ATTRIBUTE_NAMESPACE); $conceptId = $concept ? '?concept_id=' . $concept->getId() : ''; echo button_to(__('Add Property'), 'conceptprop/create' . $conceptId . '', array('title' => 'Create', 'class' => 'sf_admin_action_create')); ?> </li> <?php } else { ?> <?php } ?> </ul>
echo $value ? $value : ' '; ?> <div class="sf_edit_help"><?php echo __('Indique el orden de la tabla dentro de la lisa'); ?> </div> </div> </div> </fieldset> <?php include_partial('edit_actions', array('tabla' => $tabla)); ?> </form> <?php if ($tabla->getIdTabla()) { ?> <ul class="sf_admin_actions"> <li class="float-left"> <?php echo button_to(__('Borrar'), 'tablas/delete?id_tabla=' . $tabla->getIdTabla(), array('post' => true, 'confirm' => __('¿Quiere borrar este objeto?'), 'class' => 'sf_admin_action_delete')); ?> </li> </ul> <?php }
<?php include_partial('global/formerrors', array('form' => array($address_form, $reference_form))); ?> <form action="<?php echo url_for('entity/editAddress'); ?> " method="POST"> <?php echo input_hidden_tag('id', $address->id); ?> <table> <?php include_partial('reference/required', array('form' => $reference_form)); ?> <?php include_partial('global/form', array('form' => $address_form)); ?> <td></td> <td> <?php echo submit_tag('Save'); ?> <?php echo button_to('Cancel', 'entity/address?id=' . $address->id); ?> </table> </form>
<input type="hidden" name="rm" value="2" /> <input type="hidden" name="return" value="<?php echo url_for('@buy_process', true); ?> " /> <input type="hidden" name="cancel_return" value="<?php echo url_for('@buy_cancel', true); ?> " /> <input type="hidden" name="currency_code" value="USD" /> <input type="hidden" name="country" value="US" /> <input type="hidden" name="no_shipping" value="1" /> <input type="hidden" name="no_note" value="1" /> <input type="hidden" name="invoice" value="<?php echo $payment->getId(); ?> " /> <img alt="" id="btnPaypal" src="/img/common/paypal.gif" /> <input type="submit" name="submit" value="<?php echo __("Confirm"); ?> "/> <?php echo button_to(__('Cancel'), '@buy_cancel'); ?> </form> </td> </tr> </table> <?php }
?> </form> <?php if ($mensaje->getPrimaryKey()) { ?> <ul class="sf_admin_actions"> <?php $value = ""; $usuario = Usuario::getUsuarioActual(); if ($usuario->getPrimaryKey() == $mensaje->getIdUsuario()) { $value = "<li class=\"float-left\">"; $value .= button_to(__('Borrar completamente'), 'mensajes/delete_salida?id_mensaje=' . $mensaje->getPrimaryKey(), array('post' => true, 'confirm' => __('¿Quiere borrar este mensaje? También se borrarán las copias enviadas a los destinatarios'), 'class' => 'sf_admin_action_delete')); $value .= "</li>\n"; $mensaje_destino = MensajeDestinoPeer::retrieveByPk($mensaje->getPrimaryKey(), $usuario->getPrimaryKey()); if (isset($mensaje_destino)) { $value .= "<li class=\"float-left\">"; $value .= button_to(__('borrar copia recibida'), 'mensajes/delete_entrada?id_mensaje=' . $mensaje->getPrimaryKey(), array('post' => true, 'confirm' => __('¿Quiere borrar esta copia? El mensaje original se mantendrá intacto'), 'class' => 'sf_admin_action_delete')); $value .= "</li>\n"; } } else { $value = "<li class=\"float-left\">"; $value .= button_to(__('Borrar'), 'mensajes/delete_entrada?id_mensaje=' . $mensaje->getPrimaryKey(), array('post' => true, 'confirm' => __('¿Quiere borrar este objeto?'), 'class' => 'sf_admin_action_delete')); $value .= "</li>\n"; } echo $value; ?> </ul> <?php }
<?php } if ($sf_user->hasCredential(array(0 => array(0 => 'administrator', 1 => 'schemaadmin', 2 => 'agentadmin'))) && count($sf_flash->get('newUsers', array()))) { ?> <li><?php if ($schema_has_user->getId()) { echo button_to(__('Add Maintainer'), 'schemauser/create', array('title' => 'Create', 'class' => 'sf_admin_action_create')); } ?> </li> <?php } if ($sf_user->hasCredential(array(0 => array(0 => 'administrator', 1 => 'schemaadmin', 2 => 'agentadmin'))) && 1 < count($sf_flash->get('newUsers', array()))) { ?> <li><?php echo submit_tag(__('Save and add'), array('name' => 'save_and_add', 'title' => 'Save and add', 'class' => 'sf_admin_action_save_and_add')); ?> </li> <?php } if ($sf_user->hasCredential(array(0 => array(0 => 'administrator', 1 => 'schemaadmin', 2 => 'agentadmin', 3 => 'schemamaintainer')))) { ?> <li><?php echo button_to(__('Cancel'), 'schemauser/cancel?id=' . $schema_has_user->getId(), array('title' => 'Cancel', 'class' => 'sf_admin_action_cancel')); ?> </li> <?php } ?> </ul>
<?php // auto-generated by sfPropelAdmin // date: 2007/07/18 17:55:34 ?> <ul class="sf_admin_actions"> <li><?php echo button_to(__('list'), 'horarioescolar/list?id=' . $horarioescolar->getId(), array('class' => 'sf_admin_action_list')); ?> </li> <li><?php echo submit_tag(__('save'), array('name' => 'save', 'class' => 'sf_admin_action_save')); ?> </li> <li><?php echo submit_tag(__('save and add'), array('name' => 'save_and_add', 'class' => 'sf_admin_action_save_and_add')); ?> </li> </ul>
</div> </div> <div class="form-row"> <label for="filters_created_at"><?php echo __('Data adesione:'); ?> </label> <div class="content"> <?php echo input_date_range_tag('filters[created_at]', isset($filters['created_at']) ? $filters['created_at'] : null, array('rich' => true, 'withtime' => true, 'calendar_button_img' => '/sf/sf_admin/images/date.png')); ?> </div> </div> </fieldset> <ul class="sf_admin_actions"> <li><?php echo button_to(__('reset'), 'premiumdemo/list?filter=filter', 'class=sf_admin_action_reset_filter'); ?> </li> <li><?php echo submit_tag(__('filter'), 'name=filter class=sf_admin_action_filter'); ?> </li> </ul> </form> </div>
<?php echo object_input_date_tag($rel_calendariovacunacion_alumno, 'getFecha', array('rich' => true, 'withtime' => true, 'calendar_button_img' => sfConfig::get('sf_admin_web_dir') . '/images/date.png', 'control_name' => 'rel_calendariovacunacion_alumno[fecha]')); ?> </div> </div> </fieldset> <?php echo include_partial('edit_actions', array('rel_calendariovacunacion_alumno' => $rel_calendariovacunacion_alumno)); ?> </form> <ul class="sf_admin_actions"> <li class="float-left"><?php if ($rel_calendariovacunacion_alumno->getId()) { echo button_to(__('delete'), 'relCalendariovacunacionAlumno/delete?id=' . $rel_calendariovacunacion_alumno->getId(), array('post' => true, 'confirm' => __('Are you sure?'), 'class' => 'sf_admin_action_delete')); } ?> </li> </ul> </div> <div id="sf_admin_footer"> <?php include_partial('relCalendariovacunacionAlumno/edit_footer', array('rel_calendariovacunacion_alumno' => $rel_calendariovacunacion_alumno)); ?> </div>
echo __('Save'); ?> " name="btnSave" id="submitSave"/> <input type="button" class="" id="btnAddRow" value="<?php echo __('Add Row'); ?> " name="btnAddRow"> <input type="button" class="delete" id="submitRemoveRows" value="<?php echo __('Remove Rows'); ?> " name="btnRemoveRows"> <?php echo button_to(__('Reset'), 'time/editTimesheet?timesheetId=' . $timesheetId . '&employeeId=' . $employeeId . '&actionName=' . $backAction, array('class' => 'reset', 'id' => 'btnReset')); ?> <?php echo button_to(__('Cancel'), 'time/' . $backAction . '?timesheetStartDate=' . $startDate . '&employeeId=' . $employeeId, array('class' => 'reset', 'id' => 'btnBack')); ?> </p> </div> </form> </div> <!-- inner --> </div> <!-- Box --> <?php echo $listForm; ?> <!-- comment-Dialog --> <div class="modal hide" id="commentDialog"> <div class="modal-header">
<?php // auto-generated by sfPropelAdmin // date: 2007/05/02 17:35:40 ?> <ul class="sf_admin_actions"> <li><?php echo button_to(__('create'), 'relDivisionActividadDocente/create', array('class' => 'sf_admin_action_create')); ?> </li> <li><?php echo button_to(__('exportar'), 'relDivisionActividadDocente/exportToIcal', array('class' => '')); ?> </li> <li><?php echo button_to(__('ver calendario'), 'relDivisionActividadDocente/verCalendario', array('class' => '')); ?> </li> </ul>
?> </label> <div class="content"> <?php if (isset($filters['period']['from']) && !is_int($filters['period']['from'])) { $filters['period']['from'] = strtotime($filters['period']['from']); } if (isset($filters['period']['to']) && !is_int($filters['period']['to'])) { $filters['period']['to'] = strtotime($filters['period']['to']); } ?> <?php echo input_date_range_tag('filters[period]', isset($filters['period']) ? $filters['period'] : null, array('rich' => true, 'withtime' => false, 'calendar_button_img' => '/sf/sf_admin/images/date.png')); ?> </div> </div> </fieldset> <ul class="sf_admin_actions"> <li><?php echo button_to(__('reset'), 'sfStatistics/index?filter=filter', 'class=sf_admin_action_reset_filter'); ?> </li> <li><?php echo submit_tag(__('filter'), 'name=filter class=sf_admin_action_filter'); ?> </li> </ul> </form> </div>
<div class="row"> <?php echo form_error('login'); ?> <label for="login">Login: </label> <?php echo input_tag('login'); ?> </div> <div class="row"> <?php echo form_error('password'); ?> <label for="password">Hasło: </label> <?php echo input_password_tag('password'); ?> </div> </fieldset> <?php echo submit_tag('Dalej', array('class' => 'submit')); ?> <?php echo button_to('Powrót', $sf_request->getReferer(), array('class' => 'submit')); ?> </form> <?php include_partial('global/page_footer');
<?php } ?> </td> <td> <?php if ($name != $sf_sympal_site->getTheme()) { ?> <?php echo button_to(__('Make %1% Default', array('%1%' => $sf_sympal_site->getTitle())), '@sympal_themes_make_default?site=1&name=' . $name); ?> <?php } else { ?> <?php echo button_to(__('Remove %1% Default', array('%1%' => $sf_sympal_site->getTitle())), '@sympal_themes_make_default?site=1&name=' . $name); ?> <?php } ?> </td> </tr> <?php } ?> </tbody> </table> </div> </div> </div>
<div class="sf_apply_notice"> <p> Thank you for confirming your account! You are now logged into the site. </p> <p> <?php echo button_to("Continue", "@homepage"); ?> </p> </div>
<?php // auto-generated by sfPropelAdmin // date: 2007/05/02 13:04:37 ?> <ul class="sf_admin_actions"> <li><?php echo button_to(__('list'), 'relDivisionActividadDocente/list?id=' . $rel_division_actividad_docente->getId(), array('class' => 'sf_admin_action_list')); ?> </li> <li><?php echo submit_tag(__('save'), array('name' => 'save', 'class' => 'sf_admin_action_save')); ?> </li> <li><?php echo submit_tag(__('save and add'), array('name' => 'save_and_add', 'class' => 'sf_admin_action_save_and_add')); ?> </li> </ul>
?> </div> </div> </fieldset> <!--Ana: Para el filtro por calendario --> <input type="hidden" name="filtro_calendario" id="filtro_calendario" value="0"> <input type="hidden" name="mes" id="mes" value="<?php echo date('m'); ?> "> <input type="hidden" name="year" id="year" value="<?php echo date('Y'); ?> "> <ul class="sf_admin_actions"> <li><?php echo button_to(__('reiniciar'), 'tareas/list', 'class=sf_admin_action_reset_filter'); //?filter=filter ?> </li> <li><?php echo submit_tag(__('filtrar'), 'name=filter class=sf_admin_action_filter'); ?> </li> </ul> </form> </div>
<h1>Permisos por Roles</h1> <br> <?php echo form_tag('rol/savePermiso', 'onSubmit="selectItem()"'); ?> Rol: <?php echo select_tag('id', options_for_select($optionsRol, $sf_params->get('id')), 'onChange=linkTo()'); ?> <br> <br> <?php echo select_tag('permisos', options_for_select($optionsPermisos), 'multiple=multiple id="fromBox"'); echo select_tag('rolPermisos[]', options_for_select($optionsRolPermisos), 'multiple=multiple id="toBox"'); // echo select_tag('rolPermisos[]', objects_for_select($optionsRolPermisos,'getFkPermisoId','getPermiso()->getNombre',''), 'multiple=multiple id="toBox"'); ?> <ul class="sf_admin_actions"> <li><?php echo submit_tag('submit', 'class=sf_admin_action_save value=Grabar'); ?> </li> <li><?php echo button_to('Listado de Roles', 'rol/list', array('class' => 'sf_admin_action_list')); ?> </li> </ul> </form> </div> </div> <script type="text/javascript"> createMovableOptions("fromBox","toBox",500,300,'Permisos Disponibles','Permisos Seleccionados'); </script>
<?php echo label_for('historico_documento[id_usuario]', __($labels['historico_documento{id_usuario}']), ''); ?> <div class="content"> <?php $usuario = $historico_documento->getUsuario(); $value = $usuario ? $usuario->__toString() : "- " . __('Sin definir') . " -"; echo $value ? $value : ' '; ?> </div> </div> </fieldset> <?php include_partial('edit_actions', array('historico_documento' => $historico_documento)); ?> </form> <ul class="sf_admin_actions"> <li class="float-left"><?php if ($historico_documento->getIddocumento() && $historico_documento->getVersion()) { $url = 'historico_documentos/delete?id_documento=' . $historico_documento->getIddocumento(); $url .= '&version=' . $historico_documento->getVersion(); echo button_to(__('Borrar'), $url, array('post' => true, 'confirm' => __('¿Estás seguro?'), 'class' => 'sf_admin_action_delete')); } ?> </li> </ul>
for ($i = 1; $i <= count($opciones); $i++) { $html .= "<li>"; $html .= radiobutton_tag('formulario[estado_interes]', $i, $valorSeleccionado == $i, 'id=formulario_estado_interes_' . $i); $html .= "<label for=formulario_estado_interes_" . $i . ">"; $html .= $opciones[$i]; $html .= "</label>"; $html .= "</li>\n"; } $html .= "</ul>\n"; echo $html; ?> </div> </div> </fieldset> <?php include_partial('edit_actions', array('formulario' => $formulario)); ?> </form> <ul class="sf_admin_actions"> <li class="float-left"><?php if ($formulario->getIdFormulario()) { echo button_to(__('Borrar'), 'formularios/delete?id_formulario=' . $formulario->getIdFormulario(), array('post' => true, 'confirm' => __('¿Desea borrar este objeto?'), 'class' => 'sf_admin_action_delete')); } ?> </li> </ul>
<?php sympal_use_javascript('jquery.js'); sympal_use_javascript('jquery.ui.js'); sympal_use_stylesheet('/sfSympalAdminPlugin/css/nested_sortable/nestedsortablewidget.css'); sympal_use_javascript('/sfSympalAdminPlugin/js/nested_sortable/interface.js'); sympal_use_javascript('/sfSympalAdminPlugin/js/nested_sortable/inestedsortable.pack.js'); sympal_use_javascript('/sfSympalAdminPlugin/js/nested_sortable/jquery.nestedsortablewidget.pack.js'); ?> <?php echo button_to(__('Back to list', array(), 'sf_admin'), '@' . $sf_context->getRouting()->getCurrentRouteName()); ?> <h1><?php echo $title = __('Adjust Order'); ?> </h1> <?php $sf_response->setTitle($title); ?> <?php foreach ($pager->getResults() as $result) { ?> <?php if ($result->getNode()->isRoot()) { ?>
<tfoot> <tr> <th colspan="9"> </th> </tr> </tfoot> </table> <?php } else { ?> No hay horarios cargados <?php } ?> <div> <ul class="sf_admin_actions"> <li> <?php $id = $sf_params->get('idDocente') ? $sf_params->get('idDocente') : 1; echo button_to(__('create'), 'docenteHorario/edit?idDocente=' . $id, array('class' => 'sf_admin_action_create')); ?> <li> <li> <?php echo button_to('Listado de Docentes', 'docente/list', array('class' => 'sf_admin_action_list')); ?> </li> </ul> </div> </form>
} ?> </div> </fieldset> <ul class="sf_admin_actions"> <li><?php echo submit_tag(__('save'), array('name' => 'save', 'class' => 'sf_admin_action_save')); ?> </li> <li><?php echo button_to(__('Legajos'), 'legajopedagogico/verLegajo?aid=' . $alumno_id . '&cid=' . $legajo_categoria_id, array('class' => 'sf_admin_action_list')); ?> </li> </ul> </form> <ul class="sf_admin_actions"> <li class="float-left"><?php if ($legajopedagogico->getId()) { echo button_to(__('delete'), 'legajopedagogico/delete?id=' . $legajopedagogico->getId(), array('post' => true, 'confirm' => __('Are you sure?'), 'class' => 'sf_admin_action_delete')); } ?> </li> </ul> </div>
?> <?php } ?> <?php $value = object_checkbox_tag($tarea, 'getAvisarEmailFin', array('control_name' => 'tarea[avisar_email_fin]')); echo $value ? $value : " "; ?> </div> </div> </fieldset> <?php include_partial('edit_actions', array('tarea' => $tarea)); ?> </form> <?php if ($tarea->getIdTarea()) { ?> <ul class="sf_admin_actions"> <li class="float-left"> <?php echo button_to(__('borrar'), 'tarea/delete?id_tarea=' . $tarea->getIdTarea(), array('post' => true, 'confirm' => __('¿Desea borrar este objeto?'), 'class' => 'sf_admin_action_delete')); ?> </li> </ul> <?php }
<ul class="sf_admin_actions"> <li> <?php echo button_to(__('crear'), 'empresas/create', array('class' => 'sf_admin_action_create')); ?> </li> </ul>
</tbody> <tfoot> <tr><th colspan="<?php echo sizeof($lista_campos_extra) + 2; ?> "> <div class="float-right"> <?php $value = pager_navigation($pager, 'formularios/edit/?id_formulario=' . $id_formulario); echo $value ? $value : ' '; ?> </div> <?php $cuantos = $pager->getNbResults(); echo format_number_choice('[0] no hay resultados|[1] 1 resultado|(1,+Inf] %1% resultados', array('%1%' => $cuantos), $cuantos); ?> </th></tr> </tfoot> </table> <ul class="sf_admin_actions"> <div style="clear:left"> </div> <br /> <li><?php if ($tabla->getIdTabla() != null) { echo button_to(__('Crear nuevo registro'), 'formularios/create?id_tabla=' . $tabla->getIdTabla() . "&id_tabla_proviene=" . $id_tabla . "&id_formulario_proviene=" . $id_formulario, array('class' => 'sf_admin_action_create')); } ?> </li> </ul>