Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
84c7b31dfb | ||
| 1499347b7b | |||
| 1d39bc03d8 |
@@ -1,4 +1,13 @@
|
||||
CREATE TABLE ident_switch
|
||||
-- Patched version of SQL/postgres.initial.sql for gecka/ident-switch.
|
||||
-- Commit this into your Gitea fork at the same path, replacing the
|
||||
-- upstream file. Only two changes from upstream:
|
||||
-- 1. CREATE TABLE / CREATE INDEX -> IF NOT EXISTS
|
||||
-- 2. INSERT INTO system -> upsert via ON CONFLICT
|
||||
-- This makes the script safe to re-run against an already-migrated
|
||||
-- database, which happens on every container restart unless
|
||||
-- /var/www/html is persisted (composer re-installs "fresh" each time).
|
||||
|
||||
CREATE TABLE IF NOT EXISTS ident_switch
|
||||
(
|
||||
id
|
||||
serial
|
||||
@@ -82,8 +91,9 @@ CREATE TABLE ident_switch
|
||||
UNIQUE (user_id, label)
|
||||
);
|
||||
|
||||
CREATE INDEX IX_ident_switch_user_id ON ident_switch(user_id);
|
||||
CREATE INDEX IX_ident_switch_iid ON ident_switch(iid);
|
||||
CREATE INDEX IX_ident_switch_parent_id ON ident_switch(parent_id);
|
||||
CREATE INDEX IF NOT EXISTS IX_ident_switch_user_id ON ident_switch(user_id);
|
||||
CREATE INDEX IF NOT EXISTS IX_ident_switch_iid ON ident_switch(iid);
|
||||
CREATE INDEX IF NOT EXISTS IX_ident_switch_parent_id ON ident_switch(parent_id);
|
||||
|
||||
INSERT INTO system (name, value) VALUES ('ident_switch-version', '2026021000');
|
||||
INSERT INTO system (name, value) VALUES ('ident_switch-version', '2026021000')
|
||||
ON CONFLICT (name) DO UPDATE SET value = EXCLUDED.value;
|
||||
@@ -2,7 +2,7 @@
|
||||
* ident_switch - Account switcher UI and new mail notifications.
|
||||
*
|
||||
* Places the hidden <select> from the footer into the appropriate
|
||||
* skin location (Larry, Classic, Elastic), shows it, and registers
|
||||
* skin location (Larry, Classic, Elastic, Workbench), shows it, and registers
|
||||
* notification listeners for background mail checking.
|
||||
*
|
||||
* Copyright (C) 2016-2018 Boris Gulay
|
||||
@@ -22,7 +22,6 @@ $(function() {
|
||||
|
||||
var $sw = $wrapper.find('#plugin-ident_switch-account');
|
||||
var placed = false;
|
||||
|
||||
switch (rcmail.env.skin) {
|
||||
case 'larry':
|
||||
placed = plugin_switchIdent_addCbLarry($wrapper, $sw);
|
||||
@@ -33,6 +32,9 @@ $(function() {
|
||||
case 'elastic':
|
||||
placed = plugin_switchIdent_addCbElastic($wrapper, $sw);
|
||||
break;
|
||||
case 'workbench':
|
||||
placed = plugin_switchIdent_addCbElastic($wrapper, $sw);
|
||||
break;
|
||||
}
|
||||
|
||||
if (!placed) {
|
||||
|
||||
Reference in New Issue
Block a user