mirror of
https://git.wownero.com/lza_menace/suchwow.git
synced 2024-08-15 01:03:19 +00:00
add cli command to show post details
This commit is contained in:
parent
e14131d4e2
commit
8ab985b88e
1 changed files with 9 additions and 0 deletions
|
@ -119,5 +119,14 @@ def remove_admin(username):
|
||||||
else:
|
else:
|
||||||
print("That moderator doesn't exist")
|
print("That moderator doesn't exist")
|
||||||
|
|
||||||
|
@app.cli.command("show")
|
||||||
|
@click.argument("post_id")
|
||||||
|
def post_id(post_id):
|
||||||
|
p = Post.filter(id=post_id).first()
|
||||||
|
if p:
|
||||||
|
print(p.show())
|
||||||
|
else:
|
||||||
|
print("That post doesn't exist")
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
app.run()
|
app.run()
|
||||||
|
|
Loading…
Reference in a new issue