mirror of
https://github.com/devcode-it/openstamanager.git
synced 2025-02-11 09:00:42 +01:00
Merge branch 'master' of https://github.com/devcode-it/openstamanager
This commit is contained in:
commit
c02db9829a
@ -68,6 +68,7 @@ Il formato utilizzato è basato sulle linee guida di [Keep a Changelog](http://k
|
||||
- Aggiunto codice fornitore in ordini cliente
|
||||
- Aggiunta selezione periodo nelle stampe contabili
|
||||
- Aggiunta condizione di fornitura in ordini
|
||||
- Aggiunto avviso per fatture scartate
|
||||
### Modificato(Changed)
|
||||
- Miglioria per velocizzazione apertura DDT
|
||||
- Migliorie modulo Causali
|
||||
|
11
README.md
11
README.md
@ -43,7 +43,8 @@ La documentazione ufficiale è disponibile all'indirizzo <https://docs.openstama
|
||||
- [Requisiti](#requisiti)
|
||||
- [Installazione](#installazione)
|
||||
- [Versioni](#versioni)
|
||||
- [GitHub](#github)
|
||||
- [Build](#build)
|
||||
- [Strumenti di sviluppo e debug](#strumenti-di-sviluppo-e-debug)
|
||||
- [Perché software open-source](#perché-software-open-source)
|
||||
- [Community](#community)
|
||||
- [Contribuire](#contribuire)
|
||||
@ -122,7 +123,7 @@ Per vedere tutte le versioni disponibili al download, visitare la [pagina relati
|
||||
Nel caso utilizziate il programma per uso commerciale, si consiglia di scaricare le release disponibili nel sito ufficiale del progetto (<https://www.openstamanager.com>), evitando di utilizzare direttamente il codice della repository.
|
||||
Se siete inoltre interessati a supporto e assistenza professionali, li potete richiedere nella [sezione dedicata](https://www.openstamanager.com/per-le-aziende/).
|
||||
|
||||
### GitHub
|
||||
### Build
|
||||
|
||||
Nel caso si stia utilizzando la versione direttamente ottenuta dalla repository di GitHub, è necessario eseguire i seguenti comandi da linea di comando per completare le dipendenze PHP (tramite [Composer](https://getcomposer.org)) e gli assets (tramite [Yarn](https://yarnpkg.com)) del progetto.
|
||||
|
||||
@ -141,6 +142,12 @@ yarn run develop-OSM
|
||||
|
||||
Per ulteriori informazioni, visitare le sezioni [Assets](https://docs.openstamanager.com/docs/base/assets) e [Framework](https://docs.openstamanager.com/docs/base/framework) della documentazione.
|
||||
|
||||
## Strumenti di sviluppo e debug
|
||||
|
||||
Consigliamo di installare [psalm](https://github.com/vimeo/psalm) e configurarlo nel proprio IDE se supportato, in modo che vengano eseguiti ulteriori controlli automatici sul codice scritto.
|
||||
|
||||
E' già configurato su **composer** l'inclusione di [PHP-CS-Fixer](https://github.com/PHP-CS-Fixer/PHP-CS-Fixer), uno strumento che permette di formattare in modo uniforme il codice scritto. Si può configurare nel proprio IDE se supportato. Il percorso dell'eseguibile è `vendor/bin/php-cs-fixer`.
|
||||
|
||||
## Perché software open-source
|
||||
|
||||
Il progetto è un software open-source perché permette agli utilizzatori di studiarne il funzionamento ed adattarlo alle proprie esigenze; inoltre, in ambito commerciale, non obbliga l'utilizzatore ad essere legato allo stesso fornitore di assistenza.
|
||||
|
@ -43,7 +43,7 @@
|
||||
"league/oauth2-google": "^3.0",
|
||||
"maximebf/debugbar": "^1.15",
|
||||
"monolog/monolog": "^1.22",
|
||||
"mpdf/mpdf": "^v8.0.7",
|
||||
"mpdf/mpdf": "^v8.0.10",
|
||||
"mpociot/vat-calculator": "^2.3",
|
||||
"owasp/csrf-protector-php": "^1.0",
|
||||
"phpmailer/phpmailer": "^6.0",
|
||||
|
@ -402,7 +402,7 @@ function release(done) {
|
||||
|
||||
archive.pipe(output);
|
||||
|
||||
// Individuazione dei file da aggiungere
|
||||
// Individuazione dei file da aggiungere e escludere
|
||||
glob([
|
||||
'**/*',
|
||||
'!checksum.json',
|
||||
@ -417,6 +417,7 @@ function release(done) {
|
||||
'files/temp/.gitkeep',
|
||||
'!logs/**',
|
||||
'!config.inc.php',
|
||||
'!psalm.xml',
|
||||
'!update/structure.php',
|
||||
'!**/*.(lock|phar|log|zip|bak|jar|txt)',
|
||||
'!**/~*',
|
||||
|
@ -213,6 +213,7 @@ foreach ($db as $name => $values) {
|
||||
$dirs = [
|
||||
'backup' => tr('Necessario per il salvataggio dei backup'),
|
||||
'files' => tr('Necessario per il salvataggio di file inseriti dagli utenti'),
|
||||
'files/temp' => tr('Necessario per la generazione delle stampe'),
|
||||
'logs' => tr('Necessario per la gestione dei file di log'),
|
||||
];
|
||||
|
||||
|
@ -711,7 +711,7 @@ if ($is_cliente or $is_fornitore or $is_tecnico) {
|
||||
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
{[ "type": "textarea", "label": "<?php echo tr('Note'); ?>", "name": "note", "value": "$note$", "maxlength": 255, "charcounter": 1 ]}
|
||||
{[ "type": "textarea", "label": "<?php echo tr('Note'); ?>", "name": "note", "value": "$note$", "charcounter": 1 ]}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@ -830,7 +830,7 @@ if (empty($record['deleted_at'])) {
|
||||
|
||||
<script>
|
||||
$(document).ready( function() {
|
||||
$(".colorpicker").colorpicker().on("changeColor", function() {
|
||||
$(".colorpicker").colorpicker({ format: 'hex' }).on("changeColor", function() {
|
||||
$("#colore_t").parent().find(".square").css("background", $("#colore_t").val());
|
||||
});
|
||||
|
||||
|
@ -74,13 +74,13 @@ if (isset($id_record)) {
|
||||
|
||||
<script>
|
||||
$(document).ready( function() {
|
||||
$('#modals > div .colorpicker').colorpicker().on('changeColor', function() {
|
||||
$('#modals > div .colorpicker').colorpicker({ format: 'hex' }).on('changeColor', function() {
|
||||
$('#modals > div #colore_').parent().find('.square').css('background', $('#modals > div #colore_').val());
|
||||
});
|
||||
|
||||
$('#modals > div #colore_').parent().find('.square').css('background', $('#modals > div #colore_').val());
|
||||
|
||||
$('#modals > div .colorpicker').colorpicker().on('changeColor', function() {
|
||||
$('#modals > div .colorpicker').colorpicker({ format: 'hex' }).on('changeColor', function() {
|
||||
$('#modals > div #colore_').parent().find('.square').css('background', $('#modals > div #colore_').val());
|
||||
});
|
||||
|
||||
|
@ -81,7 +81,7 @@ include_once __DIR__.'/../../core.php';
|
||||
|
||||
<script>
|
||||
$(document).ready( function() {
|
||||
$('.colorpicker').colorpicker().on('changeColor', function() {
|
||||
$('.colorpicker').colorpicker({ format: 'hex' }).on('changeColor', function() {
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
});
|
||||
|
||||
|
@ -55,7 +55,7 @@ if (isset($id_record)) {
|
||||
|
||||
<script>
|
||||
$(document).ready( function() {
|
||||
$('.colorpicker').colorpicker().on('changeColor', function() {
|
||||
$('.colorpicker').colorpicker({ format: 'hex' }).on('changeColor', function() {
|
||||
$('#modals > div #colore_').parent().find('.square').css('background', $('#modals > div #colore_').val());
|
||||
});
|
||||
|
||||
|
@ -52,7 +52,7 @@ include_once __DIR__.'/../../core.php';
|
||||
|
||||
<script>
|
||||
$(document).ready( function() {
|
||||
$('.colorpicker').colorpicker().on('changeColor', function() {
|
||||
$('.colorpicker').colorpicker({ format: 'hex' }).on('changeColor', function() {
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
});
|
||||
|
||||
|
@ -24,7 +24,7 @@ $r = $dbo->fetchOne('SELECT dt_ddt.*,
|
||||
an_referenti.nome
|
||||
FROM dt_ddt
|
||||
INNER JOIN an_anagrafiche ON dt_ddt.idanagrafica = an_anagrafiche.idanagrafica
|
||||
INNER JOIN an_referenti ON an_referenti.id = dt_ddt.idreferente
|
||||
LEFT OUTER JOIN an_referenti ON an_referenti.id = dt_ddt.idreferente
|
||||
WHERE dt_ddt.id='.prepare($id_record));
|
||||
|
||||
// Variabili da sostituire
|
||||
|
56
modules/emails/src/EmailTask.php
Normal file
56
modules/emails/src/EmailTask.php
Normal file
@ -0,0 +1,56 @@
|
||||
<?php
|
||||
/*
|
||||
* OpenSTAManager: il software gestionale open source per l'assistenza tecnica e la fatturazione
|
||||
* Copyright (C) DevCode s.r.l.
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation, either version 3 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
namespace Modules\Emails;
|
||||
|
||||
use Carbon\Carbon;
|
||||
use Notifications\EmailNotification;
|
||||
use PHPMailer\PHPMailer\Exception;
|
||||
use Tasks\Manager;
|
||||
|
||||
class EmailTask extends Manager
|
||||
{
|
||||
|
||||
public function needsExecution()
|
||||
{
|
||||
$lista = database()->fetchArray("SELECT * FROM em_emails WHERE (sent_at IS NULL OR failed_at IS NOT NULL) AND attempt<".prepare(setting('Numero massimo di tentativi'))." ORDER BY created_at");
|
||||
$remaining = sizeof($lista);
|
||||
|
||||
return !empty($remaining);
|
||||
}
|
||||
|
||||
public function execute()
|
||||
{
|
||||
$lista = database()->fetchArray("SELECT * FROM em_emails WHERE (sent_at IS NULL OR failed_at IS NOT NULL) AND attempt<".prepare(setting('Numero massimo di tentativi'))." ORDER BY created_at LIMIT 0,".setting('Numero email da inviare in contemporanea per account'));
|
||||
|
||||
foreach ($lista as $mail) {
|
||||
|
||||
$mail = Mail::find($mail['id']);
|
||||
|
||||
try {
|
||||
$email = EmailNotification::build($mail);
|
||||
$email->send();
|
||||
} catch (Exception $e) {
|
||||
echo $e;
|
||||
}
|
||||
}
|
||||
|
||||
return $lista;
|
||||
}
|
||||
}
|
@ -43,7 +43,7 @@ include_once __DIR__.'/../../core.php';
|
||||
|
||||
<script>
|
||||
$(document).ready( function() {
|
||||
$('.colorpicker').colorpicker().on('changeColor', function() {
|
||||
$('.colorpicker').colorpicker({ format: 'hex' }).on('changeColor', function() {
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
});
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
|
@ -69,7 +69,7 @@ if (!empty($righe)) {
|
||||
|
||||
<script>
|
||||
$(document).ready( function() {
|
||||
$('.colorpicker').colorpicker().on('changeColor', function() {
|
||||
$('.colorpicker').colorpicker({ format: 'hex' }).on('changeColor', function() {
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
});
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
|
@ -47,7 +47,7 @@ include_once __DIR__.'/../../core.php';
|
||||
|
||||
<script>
|
||||
$(document).ready( function() {
|
||||
$('.colorpicker').colorpicker().on('changeColor', function() {
|
||||
$('.colorpicker').colorpicker({ format: 'hex' }).on('changeColor', function() {
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
});
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
|
@ -73,7 +73,7 @@ if (!empty($righe)) {
|
||||
|
||||
<script>
|
||||
$(document).ready( function() {
|
||||
$('.colorpicker').colorpicker().on('changeColor', function() {
|
||||
$('.colorpicker').colorpicker({ format: 'hex' }).on('changeColor', function() {
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
});
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
|
@ -36,12 +36,3 @@ include_once __DIR__.'/../../core.php';
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
<script>
|
||||
$(document).ready( function() {
|
||||
$('.colorpicker').colorpicker().on('changeColor', function() {
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
});
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
});
|
||||
</script>
|
||||
|
@ -61,12 +61,3 @@ if (!empty($righe)) {
|
||||
}
|
||||
?>
|
||||
|
||||
|
||||
<script>
|
||||
$(document).ready( function() {
|
||||
$('.colorpicker').colorpicker().on('changeColor', function() {
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
});
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
});
|
||||
</script>
|
||||
|
@ -47,7 +47,7 @@ include_once __DIR__.'/../../core.php';
|
||||
|
||||
<script>
|
||||
$(document).ready( function() {
|
||||
$('.colorpicker').colorpicker().on('changeColor', function() {
|
||||
$('.colorpicker').colorpicker({ format: 'hex' }).on('changeColor', function() {
|
||||
$('#modals > div #colore_').parent().find('.square').css( 'background', $('#modals > div #colore_').val() );
|
||||
});
|
||||
|
||||
|
@ -111,7 +111,7 @@ if ($record['can_delete']) {
|
||||
?>
|
||||
<script>
|
||||
$(document).ready( function() {
|
||||
$('.colorpicker').colorpicker().on('changeColor', function() {
|
||||
$('.colorpicker').colorpicker({ format: 'hex' }).on('changeColor', function() {
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
});
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
|
@ -60,7 +60,7 @@ include_once __DIR__.'/../../core.php';
|
||||
|
||||
<script>
|
||||
$(document).ready( function() {
|
||||
$('.colorpicker').colorpicker().on('changeColor', function() {
|
||||
$('.colorpicker').colorpicker({ format: 'hex' }).on('changeColor', function() {
|
||||
$('#modals > div #colore_').parent().find('.square').css( 'background', $('#modals > div #colore_').val() );
|
||||
});
|
||||
|
||||
|
@ -86,7 +86,7 @@ if (!empty($record['can_delete'])) {
|
||||
|
||||
<script>
|
||||
$(document).ready( function() {
|
||||
$('.colorpicker').colorpicker().on('changeColor', function() {
|
||||
$('.colorpicker').colorpicker({ format: 'hex' }).on('changeColor', function() {
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
});
|
||||
$('#colore').parent().find('.square').css( 'background', $('#colore').val() );
|
||||
|
@ -7,7 +7,7 @@
|
||||
"autonumeric": "^4.6.0",
|
||||
"autosize": "^3.0.21",
|
||||
"bootstrap": "^3.4.1",
|
||||
"bootstrap-colorpicker": "2.5.1",
|
||||
"bootstrap-colorpicker": "^2.5.3",
|
||||
"bootstrap-daterangepicker": "^2.1.25",
|
||||
"bootstrap-maxlength": "^1.10.1",
|
||||
"chart.js": "^3.8.0",
|
||||
|
15
psalm.xml
Normal file
15
psalm.xml
Normal file
@ -0,0 +1,15 @@
|
||||
<?xml version="1.0"?>
|
||||
<psalm
|
||||
errorLevel="7"
|
||||
resolveFromConfigFile="true"
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xmlns="https://getpsalm.org/schema/config"
|
||||
xsi:schemaLocation="https://getpsalm.org/schema/config vendor/vimeo/psalm/config.xsd"
|
||||
>
|
||||
<projectFiles>
|
||||
<directory name="src" />
|
||||
<ignoreFiles>
|
||||
<directory name="vendor" />
|
||||
</ignoreFiles>
|
||||
</projectFiles>
|
||||
</psalm>
|
@ -523,6 +523,8 @@ class Prints
|
||||
|
||||
'default_font' => 'dejavusanscondensed',
|
||||
|
||||
'tempDir' => base_dir() . '/files/temp',
|
||||
|
||||
// Abilitazione per lo standard PDF/A
|
||||
//'PDFA' => true,
|
||||
//'PDFAauto' => true,
|
||||
|
@ -71,4 +71,4 @@ INSERT INTO `co_tipidocumento` (`id`, `descrizione`, `dir`, `reversed`, `codice_
|
||||
INSERT INTO `co_tipidocumento` (`id`, `descrizione`, `dir`, `reversed`, `codice_tipo_documento_fe`) VALUES (NULL, 'Fattura per acquisti da San Marino', 'uscita', '0', 'TD28');
|
||||
|
||||
-- Fix vista Ddt in entrata
|
||||
UPDATE `zz_views` INNER JOIN `zz_modules` ON `zz_views`.`id_module` = `zz_modules`.`id` SET `zz_views`.`order_by` = 'CAST(IF(numero_esterno="", numero, numero_esterno) AS UNSIGNED)' WHERE `zz_modules`.`name` = 'Ddt di acquisto' AND `zz_views`.`name` = 'Numero'
|
||||
UPDATE `zz_views` INNER JOIN `zz_modules` ON `zz_views`.`id_module` = `zz_modules`.`id` SET `zz_views`.`order_by` = 'CAST(IF(numero_esterno="", numero, numero_esterno) AS UNSIGNED)' WHERE `zz_modules`.`name` = 'Ddt di acquisto' AND `zz_views`.`name` = 'Numero';
|
||||
|
@ -22,4 +22,7 @@ INSERT INTO `zz_views` ( `id_module`, `name`, `query`, `order`, `search`, `slow`
|
||||
UPDATE `zz_plugins` SET `title` = 'Netto clienti', `name` = 'Netto Clienti' WHERE `zz_plugins`.`name` = 'Listino Clienti';
|
||||
|
||||
ALTER TABLE `mg_articoli` ADD `minimo_vendita` DECIMAL(15,6) NOT NULL AFTER `prezzo_vendita_ivato`;
|
||||
ALTER TABLE `mg_articoli` ADD `minimo_vendita_ivato` DECIMAL(15,6) NOT NULL AFTER `minimo_vendita`;
|
||||
ALTER TABLE `mg_articoli` ADD `minimo_vendita_ivato` DECIMAL(15,6) NOT NULL AFTER `minimo_vendita`;
|
||||
|
||||
-- Aggiunto task invio mail
|
||||
INSERT INTO `zz_tasks` (`id`, `name`, `class`, `expression`, `next_execution_at`, `last_executed_at`) VALUES (NULL, 'Invio automatico mail', 'Modules\\Emails\\EmailTask', '*/1 * * * *', NULL, NULL);
|
||||
|
Loading…
x
Reference in New Issue
Block a user