mirror of
https://codeberg.org/streams/streams.git
synced 2024-09-20 00:55:19 +00:00
Merge branch 'dev' of /home/macgirvin/z into dev
This commit is contained in:
commit
462253d4aa
10 changed files with 4997 additions and 4891 deletions
|
@ -349,8 +349,8 @@ class Channel extends Controller {
|
||||||
'title' => 'oembed'
|
'title' => 'oembed'
|
||||||
]);
|
]);
|
||||||
|
|
||||||
if ($update && isset($_SESSION['loadtime'])) {
|
if ($update && isset($_SESSION['loadtime_channel'])) {
|
||||||
$simple_update = " AND (( item_unseen = 1 AND item.changed > '" . datetime_convert('UTC','UTC',$_SESSION['loadtime']) . "' ) OR item.changed > '" . datetime_convert('UTC','UTC',$_SESSION['loadtime']) . "' ) ";
|
$simple_update = " AND item.changed > '" . datetime_convert('UTC','UTC',$_SESSION['loadtime_channel']) . "' ";
|
||||||
}
|
}
|
||||||
if ($load) {
|
if ($load) {
|
||||||
$simple_update = '';
|
$simple_update = '';
|
||||||
|
@ -368,7 +368,6 @@ class Channel extends Controller {
|
||||||
dbesc($mid . '%'),
|
dbesc($mid . '%'),
|
||||||
intval(App::$profile['profile_uid'])
|
intval(App::$profile['profile_uid'])
|
||||||
);
|
);
|
||||||
$_SESSION['loadtime'] = datetime_convert();
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
$r = q("SELECT parent AS item_id from item
|
$r = q("SELECT parent AS item_id from item
|
||||||
|
@ -380,7 +379,6 @@ class Channel extends Controller {
|
||||||
ORDER BY created DESC",
|
ORDER BY created DESC",
|
||||||
intval(App::$profile['profile_uid'])
|
intval(App::$profile['profile_uid'])
|
||||||
);
|
);
|
||||||
$_SESSION['loadtime'] = datetime_convert();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -506,9 +506,15 @@ class Item extends Controller {
|
||||||
// if interacting with a pubstream item (owned by the sys channel),
|
// if interacting with a pubstream item (owned by the sys channel),
|
||||||
// create a copy of the parent in your stream
|
// create a copy of the parent in your stream
|
||||||
|
|
||||||
if (local_channel()) {
|
// $r may have changed. Check it again before trying to use it.
|
||||||
|
|
||||||
|
if ($r && local_channel()) {
|
||||||
|
$old_id = $r[0]['id'];
|
||||||
$r = [ copy_of_pubitem(App::get_channel(), $r[0]['mid']) ];
|
$r = [ copy_of_pubitem(App::get_channel(), $r[0]['mid']) ];
|
||||||
$pub_copy = true;
|
if ($r[0]['id'] !== $old_id) {
|
||||||
|
// keep track that a copy was made to display a special status notice that is unique to this condition
|
||||||
|
$pub_copy = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -41,7 +41,7 @@ class Siteinfo extends Controller {
|
||||||
'$transport_link' => '<a href="https://zotlabs.com">https://zotlabs.com</a>',
|
'$transport_link' => '<a href="https://zotlabs.com">https://zotlabs.com</a>',
|
||||||
|
|
||||||
'$ebs' => System::ebs(),
|
'$ebs' => System::ebs(),
|
||||||
'$additional_text' => t('Federated transport protocols:'),
|
'$additional_text' => t('Protocols:'),
|
||||||
'$additional_fed' => $federated,
|
'$additional_fed' => $federated,
|
||||||
'$prj_version' => ((get_config('system','hidden_version_siteinfo')) ? '' : sprintf( t('Version %s'), System::get_project_version())),
|
'$prj_version' => ((get_config('system','hidden_version_siteinfo')) ? '' : sprintf( t('Version %s'), System::get_project_version())),
|
||||||
'$prj_linktxt' => t('Project homepage'),
|
'$prj_linktxt' => t('Project homepage'),
|
||||||
|
|
|
@ -747,14 +747,13 @@ class Directory extends DAV\Node implements DAV\ICollection, DAV\IQuota, DAV\IMo
|
||||||
return $ret;
|
return $ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
$r = q("SELECT channel_id, channel_address FROM channel left join profile on profile.uid = channel.channel_id WHERE channel_removed = 0 AND channel_system = 0 AND (channel_pageflags & %d) = 0",
|
$r = q("SELECT channel_id, channel_address, profile.publish FROM channel left join profile on profile.uid = channel.channel_id WHERE channel_removed = 0 AND channel_system = 0 AND (channel_pageflags & %d) = 0 and profile.is_default = 1",
|
||||||
intval(PAGE_HIDDEN)
|
intval(PAGE_HIDDEN)
|
||||||
);
|
);
|
||||||
|
|
||||||
if ($r) {
|
if ($r) {
|
||||||
foreach ($r as $rr) {
|
foreach ($r as $rr) {
|
||||||
if (perm_is_allowed($rr['channel_id'], $auth->observer, 'view_storage')) {
|
if ((perm_is_allowed($rr['channel_id'], $auth->observer, 'view_storage') && $rr['publish']) || $rr['channel_id'] == $this->auth->channel_id) {
|
||||||
logger('found channel: ' . $rr['channel_address'], LOGGER_DATA);
|
logger('found channel: /cloud/' . $rr['channel_address'], LOGGER_DATA);
|
||||||
$ret[] = new Directory($rr['channel_address'], $auth);
|
$ret[] = new Directory($rr['channel_address'], $auth);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -166,7 +166,7 @@ class Zot6Handler implements IHandler {
|
||||||
dbesc($recip)
|
dbesc($recip)
|
||||||
);
|
);
|
||||||
if ($channel) {
|
if ($channel) {
|
||||||
$abook = q("select abook_id from abook where uid = %d and abook_xchan = '%s' limit 1",
|
$abook = q("select abook_id from abook where abook_channel = %d and abook_xchan = '%s' limit 1",
|
||||||
intval($channel[0]['channel_id']),
|
intval($channel[0]['channel_id']),
|
||||||
dbesc($sender)
|
dbesc($sender)
|
||||||
);
|
);
|
||||||
|
|
2
boot.php
2
boot.php
|
@ -17,7 +17,7 @@ use Zotlabs\Daemon\Run;
|
||||||
* @brief This file defines some global constants and includes the central App class.
|
* @brief This file defines some global constants and includes the central App class.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
define ( 'STD_VERSION', '21.05.28' );
|
define ( 'STD_VERSION', '21.06.02' );
|
||||||
define ( 'ZOT_REVISION', '10.0' );
|
define ( 'ZOT_REVISION', '10.0' );
|
||||||
|
|
||||||
define ( 'DB_UPDATE_VERSION', 1248 );
|
define ( 'DB_UPDATE_VERSION', 1248 );
|
||||||
|
|
File diff suppressed because it is too large
Load diff
File diff suppressed because it is too large
Load diff
|
@ -65,7 +65,6 @@
|
||||||
{{include file="field_input.tpl" field=$frontpage}}
|
{{include file="field_input.tpl" field=$frontpage}}
|
||||||
{{include file="field_checkbox.tpl" field=$mirror_frontpage}}
|
{{include file="field_checkbox.tpl" field=$mirror_frontpage}}
|
||||||
{{include file="field_checkbox.tpl" field=$login_on_homepage}}
|
{{include file="field_checkbox.tpl" field=$login_on_homepage}}
|
||||||
{{include file="field_checkbox.tpl" field=$enable_context_help}}
|
|
||||||
<div class="settings-submit-wrapper" >
|
<div class="settings-submit-wrapper" >
|
||||||
<button type="submit" name="page_site" class="btn btn-primary" value="1" >{{$submit}}</button>
|
<button type="submit" name="page_site" class="btn btn-primary" value="1" >{{$submit}}</button>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -36,8 +36,6 @@
|
||||||
|
|
||||||
<div><a href="{{$prj_src}}">{{$prj_src}}</a></div><br>
|
<div><a href="{{$prj_src}}">{{$prj_src}}</a></div><br>
|
||||||
|
|
||||||
<div>{{$prj_transport}}</div>
|
|
||||||
|
|
||||||
{{if $additional_fed}}
|
{{if $additional_fed}}
|
||||||
<div>{{$additional_text}} {{$additional_fed}}</div>
|
<div>{{$additional_text}} {{$additional_fed}}</div>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|
Loading…
Reference in a new issue