mirror of https://gitlab.com/bashrc2/epicyon
Less verbose
parent
b26a42d798
commit
3f38f55297
|
@ -1301,7 +1301,8 @@ def htmlNewswireModeration(baseDir: str, path: str, translate: {}) -> str:
|
||||||
url = item[1]
|
url = item[1]
|
||||||
nick = item[2]
|
nick = item[2]
|
||||||
status = item[3]
|
status = item[3]
|
||||||
postFilename = item[4].replace('/', '#')
|
postFilename = item[4]
|
||||||
|
postLink = postFilename.replace(baseDir + '/accounts', '')
|
||||||
|
|
||||||
# create the html for this post
|
# create the html for this post
|
||||||
resultStr += '<div class="container">'
|
resultStr += '<div class="container">'
|
||||||
|
@ -1320,7 +1321,7 @@ def htmlNewswireModeration(baseDir: str, path: str, translate: {}) -> str:
|
||||||
|
|
||||||
resultStr += \
|
resultStr += \
|
||||||
'<a href="' + basePath + \
|
'<a href="' + basePath + \
|
||||||
'/newswireapprove=' + postFilename + '">'
|
'/newswireapprove=' + postLink + '">'
|
||||||
if '[vote:' + nickname + ':approve]' in status:
|
if '[vote:' + nickname + ':approve]' in status:
|
||||||
resultStr += \
|
resultStr += \
|
||||||
'<button class="followApprove">' + \
|
'<button class="followApprove">' + \
|
||||||
|
@ -1332,7 +1333,7 @@ def htmlNewswireModeration(baseDir: str, path: str, translate: {}) -> str:
|
||||||
|
|
||||||
resultStr += \
|
resultStr += \
|
||||||
'<a href="' + basePath + \
|
'<a href="' + basePath + \
|
||||||
'/newswiredeny=' + postFilename + '">'
|
'/newswiredeny=' + postLink + '">'
|
||||||
if '[vote:' + nickname + ':deny]' in status:
|
if '[vote:' + nickname + ':deny]' in status:
|
||||||
resultStr += \
|
resultStr += \
|
||||||
'<button class="followApprove">' + \
|
'<button class="followApprove">' + \
|
||||||
|
@ -1344,10 +1345,15 @@ def htmlNewswireModeration(baseDir: str, path: str, translate: {}) -> str:
|
||||||
|
|
||||||
resultStr += \
|
resultStr += \
|
||||||
'<a href="' + basePath + \
|
'<a href="' + basePath + \
|
||||||
'/newswirediscuss=' + postFilename + '">'
|
'/newswirediscuss=' + postLink + '">'
|
||||||
resultStr += \
|
if os.path.isfile(postFilename + '.discuss'):
|
||||||
'<button class="followDeny">' + \
|
resultStr += \
|
||||||
translate['Discuss'] + '</button></a>'
|
'<button class="followApprove">' + \
|
||||||
|
translate['Discuss'] + '</button></a>'
|
||||||
|
else:
|
||||||
|
resultStr += \
|
||||||
|
'<button class="followDeny">' + \
|
||||||
|
translate['Discuss'] + '</button></a>'
|
||||||
resultStr += '</div>'
|
resultStr += '</div>'
|
||||||
return resultStr
|
return resultStr
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue