1
0
mirror of https://github.com/haiwen/seahub.git synced 2025-09-01 07:01:12 +00:00

11.0.3 sql (#5836)

This commit is contained in:
欢乐马
2023-12-18 11:24:29 +08:00
committed by GitHub
parent 637d48cb52
commit 2fe6c6fd35
4 changed files with 12 additions and 2 deletions

View File

@@ -91,3 +91,5 @@ ALTER TABLE `org_saml_config` ADD COLUMN IF NOT EXISTS `dns_txt` varchar(64) NUL
ALTER TABLE `org_saml_config` ADD COLUMN IF NOT EXISTS `domain_verified` TINYINT(1) NOT NULL DEFAULT 0;
ALTER TABLE `org_saml_config` ADD INDEX IF NOT EXISTS `org_saml_config_domain_verified_398065b9` (`domain_verified`);
UPDATE `org_saml_config` SET domain_verified=1 WHERE domain_verified=0;
ALTER TABLE `social_auth_usersocialauth` CHANGE extra_data extra_data longtext DEFAULT NULL;

View File

@@ -38,3 +38,11 @@ CREATE INDEX IF NOT EXISTS "org_saml_config_domain_verified_398065b9" ON "org_sa
INSERT INTO "org_saml_config" ("org_id", "metadata_url", "domain") SELECT "org_id", "metadata_url", "domain" FROM "org_saml_config_old";
UPDATE `org_saml_config` SET domain_verified=1 WHERE domain_verified=0;
DROP TABLE "org_saml_config_old";
DROP TABLE IF EXISTS "social_auth_usersocialauth_old";
ALTER TABLE "social_auth_usersocialauth" RENAME TO "social_auth_usersocialauth_old";
CREATE TABLE "social_auth_usersocialauth" ("id" integer NOT NULL PRIMARY KEY AUTOINCREMENT, "username" varchar(255) NOT NULL, "provider" varchar(32) NOT NULL, "uid" varchar(255) NOT NULL, "extra_data" text NULL);
CREATE INDEX "social_auth_usersocialauth_username_3f06b5cf" ON "social_auth_usersocialauth" ("username");
CREATE UNIQUE INDEX "social_auth_usersocialauth_provider_uid_e6b5e668_uniq" ON "social_auth_usersocialauth" ("provider", "uid");
INSERT INTO "social_auth_usersocialauth" ("username", "provider", "uid", "extra_data") SELECT "username", "provider", "uid", "extra_data" FROM "social_auth_usersocialauth_old";
DROP TABLE "social_auth_usersocialauth_old";