]> git.mxchange.org Git - friendica.git/blobdiff - static/dbview.config.php
Merge pull request #10411 from annando/header-noscrape
[friendica.git] / static / dbview.config.php
index 791665f73452e955461bfb9698e61c03c0a2da55..01cda59a62c0da7b849f137faf2eaf5e8cd0878e 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 /**
- * @copyright Copyright (C) 2020, Friendica
+ * @copyright Copyright (C) 2010-2021, the Friendica project
  *
  * @license GNU AGPL version 3 or any later version
  *
  */
 
  return [
+       "application-view" => [
+               "fields" => [
+                       "id" => ["application", "id"],
+                       "uid" => ["application-token", "uid"],
+                       "name" => ["application", "name"],
+                       "redirect_uri" => ["application", "redirect_uri"],
+                       "website" => ["application", "website"],
+                       "client_id" => ["application", "client_id"],
+                       "client_secret" => ["application", "client_secret"],
+                       "code" => ["application-token", "code"],
+                       "access_token" => ["application-token", "access_token"],
+                       "created_at" => ["application-token", "created_at"],
+                       "scopes" => ["application-token", "scopes"],
+                       "read" => ["application-token", "read"],
+                       "write" => ["application-token", "write"],
+                       "follow" => ["application-token", "follow"],
+                       "push" => ["application-token", "push"],
+               ],
+               "query" => "FROM `application-token`
+                       INNER JOIN `application` ON `application-token`.`application-id` = `application`.`id`"
+       ],
        "post-user-view" => [
                "fields" => [
                        "id" => ["post-user", "id"],
@@ -60,6 +81,7 @@
                        "received" => ["post-user", "received"],
                        "changed" => ["post-thread-user", "changed"],
                        "post-type" => ["post-user", "post-type"],
+                       "post-reason" => ["post-user", "post-reason"],
                        "private" => ["post-user", "private"],
                        "pubmail" => ["post-thread-user", "pubmail"],
                        "visible" => ["post-user", "visible"],
                        "parent-author-link" => ["parent-post-author", "url"],
                        "parent-author-name" => ["parent-post-author", "name"],
                        "parent-author-network" => ["parent-post-author", "network"],
+                       "parent-author-blocked" => ["parent-post-author", "blocked"],
+                       "parent-author-hidden" => ["parent-post-author", "hidden"],
                ],
                "query" => "FROM `post-user`
                        STRAIGHT_JOIN `post-thread-user` ON `post-thread-user`.`uri-id` = `post-user`.`parent-uri-id` AND `post-thread-user`.`uid` = `post-user`.`uid`
                        "received" => ["post-thread-user", "received"],
                        "changed" => ["post-thread-user", "changed"],
                        "post-type" => ["post-user", "post-type"],
+                       "post-reason" => ["post-user", "post-reason"],
                        "private" => ["post-user", "private"],
                        "pubmail" => ["post-thread-user", "pubmail"],
                        "ignored" => ["post-thread-user", "ignored"],
                        "parent-author-link" => ["parent-post-author", "url"],
                        "parent-author-name" => ["parent-post-author", "name"],
                        "parent-author-network" => ["parent-post-author", "network"],
+                       "parent-author-blocked" => ["parent-post-author", "blocked"],
+                       "parent-author-hidden" => ["parent-post-author", "hidden"],
                ],
                "query" => "FROM `post-thread-user`
                        INNER JOIN `post-user` ON `post-user`.`id` = `post-thread-user`.`post-user-id`
                        "target-type" => ["post-content", "target-type"],
                        "target" => ["post-content", "target"],
                        "resource-id" => ["post-content", "resource-id"],
+                       "contact-id" => ["post", "author-id"],
+                       "contact-link" => ["author", "url"],
+                       "contact-addr" => ["author", "addr"],
+                       "contact-name" => ["author", "name"],
+                       "contact-nick" => ["author", "nick"],
+                       "contact-avatar" => ["author", "thumb"],
+                       "contact-network" => ["author", "network"],
+                       "contact-blocked" => ["author", "blocked"],
+                       "contact-hidden" => ["author", "hidden"],
+                       "contact-readonly" => ["author", "readonly"],
+                       "contact-archive" => ["author", "archive"],
+                       "contact-pending" => ["author", "pending"],
+                       "contact-rel" => ["author", "rel"],
+                       "contact-uid" => ["author", "uid"],
+                       "contact-contact-type" => ["author", "contact-type"],
+                       "writable" => "IF (`post`.`network` IN ('apub', 'dfrn', 'dspr', 'stat'), true, `author`.`writable`)",
+                       "self" => "false",
+                       "cid" => ["author", "id"],
+                       "alias" => ["author", "alias"],
+                       "photo" => ["author", "photo"],
+                       "name-date" => ["author", "name-date"],
+                       "uri-date" => ["author", "uri-date"],
+                       "avatar-date" => ["author", "avatar-date"],
+                       "thumb" => ["author", "thumb"],
+                       "dfrn-id" => ["author", "dfrn-id"],
                        "author-id" => ["post", "author-id"],
                        "author-link" => ["author", "url"],
                        "author-addr" => ["author", "addr"],
                        "parent-author-link" => ["parent-post-author", "url"],
                        "parent-author-name" => ["parent-post-author", "name"],
                        "parent-author-network" => ["parent-post-author", "network"],
+                       "parent-author-blocked" => ["parent-post-author", "blocked"],
+                       "parent-author-hidden" => ["parent-post-author", "hidden"],
                ],
                "query" => "FROM `post`
                        STRAIGHT_JOIN `post-thread` ON `post-thread`.`uri-id` = `post`.`parent-uri-id`
                        "target-type" => ["post-content", "target-type"],
                        "target" => ["post-content", "target"],
                        "resource-id" => ["post-content", "resource-id"],
+                       "contact-id" => ["post-thread", "author-id"],
+                       "contact-link" => ["author", "url"],
+                       "contact-addr" => ["author", "addr"],
+                       "contact-name" => ["author", "name"],
+                       "contact-nick" => ["author", "nick"],
+                       "contact-avatar" => ["author", "thumb"],
+                       "contact-network" => ["author", "network"],
+                       "contact-blocked" => ["author", "blocked"],
+                       "contact-hidden" => ["author", "hidden"],
+                       "contact-readonly" => ["author", "readonly"],
+                       "contact-archive" => ["author", "archive"],
+                       "contact-pending" => ["author", "pending"],
+                       "contact-rel" => ["author", "rel"],
+                       "contact-uid" => ["author", "uid"],
+                       "contact-contact-type" => ["author", "contact-type"],
+                       "writable" => "IF (`post`.`network` IN ('apub', 'dfrn', 'dspr', 'stat'), true, `author`.`writable`)",
+                       "self" => "false",
+                       "cid" => ["author", "id"],
+                       "alias" => ["author", "alias"],
+                       "photo" => ["author", "photo"],
+                       "name-date" => ["author", "name-date"],
+                       "uri-date" => ["author", "uri-date"],
+                       "avatar-date" => ["author", "avatar-date"],
+                       "thumb" => ["author", "thumb"],
+                       "dfrn-id" => ["author", "dfrn-id"],
                        "author-id" => ["post-thread", "author-id"],
                        "author-link" => ["author", "url"],
                        "author-addr" => ["author", "addr"],
                        "parent-author-link" => ["parent-post-author", "url"],
                        "parent-author-name" => ["parent-post-author", "name"],
                        "parent-author-network" => ["parent-post-author", "network"],
+                       "parent-author-blocked" => ["parent-post-author", "blocked"],
+                       "parent-author-hidden" => ["parent-post-author", "hidden"],
                ],
                "query" => "FROM `post-thread`
                        INNER JOIN `post` ON `post`.`uri-id` = `post-thread`.`uri-id`
                        "photo" => ["contact", "photo"],
                        "thumb" => ["contact", "thumb"],
                        "micro" => ["contact", "micro"],
+                       "header" => ["contact", "header"],
                        "site-pubkey" => ["contact", "site-pubkey"],
                        "issued-id" => ["contact", "issued-id"],
                        "dfrn-id" => ["contact", "dfrn-id"],