Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
en:entwickler:aenderungen_in_der_datenbank_einbauen [2021/10/24 09:01] fasseen:entwickler:aenderungen_in_der_datenbank_einbauen [2021/11/15 14:24] (current) – [How is editing the XML file?] fasse
Line 37: Line 37:
  
 === How can PHP code to run? === === How can PHP code to run? ===
-In addition to the SQL commands, it is also possible to run  PHP code. This is done by calling a method of the class **ComponentUpdateSteps**. In this class you can add a new method that contains a snippet of code, for eg. loop over all organizations and execute an SQL statement for any organization. You can call this method then by calling this method as a static method in the XML file in a **step**. <code xml><step id="550">ComponentUpdate::updateStepDeleteDateRoles</step></code>+In addition to the SQL commands, it is also possible to run  PHP code. This is done by calling a method of the class [[https://www.admidio.org/dokusource/class_component_update_steps.html|ComponentUpdateSteps]]. In this class you can add a new method that contains a snippet of code, for eg. loop over all organizations and execute an SQL statement for any organization. You can call this method then by calling this method as a static method in the XML file in a **step**. <code xml><step id="550">ComponentUpdateSteps::updateStep41AddUuid</step></code>
  • en/entwickler/aenderungen_in_der_datenbank_einbauen.1635058872.txt.gz
  • Last modified: 2021/10/24 09:01
  • by fasse