mirror of
https://github.com/qelectrotech/qelectrotech-source-mirror.git
synced 2026-09-28 04:54:13 +02:00
8e2a29deaf
ConductorCreator inserts a conductor and only afterwards calls refreshText(), which resolves the auto-numbering formula into properties.text. The project database inserted its row while text was still the raw formula, and refreshText() writes the resolved text without emitting propertiesChange -- the signal the database listens for -- so nothing corrects the row. Measured: with a conductor auto-numbering "W%sequ_1" selected, two wired conductors read W1 and W2 on the live objects and in the saved file, but "W%sequ_1" and "W%sequ_1" in conductor.text and in wiring_list_view.wire_number. A full updateDB() corrects it, so the data was right and only the cache was stale. Anything that reads the database between creating a conductor and the next rebuild -- the wiring list, a BOM export, a custom query -- sees the formula, not the number. Update the row after refreshText(). The row change deliberately emits no dataBaseUpdated(), as updateConductor() already documents, so this adds no model re-queries. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>