Manipulating Data in Guild History
Hi!
I want to manipulate the Guild History View, in this case the Bank View. I already found the LibGuildHistory Lib and that helped to show all the transactions that was not visible before. Now I would like to change the "X Hours ago" Label per transaction to the real Date like 2014-12-16 10:00:00 I dont know if its possible, but i would guess that there has to be a real datetime saved per transaction. I dont even know, how to add/remove/change things in the view. I even dont get how the author of LibGuildHistory adds the old transactions to the view and how I can get a hand on the underlying table data. Maybe someone here can point me to some documentation, example code or something that helps me to get a start on how to do it? Espacially how to manipulate existing Data in the view and/or adding additional data to the view (e.g. another column with additional data) and how to access the relevant table data? Later it would be awesome if I could only show x transactions per page and have previous/next buttons to switch between pages. Or have Filter to only show transactions from the last 7 days ... thx in advance! |
It should be simple. Guild history data contains timestamp when event was received and time since event, so it is easy to get real time. You will need just to hook setup function for guild history row and change what is displayed.
Lua Code:
Now you just have to figure out how to convert GMT time to your timezone. I was thinking about something like: Lua Code:
|
Quote:
Lua Code:
As far as I have seening GetSecondsSinceMidnight() reflects your current client settings, including daylight saving. If the date you want to correct is in another daylight saving range, the correction will differ +/- one hour. |
Thank you very much for this examples. I will try this.
But where do you find this Informations? e.g. GUILD_HISTORY.SetupGuildEvent or data.secsSinceEvent? There is not much Info in the Wiki, I only find secsSinceEvent in combination with GetGuildEventInfo. Is there a better Resource for this? I dont want to bother you every time I need to find such Functions/Attributes :D |
This worked the way you wrote it. Great! Thank you ;)
|
Quote:
|
All times are GMT -6. The time now is 06:24 AM. |
vBulletin © 2024, Jelsoft Enterprises Ltd
© 2014 - 2022 MMOUI