--- /dev/null
+<?php
+
+namespace App\Nova\Actions;
+
+use App\User;
+use Illuminate\Bus\Queueable;
+use Illuminate\Contracts\Queue\ShouldQueue;
+use Illuminate\Queue\InteractsWithQueue;
+use Illuminate\Support\Collection;
+use Laravel\Nova\Actions\Action;
+use Laravel\Nova\Fields\ActionFields;
+use Maatwebsite\Excel\Concerns\WithHeadings;
+use Maatwebsite\Excel\Concerns\WithMapping;
+use Maatwebsite\LaravelNovaExcel\Actions\DownloadExcel;
+
+class ExportUsersToExcel extends DownloadExcel implements WithMapping, WithHeadings
+{
+
+ public $name = "Exporter vers Excel";
+ public $confirmButtonText = "Télécharger";
+ public $confirmText = "Export des utilisateurs vers Excel";
+
+ /**
+ * @param User $user
+ * @return array
+ */
+ public function map($user): array
+ {
+ return [
+ $user->first_name,
+ $user->last_name,
+ $user->email,
+ $user->address_line_1,
+ $user->city,
+ $user->postal_code,
+ $user->country,
+ $user->phone,
+ (string) $user->organization
+
+
+ ];
+ }
+
+ public function headings(): array
+ {
+ return [
+ 'Prénom',
+ 'Nom',
+ 'Email',
+ 'Adresse',
+ 'Ville',
+ 'Code Postal',
+ 'Pays',
+ 'Téléphone',
+ 'Organisation'
+
+ ];
+ }
+
+}
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
- "content-hash": "a63ddd7c0e259fef66125fa383140abb",
+ "content-hash": "8f33d2bbf6bc00c0cb50b2151651b430",
"packages": [
{
"name": "algolia/algoliasearch-client-php",
},
"time": "2021-01-06T19:20:22+00:00"
},
+ {
+ "name": "laravie/serialize-queries",
+ "version": "v0.2.3",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/laravie/serialize-queries.git",
+ "reference": "0b73889e102db6708d64ff003b028b42687ceeb4"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/laravie/serialize-queries/zipball/0b73889e102db6708d64ff003b028b42687ceeb4",
+ "reference": "0b73889e102db6708d64ff003b028b42687ceeb4",
+ "shasum": ""
+ },
+ "require": {
+ "illuminate/database": "^5.8 || ^6.0 || ^7.0 || ^8.0",
+ "illuminate/queue": "^5.8 || ^6.0 || ^7.0 || ^8.0",
+ "opis/closure": "^3.4.2",
+ "php": ">=7.1"
+ },
+ "require-dev": {
+ "orchestra/testbench": "^3.8 || ^4.0 || ^5.0 || ^6.0"
+ },
+ "type": "library",
+ "extra": {
+ "branch-alias": {
+ "dev-master": "1.x-dev"
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Laravie\\SerializesQuery\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Mior Muhammad Zaki",
+ "email": "crynobone@gmail.com"
+ }
+ ],
+ "description": "Serializable Laravel Query Builder",
+ "support": {
+ "issues": "https://github.com/laravie/serialize-queries/issues",
+ "source": "https://github.com/laravie/serialize-queries/tree/v0.2.3"
+ },
+ "funding": [
+ {
+ "url": "https://paypal.me/crynobone",
+ "type": "custom"
+ },
+ {
+ "url": "https://liberapay.com/crynobone",
+ "type": "liberapay"
+ }
+ ],
+ "time": "2020-10-25T04:39:37+00:00"
+ },
{
"name": "league/commonmark",
"version": "1.5.7",
],
"time": "2020-11-27T16:17:38+00:00"
},
+ {
+ "name": "maatwebsite/laravel-nova-excel",
+ "version": "1.2.3",
+ "source": {
+ "type": "git",
+ "url": "https://github.com/Maatwebsite/Laravel-Nova-Excel.git",
+ "reference": "12a696e53be79e0f212c089abaa5f248d74eeb13"
+ },
+ "dist": {
+ "type": "zip",
+ "url": "https://api.github.com/repos/Maatwebsite/Laravel-Nova-Excel/zipball/12a696e53be79e0f212c089abaa5f248d74eeb13",
+ "reference": "12a696e53be79e0f212c089abaa5f248d74eeb13",
+ "shasum": ""
+ },
+ "require": {
+ "laravel/nova": "*",
+ "laravie/serialize-queries": "^0.2",
+ "maatwebsite/excel": "^3.1",
+ "php": ">=7.1.0"
+ },
+ "type": "library",
+ "extra": {
+ "laravel": {
+ "providers": [
+ "Maatwebsite\\LaravelNovaExcel\\LaravelNovaExcelServiceProvider"
+ ]
+ }
+ },
+ "autoload": {
+ "psr-4": {
+ "Maatwebsite\\LaravelNovaExcel\\": "src/"
+ }
+ },
+ "notification-url": "https://packagist.org/downloads/",
+ "license": [
+ "MIT"
+ ],
+ "authors": [
+ {
+ "name": "Patrick Brouwers",
+ "email": "patrick@maatwebsite.nl"
+ }
+ ],
+ "description": "Supercharged Excel exports for Laravel Nova Resources",
+ "keywords": [
+ "PHPExcel",
+ "actions",
+ "laravel",
+ "laravel-nova",
+ "nova",
+ "phpspreadsheet"
+ ],
+ "support": {
+ "issues": "https://github.com/Maatwebsite/Laravel-Nova-Excel/issues",
+ "source": "https://github.com/Maatwebsite/Laravel-Nova-Excel/tree/1.2.3"
+ },
+ "time": "2020-10-08T14:10:40+00:00"
+ },
{
"name": "maennchen/zipstream-php",
"version": "2.1.0",