Some UI tweaks and some sqlite performance things.

git-svn-id: https://www.unprompted.com/svn/projects/tildefriends/trunk@3755 ed5197a5-7fde-0310-b194-c3ffbd925b24
This commit is contained in:
2022-01-13 00:16:27 +00:00
parent 35b7eb511a
commit 7ba1e6980f
6 changed files with 8 additions and 5 deletions

View File

@ -237,9 +237,9 @@ async function getRelatedPostIds(db, message, ids, limit) {
" rowid <= ? AND "+
" author IN (" + ids_batch.map(x => '?').join(", ") + ") AND "+
" json_extract(content, '$.type') = 'post' AND "+
" json_extract(content, '$.root') = ? "+
" (id = ? OR json_extract(content, '$.root') = ?) "+
"ORDER BY timestamp DESC LIMIT ?",
[].concat([message.timestamp, row_id_max], ids_batch, [id, limit]),
[].concat([message.timestamp, row_id_max], ids_batch, [message.id, id, limit]),
function(row) {
if (row.id) {
recent.push({id: row.id, timestamp: row.timestamp});

View File

@ -53,7 +53,7 @@ Vue.component('tf-message', {
template: `<md-app class="md-elevation-8" style="margin: 1em" v-if="!content_json || ['pub', 'vote'].indexOf(content_json.type) == -1">
<md-app-toolbar>
<h3>
<md-button class="md-icon-button" @click="show_message">
<md-button class="md-icon-button md-dense" @click="show_message">
<md-icon>percent</md-icon>
</md-button>
<tf-user :id="message.author"></tf-user>