1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374 |
- <?php
- global $myUser;
- if(!$myUser->connected()) throw new Exception("Vous devez être connecté pour accéder à cette fonctionnalité",401);
- if(!$myUser->can('part','read')) throw new Exception("Vous n'avez pas la permission pour executer cette fonctionnalité",403);
- require_once(__DIR__.SLASH.'Part.class.php');
- ?>
- <div class="row">
-
- <div class="col-md-8">
- <select id="filters" data-type="filter" data-label="Recherche" data-function="part_part_search">
- <option value="label" data-filter-type="text">Libellé</option>
- </select>
- </div>
-
- <div class="col-md-4">
- <?php if($myUser->can('part', 'edit')) : ?>
- <a href="index.php?module=part&page=sheet.part" class="btn btn-success right"><i class="fas fa-plus"></i> Ajouter</a>
- <?php endif; ?>
- </div>
- </div>
- <br/>
- <div class="row">
- <!-- search results -->
- <div class="col-xl-12">
- <ul id="parts" data-entity-search="part_part_search">
- <li data-id="{{id}}" data-part="{{part}}" class="hidden">
- <div class="part">
- <input type="text" data-type="part" data-force="false" placeholder="Nom du composant" value="{{label}}" class="form-control label">
- <div class="part-image" data-label="Image" style="height:220px;background : url(data:{{picture}}) 0% 0% / cover" data-stream="{{picture}}"></div>
- <input class="hidden" type="file">
-
- <div class="price w-100 mt-2">
- <div class="input-group">
- <div class="input-group-prepend">
- <span class="input-group-text">Prix</span>
- </div>
- <input class="form-control" type="text" value="{{price}}">
- <div class="input-group-append">
- <span class="input-group-text">€</span>
- </div>
- </div>
- </div>
- <div class="brand w-100 mt-2 mb-3">
- <div class="input-group">
- <div class="input-group-prepend">
- <span class="input-group-text">Marque</span>
- </div>
- <input class="form-control" type="text" value="{{brand}}"/>
- </div>
- </div>
-
-
-
- <a onclick="part_part_find(this)" title="Chercher sur le net" class="link"><i class="fas fa-globe-americas pointer"></i></a>
- <div class="btn btn-delete" onclick="part_part_delete(this);"><i class="far fa-trash-alt"></i></div>
- <div class="clear"></div>
- <div class="btn btn-dark w-100 mb-3 btn-save-part" onclick="part_part_save(this)"><i class="far fa-check-circle"></i>Valider</div>
- </div>
- </li>
- </ul>
-
- <!-- Pagination -->
-
- <ul class="pagination">
- <li class="page-item hidden" data-value="{{value}}" title="Voir la page {{label}}" onclick="$(this).parent().find('li').removeClass('active');$(this).addClass('active');part_part_search();">
- <a class="page-link" href="#">{{label}}</a>
- </li>
- </ul>
- </div>
- </div>
|