first commit
This commit is contained in:
146
templates/backend_admin/annonce/add_update.htm.twig
Normal file
146
templates/backend_admin/annonce/add_update.htm.twig
Normal file
@@ -0,0 +1,146 @@
|
||||
{% extends 'base_backend_admin.html.twig' %}
|
||||
|
||||
{% block title %} Annonce {% endblock %}
|
||||
|
||||
{% block content %}
|
||||
|
||||
|
||||
{% set titlePage = 'Ajouter' %}
|
||||
{% if app.request.attributes.get('_route') == 'backend_societe_update' %}
|
||||
{% set titlePage = 'Modifier' %}
|
||||
{% endif %}
|
||||
|
||||
|
||||
<!-- Page Heading -->
|
||||
<div class="d-sm-flex align-items-center justify-content-between mb-4">
|
||||
<h1 class="h3 mb-0 text-gray-800">Annonces</h1>
|
||||
<ol class="breadcrumb float-sm-right">
|
||||
<li class="breadcrumb-item">Annonce</li>
|
||||
<li class="breadcrumb-item">{{ titlePage }}</li>
|
||||
</ol>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Begin Page Content -->
|
||||
<div class="container-fluid">
|
||||
|
||||
{% include 'backend_admin/basic/notice.html.twig' %}
|
||||
|
||||
<!-- DataTales Example -->
|
||||
<div class="card shadow mb-4">
|
||||
|
||||
<div class="card-header py-3">
|
||||
<h6 class="m-0 font-weight-bold text-primary">{{ titlePage }} une nouvelle Annonce</h6>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
|
||||
{{ form_start(form) }}
|
||||
<div class="row g-3">
|
||||
|
||||
{{ form_errors(form) }}
|
||||
{{ form_row(form._token) }}
|
||||
|
||||
<div class="col-8 my-3">
|
||||
{{ form_label(form.titre, 'Titre *', {'attr': {'class': 'form-label'}}) }}
|
||||
<div class="input-group">
|
||||
<span class="input-group-text"><i class="fa-solid fa-book"></i></span>
|
||||
{{ form_widget(form.titre, {'attr': {'class': 'form-control'}}) }}
|
||||
<div class="invalid-feedback">
|
||||
{{ form_errors(form.titre) }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-4 my-3">
|
||||
{{ form_label(form.categorie, 'Catégorie', {'attr': {'class': 'form-label'}}) }}
|
||||
<div class="input-group">
|
||||
<span class="input-group-text"><i class="fa-solid fa-bars"></i></span>
|
||||
{{ form_widget(form.categorie, {'attr': {'class': 'form-control'}}) }}
|
||||
<div class="invalid-feedback">
|
||||
{{ form_errors(form.categorie) }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-6 my-3">
|
||||
{{ form_label(form.prix_promo, 'Prix promo *', {'attr': {'class': 'form-label'}}) }}
|
||||
<div class="input-group">
|
||||
<span class="input-group-text"><i class="fa-solid fa-money-bill-wave"></i></span>
|
||||
{{ form_widget(form.prix_promo, {'attr': {'class': 'form-control'}}) }}
|
||||
<div class="invalid-feedback">
|
||||
{{ form_errors(form.prix_promo) }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-6">
|
||||
{{ form_label(form.pourcentage_reduction, 'Pourcentage reduction', {'attr': {'class': 'form-label'}}) }}
|
||||
<div class="input-group">
|
||||
<span class="input-group-text"><i class="fa-solid fa-percent"></i></span>
|
||||
{{ form_widget(form.pourcentage_reduction, {'attr': {'class': 'form-control'}}) }}
|
||||
<div class="invalid-feedback">
|
||||
{{ form_errors(form.pourcentage_reduction) }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-8">
|
||||
{{ form_label(form.societe, 'Société', {'attr': {'class': 'form-label'}}) }}
|
||||
<div class="input-group">
|
||||
<span class="input-group-text"><i class="fa-solid fa-building"></i></span>
|
||||
{{ form_widget(form.societe, {'attr': {'class': 'form-control select-filter select2bs4 select-filter-speaker'}}) }}
|
||||
<div class="invalid-feedback">
|
||||
{{ form_errors(form.societe) }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-6">
|
||||
{{ form_label(form.prix_marche, 'Prix du marché', {'attr': {'class': 'form-label'}}) }}
|
||||
<div class="input-group">
|
||||
<span class="input-group-text"><i class="fa-solid fa-money-bill-1"></i></span>
|
||||
{{ form_widget(form.prix_marche, {'attr': {'class': 'form-control'}}) }}
|
||||
<div class="invalid-feedback">
|
||||
{{ form_errors(form.prix_marche) }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-12 my-3">
|
||||
<div class="col-4" >
|
||||
{{ form_label(form.largeur, 'Largeur Annonce', {'attr': {'class': 'form-label'}}) }}
|
||||
<div class="input-group">
|
||||
<span class="input-group-text"><i class="fa-solid fa-left-right"></i></span>
|
||||
{{ form_widget(form.largeur, {'attr': {'class': 'form-control'}}) }}
|
||||
<div class="invalid-feedback">
|
||||
{{ form_errors(form.largeur) }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="col-12 my-3">
|
||||
{{ form_label(form.description, 'Déscription *', {'attr': {'class': 'form-label'}}) }}
|
||||
{{ form_widget(form.description, {'attr': {'class': 'form-control'}}) }}
|
||||
<div class="invalid-feedback">{{ form_errors(form.description) }}</div>
|
||||
</div>
|
||||
|
||||
<hr class="my-4">
|
||||
{{ form_widget(form.save, {'label': "Enregister", 'attr': {'class': 'w-90 btn btn-primary btn-lg'}}) }}
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
{{ form_end(form) }}
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
{% endblock %}
|
||||
113
templates/backend_admin/annonce/index.html.twig
Normal file
113
templates/backend_admin/annonce/index.html.twig
Normal file
@@ -0,0 +1,113 @@
|
||||
{% extends 'base_backend_admin.html.twig' %}
|
||||
|
||||
{% block title %} Annonce {% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<!-- Page Heading -->
|
||||
<div class="d-sm-flex align-items-center justify-content-between mb-4">
|
||||
<h1 class="h3 mb-0 text-gray-800">Annonce</h1>
|
||||
<ol class="breadcrumb float-sm-right">
|
||||
<li class="breadcrumb-item">Annonce</li>
|
||||
</ol>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<!-- Begin Page Content -->
|
||||
<div class="container-fluid">
|
||||
|
||||
{% include 'backend_admin/basic/notice.html.twig' %}
|
||||
|
||||
<a href="{{ path('backend_admin_annonce_add') }}" class="btn btn-success btn-icon-split mb-4">
|
||||
<span class="icon text-white"><i class="fa-regular fa-square-plus"></i></span>
|
||||
<span class="text text-white">Ajouter une nouvelle annonce</span>
|
||||
</a>
|
||||
|
||||
|
||||
<!-- DataTales Example -->
|
||||
<div class="card shadow mb-4">
|
||||
|
||||
<div class="card-header py-3">
|
||||
<h6 class="m-0 font-weight-bold text-success">Liste des annonces</h6>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="table-responsive">
|
||||
<table class="table table-bordered" id="dataTableAnnonce" width="100%" cellspacing="0">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>#</th>
|
||||
<th>Titre</th>
|
||||
<th>Prix Promo</th>
|
||||
<th>Réduction</th>
|
||||
<th>Dimension</th>
|
||||
<th>Société</th>
|
||||
<th>Activer</th>
|
||||
<th>Complet</th>
|
||||
<th>Modifier</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tfoot>
|
||||
<tr>
|
||||
<th>#</th>
|
||||
<th>Titre</th>
|
||||
<th>Prix Promo</th>
|
||||
<th>Réduction</th>
|
||||
<th>Dimension</th>
|
||||
<th>Société</th>
|
||||
<th>Activer</th>
|
||||
<th>Complet</th>
|
||||
<th>Modifier</th>
|
||||
</tr>
|
||||
</tfoot>
|
||||
<tbody>
|
||||
{% for annonce in annonces %}
|
||||
<tr>
|
||||
<td>{{ annonce.getId() }}</td>
|
||||
<td>{{ annonce.getTitre() }}</td>
|
||||
<td>{{ annonce.getPrixPromo() }}</td>
|
||||
<td>{{ annonce.getPourcentageReduction() }}%</td>
|
||||
<td>{{ annonce.Dimension() }}</td>
|
||||
<td>{{ annonce.getSociete().getNom() }}</td>
|
||||
<td>{% if annonce.isActive() and annonce.isComplet() %}
|
||||
<i class="fa-solid fa-circle-check fa-xl" style="color: #26a269;"></i>
|
||||
{% else %}
|
||||
<i class="fa-solid fa-circle-xmark fa-xl" style="color: #e01b24;"></i>
|
||||
{% endif %}
|
||||
</td>
|
||||
<td>
|
||||
{% if annonce.isComplet() %}
|
||||
<i class="fa-solid fa-thumbs-up fa-xl" style="color: #1a5fb4;"></i>
|
||||
{% else %}
|
||||
<i class="fa-solid fa-thumbs-down fa-xl" style="color: #c01c28;"></i>
|
||||
{% endif %}
|
||||
|
||||
|
||||
</td>
|
||||
<td>
|
||||
<a href="{{ path('backend_admin_annonce_update',{id:annonce.id}) }}" title="modifier" class="btn btn-info btn-action"><i class="fa fa-edit"></i></a>
|
||||
<a href="{{ path('backend_admin_annonce_uploder',{id:annonce.id}) }}" title="gestion des images" class="btn btn-warning"><i class="fa-regular fa-image"></i></a>
|
||||
|
||||
{% if annonce.isComplet() and not annonce.isActive() %}
|
||||
<a href="{{ path('backend_admin_annonce_delete',{id:annonce.id, delete: true}) }}" title="activer l'annonce" class="btn btn-success"><i class="fa-solid fa-circle-check"></i></a>
|
||||
{% elseif annonce.isComplet() and annonce.isActive() %}
|
||||
<a href="{{ path('backend_admin_annonce_delete',{id:annonce.id, delete: false}) }}" title="déactiver l'annonce" class="btn btn-danger"><i class="fa-solid fa-circle-xmark"></i></a>
|
||||
{% endif %}
|
||||
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
||||
|
||||
{% block javascripts %}
|
||||
{{ parent() }}
|
||||
{{ encore_entry_script_tags('app_backend_annonce') }}
|
||||
{% endblock %}
|
||||
306
templates/backend_admin/annonce/uploder.htm.twig
Normal file
306
templates/backend_admin/annonce/uploder.htm.twig
Normal file
@@ -0,0 +1,306 @@
|
||||
{% extends 'base_backend_admin.html.twig' %}
|
||||
|
||||
{% block title %} Annonce {% endblock %}
|
||||
|
||||
|
||||
{% block stylesheets %}
|
||||
{{ parent() }}
|
||||
{{ encore_entry_link_tags('app_backend_annonce') }}
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<!-- Page Heading -->
|
||||
<div class="d-sm-flex align-items-center justify-content-between mb-4">
|
||||
<h1 class="h3 mb-0 text-gray-800">Anonnce Images</h1>
|
||||
<ol class="breadcrumb float-sm-right">
|
||||
<li class="breadcrumb-item active">Anonnce</li>
|
||||
<li class="breadcrumb-item active">Images</li>
|
||||
</ol>
|
||||
</div>
|
||||
|
||||
<div class="row">
|
||||
|
||||
{% include 'backend_admin/basic/notice.html.twig' %}
|
||||
|
||||
<div class="card shadow mb-4" >
|
||||
<!-- Card Header - Dropdown -->
|
||||
<div class="card-header py-3 d-flex flex-row align-items-center justify-content-between">
|
||||
<h6 class="m-0 font-weight-bold text-primary">Chargement des images d'annonce pour la page d'accueil et de recherche</h6>
|
||||
</div>
|
||||
<!-- Card Body -->
|
||||
<div class="card-body">
|
||||
<table class="table" border="1" align="center">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td width="15%">
|
||||
<div class="holder">
|
||||
{% if annonce.getImageHome() %}
|
||||
<img id="img-preview-home" class="img-thumbnail" src="{{ asset('uploads/images/annonces/' ~ annonce.getImageHome()) }}" alt="pic"/>
|
||||
{% else %}
|
||||
<img id="img-preview-home" class="img-thumbnail" src="{{ asset('images/backend/img/h.png') }}" alt="pic"/>
|
||||
{% endif %}
|
||||
</div>
|
||||
</td>
|
||||
<td width="75%">
|
||||
<div class="progress" >
|
||||
<div class="progress-bar" id="progress-bar-accueil" role="progressbar" style="width: 0%" aria-valuenow="60" aria-valuemin="0" aria-valuemax="100">0%</div>
|
||||
</div>
|
||||
<fieldset class="upload_dropZone text-center mb-3 p-4">
|
||||
<p>
|
||||
Image pour la page <b>d'accueil</b>
|
||||
</p>
|
||||
<p class="small my-3">
|
||||
Largeur d'image doit d'être <b>{{ annonce.getDimensionWidth() }}px</b> | Hauteur d'image doit d'être <b>240px</b><br>
|
||||
</p>
|
||||
<input id="upload_image_accueil" class="position-absolute invisible" type="file" accept="image/jpeg, image/png, image/gif, image/jpg" multiple="false"/>
|
||||
<label class="btn btn-upload mb-3" for="upload_image_accueil">
|
||||
<i class="fa-regular fa-image"></i> choisir l'image
|
||||
</label>
|
||||
</fieldset>
|
||||
</td>
|
||||
<td width="10%">
|
||||
<br>
|
||||
<button type="button" class="btn btn-primary" id="submit-image-accueil">
|
||||
<i class="fa-solid fa-cloud-arrow-up fa-lg"></i> Importer
|
||||
</button>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="15%">
|
||||
<div class="holder">
|
||||
{% if annonce.getImageSearch() %}
|
||||
<img id="img-preview-search" class="img-thumbnail" src="{{ asset('uploads/images/annonces/' ~ annonce.getImageSearch()) }}" alt="pic"/>
|
||||
{% else %}
|
||||
<img id="img-preview-search" class="img-thumbnail" src="{{ asset('images/backend/img/h.png') }}" alt="pic"/>
|
||||
{% endif %}
|
||||
</div>
|
||||
</td>
|
||||
<td width="75%">
|
||||
<div class="progress" >
|
||||
<div class="progress-bar" id="progress-bar-search" role="progressbar" style="width: 0%" aria-valuenow="60" aria-valuemin="0" aria-valuemax="100">0%</div>
|
||||
</div>
|
||||
<fieldset class="upload_dropZone text-center mb-3 p-4">
|
||||
<p>
|
||||
Image pour la page <b>de recherche</b>
|
||||
</p>
|
||||
<p class="small my-3">
|
||||
Largeur d'image doit d'être <b>438px</b> | Hauteur d'image doit d'être <b>240px</b><br>
|
||||
</p>
|
||||
<input id="upload_image_search" class="position-absolute invisible" type="file" accept="image/jpeg, image/png, image/gif, image/jpg" />
|
||||
<label class="btn btn-upload mb-3" for="upload_image_search">
|
||||
<i class="fa-regular fa-image"></i> choisir l'image
|
||||
</label>
|
||||
</fieldset>
|
||||
</td>
|
||||
<td width="10%">
|
||||
<br>
|
||||
<button type="button" class="btn btn-primary" id="submit-image-search">
|
||||
<i class="fa-solid fa-cloud-arrow-up fa-lg"></i> Importer
|
||||
</button>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="card shadow mb-4" >
|
||||
<!-- Card Header - Dropdown -->
|
||||
<div class="card-header py-3 d-flex flex-row align-items-center justify-content-between">
|
||||
<h6 class="m-0 font-weight-bold text-primary">Chargement des images d'annonce pour la page détail</h6>
|
||||
</div>
|
||||
<!-- Card Body -->
|
||||
<div class="card-body">
|
||||
<table class="table" border="1" align="center">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td width="15%">
|
||||
<div class="holder">
|
||||
{% if annonce.getImageDetail1() %}
|
||||
<img id="img-preview-detail1" class="img-thumbnail" src="{{ asset('uploads/images/annonces/' ~ annonce.getImageDetail1()) }}" alt="pic"/>
|
||||
{% else %}
|
||||
<img id="img-preview-detail1" class="img-thumbnail" src="{{ asset('images/backend/img/h.png') }}" alt="pic"/>
|
||||
{% endif %}
|
||||
</div>
|
||||
</td>
|
||||
<td width="75%">
|
||||
<div class="progress" >
|
||||
<div class="progress-bar" id="progress-bar-detail1" role="progressbar" style="width: 0%" aria-valuenow="60" aria-valuemin="0" aria-valuemax="100">0%</div>
|
||||
</div>
|
||||
<fieldset class="upload_dropZone text-center mb-3 p-4">
|
||||
<p>
|
||||
Image 1 pour la page <b>détail</b>
|
||||
</p>
|
||||
<p class="small my-3">
|
||||
Taille maximum de l'image 2Mo<br>
|
||||
</p>
|
||||
<input id="upload_image_detail1" class="position-absolute invisible" type="file" accept="image/jpeg, image/png, image/gif, image/jpg" />
|
||||
<label class="btn btn-upload mb-3" for="upload_image_detail1">
|
||||
<i class="fa-regular fa-image"></i> choisir l'image
|
||||
</label>
|
||||
</fieldset>
|
||||
</td>
|
||||
<td width="10%">
|
||||
<br>
|
||||
<button type="button" class="btn btn-primary" id="submit-image-detail1">
|
||||
<i class="fa-solid fa-cloud-arrow-up fa-lg"></i> Importer
|
||||
</button>
|
||||
{#<button type="button" class="btn btn-warning"><i class="fa-solid fa-pen-to-square"></i> Editer </button><button type="button" class="btn btn-success"><i class="fa-solid fa-magnifying-glass"></i> Afficher</button><button type="button" class="btn btn-danger"><i class="fa-solid fa-trash"></i> Supprimer/button>#}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="15%">
|
||||
<div class="holder">
|
||||
{% if annonce.getImageDetail2() %}
|
||||
<img id="img-preview-detail2" class="img-thumbnail" src="{{ asset('uploads/images/annonces/' ~ annonce.getImageDetail2()) }}" alt="pic"/>
|
||||
{% else %}
|
||||
<img id="img-preview-detail2" class="img-thumbnail" src="{{ asset('images/backend/img/h.png') }}" alt="pic"/>
|
||||
{% endif %}
|
||||
</div>
|
||||
</td>
|
||||
<td width="75%">
|
||||
<div class="progress" >
|
||||
<div class="progress-bar" id="progress-bar-detail2" role="progressbar" style="width: 0%" aria-valuenow="60" aria-valuemin="0" aria-valuemax="100">0%</div>
|
||||
</div>
|
||||
<fieldset class="upload_dropZone text-center mb-3 p-4">
|
||||
<p>
|
||||
Image 2 pour la page <b>détail</b>
|
||||
</p>
|
||||
<p class="small my-3">
|
||||
Taille maximum de l'image 2Mo<br>
|
||||
</p>
|
||||
<input id="upload_image_detail2" class="position-absolute invisible" type="file" accept="image/jpeg, image/png, image/gif, image/jpg" />
|
||||
<label class="btn btn-upload mb-3" for="upload_image_detail2">
|
||||
<i class="fa-regular fa-image"></i> choisir l'image
|
||||
</label>
|
||||
</fieldset>
|
||||
</td>
|
||||
<td width="10%">
|
||||
<br>
|
||||
<button type="button" class="btn btn-primary" id="submit-image-detail2">
|
||||
<i class="fa-solid fa-cloud-arrow-up fa-lg"></i> Importer
|
||||
</button>
|
||||
{#<button type="button" class="btn btn-warning"><i class="fa-solid fa-pen-to-square"></i> Editer </button><button type="button" class="btn btn-success"><i class="fa-solid fa-magnifying-glass"></i> Afficher</button><button type="button" class="btn btn-danger"><i class="fa-solid fa-trash"></i> Supprimer/button>#}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="15%">
|
||||
<div class="holder">
|
||||
{% if annonce.getImageDetail3() %}
|
||||
<img id="img-preview-detail3" class="img-thumbnail" src="{{ asset('uploads/images/annonces/' ~ annonce.getImageDetail3()) }}" alt="pic"/>
|
||||
{% else %}
|
||||
<img id="img-preview-detail3" class="img-thumbnail" src="{{ asset('images/backend/img/h.png') }}" alt="pic"/>
|
||||
{% endif %}
|
||||
</div>
|
||||
</td>
|
||||
<td width="75%">
|
||||
<div class="progress" >
|
||||
<div class="progress-bar" id="progress-bar-detail3" role="progressbar" style="width: 0%" aria-valuenow="60" aria-valuemin="0" aria-valuemax="100">0%</div>
|
||||
</div>
|
||||
<fieldset class="upload_dropZone text-center mb-3 p-4">
|
||||
<p>
|
||||
Image 3 pour la page <b>détail</b>
|
||||
</p>
|
||||
<p class="small my-3">
|
||||
Taille maximum de l'image 2Mo<br>
|
||||
</p>
|
||||
<input id="upload_image_detail3" class="position-absolute invisible" type="file" accept="image/jpeg, image/png, image/gif, image/jpg" />
|
||||
<label class="btn btn-upload mb-3" for="upload_image_detail3">
|
||||
<i class="fa-regular fa-image"></i> choisir l'image
|
||||
</label>
|
||||
</fieldset>
|
||||
</td>
|
||||
<td width="10%">
|
||||
<br>
|
||||
<button type="button" class="btn btn-primary" id="submit-image-detail3">
|
||||
<i class="fa-solid fa-cloud-arrow-up fa-lg"></i> Importer
|
||||
</button>
|
||||
{#<button type="button" class="btn btn-warning"><i class="fa-solid fa-pen-to-square"></i> Editer </button><button type="button" class="btn btn-success"><i class="fa-solid fa-magnifying-glass"></i> Afficher</button><button type="button" class="btn btn-danger"><i class="fa-solid fa-trash"></i> Supprimer/button>#}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td width="15%">
|
||||
<div class="holder">
|
||||
{% if annonce.getImageDetail4() %}
|
||||
<img id="img-preview-detail4" class="img-thumbnail" src="{{ asset('uploads/images/annonces/' ~ annonce.getImageDetail4()) }}" alt="pic"/>
|
||||
{% else %}
|
||||
<img id="img-preview-detail4" class="img-thumbnail" src="{{ asset('images/backend/img/h.png') }}" alt="pic"/>
|
||||
{% endif %}
|
||||
</div>
|
||||
</td>
|
||||
<td width="75%">
|
||||
<div class="progress" >
|
||||
<div class="progress-bar" id="progress-bar-detail4" role="progressbar" style="width: 0%" aria-valuenow="60" aria-valuemin="0" aria-valuemax="100">0%</div>
|
||||
</div>
|
||||
<fieldset class="upload_dropZone text-center mb-3 p-4">
|
||||
<p>
|
||||
Image 4 pour la page <b>détail</b>
|
||||
</p>
|
||||
<p class="small my-3">
|
||||
Taille maximum de l'image 2Mo<br>
|
||||
</p>
|
||||
<input id="upload_image_detail4" class="position-absolute invisible" type="file" accept="image/jpeg, image/png, image/gif, image/jpg" />
|
||||
<label class="btn btn-upload mb-3" for="upload_image_detail4">
|
||||
<i class="fa-regular fa-image"></i> choisir l'image
|
||||
</label>
|
||||
</fieldset>
|
||||
</td>
|
||||
<td width="10%">
|
||||
<br>
|
||||
<button type="button" class="btn btn-primary" id="submit-image-detail4">
|
||||
<i class="fa-solid fa-cloud-arrow-up fa-lg"></i> Importer
|
||||
</button>
|
||||
{#<button type="button" class="btn btn-warning"><i class="fa-solid fa-pen-to-square"></i> Editer </button><button type="button" class="btn btn-success"><i class="fa-solid fa-magnifying-glass"></i> Afficher</button><button type="button" class="btn btn-danger"><i class="fa-solid fa-trash"></i> Supprimer/button>#}
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<!-- Modal -->
|
||||
<div class="modal fade" id="cropperModal" tabindex="-1" aria-labelledby="exampleModalLabel" aria-hidden="true">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<h5 class="modal-title" id="exampleModalLabel">Modal title</h5>
|
||||
<button type="button" class="btn-close" data-bs-dismiss="modal" aria-label="Close"></button>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<img id="imgPreviewCropper" src="" data-type-img=""/>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button id="resize-image" type="button" class="btn btn-primary">Redimensionner</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
{% endblock %}
|
||||
|
||||
{% block javascripts %}
|
||||
<script>
|
||||
|
||||
var pathUplodImageAdd = "{{ path('backend_admin_annonce_uploder_add', {id: annonce.id }) }}";
|
||||
var pathUplodImageDelete = "{{ path('backend_admin_annonce_uploder_delete') }}";
|
||||
|
||||
var heightImgAccueil = 240;
|
||||
var widthImgAccueil = {{ annonce.getDimensionWidth() }};
|
||||
var largeurAnnonce = {{ annonce.getLargeur() }};
|
||||
|
||||
</script>
|
||||
|
||||
{{ parent() }}
|
||||
{{ encore_entry_script_tags('app_backend_annonce') }}
|
||||
{% endblock %}
|
||||
Reference in New Issue
Block a user