feat: release SysMVC 2.0 with enhanced CSRF protection and UI improvements
Major version upgrade from 1.0.0 to 2.0.0 including copyright year updates, website URL migration to syspanel.com.br, and comprehensive CSRF token handling improvements. The Twig csrf() helper now returns a complete hidden input field instead of a raw token value, and token generation is now automatic when empty. Session initialization has been centralized in BaseController, and child controllers now properly call parent constructors. CRUD views have been modernized with flexbox layouts and consistent CSRF rendering. Documentation has been expanded with features, requirements, and project structure sections, and donation sections have been added across all pages.
This commit is contained in:
@@ -0,0 +1,93 @@
|
||||
<?php $_shouldextend[1]=1; ?>
|
||||
|
||||
<?php $this->startSection('title', 'Console CLI'); ?>
|
||||
|
||||
<?php $this->startSection('content'); ?>
|
||||
<div class="container">
|
||||
<h2>Console CLI</h2>
|
||||
<p>The SysMVC CLI console, based on Symfony Console, allows you to efficiently manage your project using command-line commands.</p>
|
||||
|
||||
<h3>Useful Commands</h3>
|
||||
<ul>
|
||||
<li><strong>php bin/console generate:app-key</strong> - Generates a new application key.</li>
|
||||
<li><strong>php bin/console app:say-hello</strong> - Hello.</li>
|
||||
</ul>
|
||||
|
||||
<h3>Extending with More Commands</h3>
|
||||
<p>The Symfony Console allows you to create and extend custom commands. Here is an example of how to create a custom command:</p>
|
||||
<pre>
|
||||
<code>
|
||||
// src/Command/SayHelloCommand.php
|
||||
namespace App\Command;
|
||||
|
||||
use Symfony\Component\Console\Command\Command;
|
||||
use Symfony\Component\Console\Input\InputInterface;
|
||||
use Symfony\Component\Console\Output\OutputInterface;
|
||||
|
||||
class SayHelloCommand extends Command
|
||||
{
|
||||
protected static $defaultName = 'app:say-hello';
|
||||
|
||||
protected function configure()
|
||||
{
|
||||
$this
|
||||
->setDescription('Says hello.')
|
||||
->setHelp('This command allows you to say hello...');
|
||||
}
|
||||
|
||||
protected function execute(InputInterface $input, OutputInterface $output)
|
||||
{
|
||||
$output->writeln('Hello from SysMVC!');
|
||||
return Command::SUCCESS;
|
||||
}
|
||||
}
|
||||
</code>
|
||||
</pre>
|
||||
|
||||
<p>To register the command, add it to the service in the <code>config/services.yaml</code> file:</p>
|
||||
<pre>
|
||||
<code>
|
||||
# config/services.yaml
|
||||
services:
|
||||
App\Command\SayHelloCommand:
|
||||
tags: ['console.command']
|
||||
</code>
|
||||
</pre>
|
||||
|
||||
<p>Now you can execute the custom command:</p>
|
||||
<pre>
|
||||
<code>
|
||||
$ php bin/console app:say-hello
|
||||
</code>
|
||||
</pre>
|
||||
|
||||
<p>For more information about available commands and how to create custom commands, check the <a href="https://symfony.com/doc/current/console.html" target="_blank">Symfony Console documentation</a>.</p>
|
||||
</div>
|
||||
|
||||
|
||||
<br><br>
|
||||
|
||||
<p>Github: <a href="https://github.com/syspanel/SysMVC.git">https://github.com/syspanel/SysMVC.git</a></p>
|
||||
|
||||
<br><br>
|
||||
|
||||
<h2 class="mt-4">Contact</h2>
|
||||
<p>If you're interested in SysMVC, get in touch:</p>
|
||||
<ul>
|
||||
<li>Email: <a href="mailto:syspanel@gmx.com">syspanel@gmx.com</a></li>
|
||||
<li>WhatsApp: <a href="https://wa.me/5535992261684" target="_blank">+55 (35) 99226-1684</a></li>
|
||||
</ul>
|
||||
|
||||
<hr class="my-5">
|
||||
|
||||
<h2 class="mt-4">🙎 Support the Project</h2>
|
||||
<p>If you find this project useful, consider supporting its development with a donation via PayPal:</p>
|
||||
<p>
|
||||
<a href="https://www.paypal.com/donate/?business=marcocosta@gmx.com¤cy_code=USD" target="_blank">
|
||||
<img src="https://www.paypalobjects.com/en_US/i/btn/btn_donate_LG.gif" alt="Donate via PayPal">
|
||||
</a>
|
||||
</p>
|
||||
</div>
|
||||
<?php $this->stopSection(); ?>
|
||||
|
||||
<?php if (isset($_shouldextend[1])) { echo $this->runChild('layout'); } ?>
|
||||
Reference in New Issue
Block a user