first/last name instead ofj ust name, fix og migration instead of updating in second file sqlite issue

This commit is contained in:
2026-01-26 23:31:29 -08:00
parent ea1cb8cd29
commit 348665deb8
15 changed files with 74 additions and 94 deletions

View File

@@ -24,9 +24,10 @@
<?php
echo $this->Form->control('submitted_at');
echo $this->Form->control('client_ip');
echo $this->Form->control('name');
echo $this->Form->control('first_name');
echo $this->Form->control('last_name');
echo $this->Form->control('email');
echo $this->Form->control('subject');
echo $this->Form->control('contact_subject');
echo $this->Form->control('message');
echo $this->Form->control('confirm_email_sent', ['empty' => true]);
echo $this->Form->control('backend_email_sent', ['empty' => true]);

View File

@@ -13,9 +13,9 @@
<th><?= $this->Paginator->sort('id') ?></th>
<th><?= $this->Paginator->sort('submitted_at') ?></th>
<th><?= $this->Paginator->sort('client_ip') ?></th>
<th><?= $this->Paginator->sort('name') ?></th>
<th><?= $this->Paginator->sort('first_name') . ' ' . $this->Paginator->sort('last_name'); ?></th>
<th><?= $this->Paginator->sort('email') ?></th>
<th><?= $this->Paginator->sort('subject') ?></th>
<th><?= $this->Paginator->sort('contact_subject') ?></th>
<th><?= $this->Paginator->sort('confirm_email_sent') ?></th>
<th><?= $this->Paginator->sort('backend_email_sent') ?></th>
<th class="actions"><?= __('Actions') ?></th>
@@ -27,9 +27,9 @@
<td><?= h($contactUsFormSubmission->id) ?></td>
<td><?= h($contactUsFormSubmission->submitted_at) ?></td>
<td><?= h($contactUsFormSubmission->client_ip) ?></td>
<td><?= h($contactUsFormSubmission->name) ?></td>
<td><?= h($contactUsFormSubmission->full_name) ?></td>
<td><?= h($contactUsFormSubmission->email) ?></td>
<td><?= h($contactUsFormSubmission->subject) ?></td>
<td><?= h($contactUsFormSubmission->contact_subject) ?></td>
<td><?= h($contactUsFormSubmission->confirm_email_sent) ?></td>
<td><?= h($contactUsFormSubmission->backend_email_sent) ?></td>
<td class="actions">

View File

@@ -15,7 +15,7 @@
</aside>
<div class="column column-80">
<div class="contactUsFormSubmissions view content">
<h3><?= h($contactUsFormSubmission->name) ?></h3>
<h3><?= h($contactUsFormSubmission->email) ?></h3>
<table>
<tr>
<th><?= __('Id') ?></th>
@@ -27,7 +27,7 @@
</tr>
<tr>
<th><?= __('Name') ?></th>
<td><?= h($contactUsFormSubmission->name) ?></td>
<td><?= h($contactUsFormSubmission->full_name) ?></td>
</tr>
<tr>
<th><?= __('Email') ?></th>
@@ -35,7 +35,7 @@
</tr>
<tr>
<th><?= __('Subject') ?></th>
<td><?= h($contactUsFormSubmission->subject) ?></td>
<td><?= h($contactUsFormSubmission->contact_subject) ?></td>
</tr>
<tr>
<th><?= __('Submitted At') ?></th>

View File

@@ -5,10 +5,6 @@
*/
?>
<div class="row">
<aside class="column">
<div class="side-nav">
</div>
</aside>
<div class="column column-80">
<div class="contactUsFormSubmissions form content">
<?= $this->Form->create($contactUsFormSubmission) ?>

View File

@@ -7,10 +7,10 @@
$fields = \Cake\Core\Configure::readOrFail('ContactUs.fields');
?>
<?php
echo $this->Form->control('name');
echo $this->Form->control('first_name');
echo $this->Form->control('last_name');
echo isset($fields['email']) && $fields['email'] ? $this->Form->control('email', ['required' => true]) : '';
echo isset($fields['subject']) && $fields['subject'] ? $this->Form->control('subject', ['required' => true]) : '';
echo $this->Form->control('message');
echo isset($fields['captcha']) && $fields['captcha'] ? $this->Captcha->render(['placeholder' => __('Please solve the riddle')]) : '';
?>

View File

@@ -11,7 +11,7 @@ use Cake\Core\Configure;
<?= __d('cake_contact_us', "A contact us form submission was received at {0}", $contactUsFormSubmission->submitted_at) ?>,
</p>
<p>
<?= h($contactUsFormSubmission->name); ?>
<?= h($contactUsFormSubmission->full_name); ?>
</p>
<?php if (Configure::read('ContactUs.fields.email', false) && isset($contactUsFormSubmission->email)) : ?>
<p>
@@ -20,13 +20,13 @@ use Cake\Core\Configure;
</p>
<?php endif; ?>
<?php if (Configure::read('ContactUs.fields.subject', false) && isset($contactUsFormSubmission->subject)) : ?>
<?php if (Configure::read('ContactUs.fields.subject', false) && isset($contactUsFormSubmission->contact_subject)) : ?>
<p>
<strong><?= __d('cake_contact_us', 'Subject: ') ?></strong>
<span><?= h($contactUsFormSubmission->subject); ?></span>
<span><?= h($contactUsFormSubmission->contact_subject); ?></span>
</p>
<?php endif; ?>
<p>
<strong><?= __d('cake_contact_us', 'Message: ') ?></strong>
<?= h($contactUsFormSubmission->message); ?>
</p>
</p>