How to add new column Device list page

actually wanted to show a called last updated which tells when the device gets upgraded last time ? How does we achieve it ? what are the places the code needs to be addressed ?

Admin → Config → “Edit index page”

1 Like

Does it add in the DB as well ?

I’m not sure I understand your question.

the ask is to keep a column called Last upgraded in device list page where i have to display the devices based on last upgraded (decending order). i wanted to add a column in db in device list , so that UI will fetch the value and display it in the Device list page

You can add, remove, or change any of the columns displayed by using the Admin → Config page

1 Like

Sorry to asking you again.

My requirement is Device list page should have a column “Last upgrade”.

Last upgrade should be marked with timestamp when ACS gets Transfer Complete +M Download (where ACS feels Device gets upgraded successfully also checking with Device SW version)

Device list should show timestamp when the device upgraded last.

Below is my approach

  1. Add a entry _lastUpgrade in db as _lastInform
  2. Add the value to _lastUpgrade when ACS recieves Transfercomplete without any fault code.
  3. Device list page should fetch the value from DB as it does for _lastInform…

Can you guide me how to add an entry to DB and how to set the value to DB when ACS gets trasnfer complete event ?

if your real requirement is just to be able to see on GenieACS Web when a router was upgraded, I would look at tags:

ie: a preset and provision to be executed on DownloadComplete, and simply does something like declare( “Tags.FirmUpGraded”+TodayAsYYYYMMDD , etc, etc );

this way you won’t have to deal with databases. I’m saying this because I would not mess with MongoDB database in any way. And if you have to use a db, I’d rather use a text file via extension, informing devid and date/time

And if you have to use a db, I’d rather use a text file via extension, informing devid and date/time

  • can you explain me bit more on this

what I meant by that is that you don’t have to actually connect and couple things in order to get results. A text file or a database or even a printed page is just a result you might want to process later.

about extensions, here’s an example:

I would prefer a DB to Text files, but would not recommend using MongoDB. I would use a SQL based DB for these things. I am currently using that for provisioning data and some data aggregated from logs.

Thanks all. I have done it