mirror of
https://github.com/devcode-it/openstamanager.git
synced 2025-02-02 17:07:01 +01:00
Merge branch 'master' of https://github.com/devcode-it/openstamanager
This commit is contained in:
commit
c5eddb8979
10
actions.php
10
actions.php
@ -349,10 +349,12 @@ HTMLBuilder\HTMLBuilder::setRecord($record);
|
||||
|
||||
if ($structure->permission == 'rw') {
|
||||
// Esecuzione delle operazioni di gruppo
|
||||
$id_records = post('id_records');
|
||||
$id_records = is_array($id_records) ? $id_records : explode(';', $id_records);
|
||||
$id_records = array_clean($id_records);
|
||||
$id_records = array_unique($id_records);
|
||||
if (!empty(post('id_records'))){
|
||||
$id_records = post('id_records');
|
||||
$id_records = is_array($id_records) ? $id_records : explode(';', $id_records);
|
||||
$id_records = array_clean($id_records);
|
||||
$id_records = array_unique($id_records);
|
||||
}
|
||||
|
||||
$bulk = $structure->filepath('bulk.php');
|
||||
$bulk = empty($bulk) ? [] : include $bulk;
|
||||
|
@ -80,7 +80,9 @@ if (!empty($query)) {
|
||||
$align = [];
|
||||
$row = isset($rows[0]) ? $rows[0] : [];
|
||||
foreach ($row as $field => $value) {
|
||||
$value = trim($value);
|
||||
if (!empty($value)){
|
||||
$value = trim($value);
|
||||
}
|
||||
|
||||
// Allineamento a destra se il valore della prima riga risulta numerica
|
||||
if (is_numeric($value) && formatter()->isStandardNumber($value)) {
|
||||
@ -119,7 +121,9 @@ if (!empty($query)) {
|
||||
$column['class'] = $align[$field];
|
||||
}
|
||||
|
||||
$value = trim($r[$field]);
|
||||
if (!empty($r[$field])){
|
||||
$value = trim($r[$field]);
|
||||
}
|
||||
|
||||
// Formattazione HTML
|
||||
if (empty($total['html_format'][$pos]) && !empty($value)) {
|
||||
|
@ -15,7 +15,7 @@
|
||||
}],
|
||||
"type": "project",
|
||||
"require": {
|
||||
"php": ">=7.2",
|
||||
"php": "^7.3|^8.0",
|
||||
"ext-curl": "*",
|
||||
"ext-dom": "*",
|
||||
"ext-fileinfo": "*",
|
||||
@ -34,9 +34,9 @@
|
||||
"dragonmantank/cron-expression": "^1.0",
|
||||
"ezyang/htmlpurifier": "^4.8",
|
||||
"filp/whoops": "^2.1",
|
||||
"guzzlehttp/guzzle": "^6.3",
|
||||
"guzzlehttp/guzzle": "^7.0.1",
|
||||
"ifsnop/mysqldump-php": "^2.3",
|
||||
"illuminate/database": "^6.0",
|
||||
"illuminate/database": "^8.0",
|
||||
"intervention/image": "^2.3",
|
||||
"league/csv": "9.5.0",
|
||||
"league/oauth2-client": "^2.6",
|
||||
@ -63,7 +63,7 @@
|
||||
"wdog/sdd_ita": "dev-master"
|
||||
},
|
||||
"require-dev": {
|
||||
"codeception/codeception": "^3.0",
|
||||
"codeception/codeception": "^4.0",
|
||||
"friendsofphp/php-cs-fixer": "^2.10"
|
||||
},
|
||||
"autoload": {
|
||||
@ -137,10 +137,11 @@
|
||||
"sort-packages": true,
|
||||
"optimize-autoloader": false,
|
||||
"apcu-autoloader": true,
|
||||
"minimum-stability": "dev",
|
||||
"prefer-stable": true,
|
||||
"platform-check": false,
|
||||
"platform": {
|
||||
"php": "7.4"
|
||||
"php": "8.0.17"
|
||||
},
|
||||
"allow-plugins": {
|
||||
"kylekatarnls/update-helper": true
|
||||
|
@ -495,7 +495,7 @@ if (Auth::check()) {
|
||||
<aside class="control-sidebar control-sidebar-light">
|
||||
<h4 class="text-center">'.tr('Plugin disponibili').'</h4>
|
||||
<ul class="nav nav-tabs nav-pills nav-stacked">
|
||||
<li data-toggle="control-sidebar" class="active">
|
||||
<li data-toggle="control-sidebar" class="active btn-default">
|
||||
<a data-toggle="tab" href="#tab_0">
|
||||
<i class="'.$structure['icon'].'"></i> '.$structure['title'].'
|
||||
</a>
|
||||
@ -521,7 +521,7 @@ if (Auth::check()) {
|
||||
}
|
||||
|
||||
echo '
|
||||
<li data-toggle="control-sidebar">
|
||||
<li data-toggle="control-sidebar" class="btn-default" >
|
||||
<a data-toggle="tab" href="#tab_'.$plugin['id'].'" id="link-tab_'.$plugin['id'].'">
|
||||
'.$plugin['title'].'
|
||||
<span class="badge pull-right">'.($count>0 ? $count: '').'</span>
|
||||
@ -535,8 +535,8 @@ if (Auth::check()) {
|
||||
$notes = $structure->recordNotes($id_record);
|
||||
|
||||
echo '
|
||||
<li data-toggle="control-sidebar" class="bg-info">
|
||||
<a data-toggle="tab" href="#tab_note" id="link-tab_note">
|
||||
<li data-toggle="control-sidebar" class="btn-default">
|
||||
<a class="bg-info" data-toggle="tab" href="#tab_note" id="link-tab_note">
|
||||
'.tr('Note interne').'
|
||||
<span class="badge pull-right">'.($notes->count() ?: '').'</span>
|
||||
</a>
|
||||
@ -546,16 +546,16 @@ if (Auth::check()) {
|
||||
// Tab per le checklist
|
||||
if ($structure->permission != '-' && $structure->use_checklists) {
|
||||
echo '
|
||||
<li data-toggle="control-sidebar" class="bg-success">
|
||||
<a data-toggle="tab" href="#tab_checks" id="link-tab_checks">'.tr('Checklist').'</a>
|
||||
<li data-toggle="control-sidebar" class="btn-default">
|
||||
<a class="bg-info" data-toggle="tab" href="#tab_checks" id="link-tab_checks">'.tr('Checklist').'</a>
|
||||
</li>';
|
||||
}
|
||||
|
||||
// Tab per le informazioni sulle operazioni
|
||||
if (Auth::admin()) {
|
||||
echo '
|
||||
<li data-toggle="control-sidebar" class="bg-warning">
|
||||
<a data-toggle="tab" href="#tab_info" id="link-tab_info">
|
||||
<li data-toggle="control-sidebar" class="btn-default">
|
||||
<a class="bg-info" data-toggle="tab" href="#tab_info" id="link-tab_info">
|
||||
'.tr('Info').'
|
||||
</a>
|
||||
</li>';
|
||||
|
@ -386,7 +386,10 @@ class Database extends Util\Singleton
|
||||
*/
|
||||
public function prepare($parameter)
|
||||
{
|
||||
return $this->getPDO()->quote($parameter);
|
||||
if (!empty($parameter))
|
||||
return $this->getPDO()->quote($parameter);
|
||||
else
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -421,14 +421,18 @@ class Formatter
|
||||
*/
|
||||
public function formatDate($value)
|
||||
{
|
||||
$object = DateTime::createFromFormat(static::$standards['date'], $value);
|
||||
if (!empty($value)){
|
||||
$object = DateTime::createFromFormat(static::$standards['date'], $value);
|
||||
|
||||
// Fallback per la gestione dei timestamp
|
||||
$object = !is_object($object) ? DateTime::createFromFormat(static::$standards['timestamp'], $value) : $object;
|
||||
// Fallback per la gestione dei timestamp
|
||||
$object = !is_object($object) ? DateTime::createFromFormat(static::$standards['timestamp'], $value) : $object;
|
||||
|
||||
$result = is_object($object) ? $object->format($this->getDatePattern()) : false;
|
||||
$result = is_object($object) ? $object->format($this->getDatePattern()) : false;
|
||||
|
||||
return $result;
|
||||
return $result;
|
||||
}else{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -376,9 +376,15 @@ class Query
|
||||
$select[] = $view['query'].(!empty($view['name']) ? " AS '".$view['name']."'" : '');
|
||||
|
||||
if (!empty($view['visible'])) {
|
||||
$view['name'] = trim($view['name']);
|
||||
$view['search_inside'] = trim($view['search_inside']);
|
||||
$view['order_by'] = trim($view['order_by']);
|
||||
if (!empty($view['name'])){
|
||||
$view['name'] = trim($view['name']);
|
||||
}
|
||||
if (!empty($view['search_inside'])){
|
||||
$view['search_inside'] = trim($view['search_inside']);
|
||||
}
|
||||
if (!empty($view['order_by'])){
|
||||
$view['order_by'] = trim($view['order_by']);
|
||||
}
|
||||
|
||||
$fields[] = trim($view['name']);
|
||||
|
||||
|
@ -11,6 +11,7 @@ return [
|
||||
'an_tipianagrafiche',
|
||||
'an_tipianagrafiche_anagrafiche',
|
||||
'an_zone',
|
||||
'an_pagamenti_anagrafiche',
|
||||
'co_banche',
|
||||
'co_contratti',
|
||||
'co_dichiarazioni_intento',
|
||||
@ -40,6 +41,7 @@ return [
|
||||
'co_statipreventivi',
|
||||
'co_tipidocumento',
|
||||
'co_tipi_scadenze',
|
||||
'co_stampecontabili',
|
||||
'do_categorie',
|
||||
'do_documenti',
|
||||
'do_permessi',
|
||||
|
Loading…
x
Reference in New Issue
Block a user