mirror of
https://github.com/devcode-it/openstamanager.git
synced 2025-02-12 17:40:39 +01:00
Visualizzazione attività in Dashboard per permessi in sola lettura
Correzioni minori, fix visualizzazione attività con tecnico assegnato per Anagrafiche di tipo Tecnico (#970).
This commit is contained in:
parent
57e0b204f5
commit
47b19efe57
2
modules/dashboard/actions.php → modules/dashboard/ajax.php
Executable file → Normal file
2
modules/dashboard/actions.php → modules/dashboard/ajax.php
Executable file → Normal file
@ -126,7 +126,7 @@ switch (filter('op')) {
|
||||
(
|
||||
(co_preventivi.data_accettazione >= '.prepare($start).' AND co_preventivi.data_accettazione <= '.prepare($end).')
|
||||
OR (co_preventivi.data_conclusione >= '.prepare($start).' AND co_preventivi.data_conclusione <= '.prepare($end).')
|
||||
)
|
||||
)
|
||||
AND
|
||||
co_statipreventivi.is_pianificabile=1';
|
||||
|
@ -335,7 +335,7 @@ $modulo_interventi = Modules::get('Interventi');
|
||||
echo '
|
||||
<script type="text/javascript">
|
||||
globals.dashboard = {
|
||||
load_url: globals.rootdir + "/actions.php?id_module='.$id_module.'",
|
||||
load_url: "'.$structure->fileurl('ajax.php').'?id_module='.$id_module.'",
|
||||
style: "'.$def.'",
|
||||
show_sunday: '.intval(setting('Visualizzare la domenica sul calendario')).',
|
||||
start_time: "'.setting('Ora inizio sul calendario').'",
|
||||
@ -559,7 +559,7 @@ echo '
|
||||
select: function(start, end, allDay) { // info
|
||||
// let start = info.start;
|
||||
// let end = info.end;
|
||||
|
||||
|
||||
let is_allDay = !start.hasTime() && !end.hasTime();
|
||||
|
||||
if (is_allDay!==true){
|
||||
@ -580,7 +580,7 @@ echo '
|
||||
editable: globals.dashboard.write_permission,
|
||||
eventDrop: function(event, delta, revertFunc ) {// info
|
||||
// let event = info.event;
|
||||
|
||||
|
||||
if (event.allDay!==true){
|
||||
$.post(globals.dashboard.load_url, {
|
||||
op: "modifica_intervento",
|
||||
@ -599,7 +599,7 @@ echo '
|
||||
|
||||
if (data !=="ok"){
|
||||
revertFunc(); // info.revert();
|
||||
}
|
||||
}
|
||||
|
||||
});
|
||||
}else{
|
||||
@ -617,7 +617,7 @@ echo '
|
||||
timeEnd: moment(event.end).format("YYYY-MM-DD HH:mm")
|
||||
}, function (data, response) {
|
||||
data = $.trim(data);
|
||||
|
||||
|
||||
if (response == "success" && data !== "ok") {
|
||||
swal("'.tr('Attenzione').'", data, "warning");
|
||||
}else if (response !== "success"){
|
||||
|
@ -86,7 +86,7 @@ class Task extends Resource implements RetrieveInterface, CreateInterface
|
||||
|
||||
$endpointParts = parse_url($endpoint);
|
||||
$endpointParts['path'] = $endpointParts['path'] ?: '/';
|
||||
$endpointParts['port'] = $endpointParts['port'] ?: $endpointParts['scheme'] === 'https' ? 443 : 80;
|
||||
$endpointParts['port'] = $endpointParts['port'] ?: ($endpointParts['scheme'] === 'https' ? 443 : 80);
|
||||
|
||||
$contentLength = strlen($postData);
|
||||
|
||||
|
@ -178,6 +178,7 @@ class Response
|
||||
$messages = array_column(self::$status, 'message');
|
||||
|
||||
$array['message'] = $messages[array_search($array['status'], $codes)];
|
||||
http_response_code($array['status']);
|
||||
}
|
||||
|
||||
$flags = JSON_FORCE_OBJECT;
|
||||
|
@ -138,3 +138,5 @@ INSERT INTO `zz_api_resources` (`id`, `version`, `type`, `resource`, `class`, `e
|
||||
|
||||
-- Aggiunto collegamento tra DDT in direzioni opposte per gestione movimentazioni interne tra sedi
|
||||
ALTER TABLE `dt_ddt` ADD `id_ddt_trasporto_interno` INT(11) NULL, ADD FOREIGN KEY (`id_ddt_trasporto_interno`) REFERENCES `dt_ddt`(`id`) ON DELETE CASCADE;
|
||||
|
||||
UPDATE `zz_group_module` SET `clause` = 'in_interventi.id IN (SELECT idintervento FROM in_interventi_tecnici WHERE idintervento=in_interventi.id AND idtecnico=|id_anagrafica| UNION SELECT id_intervento FROM in_interventi_tecnici_assegnati WHERE id_intervento=in_interventi.id AND id_tecnico=|id_anagrafica|)' WHERE `zz_group_module`.`name` = 'Mostra interventi ai tecnici coinvolti';
|
||||
|
Loading…
x
Reference in New Issue
Block a user