aboutsummaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
Diffstat (limited to 'doc')
-rw-r--r--doc/hook/collect_public_recipients.bb42
-rw-r--r--doc/hook/daemon_master_release.bb5
-rw-r--r--doc/hook/privacygroup_extras.bb12
-rw-r--r--doc/hook/privacygroup_extras_drop.bb11
-rw-r--r--doc/hook/privacygroup_extras_post.bb11
-rw-r--r--doc/hooklist.bb15
6 files changed, 96 insertions, 0 deletions
diff --git a/doc/hook/collect_public_recipients.bb b/doc/hook/collect_public_recipients.bb
new file mode 100644
index 000000000..de3f4049e
--- /dev/null
+++ b/doc/hook/collect_public_recipients.bb
@@ -0,0 +1,42 @@
+[h2]collect_public_recipients[/h2]
+
+Replace the default list of public recipients (i.e., all contacts).
+
+Allow plugins to create a list of recipients for public messages instead of the default
+of all channel connections.
+
+Called with the following array:
+ [
+ 'recipients' => [],
+ 'item' => $item,
+ 'private_envelope' => $private_envelope,
+ 'include_groups' => $include_groups
+ ];
+
+[code]
+ if(array_key_exists('public_policy',$item) && $item['public_policy'] !== 'self') {
+
+ $hookinfo = [
+ 'recipients' => [],
+ 'item' => $item,
+ 'private_envelope' => $private_envelope,
+ 'include_groups' => $include_groups
+ ];
+
+ call_hooks('collect_public_recipients',$hookinfo);
+
+ if ($hookinfo['recipients']) {
+ $r = $hookinfo['recipients'];
+ } else {
+ $r = q("select abook_xchan, xchan_network from abook left join xchan on abook_xchan = xchan_hash where abook_channel = %d and abook_self = 0 and abook_pending = 0 and abook_archived = 0 ",
+ intval($item['uid'])
+ );
+ }
+
+ if($r) {
+
+ . . .
+
+[/code]
+
+see: include/item.php
diff --git a/doc/hook/daemon_master_release.bb b/doc/hook/daemon_master_release.bb
new file mode 100644
index 000000000..a17216d48
--- /dev/null
+++ b/doc/hook/daemon_master_release.bb
@@ -0,0 +1,5 @@
+[h2]daemon_master_release[/h2]
+
+Permit filtering or alternate methods of processing of background processes when [code] \Zotlabs\Daemon\Master::Release() [/code] is called.
+
+Default behavior is for a new PHP process to fire immediately upon a call to Master::Summon(). This hook permits pre-emption and the ability to provide queuing or other alternatives to this procedure.
diff --git a/doc/hook/privacygroup_extras.bb b/doc/hook/privacygroup_extras.bb
new file mode 100644
index 000000000..bd67f2470
--- /dev/null
+++ b/doc/hook/privacygroup_extras.bb
@@ -0,0 +1,12 @@
+[h2]privacygroup_extras[/h2]
+
+Add items to the Privacy Group edit form
+
+[code]
+ $hookinfo = [ 'pgrp_extras' => '', 'group'=>$argv(1) ];
+ call_hooks ('privacygroup_extras',$hookinfo);
+ $pgrp_extras = $hookinfo['pgrp_extras'];
+[/code]
+
+see: Zotlabs/Module/Group.php
+see: view/tpl/privacy_groups.tpl
diff --git a/doc/hook/privacygroup_extras_drop.bb b/doc/hook/privacygroup_extras_drop.bb
new file mode 100644
index 000000000..fd27ab255
--- /dev/null
+++ b/doc/hook/privacygroup_extras_drop.bb
@@ -0,0 +1,11 @@
+[h2]privacygroup_extras_drop[/h2]
+
+Called after privacy group is dropped
+
+[code]
+ $hookinfo = [ 'pgrp_extras' => '', 'group'=>$argv(2) ];
+ call_hooks ('privacygroup_extras_drop',$hookinfo);
+[/code]
+
+see: Zotlabs/Module/Group.php
+see: view/tpl/privacy_groups.tpl
diff --git a/doc/hook/privacygroup_extras_post.bb b/doc/hook/privacygroup_extras_post.bb
new file mode 100644
index 000000000..704db1997
--- /dev/null
+++ b/doc/hook/privacygroup_extras_post.bb
@@ -0,0 +1,11 @@
+[h2]privacygroup_extras_post[/h2]
+
+Called as privacy group edit form is edited.
+
+[code]
+ $hookinfo = [ 'pgrp_extras' => '', 'group'=>$group['id'] ];
+ call_hooks ('privacygroup_extras_post',$hookinfo);
+[/code]
+
+see: Zotlabs/Module/Group.php
+see: view/tpl/privacy_groups.tpl
diff --git a/doc/hooklist.bb b/doc/hooklist.bb
index 08fc587e2..6d56d5e71 100644
--- a/doc/hooklist.bb
+++ b/doc/hooklist.bb
@@ -136,6 +136,9 @@ Hooks allow plugins/addons to "hook into" the code at many points and alter the
[zrl=[baseurl]/help/hook/check_siteallowed]check_siteallowed[/zrl]
Used to over-ride or bypass the site black/white block lists
+[zrl=[baseurl]/help/hook/collect_public_recipients]collect_public_recipients[/zrl]
+ Used to establish a list of recipients to send a public message to.
+
[zrl=[baseurl]/help/hook/comment_buttons]comment_buttons[/zrl]
Called when rendering the edit buttons for comments
@@ -190,6 +193,9 @@ Hooks allow plugins/addons to "hook into" the code at many points and alter the
[zrl=[baseurl]/help/hook/daemon_addon]daemon_addon[/zrl]
Called when invoking the extensible background daemon
+[zrl=[baseurl]/help/hook/daemon_master_release]daemon_master_release[/zrl]
+ Called at the start of processing \Zotlabs\Daemon\Master::Release()
+
[zrl=[baseurl]/help/hook/directory_item]directory_item[/zrl]
Called when generating a directory listing for display
@@ -553,6 +559,15 @@ Hooks allow plugins/addons to "hook into" the code at many points and alter the
[zrl=[baseurl]/help/hook/prepare_body_init]prepare_body_init[/zrl]
Called before generating the HTML for a displayed conversation item
+[zrl=[baseurl]/help/hook/privacygroup_extras]privacygroup_extras[/zrl]
+ Called before generating the HTML for the Privacy Group edit options
+
+[zrl=[baseurl]/help/hook/privacygroup_extras_delete]privacygroup_extras_delete[/zrl]
+ Called after privacy group is dropped.
+
+[zrl=[baseurl]/help/hook/privacygroup_extras_post]privacygroup_extras_post[/zrl]
+ Called when privacy group edit form is submitted.
+
[zrl=[baseurl]/help/hook/proc_run]proc_run[/zrl]
Called when invoking PHP sub processes