A
A
Alexander2019-10-01 17:40:46
1C-Bitrix
Alexander, 2019-10-01 17:40:46

How do you create tables for ORM entities in D7?

Often, during operation, the entity swells - new columns are added. How would you automate their creation? So that after each edit on dev, do not add them manually using SQL, first on dev, then on the test, and then on the battlefield, do not forget.
On some servers, I have a code update detection and this event triggers a PHP script that, for example, rebuilds styles. I would like to make additional creation of fields in it, if such appeared in entities.
How do you do it, if you do?
Comparing the results of getFields() and getMap(), and manually forming a request is somehow not beautiful and lazy.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
serginhold, 2019-10-01
@serginhold

migration handles are written. commit under git, and when uploaded by the command, they run

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question