File "admin-flyers-products-edit.tmpl"

Full Path: /srv/www/www.cadoro.it/src/templates/admin-flyers-products-edit.tmpl
File size: 10.22 KB
MIME-type: text/html
Charset: utf-8

{extends file='layout-admin.tmpl'}
<html>
  <body>
    {block name="breadcrumbs"}
    <div class="breadcrumbs">
      <a href="{$base_url}/admin/flyers">Volantini</a> <span class="divider">&raquo;</span>
      <a href="{$base_url}/admin/flyers/{$flyer.id}">{$flyer.title}</a> <span class="divider">&raquo;</span>
      <strong>{$product.title}</strong>
    </div>
    {/block}
    {block name="content"}
    <div class="sheet">
      <div class="sheet-header">
        <h1>
          Modifica prodotto
          <small>{$product.title}</small>
        </h1>
      </div>
      <div class="sheet-body">
        {if $errors}
        <div class="alert alert-danger">
          <strong>Si sono verificati degli errori, impossibile proseguire!</strong>
        </div>
        {/if}
        <form class="form-horizontal" method="post" action="" enctype="multipart/form-data">
          <fieldset>
            <legend>1. Dati prodotto</legend>
            <div class="form-group">
              <label class="control-label col-md-2" for="category">Categoria</label>
              <div class="controls col-md-10">
                <input type="text" class="form-control" id="category" name="category" value="{_f('category', $product)}">
                {if isset($errors.category)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="subcategory">Sottocategoria</label>
              <div class="controls col-md-10">
                <input type="text" class="form-control" id="subcategory" name="subcategory" value="{_f('subcategory', $product)}">
                {if isset($errors.subcategory)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="code">Codice</label>
              <div class="controls col-md-10">
                <input type="text" class="form-control" id="code" name="code" value="{_f('code', $product)}">
                {if isset($errors.code)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="title">Titolo</label>
              <div class="controls col-md-10">
                <input type="text" class="form-control" id="title" name="title" value="{_f('title', $product)}">
                {if isset($errors.title)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="description">Descrizione</label>
              <div class="controls col-md-10">
                <input type="text" class="form-control" id="description" name="description" value="{_f('description', $product)}">
                {if isset($errors.description)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="brand">Brand</label>
              <div class="controls col-md-10">
                <input type="text" class="form-control" id="brand" name="brand" value="{_f('brand', $product)}">
                {if isset($errors.brand)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="ean">EAN</label>
              <div class="controls col-md-10">
                <input type="text" class="form-control" id="ean" name="ean" value="{_f('ean', $product)}">
                {if isset($errors.ean)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="offer_price">Offerta (prezzo)</label>
              <div class="controls col-md-10">
                <input type="text" class="form-control" id="offer_price" name="offer_price" value="{_fn('offer_price', $product)}">
                {if isset($errors.offer_price)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="offer_price_old">Offerta (listino)</label>
              <div class="controls col-md-10">
                <input type="text" class="form-control" id="offer_price_old" name="offer_price_old" value="{_fn('offer_price_old', $product)}">
                {if isset($errors.offer_price_old)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="offer_discount">Offerta (sconto)</label>
              <div class="controls col-md-10">
                <input type="text" class="form-control" id="offer_discount" name="offer_discount" value="{_f('offer_discount', $product)}">
                {if isset($errors.offer_discount)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="offer_multi">Offerta (multi)</label>
              <div class="controls col-md-10">
                <input type="text" class="form-control" id="offer_multi" name="offer_multi" value="{_f('offer_multi', $product)}">
                {if isset($errors.offer_multi)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="offer_type">Offerta (tipo)</label>
              <div class="controls col-md-10">
                <input type="text" class="form-control" id="offer_type" name="offer_type" value="{_f('offer_type', $product)}">
                {if isset($errors.offer_type)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="stores">Punti vendita</label>
              <div class="controls col-md-10">
                <input type="text" class="form-control" id="stores" name="stores" value="{_f('stores', $product)}">
                {if isset($errors.stores)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="stores_card">Punti vendita CARD</label>
              <div class="controls col-md-10">
                <input type="text" class="form-control" id="stores_card" name="stores_card" value="{_f('stores_card', $product)}">
                {if isset($errors.stores_card)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="label">Tipologia</label>
              <div class="controls col-md-10">
                <input type="text" class="form-control" id="label" name="label" value="{_f('label', $product)}">
                {if isset($errors.label)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="label2">Cartiglio</label>
              <div class="controls col-md-10">
                <input type="text" class="form-control" id="label2" name="label2" value="{_f('label2', $product)}">
                {if isset($errors.label2)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="date_begin">Data inizio</label>
              <div class="controls col-md-10">
                {_date_combos("date_begin", _d('date_begin', $product), -1, 1)}
                {if isset($errors.date_begin)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="date_end">Data fine</label>
              <div class="controls col-md-10">
                {_date_combos("date_end", _d('date_end', $product), -1, 1)}
                {if isset($errors.date_end)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="file">Immagine prodotto</label>
              <div class="controls col-md-10">
                <input type="file" class="form-control" id="image" name="image">
                <p class="mt10">
                  <img src="{$base_url}/assets/{$product.image_thumb}" alt="">
                </p>
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="homepage">Mostra in home page</label>
              <div class="controls col-md-10">
                <input type="checkbox" class="form-control" id="homepage" name="homepage" value="1"{if _f('homepage', $product)} checked="checked"{/if}>
                {if isset($errors.homepage)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
            <div class="form-group">
              <label class="control-label col-md-2" for="below_cost">Sottocosto</label>
              <div class="controls col-md-10">
                <input type="checkbox" class="form-control" id="below_cost" name="below_cost" value="1"{if _f('below_cost', $product)} checked="checked"{/if}>
                {if isset($errors.below_cost)}<p class="help-block error">Campo obbligatorio!</p>{/if}
              </div>
            </div>
          </fieldset>
          <div class="form-group"><div class="col-md-offset-2 col-md-10">
            <button type="submit" class="btn btn-primary">Salva le modifiche</button>
            <a href="{$base_url}/admin/flyers/{$flyer.id}/products" class="btn btn-default">Annulla</a>
          </div></div>
        </form>
      </div>
    </div>
    {/block}
  </body>
</html>