alsmanager_lib 3.0.41 → 3.0.43
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/modules.js +14 -14
- package/package.json +1 -1
package/lib/modules.js
CHANGED
|
@@ -2773,11 +2773,11 @@ function getDevicesSelectSQLite(search_type, inv_code, dev_type, marca, dev_mode
|
|
|
2773
2773
|
query += "end as Codice ";
|
|
2774
2774
|
query += "from devices d ";
|
|
2775
2775
|
if (dev_status)
|
|
2776
|
-
query += "left join device_usage du on d.id = du.id_device"
|
|
2776
|
+
query += "left join device_usage du on d.id = du.id_device ";
|
|
2777
2777
|
if (dev_gestione)
|
|
2778
|
-
query += "left join device_gestioni dg on d.id = dg.id_device"
|
|
2778
|
+
query += "left join device_gestioni dg on d.id = dg.id_device ";
|
|
2779
2779
|
if (in_consegna)
|
|
2780
|
-
query += "left join consegna_beni cb on d.id = cb.id_bene"
|
|
2780
|
+
query += "left join consegna_beni cb on d.id = cb.id_bene ";
|
|
2781
2781
|
|
|
2782
2782
|
var where_clause = " where (d.is_removed is null or d.is_removed = 0) ";
|
|
2783
2783
|
if (inv_code || dev_type || marca || dev_model || (is_PNRR && is_PNRR > 0) || dev_status || dev_gestione || no_inv || in_consegna) {
|
|
@@ -2842,7 +2842,7 @@ function getDevicesSelectSQLite(search_type, inv_code, dev_type, marca, dev_mode
|
|
|
2842
2842
|
}
|
|
2843
2843
|
}
|
|
2844
2844
|
if (in_consegna) {
|
|
2845
|
-
|
|
2845
|
+
where_clause += " (cb.id_consegna is not null and cb.tipo_bene = 'DEVICE' and cb.stato_restituzione = 0)"
|
|
2846
2846
|
}
|
|
2847
2847
|
}
|
|
2848
2848
|
}
|
|
@@ -2864,11 +2864,11 @@ function getDevicesSelectMySQL(search_type, inv_code, dev_type, marca, dev_model
|
|
|
2864
2864
|
query += "end as Codice ";
|
|
2865
2865
|
query += "from devices d ";
|
|
2866
2866
|
if (dev_status)
|
|
2867
|
-
query += "left join device_usage du on d.id = du.id_device"
|
|
2867
|
+
query += "left join device_usage du on d.id = du.id_device ";
|
|
2868
2868
|
if (dev_gestione)
|
|
2869
|
-
query += "left join device_gestioni dg on d.id = dg.id_device"
|
|
2869
|
+
query += "left join device_gestioni dg on d.id = dg.id_device ";
|
|
2870
2870
|
if (in_consegna)
|
|
2871
|
-
query += "left join consegna_beni cb on d.id = cb.id_bene"
|
|
2871
|
+
query += "left join consegna_beni cb on d.id = cb.id_bene ";
|
|
2872
2872
|
|
|
2873
2873
|
|
|
2874
2874
|
var where_clause = " where (d.is_removed is null or d.is_removed = 0) ";
|
|
@@ -2934,7 +2934,7 @@ function getDevicesSelectMySQL(search_type, inv_code, dev_type, marca, dev_model
|
|
|
2934
2934
|
}
|
|
2935
2935
|
}
|
|
2936
2936
|
if (in_consegna) {
|
|
2937
|
-
|
|
2937
|
+
where_clause += " (cb.id_consegna is not null and cb.tipo_bene = 'DEVICE' and cb.stato_restituzione = 0)"
|
|
2938
2938
|
}
|
|
2939
2939
|
}
|
|
2940
2940
|
}
|
|
@@ -2958,11 +2958,11 @@ function getDevicesSelectMySQL2(search_type, inv_code, dev_type, marca, dev_mode
|
|
|
2958
2958
|
query += "end as Codice ";
|
|
2959
2959
|
query += "from devices d ";
|
|
2960
2960
|
if (dev_status)
|
|
2961
|
-
query += "left join device_usage du on d.id = du.id_device"
|
|
2961
|
+
query += "left join device_usage du on d.id = du.id_device ";
|
|
2962
2962
|
if (dev_gestione)
|
|
2963
|
-
query += "left join device_gestioni dg on d.id = dg.id_device"
|
|
2963
|
+
query += "left join device_gestioni dg on d.id = dg.id_device ";
|
|
2964
2964
|
if (in_consegna)
|
|
2965
|
-
query += "left join consegna_beni cb on d.id = cb.id_bene"
|
|
2965
|
+
query += "left join consegna_beni cb on d.id = cb.id_bene ";
|
|
2966
2966
|
|
|
2967
2967
|
var where_clause = " where (d.is_removed is null or d.is_removed = 0) ";
|
|
2968
2968
|
if (inv_code || dev_type || marca || dev_model || (is_PNRR && is_PNRR > 0) || dev_status || dev_gestione || no_inv || in_consegna) {
|
|
@@ -3027,7 +3027,7 @@ function getDevicesSelectMySQL2(search_type, inv_code, dev_type, marca, dev_mode
|
|
|
3027
3027
|
}
|
|
3028
3028
|
}
|
|
3029
3029
|
if (in_consegna) {
|
|
3030
|
-
|
|
3030
|
+
where_clause += " (cb.id_consegna is not null and cb.tipo_bene = 'DEVICE' and cb.stato_restituzione = 0)"
|
|
3031
3031
|
}
|
|
3032
3032
|
}
|
|
3033
3033
|
}
|
|
@@ -6823,7 +6823,7 @@ function queryConsegnaByIdSQLite(id_consegna) {
|
|
|
6823
6823
|
var query = "SELECT id, id_place, id_site, data_richiesta, data_consegna, data_rientro, ";
|
|
6824
6824
|
query += "case ";
|
|
6825
6825
|
query += "when stato_restituzione is null then 0 else stato_restituzione end as stato_restituzione";
|
|
6826
|
-
query += ", is_home, note, richiedente_adulto, richiedente_alunno, richiedente_genitore from consegne";
|
|
6826
|
+
query += ", is_home, note, richiedente_adulto, richiedente_alunno, richiedente_genitore, email_adulto, email_genitore, invia_email_sollecito from consegne";
|
|
6827
6827
|
query += " where id = " + id_consegna;
|
|
6828
6828
|
return query;
|
|
6829
6829
|
}
|
|
@@ -6832,7 +6832,7 @@ function queryConsegnaByIdMySQL(id_consegna) {
|
|
|
6832
6832
|
var query = "SELECT id, id_place, id_site, data_richiesta, data_consegna, data_rientro, ";
|
|
6833
6833
|
query += "case ";
|
|
6834
6834
|
query += "when stato_restituzione is null then 0 else stato_restituzione end as stato_restituzione";
|
|
6835
|
-
query += ", is_home, note, richiedente_adulto, richiedente_alunno, richiedente_genitore from consegne";
|
|
6835
|
+
query += ", is_home, note, richiedente_adulto, richiedente_alunno, richiedente_genitore, email_adulto, email_genitore, invia_email_sollecito from consegne";
|
|
6836
6836
|
query += " where id = :id_consegna";
|
|
6837
6837
|
return query;
|
|
6838
6838
|
}
|