<div tal:replace="nothing">
<!--

camcops_server/templates/deform/readonly/horizontal_form.pt

===============================================================================

    Copyright (C) 2012, University of Cambridge, Department of Psychiatry.
    Created by Rudolf Cardinal (rnc1001@cam.ac.uk).

    This file is part of CamCOPS.

    CamCOPS is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    CamCOPS is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with CamCOPS. If not, see <https://www.gnu.org/licenses/>.

===============================================================================

A Zope page template, used by Deform.
Mostly original Deform code but with some modifications.

-->
</div>
<form
  tal:define="style style|field.widget.style;
              css_class css_class|string:${field.widget.css_class or field.css_class or ''};
              item_template item_template|field.widget.readonly_item_template;
              title title|field.title;
              errormsg errormsg|field.errormsg;
              description description|field.description;
              buttons buttons|field.buttons;
              use_ajax use_ajax|field.use_ajax;
              ajax_options ajax_options|field.ajax_options;
              formid formid|field.formid;
              method method|field.method;"
  tal:attributes="style style;
                  class css_class;"
  id="${formid}"
  method="${method}"
  enctype="multipart/form-data"
  accept-charset="utf-8"
  i18n:domain="deform"
  class="deform ${field.bootstrap_form_style | 'form-horizontal'}"
  >
  <!-- added class="..." above -->

  <fieldset class="deform-form-fieldset">

    <legend tal:condition="title">${title}</legend>

    <p class="section first" tal:condition="description">
      ${description}
    </p>

    <div tal:repeat="child field"
         tal:replace="structure child.render_template(item_template)"/>

  </fieldset>

</form>
