runbot/runbot_merge/migrations/15.0.1.13/pre-migration.py
Xavier Morel 67f1c1e288 [IMP] runbot_merge: add staging duration
Computed on the fly for now. Formatted nicely in the frontend, there
does not seem to be any sort of duration widget in the backend so
just display the integer number of seconds.

Fixes #865
2024-05-30 15:11:38 +02:00

5 lines
223 B
Python

def migrate(cr, version):
cr.execute("ALTER TABLE runbot_merge_stagings "
"ADD COLUMN staging_end timestamp without time zone")
cr.execute("UPDATE runbot_merge_stagings SET staging_end = write_date")