diff options
-rw-r--r-- | Zotlabs/Daemon/Importdoc.php | 7 | ||||
-rw-r--r-- | Zotlabs/Module/Sse_bs.php | 10 | ||||
-rw-r--r-- | include/items.php | 3 | ||||
-rw-r--r-- | view/tpl/comment_item.tpl | 3 | ||||
-rw-r--r-- | view/tpl/jot.tpl | 3 |
5 files changed, 18 insertions, 8 deletions
diff --git a/Zotlabs/Daemon/Importdoc.php b/Zotlabs/Daemon/Importdoc.php index 46f96098f..de571848e 100644 --- a/Zotlabs/Daemon/Importdoc.php +++ b/Zotlabs/Daemon/Importdoc.php @@ -11,15 +11,18 @@ class Importdoc { self::update_docs_dir('doc/*'); + $sys = get_sys_channel(); + // remove old files that weren't updated (indicates they were most likely deleted). - $i = q("select id, uid from item where item_type = 5 and edited < %s - INTERVAL %s", + $i = q("select id from item where uid = %d and item_type = 5 and edited < %s - INTERVAL %s", + intval($sys['channel_id']), db_utcnow(), db_quoteinterval('14 DAY') ); if ($i) { foreach ($i as $iv) { - drop_item($iv['id'], uid: $iv['uid']); + drop_item($iv['id'], uid: $sys['channel_id']); } } diff --git a/Zotlabs/Module/Sse_bs.php b/Zotlabs/Module/Sse_bs.php index d214ba28f..5292abfaa 100644 --- a/Zotlabs/Module/Sse_bs.php +++ b/Zotlabs/Module/Sse_bs.php @@ -207,7 +207,7 @@ class Sse_bs extends Controller { $item_normal $sql_extra $sql_extra2 - ORDER BY created DESC LIMIT $limit OFFSET $offset", + ORDER BY created DESC, received DESC LIMIT $limit OFFSET $offset", intval(self::$uid), dbescdate($_SESSION['sse_loadtime']), dbesc(self::$ob_hash) @@ -290,7 +290,7 @@ class Sse_bs extends Controller { $item_normal $sql_extra $sql_extra2 - ORDER BY created DESC LIMIT $limit OFFSET $offset", + ORDER BY created DESC, received DESC LIMIT $limit OFFSET $offset", intval(self::$uid), dbescdate($_SESSION['sse_loadtime']), dbesc(self::$ob_hash) @@ -373,7 +373,7 @@ class Sse_bs extends Controller { $item_normal $sql_extra $sql_extra2 - ORDER BY created DESC LIMIT $limit OFFSET $offset", + ORDER BY created DESC, received DESC LIMIT $limit OFFSET $offset", intval(self::$uid), dbescdate($_SESSION['sse_loadtime']), dbesc(self::$ob_hash) @@ -481,7 +481,7 @@ class Sse_bs extends Controller { $sql_extra $sql_extra2 $sql_extra3 - ORDER BY created DESC LIMIT $limit OFFSET $offset", + ORDER BY created DESC, received DESC LIMIT $limit OFFSET $offset", dbescdate($_SESSION['sse_loadtime']), dbesc(self::$ob_hash), dbescdate($_SESSION['last_login_date'] ?? $_SESSION['static_loadtime']) @@ -679,7 +679,7 @@ class Sse_bs extends Controller { AND author_xchan != '%s' AND item_unseen = 1 $item_normal - ORDER BY created DESC", + ORDER BY created DESC, received DESC", dbesc(ACTIVITY_POST), intval(self::$uid), dbesc(self::$ob_hash) diff --git a/include/items.php b/include/items.php index 03a21c73d..ff683260d 100644 --- a/include/items.php +++ b/include/items.php @@ -5291,7 +5291,8 @@ function addToCollectionAndSync($ret) { } xchan_query($items); - $items = fetch_post_tags($items); + // TODO: fetch_post_tags() will add term and iconfig twice if called twice and it looks like they are already added here + // $items = fetch_post_tags($items); $sync_items = []; $sync_items[] = encode_item($items[0], true); diff --git a/view/tpl/comment_item.tpl b/view/tpl/comment_item.tpl index 76b756846..059e2793a 100644 --- a/view/tpl/comment_item.tpl +++ b/view/tpl/comment_item.tpl @@ -37,6 +37,9 @@ <button class="btn btn-outline-secondary btn-sm border-0" title="{{$edcode}}" onclick="insertbbcomment('{{$comment}}','code', {{$id}}); return false;"> <i class="bi bi-code comment-icon"></i> </button> + <button class="btn btn-outline-secondary btn-sm border-0" title="highlight" onclick="insertbbcomment('{{$comment}}','mark', {{$id}}); return false;"> + <i class="bi bi-highlighter comment-icon"></i> + </button> </div> <div class="btn-group me-2"> {{if $can_upload}} diff --git a/view/tpl/jot.tpl b/view/tpl/jot.tpl index 1cecee906..a6ec453e7 100644 --- a/view/tpl/jot.tpl +++ b/view/tpl/jot.tpl @@ -116,6 +116,9 @@ <button type="button" id="main-editor-code" class="btn btn-outline-secondary btn-sm border-0" title="{{$code}}" onclick="inserteditortag('code', 'profile-jot-text'); return false;"> <i class="bi bi-code jot-icons"></i> </button> + <button type="button" id="main-editor-bold" class="btn btn-outline-secondary btn-sm border-0" title="highlight" onclick="inserteditortag('mark', 'profile-jot-text'); return false;"> + <i class="bi bi-highlighter jot-icons"></i> + </button> </div> {{/if}} {{if $visitor}} |