tomolimo / processmaker

GLPI plugin that provides an interface with ProcessMaker (http://www.processmaker.com/)
30 stars 11 forks source link

GLPI PM user import data missing #97

Closed momohamed770 closed 4 years ago

momohamed770 commented 4 years ago

Hi, I've some issue between GLPI and PM such as users imported through GLPI automatic actions have wrong emails in PM (ex. mohamedd@donotreply.com instead of the correct domain found in GLPI) also they aren't able to login to PM (do i need to add an LDAP authentication for them). Also if i need to get a manager approval inside a PM task (using report to field) how PM will know my organization structure?

tomolimo commented 4 years ago

Hello @momohamed770 To understand the philosophy of the plugin (below is an extract of the wiki):

  1. GLPI is the pilot (or the driver, or the master) of the processes. In current plugin version, the ProcessMaker server scheduled tasks can't be used in the processes.
  2. PM server is then a slave: the 'cases' can't evolve by themselves. Only users assigned to a PM task can run a case and make it evolve in a GLPI item.
  3. GLPI groups and users are mapped into PM groups and users
  4. To insure security and confidentiality, passwords of users mapped into PM are not known and are randomly generated by the plugin and are regularly reset. This to prevent that one person will approve something that should be approved by someone else.
  5. Notifications are managed by the task notifications in GLPI. But it is possible to use dedicated notifications that are linked to a task and an event (task add, task re-assign, and task close). Also it is possible to send spontaneous emails. To get more information about notifications and emails, see: Notifications.

And to add to these:

  1. One of the principles of the PM server integration into GLPI is that it must be hidden from the end-users. It means the end-user must not have any interaction with PM server, but only with GLPI.
  2. another principle is that no emails are sent from PM server, but all emails must be sent from GLPI see Notifications. if you need to sent dedicated specifications or spontaneous emails.

To answer your hierarchy question: you may use, like we are doing here, the managers of the groups. In a process, you may request (via a SQL query) the manager of a user, and then assign the next task to this manager.

We have developed manager validations for several processes, and these are used in my company.

Thank you Regards, Tomolimo

momohamed770 commented 4 years ago

Thanks for your answer but i'm still can't understand how i'll be able to assign the 2nd task to my direct manager, i'm able to get my direct manager from AD and insert in GLPI database and then make a query through PM SQL connection inside a workflow and store it in a variable.

The task should have the assignment administered using PM task assignment or must be assigned using GLPI only?

tomolimo commented 4 years ago

Hello @momohamed770 The task assignment in a process are managed by the process only. The manager task 'rule assignement' must be of type 'Value Based Assignment', and in a trigger you must assign a value to this @@REQUEST_VALIDATOR. Beware that the value must be the guid of the manager (guid that you can get from the table glpi_plugin_processmaker_users). to be noted that the manager in @@REQUEST_VALIDATOR must have the right to execute the task: for this it must be in the groupe that is authorized to execute this task (here in my sample, it is the 'GLPI Users' group). image

Thank you Regards, Tomolimo

momohamed770 commented 4 years ago

I've created a new variable @@PM_assign and inserted the value coming from the below query

Is it a must to create a trigger?

select pm_users_id from (select id from glpi_db.glpi_users where user_dn = (select comment from glpi_db.glpi_users where id = @@GLPI_ITEM_REQUESTER_GLPI_ID))x join (SELECT * FROM glpi_db.glpi_plugin_processmaker_users) y on x.id = y.id

[cid:image001.png@01D5948D.19BA7F90]

From: tomolimo [mailto:notifications@github.com] Sent: Wednesday, November 06, 2019 9:37 AM To: tomolimo/processmaker processmaker@noreply.github.com Cc: Osama Mohamed, Mohamed momohamed@EFG-HERMES.com; Mention mention@noreply.github.com Subject: Re: [tomolimo/processmaker] GLPI PM user import data missing (#97)

Hello @momohamed770https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fmomohamed770&data=02%7C01%7Cmomohamed%40efg-hermes.com%7C554c09a6e83245aec03c08d7628c1631%7C0d301d27a05141b8b1ac6de8b154a76e%7C0%7C0%7C637086226116302610&sdata=1EBq5nVXRKrOcseTJCwxhdYnnJSWZ8nGR1QjzO1k%2Bo8%3D&reserved=0 The task assignment in a process are managed by the process only. The manager task 'rule assignement' must be of type 'Value Based Assignment', and in a trigger you must assign a value to this @@REQUEST_VALIDATOR. Beware that the value must be the guid of the manager (guid that you can get from the table glpi_plugin_processmaker_users). to be noted that the manager in @@REQUEST_VALIDATOR must have the right to execute the task: for this it must be in the groupe that is authorized to execute this task (here in my sample, it is the 'GLPI Users' group). [image]https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fuser-images.githubusercontent.com%2F7569958%2F68277912-8b340200-0070-11ea-914e-af7d831f5c99.png&data=02%7C01%7Cmomohamed%40efg-hermes.com%7C554c09a6e83245aec03c08d7628c1631%7C0d301d27a05141b8b1ac6de8b154a76e%7C0%7C0%7C637086226116312567&sdata=ju1D67Zk41V8r0yBXKI0eKdatylJ7K%2FiIWL6F5v9NGM%3D&reserved=0

Thank you Regards, Tomolimo

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Ftomolimo%2Fprocessmaker%2Fissues%2F97%3Femail_source%3Dnotifications%26email_token%3DANRJ3AXDZE2DOK4X23TMADDQSJXZDA5CNFSM4JISUSIKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEDFSQBY%23issuecomment-550184967&data=02%7C01%7Cmomohamed%40efg-hermes.com%7C554c09a6e83245aec03c08d7628c1631%7C0d301d27a05141b8b1ac6de8b154a76e%7C0%7C0%7C637086226116312567&sdata=A00wprpc9PUHqVeP3uxYji66K5%2FDWdxP7bD6OU8B7CI%3D&reserved=0, or unsubscribehttps://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FANRJ3ASXR6MPUP77CBPZA6DQSJXZDANCNFSM4JISUSIA&data=02%7C01%7Cmomohamed%40efg-hermes.com%7C554c09a6e83245aec03c08d7628c1631%7C0d301d27a05141b8b1ac6de8b154a76e%7C0%7C0%7C637086226116322527&sdata=RUmL3cZZSnZztS%2BENa9bFsVEX6jARaLcxj%2F3RdedfkA%3D&reserved=0.


This e-mail and any attachments ("Email") is for the exclusive use of the intended recipient. Please notify the sender if you have received this Email in error and do not disclose or use the information contained within it as such information may be confidential, proprietary or legally privileged. Email transmission cannot be guaranteed to be secure, error-free or virus-free. We do not accept liability for any errors or omissions in the Email which arise as a result of electronic transmission, or for any damage caused by any virus transmitted by this Email. Unless specifically stated, this Email is not intended to constitute the provision of or the offer to provide any financial service or product. You should not rely on advice contained within this Email unless it is clear that you are being invited to. EFG-Hermes Holding SAE has its address at Building No. B129, Phase 3, Smart Village, KM 28, Cairo-Alexandria Desert Road, Egypt and has an issued capital of EGP 3,843,091,115 . المجموعة المالية هيرميس القابضة شركة مساهمة مبنى رقم ب 129 – المرحلة الثالثة – القرية الذكية – الكيلو 28 – طريق القاهرة الأسكندرية الصحراوى رأس المال المصدر: 3,843,091,115 جم

momohamed770 commented 4 years ago

OK fine i got it now how i can see the form of the 2nd step in the workflow to proceed with the task through the GLPI interface instead of logging to the PM server.

tomolimo commented 4 years ago

Cool :)

momohamed770 commented 4 years ago

how i can see the form of the 2nd step in the workflow to proceed with the task through the GLPI interface instead of logging to the PM server?

tomolimo commented 4 years ago

Did you read and apply the tutorials? https://github.com/tomolimo/processmaker/wiki/Tutorials

momohamed770 commented 4 years ago

I've found something missing in the synchronization of steps and the 2nd user now can seen the form normally, but I've something wrong when submitting the 1st form image

tomolimo commented 4 years ago

@momohamed770 did you try the tutorials?

momohamed770 commented 4 years ago

Yes I've checked it but I'm doing changes not tickets and I'm trying different flow, I've reviewed it to make sure I'm not doing anything wrong.

Thanks & Regards, Mohamed Osama Ibrahim

From: tomolimo [mailto:notifications@github.com] Sent: Wednesday, November 06, 2019 2:59 PM To: tomolimo/processmaker processmaker@noreply.github.com Cc: Osama Mohamed, Mohamed momohamed@EFG-HERMES.com; Mention mention@noreply.github.com Subject: Re: [tomolimo/processmaker] GLPI PM user import data missing (#97)

@momohamed770https://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fmomohamed770&data=02%7C01%7Cmomohamed%40efg-hermes.com%7Cf85da54a36484ccc4a3808d762b91ac0%7C0d301d27a05141b8b1ac6de8b154a76e%7C0%7C0%7C637086419468389761&sdata=dfitsNFb1YlLiLsR%2BzhWdp%2BnNTSRGaxzyd90EIjew8A%3D&reserved=0 did you try the tutorials?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Ftomolimo%2Fprocessmaker%2Fissues%2F97%3Femail_source%3Dnotifications%26email_token%3DANRJ3AXTXIP5HXMEQW6S2WLQSK5RPA5CNFSM4JISUSIKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEDGOEPQ%23issuecomment-550298174&data=02%7C01%7Cmomohamed%40efg-hermes.com%7Cf85da54a36484ccc4a3808d762b91ac0%7C0d301d27a05141b8b1ac6de8b154a76e%7C0%7C0%7C637086419468399759&sdata=sr3GzJtM45DBMntVgAr1TDqp%2FOV%2Fd0CkAOvAFHdj88U%3D&reserved=0, or unsubscribehttps://eur02.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FANRJ3AVHRSHY6FJZRAZMNWTQSK5RPANCNFSM4JISUSIA&data=02%7C01%7Cmomohamed%40efg-hermes.com%7Cf85da54a36484ccc4a3808d762b91ac0%7C0d301d27a05141b8b1ac6de8b154a76e%7C0%7C0%7C637086419468399759&sdata=viefWcq7Gw%2BAHCUel%2FLyRsOEaVdmvt%2FQPOBBXqkT1WY%3D&reserved=0.


This e-mail and any attachments ("Email") is for the exclusive use of the intended recipient. Please notify the sender if you have received this Email in error and do not disclose or use the information contained within it as such information may be confidential, proprietary or legally privileged. Email transmission cannot be guaranteed to be secure, error-free or virus-free. We do not accept liability for any errors or omissions in the Email which arise as a result of electronic transmission, or for any damage caused by any virus transmitted by this Email. Unless specifically stated, this Email is not intended to constitute the provision of or the offer to provide any financial service or product. You should not rely on advice contained within this Email unless it is clear that you are being invited to. EFG-Hermes Holding SAE has its address at Building No. B129, Phase 3, Smart Village, KM 28, Cairo-Alexandria Desert Road, Egypt and has an issued capital of EGP 3,843,091,115 . المجموعة المالية هيرميس القابضة شركة مساهمة مبنى رقم ب 129 – المرحلة الثالثة – القرية الذكية – الكيلو 28 – طريق القاهرة الأسكندرية الصحراوى رأس المال المصدر: 3,843,091,115 جم

tomolimo commented 4 years ago

But my question was did you try them (means did you follow the processes like explained in the tutorials)? And not only checked them :)

tomolimo commented 4 years ago

And anyway you are doing Changes or Tickets or Problems, it's working the same way

momohamed770 commented 4 years ago

Hi, I've did the tutorials and it is working fine, now i got back to my project which is a change management workflow. The issue know is that after i finish the 1st task which is a form should be filled by the requester after pressing submit, GLPI is trying to access the 2nd task which shouldn't be authorized for the users it should be authorized only for the managers. How i can end the 1st task without trying to access the 2nd task?

These processes is working normally when trying using PM only without GLPI.

tomolimo commented 4 years ago

Hello @momohamed770 Thank you for the feedback. To try to answer your question about next task: you may use a special group in which you set all the managers and assigned the task to the manager of the user. In this case, the 2nd task will be assigned to the manager of the user, and the end-user will not be able to re-assign the task to him/her. Regards, Tomolimo

tomolimo commented 4 years ago

I close this issue, as there is no feedback. Fell free to re-open it if you want to add something.