Cleanup article render, show clickable link
This commit is contained in:
parent
32d765b482
commit
aedd52f145
1 changed files with 6 additions and 5 deletions
|
@ -689,7 +689,6 @@ class Slixfeed(slixmpp.ClientXMPP):
|
||||||
db_file = config.get_pathname_to_database(jid_file)
|
db_file = config.get_pathname_to_database(jid_file)
|
||||||
title = sqlite.get_entry_title(db_file, ix)
|
title = sqlite.get_entry_title(db_file, ix)
|
||||||
form = self['xep_0004'].make_form('result', 'Updates')
|
form = self['xep_0004'].make_form('result', 'Updates')
|
||||||
form['instructions'] = title[0] if title else 'Untitled'
|
|
||||||
url = sqlite.get_entry_url(db_file, ix)
|
url = sqlite.get_entry_url(db_file, ix)
|
||||||
if url:
|
if url:
|
||||||
url = url[0]
|
url = url[0]
|
||||||
|
@ -700,11 +699,13 @@ class Slixfeed(slixmpp.ClientXMPP):
|
||||||
else:
|
else:
|
||||||
summary = 'No content to show.'
|
summary = 'No content to show.'
|
||||||
form.add_field(ftype="text-multi",
|
form.add_field(ftype="text-multi",
|
||||||
|
label=(title[0] if title else 'Untitled'),
|
||||||
value=summary)
|
value=summary)
|
||||||
form['instructions'] = url
|
url = form.add_field(var='url',
|
||||||
form.add_field(var='url',
|
label='Link',
|
||||||
ftype='hidden',
|
ftype='text-single',
|
||||||
value=url)
|
value=url)
|
||||||
|
url['validate']['datatype'] = 'xs:anyURI'
|
||||||
form['instructions'] = 'Proceed to download article.'
|
form['instructions'] = 'Proceed to download article.'
|
||||||
session['allow_prev'] = True
|
session['allow_prev'] = True
|
||||||
session['has_next'] = True
|
session['has_next'] = True
|
||||||
|
|
Loading…
Reference in a new issue