]> git.mxchange.org Git - friendica.git/blobdiff - database.sql
Updated main translation file after changing a couple strings
[friendica.git] / database.sql
index 13158d1eaa9cac38fe9754ab9389d7c376192978..7305e65d2b7e77abb1f848bc5136667f01990028 100644 (file)
@@ -1,6 +1,6 @@
 -- ------------------------------------------
 -- Friendica 2023.09-dev (Giant Rhubarb)
--- DB_UPDATE_VERSION 1522
+-- DB_UPDATE_VERSION 1525
 -- ------------------------------------------
 
 
@@ -1586,7 +1586,7 @@ CREATE TABLE IF NOT EXISTS `profile` (
        `profile-name` varchar(255) COMMENT 'Deprecated',
        `is-default` boolean COMMENT 'Deprecated',
        `hide-friends` boolean NOT NULL DEFAULT '0' COMMENT 'Hide friend list from viewers of this profile',
-       `name` varchar(255) NOT NULL DEFAULT '' COMMENT '',
+       `name` varchar(255) NOT NULL DEFAULT '' COMMENT 'Unused in favor of user.username',
        `pdesc` varchar(255) COMMENT 'Deprecated',
        `dob` varchar(32) NOT NULL DEFAULT '0000-00-00' COMMENT 'Day of birth',
        `address` varchar(255) NOT NULL DEFAULT '' COMMENT '',
@@ -1695,7 +1695,7 @@ CREATE TABLE IF NOT EXISTS `report` (
        `uid` mediumint unsigned COMMENT 'Reporting user',
        `reporter-id` int unsigned COMMENT 'Reporting contact',
        `cid` int unsigned NOT NULL COMMENT 'Reported contact',
-       `gsid` int unsigned NOT NULL COMMENT 'Reported contact server',
+       `gsid` int unsigned COMMENT 'Reported contact server',
        `comment` text COMMENT 'Report',
        `category-id` int unsigned NOT NULL DEFAULT 1 COMMENT 'Report category, one of Entity\Report::CATEGORY_*',
        `forward` boolean COMMENT 'Forward the report to the remote server',
@@ -1834,8 +1834,8 @@ CREATE TABLE IF NOT EXISTS `user-contact` (
        `rel` tinyint unsigned COMMENT 'The kind of the relation between the user and the contact',
        `info` mediumtext COMMENT '',
        `notify_new_posts` boolean COMMENT '',
-       `remote_self` boolean COMMENT '',
-       `fetch_further_information` tinyint unsigned COMMENT '',
+       `remote_self` tinyint unsigned COMMENT '0 => No mirroring, 1-2 => Mirror as own post, 3 => Mirror as reshare',
+       `fetch_further_information` tinyint unsigned COMMENT '0 => None, 1 => Fetch information, 3 => Fetch keywords, 2 => Fetch both',
        `ffi_keyword_denylist` text COMMENT '',
        `subhub` boolean COMMENT '',
        `hub-verify` varbinary(383) COMMENT '',
@@ -1900,6 +1900,37 @@ CREATE VIEW `application-view` AS SELECT
        FROM `application-token`
                        INNER JOIN `application` ON `application-token`.`application-id` = `application`.`id`;
 
+--
+-- VIEW circle-member-view
+--
+DROP VIEW IF EXISTS `circle-member-view`;
+CREATE VIEW `circle-member-view` AS SELECT 
+       `group_member`.`id` AS `id`,
+       `group`.`uid` AS `uid`,
+       `group_member`.`contact-id` AS `contact-id`,
+       `contact`.`uri-id` AS `contact-uri-id`,
+       `contact`.`url` AS `contact-link`,
+       `contact`.`addr` AS `contact-addr`,
+       `contact`.`name` AS `contact-name`,
+       `contact`.`nick` AS `contact-nick`,
+       `contact`.`thumb` AS `contact-avatar`,
+       `contact`.`network` AS `contact-network`,
+       `contact`.`blocked` AS `contact-blocked`,
+       `contact`.`hidden` AS `contact-hidden`,
+       `contact`.`readonly` AS `contact-readonly`,
+       `contact`.`archive` AS `contact-archive`,
+       `contact`.`pending` AS `contact-pending`,
+       `contact`.`self` AS `contact-self`,
+       `contact`.`rel` AS `contact-rel`,
+       `contact`.`contact-type` AS `contact-contact-type`,
+       `group_member`.`gid` AS `circle-id`,
+       `group`.`visible` AS `circle-visible`,
+       `group`.`deleted` AS `circle-deleted`,
+       `group`.`name` AS `circle-name`
+       FROM `group_member`
+                       INNER JOIN `contact` ON `group_member`.`contact-id` = `contact`.`id`
+                       INNER JOIN `group` ON `group_member`.`gid` = `group`.`id`;
+
 --
 -- VIEW post-user-view
 --