2019-06-21 13:04:46 +02:00
|
|
|
<?php
|
|
|
|
|
|
|
|
include_once __DIR__.'/../../../core.php';
|
|
|
|
|
|
|
|
switch ($resource) {
|
|
|
|
case 'tipi_scadenze':
|
2019-06-21 15:50:28 +02:00
|
|
|
$query = 'SELECT nome AS id, descrizione FROM co_tipi_scadenze |where| ORDER BY nome ASC';
|
2019-06-21 13:04:46 +02:00
|
|
|
|
|
|
|
foreach ($elements as $element) {
|
|
|
|
$filter[] = 'id='.prepare($element);
|
|
|
|
}
|
|
|
|
if (!empty($search)) {
|
|
|
|
$search_fields[] = 'nome LIKE '.prepare('%'.$search.'%');
|
|
|
|
$search_fields[] = 'descrizione LIKE '.prepare('%'.$search.'%');
|
|
|
|
}
|
|
|
|
|
|
|
|
break;
|
2019-06-29 11:01:26 +02:00
|
|
|
}
|