better-named param

master
Aevann 2024-11-13 04:21:12 +02:00
parent 87d08d3acd
commit 1c76af00e8
2 changed files with 3 additions and 3 deletions

View File

@ -19,7 +19,7 @@ valid_params = [
'post', 'post',
'before', 'before',
'after', 'after',
'title', 'title_only',
'sentto', 'sentto',
'hole', 'hole',
'subreddit', 'subreddit',
@ -101,7 +101,7 @@ def searchposts(v):
if 'q' in criteria: if 'q' in criteria:
params = [Post.title] params = [Post.title]
if 'title' not in criteria: if 'title_only' not in criteria:
params += [Post.body, Post.url, Post.embed] params += [Post.body, Post.url, Post.embed]
words = [] words = []

View File

@ -71,7 +71,7 @@
</div> </div>
<div> <div>
<div style="display: inline-block; width: 150px; text-align: center">Post Title Only:</div> <div style="display: inline-block; width: 150px; text-align: center">Post Title Only:</div>
<button type="button" data-nonce="{{g.nonce}}" data-onclick="addParam(this, 'bool')" class="searchparam mb-1">title:true</button> <button type="button" data-nonce="{{g.nonce}}" data-onclick="addParam(this, 'bool')" class="searchparam mb-1">title_only:true</button>
</div> </div>
{% if SITE_NAME != 'WPD' %} {% if SITE_NAME != 'WPD' %}
<div> <div>