Bug 23396: (QA follow-up) Add atomic update

New installs before the fix won't have the table populated, this patch
adds a fix for that, including the shortcut added by bug 17178.

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
This commit is contained in:
Tomas Cohen Arazi 2019-08-02 15:53:01 -03:00 committed by Martin Renvoize
parent 484b8245af
commit 5e4e26dd0f
No known key found for this signature in database
GPG Key ID: 422B469130441A0F
1 changed files with 22 additions and 0 deletions

View File

@ -0,0 +1,22 @@
$DBversion = 'XXX';
if( CheckVersion( $DBversion ) ) {
$dbh->do(q|
INSERT IGNORE INTO keyboard_shortcuts (shortcut_name, shortcut_keys) VALUES
("insert_copyright","Alt-C"),
("insert_copyright_sound","Alt-P"),
("insert_delimiter","Ctrl-D"),
("subfield_help","Ctrl-H"),
("link_authorities","Shift-Ctrl-L"),
("delete_field","Ctrl-X"),
("delete_subfield","Shift-Ctrl-X"),
("new_line","Enter"),
("line_break","Shift-Enter"),
("next_position","Tab"),
("prev_position","Shift-Tab"),
("toggle_keyboard", "Shift-Ctrl-K")
;|);
SetVersion( $DBversion );
print "Upgrade to $DBversion done (Bug 23396 - Fix missing keyboard_shortcuts table)\n";
}