feat: L'Ami Fiduciaire V1.0.0 — full codebase with Story 0.1 complete
Initial commit of the L'Ami Fiduciaire SaaS platform built on Laravel 12, Vue 3, Inertia.js 2, and Tailwind CSS 4. Story 0.1 (rename folders to declarations in database) is implemented and code-reviewed: migration, rollback, and 6 Pest tests all passing. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
52
app/Mail/FolderConfirmationMail.php
Normal file
52
app/Mail/FolderConfirmationMail.php
Normal file
@@ -0,0 +1,52 @@
|
||||
<?php
|
||||
|
||||
namespace App\Mail;
|
||||
|
||||
use App\Models\Folder;
|
||||
use App\Models\FolderInvitation;
|
||||
use Illuminate\Bus\Queueable;
|
||||
use Illuminate\Mail\Mailable;
|
||||
use Illuminate\Mail\Mailables\Content;
|
||||
use Illuminate\Mail\Mailables\Envelope;
|
||||
use Illuminate\Queue\SerializesModels;
|
||||
|
||||
class FolderConfirmationMail extends Mailable
|
||||
{
|
||||
use Queueable, SerializesModels;
|
||||
|
||||
/**
|
||||
* Create a new message instance.
|
||||
*/
|
||||
public function __construct(
|
||||
public Folder $folder,
|
||||
public FolderInvitation $invitation,
|
||||
public string $body
|
||||
) {}
|
||||
|
||||
/**
|
||||
* Get the message envelope.
|
||||
*/
|
||||
public function envelope(): Envelope
|
||||
{
|
||||
return new Envelope(
|
||||
subject: 'Demande de validation - '.$this->folder->title,
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the message content definition.
|
||||
*/
|
||||
public function content(): Content
|
||||
{
|
||||
return new Content(
|
||||
markdown: 'emails.folder-confirmation',
|
||||
with: [
|
||||
'folderTitle' => $this->folder->title,
|
||||
'body' => $this->body,
|
||||
'confirmUrl' => route('client.confirm', ['token' => $this->invitation->token]),
|
||||
'refuseUrl' => route('client.refuse', ['token' => $this->invitation->token]),
|
||||
'expiresAt' => $this->invitation->expires_at->format('d/m/Y à H:i'),
|
||||
]
|
||||
);
|
||||
}
|
||||
}
|
||||
51
app/Mail/FolderFileRequestMail.php
Normal file
51
app/Mail/FolderFileRequestMail.php
Normal file
@@ -0,0 +1,51 @@
|
||||
<?php
|
||||
|
||||
namespace App\Mail;
|
||||
|
||||
use App\Models\Folder;
|
||||
use App\Models\FolderInvitation;
|
||||
use Illuminate\Bus\Queueable;
|
||||
use Illuminate\Mail\Mailable;
|
||||
use Illuminate\Mail\Mailables\Content;
|
||||
use Illuminate\Mail\Mailables\Envelope;
|
||||
use Illuminate\Queue\SerializesModels;
|
||||
|
||||
class FolderFileRequestMail extends Mailable
|
||||
{
|
||||
use Queueable, SerializesModels;
|
||||
|
||||
/**
|
||||
* Create a new message instance.
|
||||
*/
|
||||
public function __construct(
|
||||
public Folder $folder,
|
||||
public FolderInvitation $invitation,
|
||||
public string $body
|
||||
) {}
|
||||
|
||||
/**
|
||||
* Get the message envelope.
|
||||
*/
|
||||
public function envelope(): Envelope
|
||||
{
|
||||
return new Envelope(
|
||||
subject: 'Documents complémentaires demandés - '.$this->folder->title,
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the message content definition.
|
||||
*/
|
||||
public function content(): Content
|
||||
{
|
||||
return new Content(
|
||||
markdown: 'emails.folder-file-request',
|
||||
with: [
|
||||
'folderTitle' => $this->folder->title,
|
||||
'body' => $this->body,
|
||||
'uploadUrl' => route('client.upload', ['token' => $this->invitation->token]),
|
||||
'expiresAt' => $this->invitation->expires_at->format('d/m/Y à H:i'),
|
||||
]
|
||||
);
|
||||
}
|
||||
}
|
||||
49
app/Mail/FolderInviteMail.php
Normal file
49
app/Mail/FolderInviteMail.php
Normal file
@@ -0,0 +1,49 @@
|
||||
<?php
|
||||
|
||||
namespace App\Mail;
|
||||
|
||||
use App\Models\Folder;
|
||||
use App\Models\FolderInvitation;
|
||||
use Illuminate\Bus\Queueable;
|
||||
use Illuminate\Mail\Mailable;
|
||||
use Illuminate\Mail\Mailables\Content;
|
||||
use Illuminate\Mail\Mailables\Envelope;
|
||||
use Illuminate\Queue\SerializesModels;
|
||||
|
||||
class FolderInviteMail extends Mailable
|
||||
{
|
||||
use Queueable, SerializesModels;
|
||||
|
||||
/**
|
||||
* Create a new message instance.
|
||||
*/
|
||||
public function __construct(
|
||||
public Folder $folder,
|
||||
public FolderInvitation $invitation
|
||||
) {}
|
||||
|
||||
/**
|
||||
* Get the message envelope.
|
||||
*/
|
||||
public function envelope(): Envelope
|
||||
{
|
||||
return new Envelope(
|
||||
subject: 'Dépôt de documents - '.$this->folder->title,
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the message content definition.
|
||||
*/
|
||||
public function content(): Content
|
||||
{
|
||||
return new Content(
|
||||
markdown: 'emails.folder-invite',
|
||||
with: [
|
||||
'folderTitle' => $this->folder->title,
|
||||
'uploadUrl' => route('client.upload', ['token' => $this->invitation->token]),
|
||||
'expiresAt' => $this->invitation->expires_at->format('d/m/Y à H:i'),
|
||||
]
|
||||
);
|
||||
}
|
||||
}
|
||||
51
app/Mail/FolderSituationMail.php
Normal file
51
app/Mail/FolderSituationMail.php
Normal file
@@ -0,0 +1,51 @@
|
||||
<?php
|
||||
|
||||
namespace App\Mail;
|
||||
|
||||
use App\Models\Folder;
|
||||
use App\Models\FolderInvitation;
|
||||
use Illuminate\Bus\Queueable;
|
||||
use Illuminate\Mail\Mailable;
|
||||
use Illuminate\Mail\Mailables\Content;
|
||||
use Illuminate\Mail\Mailables\Envelope;
|
||||
use Illuminate\Queue\SerializesModels;
|
||||
|
||||
class FolderSituationMail extends Mailable
|
||||
{
|
||||
use Queueable, SerializesModels;
|
||||
|
||||
/**
|
||||
* Create a new message instance.
|
||||
*/
|
||||
public function __construct(
|
||||
public Folder $folder,
|
||||
public FolderInvitation $invitation,
|
||||
public string $body
|
||||
) {}
|
||||
|
||||
/**
|
||||
* Get the message envelope.
|
||||
*/
|
||||
public function envelope(): Envelope
|
||||
{
|
||||
return new Envelope(
|
||||
subject: 'Situation mise à jour - '.$this->folder->title,
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the message content definition.
|
||||
*/
|
||||
public function content(): Content
|
||||
{
|
||||
return new Content(
|
||||
markdown: 'emails.folder-situation',
|
||||
with: [
|
||||
'folderTitle' => $this->folder->title,
|
||||
'body' => $this->body,
|
||||
'uploadUrl' => route('client.upload', ['token' => $this->invitation->token]),
|
||||
'expiresAt' => $this->invitation->expires_at->format('d/m/Y à H:i'),
|
||||
]
|
||||
);
|
||||
}
|
||||
}
|
||||
55
app/Mail/FolderTextMessageMail.php
Normal file
55
app/Mail/FolderTextMessageMail.php
Normal file
@@ -0,0 +1,55 @@
|
||||
<?php
|
||||
|
||||
namespace App\Mail;
|
||||
|
||||
use App\Models\Folder;
|
||||
use Illuminate\Bus\Queueable;
|
||||
use Illuminate\Mail\Mailable;
|
||||
use Illuminate\Mail\Mailables\Content;
|
||||
use Illuminate\Mail\Mailables\Envelope;
|
||||
use Illuminate\Queue\SerializesModels;
|
||||
|
||||
class FolderTextMessageMail extends Mailable
|
||||
{
|
||||
use Queueable, SerializesModels;
|
||||
|
||||
/**
|
||||
* Create a new message instance.
|
||||
*
|
||||
* @param string|null $token When set, recipient is client (use token-based URL). When null, recipient is comptable (use folders.show).
|
||||
*/
|
||||
public function __construct(
|
||||
public Folder $folder,
|
||||
public string $body,
|
||||
public ?string $token = null
|
||||
) {}
|
||||
|
||||
/**
|
||||
* Get the message envelope.
|
||||
*/
|
||||
public function envelope(): Envelope
|
||||
{
|
||||
return new Envelope(
|
||||
subject: 'Nouveau message - '.$this->folder->title,
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the message content definition.
|
||||
*/
|
||||
public function content(): Content
|
||||
{
|
||||
$messagesUrl = $this->token
|
||||
? route('client.upload', ['token' => $this->token])
|
||||
: route('folders.show', ['folder' => $this->folder]).'?tab=messages';
|
||||
|
||||
return new Content(
|
||||
markdown: 'emails.folder-text-message',
|
||||
with: [
|
||||
'folderTitle' => $this->folder->title,
|
||||
'body' => $this->body,
|
||||
'messagesUrl' => $messagesUrl,
|
||||
]
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user