Skip to content

Commit c6cd509

Browse files
committed
To be compliant with GLPI 10.0
Set version to 5.0.0
1 parent eeed2b0 commit c6cd509

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

64 files changed

+328
-381
lines changed

README.md

+2
Original file line numberDiff line numberDiff line change
@@ -14,5 +14,7 @@ version 4.3.x is compatible with GLPI 9.5 and needs ProcessMaker 3.3.0-RE-1.13 (
1414

1515
version 4.4.x is compatible with GLPI 9.5 and needs ProcessMaker 3.3.0-RE-2.0 (https://github.com/tomolimo/processmaker-server/releases/latest)
1616

17+
version 5.0.x is compatible with GLPI 10.0 and needs ProcessMaker 3.3.0-RE-2.0 (https://github.com/tomolimo/processmaker-server/releases/latest)
18+
1719
This plugin can run classic (ProcessMaker server v2) and BPMN (ProcessMaker server v3 and later) processes
1820

ajax/asynchronousdatas.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------

ajax/dropdownProcesses.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------

ajax/dropdownTaskcategories.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------

ajax/dropdownTicketCategories.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------

ajax/dropdownUsers.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------

ajax/selfservicedrafts.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------

ajax/task_users.php

+34-31
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------
@@ -97,7 +97,7 @@
9797
]);
9898

9999
// there is only one row
100-
$taskCat = $res->next();
100+
$taskCat = $res->current();
101101
$ask_for_reason = PluginProcessmakerTaskCategory::inheritedReAssignReason($taskCat['pm_is_reassignreason_mandatory'], $taskCat['gppp_is_reassignreason_mandatory']);
102102

103103
PluginProcessmakerUser::dropdown( ['name' => 'users_id_recipient',
@@ -121,43 +121,47 @@
121121
// Dialog helpers
122122
// Create the dialog with \"Re-assign\" button
123123
function showCommentDlg(title, content, alttext) {
124-
125-
var dlgContents = {
126-
title: title,
127-
modal: true,
128-
width: 'auto',
129-
height: 'auto',
130-
resizable: false,
131-
close: function (event, ui) {
132-
$(this).dialog('destroy').remove();
133-
},
134-
buttons: [{
135-
text: alttext,
136-
id: 'submit$rand',
137-
disabled: 'disabled',
138-
click: function() {
139-
$('#comment$rand').val($('#commenttxtarea$rand').val());
140-
$('#reassign$rand').click();
141-
$('#submit$rand').button('disable');
142-
}
143-
}],
144-
show: true,
145-
hide: true
124+
modalId = title.replaceAll(' ', '_')
125+
var modal = $('#'+title);
126+
if (modal && modal.length == 0) {
127+
var modal = '<div class=\"modal fade testmodalprocess\" id=\"'+ modalId +'\" tabindex=\"-1\" role=\"dialog\" aria-labelledby=\"exampleModalCenterTitle\" aria-hidden=\"true\">'
128+
+ '<div class=\"modal-dialog modal-dialog-centered\"role=\"document\">'
129+
+ '<div class=\"modal-content\">'
130+
+ '<div class=\"modal-header\">'
131+
+ '<h5 class=\"modal-modalId\" id=\"changeChoiceTitle\">'+ title +'</h5>'
132+
+ '<button type=\"button\" class=\"btn-close\" data-bs-dismiss=\"modal\" aria-label=\"Close\"></button>'
133+
+ '</div >'
134+
+ '<div class=\"modal-body\">'
135+
+ '</div>'
136+
+ '<div class=\"modal-footer\">'
137+
+ '<button type=\"button\" class=\"btn btn-primary\" id=\"submit$rand\" disabled>'+alttext+'</button>'
138+
+ '</div>'
139+
+ '</div>'
140+
+ '</div>';
141+
$('body').append(modal);
146142
}
147-
$('<div id=divreassign$rand></div>').appendTo($('#processmaker_form_task$rand-".$_REQUEST['delIndex']."'));
148-
var locDlg = $('#divreassign$rand').html(content + '<p><textarea id=commenttxtarea$rand rows=6 cols=60></textarea></p><font color=red>".addslashes(__('Input at least 10 words to justify.','processmaker'))."</font>').dialog(dlgContents);
143+
$('#'+modalId).modal('show');
144+
$('#'+modalId+' .modal-body').append('<label for=\"message-text\" class=\"col-form-label\">'+content+'</label><textarea class=\"form-control\" id=\"commenttxtarea$rand\" style=\"height: 100px\"></textarea></p><font color=red>".addslashes(__('Input at least 10 words to justify.','processmaker'))."</font>');
149145
$('#commenttxtarea$rand').focus();
150146
$('#commenttxtarea$rand').on('keydown keyup', function(e) {
151147
if ($('#commenttxtarea$rand').val().split(/\W+/).length > 10) {
152-
$('#submit$rand').button('enable');
148+
$('#submit$rand').prop('disabled', false);
153149
} else {
154-
$('#submit$rand').button('disable');
150+
$('#submit$rand').prop('disabled', true);
155151
}
156152
});
157-
158-
return locDlg;
153+
$('#'+modalId).on('hide.bs.modal', function () {
154+
$('#'+modalId).remove();
155+
})
156+
$('#submit$rand').click(() => {
157+
$('#comment$rand').val($('#commenttxtarea$rand').val());
158+
$('#reassign$rand').click();
159+
$('#submit$rand').button('disable');
160+
$('#'+modalId).modal('hide').remove();
161+
});
159162
};
160163
164+
161165
$('input[name=reassign$rand]').click(function (e) {
162166
//debugger;
163167
let post = true;
@@ -176,7 +180,6 @@ function showCommentDlg(title, content, alttext) {
176180
// un-claim
177181
if (".($can_unclaim ? 1 : 0)." && users_id_val != 0) {
178182
if (" . ($ask_for_reason ? 1 : 0) . ") {
179-
//e.preventDefault();
180183
showCommentDlg('".addslashes(__('Un-claim task', 'processmaker'))."',
181184
'".addslashes(__('Please input reason to un-claim<br/>(task will be re-assigned to former group):', 'processmaker'))."',
182185
'".addslashes(__('Un-claim', 'processmaker'))."');

css/task.css

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/*
22
-------------------------------------------------------------------------
33
ProcessMaker plugin for GLPI
4-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
4+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
55
66
https://www.araymond.com/
77
-------------------------------------------------------------------------
@@ -34,10 +34,13 @@ span.pm_task, a.pm_task {
3434

3535
a.pm_task_badge {
3636
background-color: #4185F4 !important;
37+
display: flex;
3738
}
3839

3940
span.pm_task_case {
4041
background-color: red !important;
4142
padding-right: 8px;
4243
margin-left: 8px;
44+
flex: none;
45+
align-self: flex-start;
4346
}

front/case.form.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------

front/case.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------

front/caselink.form.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------

front/caselink.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------

front/crontaskaction.form.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------

front/crontaskaction.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------

front/document.send.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------

front/process.form.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------

front/process.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------

front/process_profile.form.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------

front/processmaker.form.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
/*
33
-------------------------------------------------------------------------
44
ProcessMaker plugin for GLPI
5-
Copyright (C) 2014-2022 by Raynet SAS a company of A.Raymond Network.
5+
Copyright (C) 2014-2023 by Raynet SAS a company of A.Raymond Network.
66
77
https://www.araymond.com/
88
-------------------------------------------------------------------------

0 commit comments

Comments
 (0)