mirror of
https://github.com/migatu/conjurer.git
synced 2026-07-15 14:22:13 +00:00
aaa
This commit is contained in:
@@ -2014,10 +2014,10 @@ async def wyszukaj_linki_do_dokumentow(ctx):
|
||||
resultlink = []
|
||||
for item in query_response.json():
|
||||
logger.info(item)
|
||||
resulttab.append(item["title"])
|
||||
resulttab.append(str(item["title"]))
|
||||
item_link = "https://sci-hub.se/" + str(item["DOI"])
|
||||
resultlink.append(item_link)
|
||||
for i in range(1,5):
|
||||
for i in range(1, min(5,len(resulttab))):
|
||||
query = quote_plus(resulttab[i-1])
|
||||
result_view.add_item(discord.ui.Button(label = resulttab[i-1], row = i,url=resultlink[i]))
|
||||
await ctx.send("This is a button!", view=result_view) # Send a message with our View class that contains the button
|
||||
@@ -2026,3 +2026,7 @@ async def wyszukaj_linki_do_dokumentow(ctx):
|
||||
# *================================== Run
|
||||
logger.info("Starting discord bot")
|
||||
client.run(TOKEN)
|
||||
|
||||
|
||||
#widok - generuje się 5 stron po 4 linki
|
||||
# odśwież - zamienić na "dalej" - zaciąga kolejne 20 rezultatów
|
||||
Reference in New Issue
Block a user