Hello,
I am new to SuperOffice scripting and unfortunately not a developer. I am hoping to get some guidance.
I want to automate the activation/deactivation of a specific checkmark in a company’s details, based on whether a company (or an employee of a company) is part of a specific project. I also want to remove the checkmark if that is no longer the case.
- Is this possible to achieve with a script in SuperOffice?
- Could you point me to the necessary functions to do so?
Thanks in advance. I tried to read the documentation myself, but that’s just beyond my skill set.
Alles Antwoorden (1)
Hi,
I am afraid that this will be a bit tricky to implement without being a developer. Basically, you would probably like something called a "webhook" (a mechanism for triggering a script when something changes in the database) for the project and/or projectmember entity. This webhook should execute a CRMScript which will query the db and find all distinct companies that are related to the project (through persons who can be project members). Then it should query all companies that have the checkmark enabled, and finally perform a delta-operation (remove checkmark from companies that should no longer have it, and add checkmark to companies that should get it).
Sverre