1
0
mirror of https://github.com/devcode-it/openstamanager.git synced 2025-06-05 22:09:38 +02:00

Gestione permessi segmenti e numerazione documenti

This commit is contained in:
MatteoPistorello
2022-11-28 09:27:25 +01:00
parent 74c377a894
commit c981f650bc
45 changed files with 359 additions and 118 deletions

View File

@@ -208,3 +208,19 @@ function parseScontoCombinato($combinato)
return (1 - $result) * 100;
}
/**
* Funzione che gestisce il parsing di uno sconto combinato e la relativa trasformazione in sconto fisso.
* Esempio: (40 + 10) % = 44 %.
*
* @param $combinato
*
* @return float|int
*/
function getSegmentPredefined($id_module)
{
$id_segment = database()->selectOne('zz_segments', 'id', ['id_module' => $id_module, 'predefined' => 1])['id'];
return $id_segment;
}

View File

@@ -341,7 +341,10 @@ function redirectOperation($id_module, $id_record)
*/
function prepareToField($string)
{
return str_replace('"', '"', $string);
$string = str_replace('"', '"', $string);
$string = str_replace('"', '"', $string);
return $string;
}
/**