Correzione del bug #3

Risoluzione completa del bug #3, causato da alcuni problemi con l'inputmask inizializzata con valori negativi.
This commit is contained in:
Thomas Zilio 2017-08-12 11:41:16 +02:00
parent 0d470170d6
commit c25aff729f
6 changed files with 10 additions and 7 deletions

3
.sami
View File

@ -1,6 +1,7 @@
<?php
use Sami\Sami;
use Sami\Parser\Filter\TrueFilter;
use Symfony\Component\Finder\Finder;
$finder = Finder::create()
@ -22,7 +23,7 @@ $sami = new Sami($finder, [
]);
$sami['filter'] = function () {
return new Sami\Parser\Filter\TrueFilter();
return new TrueFilter();
};
return $sami;

View File

@ -121,7 +121,7 @@ Per poter contribuire, si consiglia di seguire le indicazioni descritte all'inte
## Sviluppatori
- **Fabio Lovato**, il fondatore ([loviuz](https://github.com/loviuz))
- **Fabio Piovan** ([magreba](https://sourceforge.net/u/magreba/profile/))
- **Fabio Piovan** ([fpsoftware](https://github.com/fpsoftware))
- **Luca Salvà** ([lucasalva87](https://github.com/lucasalva87))
- **Matteo Baccarin**
- **Thomas Zilio** ([Dasc3er](https://github.com/Dasc3er))

View File

@ -15,6 +15,8 @@ github:
title: OpenSTAManager
subTitle: Il gestionale open source per l'assistenza tecnica e la fatturazione
fontAwesomeIcon: fa fa-cog
footerText: 'Progettato e sviluppato da DevCode.'
##googleAnalyticsCode: GOOGLE-ANALYTICS-CODE
scripts:
after:

View File

@ -47,7 +47,7 @@ L'insieme di cambiamenti introdotti nel periodo compreso tra giugno 2016 e giugn
## Sviluppatori
- **Fabio Lovato**, il fondatore ([loviuz](https://github.com/loviuz))
- **Fabio Piovan** ([magreba](https://sourceforge.net/u/magreba/profile/))
- **Fabio Piovan** ([fpsoftware](https://github.com/fpsoftware))
- **Luca Salvà** ([lucasalva87](https://github.com/lucasalva87))
- **Matteo Baccarin**
- **Thomas Zilio** ([Dasc3er](https://github.com/Dasc3er))

View File

@ -943,9 +943,9 @@ function start_inputmask() {
var $this = $(this);
$this.inputmask("decimal", {
min: $this.attr('min-value') ? $this.attr('min-value') : undefined,
allowMinus: $this.attr('min-value') >= 0 ? true : false,
allowMinus: !$this.attr('min-value') || $this.attr('min-value') < 0 ? true : false,
digits: $this.attr('decimals') ? $this.attr('decimals') : globals.cifre_decimali,
digitsOptional: false,
digitsOptional: true, // Necessario per un problema di inputmask con i numeri negativi durante l'init
enforceDigitsOnBlur: true,
rightAlign: true,
autoGroup: true,
@ -1151,7 +1151,7 @@ String.prototype.toLocale = function () {
if (globals.thousands) {
x[0] = x[0].split("").reverse().join("");
x[0] = x[0].replace(/(.{3})/g,"$1" + globals.thousands);
x[0] = x[0].replace(/(.{3})/g, "$1" + globals.thousands);
x[0] = x[0].split("").reverse().join("");
}

View File

@ -6,7 +6,7 @@ switch (post('op')) {
case 'update':
// Calcolo il totale da pagare
$rs = $dbo->fetchArray('SELECT SUM(da_pagare) AS totale_da_pagare FROM co_scadenziario GROUP BY iddocumento HAVING iddocumento=(SELECT iddocumento FROM co_scadenziario s WHERE id='.prepare($id_record).')');
$totale_da_pagare = abs($rs[0]['totale_da_pagare']);
$totale_da_pagare = $rs[0]['totale_da_pagare'];
$totale_utente = 0;